QuantLib: a free/open-source library for quantitative finance
Fully annotated sources - version 1.32
Loading...
Searching...
No Matches
capletcoterminalmaxhomogeneity.hpp
1/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2
3/*
4 Copyright (C) 2007 Ferdinando Ametrano
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#ifndef quantlib_ctsmm_caplet_calibration_max_homogeneity_hpp
22#define quantlib_ctsmm_caplet_calibration_max_homogeneity_hpp
23
24#include <ql/models/marketmodels/models/ctsmmcapletcalibration.hpp>
25
26namespace QuantLib {
27
29 public:
31 const EvolutionDescription& evolution,
32 const ext::shared_ptr<PiecewiseConstantCorrelation>& corr,
33 const std::vector<ext::shared_ptr<
35 displacedSwapVariances,
36 const std::vector<Volatility>& capletVols,
37 const ext::shared_ptr<CurveState>& cs,
38 Spread displacement,
39 Real caplet0Swaption1Priority = 1.0);
40
41 // actual calibration function
43 const EvolutionDescription& evolution,
45 const std::vector<ext::shared_ptr<PiecewiseConstantVariance> >& displacedSwapVariances,
46 const std::vector<Volatility>& capletVols,
47 const CurveState& cs,
48 Spread displacement,
49 Real caplet0Swaption1Priority,
50 Size numberOfFactors,
51 Size maxIterations,
52 Real tolerance,
54 Real& totalSwaptionError, // ?
55 std::vector<Matrix>& swapCovariancePseudoRoots); // the thing we really want the pseudo
56 // root for each time step
57
58 private:
60 calibrationImpl_(Natural numberOfFactors, Natural maxIterations, Real tolerance) override;
61 // input
63 // results
65 };
66
67}
68
69#endif
static Natural capletMaxHomogeneityCalibration(const EvolutionDescription &evolution, const PiecewiseConstantCorrelation &corr, const std::vector< ext::shared_ptr< PiecewiseConstantVariance > > &displacedSwapVariances, const std::vector< Volatility > &capletVols, const CurveState &cs, Spread displacement, Real caplet0Swaption1Priority, Size numberOfFactors, Size maxIterations, Real tolerance, Real &deformationSize, Real &totalSwaptionError, std::vector< Matrix > &swapCovariancePseudoRoots)
Natural calibrationImpl_(Natural numberOfFactors, Natural maxIterations, Real tolerance) override
Curve state for market-model simulations
Definition: curvestate.hpp:41
Market-model evolution description.
QL_REAL Real
real number
Definition: types.hpp:50
unsigned QL_INTEGER Natural
positive integer
Definition: types.hpp:43
Real Spread
spreads on interest rates
Definition: types.hpp:74
std::size_t Size
size of a container
Definition: types.hpp:58
Definition: any.hpp:35