QuantLib: a free/open-source library for quantitative finance
Fully annotated sources - version 1.32
Loading...
Searching...
No Matches
analytich1hwengine.hpp
1/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2
3/*
4 Copyright (C) 2012 Klaus Spanderen
5
6 This file is part of QuantLib, a free-software/open-source library
7 for financial quantitative analysts and developers - http://quantlib.org/
8
9 QuantLib is free software: you can redistribute it and/or modify it
10 under the terms of the QuantLib license. You should have received a
11 copy of the license along with this program; if not, please email
12 <quantlib-dev@lists.sf.net>. The license is also available online at
13 <http://quantlib.org/license.shtml>.
14
15 This program is distributed in the hope that it will be useful, but WITHOUT
16 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
17 FOR A PARTICULAR PURPOSE. See the license for more details.
18*/
19
24#ifndef quantlib_analytic_h1_hw_engine_hpp
25#define quantlib_analytic_h1_hw_engine_hpp
26
27#include <ql/models/equity/hestonmodel.hpp>
28#include <ql/models/shortrate/onefactormodels/hullwhite.hpp>
29#include <ql/pricingengines/vanilla/analytichestonhullwhiteengine.hpp>
30
31namespace QuantLib {
32
34
69 public:
70 AnalyticH1HWEngine(const ext::shared_ptr<HestonModel>& model,
71 const ext::shared_ptr<HullWhite>& hullWhiteModel,
72 Real rhoSr, Size integrationOrder = 144);
73
74 AnalyticH1HWEngine(const ext::shared_ptr<HestonModel>& model,
75 const ext::shared_ptr<HullWhite>& hullWhiteModel,
76 Real rhoSr, Real relTolerance, Size maxEvaluations);
77
78 protected:
79 std::complex<Real> addOnTerm(Real phi, Time t, Size j) const override;
80
81 private:
82 class Fj_Helper;
83
84 const Real rhoSr_;
85 };
86}
87
88#endif
Analytic Heston-Hull-White engine based on the H1-HW approximation.
std::complex< Real > addOnTerm(Real phi, Time t, Size j) const override
Analytic Heston engine incl. stochastic interest rates.
Real Time
continuous quantity with 1-year units
Definition: types.hpp:62
QL_REAL Real
real number
Definition: types.hpp:50
std::size_t Size
size of a container
Definition: types.hpp:58
Definition: any.hpp:35