problems with TR1 distributions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I need to do some statistical work in C++, so I am trying to use
the TR1 extensions.  I am using g++ Debian 4.3.4-1.

To become familiar with the distributions, I found various example
code to run.  I get some of the samples to run, and others go off
into 100% cpu never to return.  (For the Debian implementation,
I have to change std::tr1:: to std::)

The following sample routines work as advertised except for
differences in expected output:

Linear Congruential
http://msdn.microsoft.com/en-us/library/bb981982.aspx
g++ output matches web page

Mersenne Twister
http://msdn.microsoft.com/en-us/library/bb982912.aspx
g++ output matches web page

Bernoulli Distribution
http://msdn.microsoft.com/en-us/library/bb981930.aspx
g++ output matches web page

Normal Distribution
http://msdn.microsoft.com/en-us/library/bb982450.aspx
g++ output DOES NOT match web page

Exponential Distribution
http://msdn.microsoft.com/en-us/library/bb982022.aspx
g++ output DOES NOT match web page


The following sample routines never return from the test program:

Poisson Distribution
http://msdn.microsoft.com/en-us/library/bb982995.aspx
never returns

Binomial Distribution
http://msdn.microsoft.com/en-us/library/bb982497.aspx
never returns

Testing C++ TR1 random number generation
http://www.johndcook.com/test_TR1_random.html
never returns



Could someone tell me what might be wrong?  Is the Debian TR1 support
not working correclty?  Is the sample code invalid?  Would Boost work
better on this sample code?  Is TR1 support not ready for prime time?


Thanks!

Lester

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux