QuantLib: a free/open-source library for quantitative finance
fully annotated source code - version 1.34
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
Fdm3DimSolver Class Reference

#include <fdm3dimsolver.hpp>

+ Inheritance diagram for Fdm3DimSolver:
+ Collaboration diagram for Fdm3DimSolver:

Public Member Functions

 Fdm3DimSolver (const FdmSolverDesc &solverDesc, const FdmSchemeDesc &schemeDesc, ext::shared_ptr< FdmLinearOpComposite > op)
 
void performCalculations () const override
 
Real interpolateAt (Real x, Real y, Rate z) const
 
Real thetaAt (Real x, Real y, Rate z) const
 
- Public Member Functions inherited from LazyObject
 LazyObject ()
 
 ~LazyObject () override=default
 
void update () override
 
bool isCalculated () const
 
void forwardFirstNotificationOnly ()
 
void alwaysForwardNotifications ()
 
void recalculate ()
 
void freeze ()
 
void unfreeze ()
 
- Public Member Functions inherited from Observable
 Observable ()
 
 Observable (const Observable &)
 
Observableoperator= (const Observable &)
 
 Observable (Observable &&)=delete
 
Observableoperator= (Observable &&)=delete
 
virtual ~Observable ()=default
 
void notifyObservers ()
 
- Public Member Functions inherited from Observer
 Observer ()=default
 
 Observer (const Observer &)
 
Observeroperator= (const Observer &)
 
virtual ~Observer ()
 
std::pair< iterator, boolregisterWith (const ext::shared_ptr< Observable > &)
 
void registerWithObservables (const ext::shared_ptr< Observer > &)
 
Size unregisterWith (const ext::shared_ptr< Observable > &)
 
void unregisterWithAll ()
 
virtual void update ()=0
 
virtual void deepUpdate ()
 

Private Attributes

const FdmSolverDesc solverDesc_
 
const FdmSchemeDesc schemeDesc_
 
const ext::shared_ptr< FdmLinearOpCompositeop_
 
const ext::shared_ptr< FdmSnapshotConditionthetaCondition_
 
const ext::shared_ptr< FdmStepConditionCompositeconditions_
 
std::vector< Realx_
 
std::vector< Realy_
 
std::vector< Realz_
 
std::vector< RealinitialValues_
 
std::vector< MatrixresultValues_
 
std::vector< ext::shared_ptr< BicubicSpline > > interpolation_
 

Additional Inherited Members

- Public Types inherited from Observer
typedef set_type::iterator iterator
 
- Protected Member Functions inherited from LazyObject
virtual void calculate () const
 
- Protected Attributes inherited from LazyObject
bool calculated_ = false
 
bool frozen_ = false
 
bool alwaysForward_
 

Detailed Description

Definition at line 37 of file fdm3dimsolver.hpp.

Constructor & Destructor Documentation

◆ Fdm3DimSolver()

Fdm3DimSolver ( const FdmSolverDesc solverDesc,
const FdmSchemeDesc schemeDesc,
ext::shared_ptr< FdmLinearOpComposite op 
)

Definition at line 33 of file fdm3dimsolver.cpp.

Member Function Documentation

◆ performCalculations()

void performCalculations ( ) const
overridevirtual

This method must implement any calculations which must be (re)done in order to calculate the desired results.

Implements LazyObject.

Definition at line 71 of file fdm3dimsolver.cpp.

+ Here is the call graph for this function:

◆ interpolateAt()

Real interpolateAt ( Real  x,
Real  y,
Rate  z 
) const

Definition at line 90 of file fdm3dimsolver.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ thetaAt()

Real thetaAt ( Real  x,
Real  y,
Rate  z 
) const

Definition at line 101 of file fdm3dimsolver.cpp.

+ Here is the call graph for this function:

Member Data Documentation

◆ solverDesc_

const FdmSolverDesc solverDesc_
private

Definition at line 49 of file fdm3dimsolver.hpp.

◆ schemeDesc_

const FdmSchemeDesc schemeDesc_
private

Definition at line 50 of file fdm3dimsolver.hpp.

◆ op_

const ext::shared_ptr<FdmLinearOpComposite> op_
private

Definition at line 51 of file fdm3dimsolver.hpp.

◆ thetaCondition_

const ext::shared_ptr<FdmSnapshotCondition> thetaCondition_
private

Definition at line 53 of file fdm3dimsolver.hpp.

◆ conditions_

const ext::shared_ptr<FdmStepConditionComposite> conditions_
private

Definition at line 54 of file fdm3dimsolver.hpp.

◆ x_

std::vector<Real> x_
private

Definition at line 56 of file fdm3dimsolver.hpp.

◆ y_

std::vector<Real> y_
private

Definition at line 56 of file fdm3dimsolver.hpp.

◆ z_

std::vector<Real> z_
private

Definition at line 56 of file fdm3dimsolver.hpp.

◆ initialValues_

std::vector<Real> initialValues_
private

Definition at line 56 of file fdm3dimsolver.hpp.

◆ resultValues_

std::vector<Matrix> resultValues_
mutableprivate

Definition at line 57 of file fdm3dimsolver.hpp.

◆ interpolation_

std::vector<ext::shared_ptr<BicubicSpline> > interpolation_
mutableprivate

Definition at line 58 of file fdm3dimsolver.hpp.