Approximate the boundary condition basing on asset spot price. More...

#include <spotRelatedRange.hpp>

Inheritance diagram for marian::SpotRelatedRange:
marian::DCRangeSetup< SpotRelatedRange > marian::RangeSetup

Public Member Functions

 SpotRelatedRange ()
 Defualt constructor. More...
 
 SpotRelatedRange (double low, double up)
 Constructor. More...
 
double getUpperBound (Market mkt, SmartPointer< Option >) const override
 returns upper boundary value More...
 
double getLowerBound (Market mkt, SmartPointer< Option >) const override
 returns lower boundary value More...
 
virtual ~SpotRelatedRange ()
 Destructor.
 
- Public Member Functions inherited from marian::DCRangeSetup< SpotRelatedRange >
virtual RangeSetupclone () const
 Virtual copy constructor.
 
- Public Member Functions inherited from marian::RangeSetup
virtual ~RangeSetup ()
 Destructor.
 

Private Attributes

double low_
 Multiplier for lower boundary.
 
double up_
 Multiplier for upper boundary.
 

Detailed Description

For some options the boundary conditions need to be set in the infinity. When we use numerical routines we must approximate this conditions with finite values. Using this class the spot range is set relatively to the spot price. When object of this class is constructed, the two multipliers low and upp are used. The lower boundary is approximated $\lim_{S \to 0} V(lS_t,t) = a \Rightarrow \lim_{x \to low*S} V(S_t,t) = a.$. The upper boundary is approximated $\lim_{S \to \infty} V(lS_t,t) = a \Rightarrow \lim_{x \to upp*S} V(S_t,t) = a.$.

Examples:
convergenceExample.cpp, and EuroOptExample.cpp.

Constructor & Destructor Documentation

marian::SpotRelatedRange::SpotRelatedRange ( )
inline

Sets low to 0.5 and up to 2.0 by default

marian::SpotRelatedRange::SpotRelatedRange ( double  low,
double  up 
)
inline
Parameters
lowMultiplier for lower boundary
upMultiplier for upper boundary

Member Function Documentation

double marian::SpotRelatedRange::getLowerBound ( Market  mkt,
SmartPointer< Option  
) const
inlineoverridevirtual
Returns
Spot multiplied by lower boundary multiplier

Implements marian::RangeSetup.

double marian::SpotRelatedRange::getUpperBound ( Market  mkt,
SmartPointer< Option  
) const
inlineoverridevirtual
Returns
Spot multiplied by upper boundary multiplier

Implements marian::RangeSetup.


The documentation for this class was generated from the following file: