QuantLib: a free/open-source library for quantitative finance
Fully annotated sources - version 1.32
Loading...
Searching...
No Matches
Public Member Functions | List of all members
LogNormalFwdRateEulerConstrained Class Reference

euler stepping More...

#include <ql/models/marketmodels/evolvers/lognormalfwdrateeulerconstrained.hpp>

+ Inheritance diagram for LogNormalFwdRateEulerConstrained:
+ Collaboration diagram for LogNormalFwdRateEulerConstrained:

Public Member Functions

 LogNormalFwdRateEulerConstrained (const ext::shared_ptr< MarketModel > &, const BrownianGeneratorFactory &, const std::vector< Size > &numeraires, Size initialStep=0)
 
MarketModelConstrained interface
void setConstraintType (const std::vector< Size > &startIndexOfSwapRate, const std::vector< Size > &endIndexOfSwapRate) override
 call once More...
 
void setThisConstraint (const std::vector< Rate > &rateConstraints, const std::valarray< bool > &isConstraintActive) override
 call before each path More...
 
- Public Member Functions inherited from ConstrainedEvolver
 ~ConstrainedEvolver () override=default
 
virtual void setConstraintType (const std::vector< Size > &startIndexOfSwapRate, const std::vector< Size > &EndIndexOfSwapRate)=0
 call once More...
 
virtual void setThisConstraint (const std::vector< Rate > &rateConstraints, const std::valarray< bool > &isConstraintActive)=0
 call before each path More...
 
- Public Member Functions inherited from MarketModelEvolver
virtual ~MarketModelEvolver ()=default
 
virtual const std::vector< Size > & numeraires () const =0
 
virtual Real startNewPath ()=0
 
virtual Real advanceStep ()=0
 
virtual Size currentStep () const =0
 
virtual const CurveStatecurrentState () const =0
 
virtual void setInitialState (const CurveState &)=0
 

MarketModel interface

ext::shared_ptr< MarketModelmarketModel_
 
std::vector< Sizenumeraires_
 
Size initialStep_
 
ext::shared_ptr< BrownianGeneratorgenerator_
 
std::vector< SizestartIndexOfSwapRate_
 
std::vector< SizeendIndexOfSwapRate_
 
std::vector< RaterateConstraints_
 
std::valarray< boolisConstraintActive_
 
std::vector< std::vector< Real > > fixedDrifts_
 
std::vector< std::vector< Real > > variances_
 
std::vector< std::vector< Real > > covariances_
 
Size numberOfRates_
 
Size numberOfFactors_
 
LMMCurveState curveState_
 
Size currentStep_
 
std::vector< Rateforwards_
 
std::vector< Ratedisplacements_
 
std::vector< RatelogForwards_
 
std::vector< RateinitialLogForwards_
 
std::vector< Realdrifts1_
 
std::vector< RealinitialDrifts_
 
std::vector< Realbrownians_
 
std::vector< RealcorrelatedBrownians_
 
std::vector< Sizealive_
 
std::vector< LMMDriftCalculatorcalculators_
 
const std::vector< Size > & numeraires () const override
 
Real startNewPath () override
 
Real advanceStep () override
 
Size currentStep () const override
 
const CurveStatecurrentState () const override
 
void setInitialState (const CurveState &) override
 
void setForwards (const std::vector< Real > &forwards)
 

Detailed Description

euler stepping

Definition at line 37 of file lognormalfwdrateeulerconstrained.hpp.

Constructor & Destructor Documentation

◆ LogNormalFwdRateEulerConstrained()

LogNormalFwdRateEulerConstrained ( const ext::shared_ptr< MarketModel > &  marketModel,
const BrownianGeneratorFactory factory,
const std::vector< Size > &  numeraires,
Size  initialStep = 0 
)

Definition at line 31 of file lognormalfwdrateeulerconstrained.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ setConstraintType()

void setConstraintType ( const std::vector< Size > &  startIndexOfSwapRate,
const std::vector< Size > &  EndIndexOfSwapRate 
)
overridevirtual

call once

Implements ConstrainedEvolver.

Definition at line 97 of file lognormalfwdrateeulerconstrained.cpp.

◆ setThisConstraint()

void setThisConstraint ( const std::vector< Rate > &  rateConstraints,
const std::valarray< bool > &  isConstraintActive 
)
overridevirtual

call before each path

Implements ConstrainedEvolver.

Definition at line 131 of file lognormalfwdrateeulerconstrained.cpp.

◆ numeraires()

const std::vector< Size > & numeraires ( ) const
overridevirtual

Implements MarketModelEvolver.

Definition at line 79 of file lognormalfwdrateeulerconstrained.cpp.

+ Here is the caller graph for this function:

◆ startNewPath()

Real startNewPath ( )
overridevirtual

Implements MarketModelEvolver.

Definition at line 150 of file lognormalfwdrateeulerconstrained.cpp.

