Re: other method to simulate an exponential



Lourdes wrote:
> Hello.
> I'm programing a simulation of ruin probabilities in C++.
> Is there any other method to simulate an exponential faster than
> y=-ln(1-uniform(0,1))/b?
> I think that using the log function makes things slower in C++.
> Many thanks.
> Lourdes

The fastest way to generate an exponential variable
is probably Marsaglia & Tsang's "ziggurat" method.
See the Journal Statistical Software, v 5, Issue 8, 2000.
http://www.jstatsoft.org/v05/i08/ziggurat.pdf

[reposted to sci.stat.math only]

.


Quantcast