Logo Search packages:      
Sourcecode: quantlib version File versions

QuantLib::McPricer< MC, S > Class Template Reference

#include <mcpricer.hpp>

Inheritance diagram for QuantLib::McPricer< MC, S >:

QuantLib::McCliquetOption QuantLib::McDiscreteArithmeticASO QuantLib::McEverest QuantLib::McHimalaya QuantLib::McMaxBasket QuantLib::McPagoda QuantLib::McPerformanceOption

List of all members.


Detailed Description

template<class MC, class S = Statistics>
class QuantLib::McPricer< MC, S >

base class for Monte Carlo pricers

Eventually this class might be linked to the general tree of pricers, in order to have tools like impliedVolatility available. Also, it could, eventually, offer greeks methods. Deriving a class from McPricer gives an easy way to write a Monte Carlo Pricer. See McEuropean as example of one factor pricer, Basket as example of multi factor pricer.

Definition at line 41 of file mcpricer.hpp.


Public Member Functions

Real errorEstimate () const
 error Estimated of the samples simulated so far
const S & sampleAccumulator (void) const
 access to the sample accumulator for more statistics
Real value (Real tolerance, Size maxSample=QL_MAX_INTEGER) const
 add samples until the required tolerance is reached
Real valueWithSamples (Size samples) const
 simulate a fixed number of samples

Protected Attributes

boost::shared_ptr
< MonteCarloModel< MC, S > > 
mcModel_

Static Protected Attributes

static const Size minSample_ = 1023

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

Generated by  Doxygen 1.6.0   Back to index