Login  Register

Re: [Quantlib-users] Hull-White and CIR path generation

Posted by Luigi Ballabio on Oct 18, 2010; 9:10am
URL: http://quantlib.414.s1.nabble.com/Re-Quantlib-users-Hull-White-and-CIR-path-generation-tp13225p13226.html

On Fri, 2010-10-15 at 16:50 +0100, Simon Ibbotson wrote:

> I've written some code for generating random numbers for the Gamma
> distribution, the Chi-squared distribution and the Non-Central
> Chi-Squared distribution but I need to wrap these up into a path
> generator for CIR which can then be used for Monte-Carlo pricing.
> [...] I don't want to use the InverseCumulativeRsg as inverting the
> CIR distribution is really slow compared to sampling from the
> Non-Central Chi-Squared.
>
> So, I'm assuming that (to use the Monte Carlo framework) I need to
> create
> 1) A CIR sequence generator.
> 2) A RNG traits template class which enables the CIR sequence generator
> class.
>
> Is this correct? Or is there something that I've missed?

Correct.  You can already generate numbers according to your
distribution, so just wrap them in a sequence generator and you should
be done.

Luigi


--

Better to have an approximate answer to the right question than a
precise answer to the wrong question.
-- John Tukey as quoted by John Chambers



------------------------------------------------------------------------------
Download new Adobe(R) Flash(R) Builder(TM) 4
The new Adobe(R) Flex(R) 4 and Flash(R) Builder(TM) 4 (formerly
Flex(R) Builder(TM)) enable the development of rich applications that run
across multiple browsers and platforms. Download your free trials today!
http://p.sf.net/sfu/adobe-dev2dev
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev