Builds Wiener process paths using Gaussian variates. More...
#include <ql/methods/montecarlo/brownianbridge.hpp>
Public Member Functions | |
BrownianBridge (Size steps) | |
BrownianBridge (const std::vector< Time > ×) | |
BrownianBridge (const TimeGrid &timeGrid) | |
inspectors | |
Size | size () const |
const std::vector< Time > & | times () const |
const std::vector< Size > & | bridgeIndex () const |
const std::vector< Size > & | leftIndex () const |
const std::vector< Size > & | rightIndex () const |
const std::vector< Real > & | leftWeight () const |
const std::vector< Real > & | rightWeight () const |
const std::vector< Real > & | stdDeviation () const |
template<class RandomAccessIterator1 , class RandomAccessIterator2 > | |
void | transform (RandomAccessIterator1 begin, RandomAccessIterator1 end, RandomAccessIterator2 output) const |
Brownian-bridge generator function. More... | |
Builds Wiener process paths using Gaussian variates.
This class generates normalized (i.e., unit-variance) paths as sequences of variations. In order to obtain the actual path of the underlying, the returned variations must be multiplied by the integrated variance (including time) over the corresponding time step.
BrownianBridge | ( | Size | steps | ) |
The constructor generates the time grid so that each step is of unit-time length.
steps | The number of steps in the path |
BrownianBridge | ( | const std::vector< Time > & | times | ) |
The step times are copied from the supplied vector
times | A vector containing the times at which the steps occur. This also defines the number of steps that will be generated. |
BrownianBridge | ( | const TimeGrid & | timeGrid | ) |
The step times are copied from the TimeGrid object
timeGrid | a time grid containing the times at which the steps will occur |
void transform | ( | RandomAccessIterator1 | begin, |
RandomAccessIterator1 | end, | ||
RandomAccessIterator2 | output | ||
) | const |
Brownian-bridge generator function.
Transforms an input sequence of random variates into a sequence of variations in a Brownian bridge path.
begin | The start iterator of the input sequence. |
end | The end iterator of the input sequence. |
output | The start iterator of the output sequence. |