◆ advanceStep()

Real advanceStep ( )
overridevirtual

Implements MarketModelEvolver.

Definition at line 157 of file lognormalfwdrateeulerconstrained.cpp.

+ Here is the call graph for this function:

◆ currentStep()

Size currentStep ( ) const
overridevirtual

Implements MarketModelEvolver.

Definition at line 226 of file lognormalfwdrateeulerconstrained.cpp.

◆ currentState()

const CurveState & currentState ( ) const
overridevirtual

Implements MarketModelEvolver.

Definition at line 230 of file lognormalfwdrateeulerconstrained.cpp.

◆ setInitialState()

void setInitialState ( const CurveState cs)
overridevirtual

Implements MarketModelEvolver.

Definition at line 93 of file lognormalfwdrateeulerconstrained.cpp.

+ Here is the call graph for this function:

◆ setForwards()

void setForwards ( const std::vector< Real > &  forwards)
private

Definition at line 83 of file lognormalfwdrateeulerconstrained.cpp.

+ Here is the caller graph for this function:

Member Data Documentation

◆ marketModel_

ext::shared_ptr<MarketModel> marketModel_
private

Definition at line 63 of file lognormalfwdrateeulerconstrained.hpp.

◆ numeraires_

std::vector<Size> numeraires_
private

Definition at line 64 of file lognormalfwdrateeulerconstrained.hpp.

◆ initialStep_

Size initialStep_
private

Definition at line 65 of file lognormalfwdrateeulerconstrained.hpp.

◆ generator_

ext::shared_ptr<BrownianGenerator> generator_
private

Definition at line 66 of file lognormalfwdrateeulerconstrained.hpp.

◆ startIndexOfSwapRate_

std::vector<Size> startIndexOfSwapRate_
private

Definition at line 68 of file lognormalfwdrateeulerconstrained.hpp.

◆ endIndexOfSwapRate_

std::vector<Size> endIndexOfSwapRate_
private

Definition at line 69 of file lognormalfwdrateeulerconstrained.hpp.

◆ rateConstraints_

std::vector<Rate> rateConstraints_
private

Definition at line 72 of file lognormalfwdrateeulerconstrained.hpp.

◆ isConstraintActive_

std::valarray<bool> isConstraintActive_
private

Definition at line 73 of file lognormalfwdrateeulerconstrained.hpp.

◆ fixedDrifts_

std::vector<std::vector<Real> > fixedDrifts_
private

Definition at line 76 of file lognormalfwdrateeulerconstrained.hpp.

◆ variances_

std::vector<std::vector<Real> > variances_
private

Definition at line 77 of file lognormalfwdrateeulerconstrained.hpp.

◆ covariances_

std::vector<std::vector<Real> > covariances_
private

Definition at line 80 of file lognormalfwdrateeulerconstrained.hpp.

◆ numberOfRates_

Size numberOfRates_
private

Definition at line 82 of file lognormalfwdrateeulerconstrained.hpp.

◆ numberOfFactors_

Size numberOfFactors_
private

Definition at line 82 of file lognormalfwdrateeulerconstrained.hpp.

◆ curveState_

LMMCurveState curveState_
private

Definition at line 83 of file lognormalfwdrateeulerconstrained.hpp.

◆ currentStep_

Size currentStep_
private

Definition at line 84 of file lognormalfwdrateeulerconstrained.hpp.

◆ forwards_

std::vector<Rate> forwards_
private

Definition at line 85 of file lognormalfwdrateeulerconstrained.hpp.

◆ displacements_

std::vector<Rate> displacements_
private

Definition at line 85 of file lognormalfwdrateeulerconstrained.hpp.

◆ logForwards_

std::vector<Rate> logForwards_
private

Definition at line 85 of file lognormalfwdrateeulerconstrained.hpp.

◆ initialLogForwards_

std::vector<Rate> initialLogForwards_
private

Definition at line 85 of file lognormalfwdrateeulerconstrained.hpp.

◆ drifts1_

std::vector<Real> drifts1_
private

Definition at line 86 of file lognormalfwdrateeulerconstrained.hpp.

◆ initialDrifts_

std::vector<Real> initialDrifts_
private

Definition at line 86 of file lognormalfwdrateeulerconstrained.hpp.

◆ brownians_

std::vector<Real> brownians_
private

Definition at line 87 of file lognormalfwdrateeulerconstrained.hpp.

◆ correlatedBrownians_

std::vector<Real> correlatedBrownians_
private

Definition at line 87 of file lognormalfwdrateeulerconstrained.hpp.

◆ alive_

std::vector<Size> alive_
private

Definition at line 88 of file lognormalfwdrateeulerconstrained.hpp.

◆ calculators_

std::vector<LMMDriftCalculator> calculators_
private

Definition at line 90 of file lognormalfwdrateeulerconstrained.hpp.