Heston analytic engine possible problem?

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Heston analytic engine possible problem?

YiannisP
Hi guys,

I briefly used the Heston analytic engine and something doesn't seem quite right.
One can look at the unit test "testAlanLewisReferencePrices" where the reference prices are matched to very high accuracy (1.e-12 or lower), with either laguerre or gaussLobatto integration. If we only change one parameter there (sigma, from 1 to 0.1), everything breaks down. Laguerre will give 16.83 where guassLobatto gives 15.84 (ATM call). Lobatto seems the one which is more wrong, but Laguerre is not too accurate either. By the way, reducing c_inf from the currently chosen value, brings Lobatto very close to Laguerre.

Any insights into this? Am I doing something wrong? Is there something that needs to be fine-tuned?

Best

Yiannis
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Heston analytic engine possible problem?

YiannisP
Let me correct myself. Laguerre does actually give an accurate result. It's GaussLobato that seems to fail.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Heston analytic engine possible problem?

Klaus Spanderen-2
Hi Yiannis,

the small sigma value gives the Gauss-Lobatto algorithm a hard time to figure
out the Fourier integral of the characteristic function. All other adaptive
integration algorithms like Gauss-Konrod etc throw in the towel much earlier.

The c_inf value is given by formula 39 in the original paper
http://www2.math.uni-wuppertal.de/~kahl/publications/
NotSoComplexLogarithmsInTheHestonModel.pdf

It was observed that a max value on the expression sqrt(1-rho^2)/w can improve
the numerical stability of the Gauss-Lobatto integration. Given your example
and some additional edge cases 1.0 seems to be a better max bound than the
10.0 currently being used. I've created a PR with the corresponding change,

https://github.com/lballabio/QuantLib/pull/192

thanks and best regards
Klaus

On Donnerstag, 19. Januar 2017 15:54:07 CET YiannisP wrote:

> Let me correct myself. Laguerre does actually give an accurate result. It's
> GaussLobato that seems to fail.
>
>
>
> --
> View this message in context:
> http://quantlib.10058.n7.nabble.com/Heston-analytic-engine-possible-problem
> -tp17977p17978.html Sent from the quantlib-users mailing list archive at
> Nabble.com.
>
> ----------------------------------------------------------------------------
> -- Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users
Loading...