ENH: Random numbers - updated dependent code from change cachedRandom->Random class

This commit is contained in:
Andrew Heather
2017-04-28 09:15:52 +01:00
parent b07bc1f0b8
commit 7f0cc0045d
96 changed files with 235 additions and 300 deletions

View File

@ -40,9 +40,9 @@ complexVector UOprocess::WeinerProcess()
{
return RootDeltaT*complexVector
(
complex(GaussGen.GaussNormal(), GaussGen.GaussNormal()),
complex(GaussGen.GaussNormal(), GaussGen.GaussNormal()),
complex(GaussGen.GaussNormal(), GaussGen.GaussNormal())
complex(GaussGen.GaussNormal<scalar>(), GaussGen.GaussNormal<scalar>()),
complex(GaussGen.GaussNormal<scalar>(), GaussGen.GaussNormal<scalar>()),
complex(GaussGen.GaussNormal<scalar>(), GaussGen.GaussNormal<scalar>())
);
}
@ -57,7 +57,7 @@ UOprocess::UOprocess
const dictionary& UOdict
)
:
GaussGen(label(0)),
GaussGen(),
Mesh(kmesh),
DeltaT(deltaT),
RootDeltaT(sqrt(DeltaT)),

View File

@ -51,8 +51,8 @@ Foam::vectorField Foam::turbGen::U()
forAll(K, i)
{
s[i] = RanGen.vector01();
rndPhases[i] = RanGen.scalar01();
s[i] = RanGen.sample01<vector>();
rndPhases[i] = RanGen.sample01<scalar>();
}
s = K ^ s;