Logo
Fully annotated reference manual - version 1.8.12
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
MultiPathGeneratorBurley2020Sobol Class Reference

Instantiation of MultiPathGenerator with standard LowDiscrepancy traits. More...

#include <qle/methods/multipathgeneratorbase.hpp>

+ Inheritance diagram for MultiPathGeneratorBurley2020Sobol:
+ Collaboration diagram for MultiPathGeneratorBurley2020Sobol:

Public Member Functions

 MultiPathGeneratorBurley2020Sobol (const QuantLib::ext::shared_ptr< StochasticProcess > &, const TimeGrid &, BigNatural seed=42, SobolRsg::DirectionIntegers directionIntegers=SobolRsg::JoeKuoD7, BigNatural scrambleSeed=43)
 
const Sample< MultiPath > & next () const override
 
void reset () override
 
- Public Member Functions inherited from MultiPathGeneratorBase
virtual ~MultiPathGeneratorBase ()
 
virtual const Sample< MultiPath > & next () const =0
 
virtual void reset ()=0
 

Private Attributes

const QuantLib::ext::shared_ptr< StochasticProcessprocess_
 
TimeGrid grid_
 
BigNatural seed_
 
SobolRsg::DirectionIntegers directionIntegers_
 
BigNatural scrambleSeed_
 
QuantLib::ext::shared_ptr< MultiPathGenerator< InverseCumulativeRsg< Burley2020SobolRsg, InverseCumulativeNormal > > > pg_
 
QuantLib::ext::shared_ptr< PathGenerator< InverseCumulativeRsg< Burley2020SobolRsg, InverseCumulativeNormal > > > pg1D_
 
Sample< MultiPath > next_
 

Detailed Description

Instantiation of MultiPathGenerator with standard LowDiscrepancy traits.

no Brownian bridge provided, use MultiPathGeneratorSobolBrownianBridge for this, for the use of the seed, see ql/math/randomnumbers/sobolrsg.cpp

\ingroup methods

Definition at line 115 of file multipathgeneratorbase.hpp.

Constructor & Destructor Documentation

◆ MultiPathGeneratorBurley2020Sobol()

MultiPathGeneratorBurley2020Sobol ( const QuantLib::ext::shared_ptr< StochasticProcess > &  process,
const TimeGrid &  grid,
BigNatural  seed = 42,
SobolRsg::DirectionIntegers  directionIntegers = SobolRsg::JoeKuoD7,
BigNatural  scrambleSeed = 43 
)

Definition at line 96 of file multipathgeneratorbase.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ next()

const Sample< MultiPath > & next ( ) const
overridevirtual

Implements MultiPathGeneratorBase.

Definition at line 121 of file multipathgeneratorbase.cpp.

121 {
122 if (pg_)
123 return pg_->next();
124 else {
125 next_.value.at(0) = pg1D_->next().value;
126 return next_;
127 }
128}
QuantLib::ext::shared_ptr< MultiPathGenerator< InverseCumulativeRsg< Burley2020SobolRsg, InverseCumulativeNormal > > > pg_
QuantLib::ext::shared_ptr< PathGenerator< InverseCumulativeRsg< Burley2020SobolRsg, InverseCumulativeNormal > > > pg1D_

◆ reset()

void reset ( )
overridevirtual

Implements MultiPathGeneratorBase.

Definition at line 105 of file multipathgeneratorbase.cpp.

105 {
106 if (auto tmp = QuantLib::ext::dynamic_pointer_cast<StochasticProcess1D>(process_)) {
107 pg1D_ = QuantLib::ext::make_shared<PathGenerator<InverseCumulativeRsg<Burley2020SobolRsg, InverseCumulativeNormal>>>(
108 tmp, grid_,
109 InverseCumulativeRsg<Burley2020SobolRsg, InverseCumulativeNormal>(
110 Burley2020SobolRsg(process_->factors() * (grid_.size() - 1), seed_, directionIntegers_, scrambleSeed_)),
111 false);
112
113 } else {
114 pg_ = QuantLib::ext::make_shared<MultiPathGenerator<InverseCumulativeRsg<Burley2020SobolRsg, InverseCumulativeNormal>>>(
116 InverseCumulativeRsg<Burley2020SobolRsg, InverseCumulativeNormal>(Burley2020SobolRsg(
117 process_->factors() * (grid_.size() - 1), seed_, directionIntegers_, scrambleSeed_)));
118 }
119}
+ Here is the caller graph for this function:

Member Data Documentation

◆ process_

const QuantLib::ext::shared_ptr<StochasticProcess> process_
private

Definition at line 125 of file multipathgeneratorbase.hpp.

◆ grid_

TimeGrid grid_
private

Definition at line 126 of file multipathgeneratorbase.hpp.

◆ seed_

BigNatural seed_
private

Definition at line 127 of file multipathgeneratorbase.hpp.

◆ directionIntegers_

SobolRsg::DirectionIntegers directionIntegers_
private

Definition at line 128 of file multipathgeneratorbase.hpp.

◆ scrambleSeed_

BigNatural scrambleSeed_
private

Definition at line 129 of file multipathgeneratorbase.hpp.

◆ pg_

QuantLib::ext::shared_ptr<MultiPathGenerator<InverseCumulativeRsg<Burley2020SobolRsg, InverseCumulativeNormal> > > pg_
private

Definition at line 131 of file multipathgeneratorbase.hpp.

◆ pg1D_

QuantLib::ext::shared_ptr<PathGenerator<InverseCumulativeRsg<Burley2020SobolRsg, InverseCumulativeNormal> > > pg1D_
private

Definition at line 132 of file multipathgeneratorbase.hpp.

◆ next_

Sample<MultiPath> next_
mutableprivate

Definition at line 133 of file multipathgeneratorbase.hpp.