mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
COMP: cachedRandom: use OSspecific version for random number
Fixes http://www.openfoam.com/mantisbt/view.php?id=233
This commit is contained in:
@ -26,11 +26,6 @@ License
|
||||
#include "cachedRandom.H"
|
||||
#include "OSspecific.H"
|
||||
|
||||
#if INT_MAX != 2147483647
|
||||
# error "INT_MAX != 2147483647"
|
||||
# error "The random number generator may not work!"
|
||||
#endif
|
||||
|
||||
// * * * * * * * * * * * * * private Member Functions * * * * * * * * * * * //
|
||||
|
||||
Foam::scalar Foam::cachedRandom::scalar01()
|
||||
@ -79,7 +74,7 @@ Foam::cachedRandom::cachedRandom(const label seed, const label count)
|
||||
osRandomSeed(seed_);
|
||||
forAll(samples_, i)
|
||||
{
|
||||
samples_[i] = drand48();
|
||||
samples_[i] = osRandomDouble();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user