On 11/28/2012 09:17 AM, tino wrote:
Hi,
There are currently only uniform random number generators available in
calc, namely RAND() and RANDBETWEEN(...). I'd be interested in
generators for other distributions, like normal, exponential etc.
I'd suggest using boost/random.hpp and then implementation will be
straight forward. We could also replace rand()/(RAND_MAX+1) in RAND()
with a boost random generator (rand() under windows can be extremely
poorly implemented and only have 2^16 different values or so). This
would also solve this windows only bug:
https://bugs.freedesktop.org/show_bug.cgi?id=33365
Opinions?
So, Michael Stahl commented in the bug that we do have our own random
number generator function. One way is to just replace the direct call
to rand() to this function instead. That should be very easy to do and
I have no objection against it.
Or, is boost's random number generator better than our own? Does anyone
know?
Kohei
--
Kohei Yoshida, LibreOffice hacker, Calc
_______________________________________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice