QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.34
Loading...
Searching...
No Matches
capletcoterminalperiodic.hpp
Go to the documentation of this file.
1/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2
3/*
4
5 Copyright (C) 2007 Mark Joshi
6
7 This file is part of QuantLib, a free-software/open-source library
8 for financial quantitative analysts and developers - http://quantlib.org/
9
10 QuantLib is free software: you can redistribute it and/or modify it
11 under the terms of the QuantLib license. You should have received a
12 copy of the license along with this program; if not, please email
13 <quantlib-dev@lists.sf.net>. The license is also available online at
14 <http://quantlib.org/license.shtml>.
15
16 This program is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
18 FOR A PARTICULAR PURPOSE. See the license for more details.
19*/
20
21
22#ifndef quantlib_ctsmm_caplet_calibration_periodic_hpp
23#define quantlib_ctsmm_caplet_calibration_periodic_hpp
24
25
28#include <ql/math/matrix.hpp>
32#include <ql/shared_ptr.hpp>
33#include <vector>
34
35namespace QuantLib {
36
37
39 const EvolutionDescription& evolution,
40 const ext::shared_ptr<PiecewiseConstantCorrelation>& corr,
41 VolatilityInterpolationSpecifier& displacedSwapVariances,
42 const std::vector<Volatility>& capletVols,
43 const ext::shared_ptr<CurveState>& cs,
44 Spread displacement,
45 Real caplet0Swaption1Priority,
46 Size numberOfFactors,
47 Size period,
48 Size max1dIterations,
49 Real tolerance1d,
50 Size maxUnperiodicIterations,
51 Real toleranceUnperiodic,
52 Size maxPeriodIterations,
53 Real periodTolerance,
54 Real& deformationSize, // used to return information, not set yet
55 Real& totalSwaptionError, // ?
56 std::vector<Matrix>& swapCovariancePseudoRoots, // the thing we really want the pseudo root
57 // for each time step
58 std::vector<Real>& finalScales, // scalings used for matching
59 Size& iterationsDone, // number of period iteratations done
60 Real& errorImprovement, // improvement in error for last iteration
61 Matrix&
62 modelSwaptionVolsMatrix // the swaption vols calibrated to at each step of the iteration
63 );
64}
65
66#endif
QL_REAL Real
real number
Definition: types.hpp:50
QL_INTEGER Integer
integer number
Definition: types.hpp:35
Real Spread
spreads on interest rates
Definition: types.hpp:74
std::size_t Size
size of a container
Definition: types.hpp:58
matrix used in linear algebra.
Definition: any.hpp:35
Integer capletSwaptionPeriodicCalibration(const EvolutionDescription &evolution, const ext::shared_ptr< PiecewiseConstantCorrelation > &corr, VolatilityInterpolationSpecifier &displacedSwapVariances, const std::vector< Volatility > &capletVols, const ext::shared_ptr< CurveState > &cs, const Spread displacement, Real caplet0Swaption1Priority, Size numberOfFactors, Size period, Size max1dIterations, Real tolerance1d, Size maxUnperiodicIterations, Real toleranceUnperiodic, Size maxPeriodIterations, Real periodTolerance, Real &, Real &totalSwaptionError, std::vector< Matrix > &swapCovariancePseudoRoots, std::vector< Real > &finalScales, Size &iterationsDone, Real &errorImprovement, Matrix &modelSwaptionVolsMatrix)
Maps shared_ptr to either the boost or std implementation.