mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
COMP: avoid ambiguous construct from tmp - randomProcesses
This commit is contained in:
@ -34,6 +34,7 @@ License
|
|||||||
|
|
||||||
Foam::scalar Foam::noiseFFT::p0 = 2e-5;
|
Foam::scalar Foam::noiseFFT::p0 = 2e-5;
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
// Construct from pressure field
|
// Construct from pressure field
|
||||||
@ -226,9 +227,9 @@ Foam::graph Foam::noiseFFT::meanPf
|
|||||||
|
|
||||||
scalarField MeanPf(N/2, 0.0);
|
scalarField MeanPf(N/2, 0.0);
|
||||||
|
|
||||||
scalarField Hwf = Hanning(N);
|
scalarField Hwf(Hanning(N));
|
||||||
|
|
||||||
for (label wi=0; wi<nw; wi++)
|
for (label wi=0; wi<nw; ++wi)
|
||||||
{
|
{
|
||||||
MeanPf += Pf(Hwf*window(N, wi));
|
MeanPf += Pf(Hwf*window(N, wi));
|
||||||
}
|
}
|
||||||
@ -272,9 +273,9 @@ Foam::graph Foam::noiseFFT::RMSmeanPf
|
|||||||
|
|
||||||
scalarField RMSMeanPf(N/2, 0.0);
|
scalarField RMSMeanPf(N/2, 0.0);
|
||||||
|
|
||||||
scalarField Hwf = Hanning(N);
|
scalarField Hwf(Hanning(N));
|
||||||
|
|
||||||
for (label wi=0; wi<nw; wi++)
|
for (label wi=0; wi<nw; ++wi)
|
||||||
{
|
{
|
||||||
RMSMeanPf += sqr(Pf(Hwf*window(N, wi)));
|
RMSMeanPf += sqr(Pf(Hwf*window(N, wi)));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -60,13 +60,15 @@ Foam::vectorField Foam::turbGen::U()
|
|||||||
|
|
||||||
s = Ek(Ea, k0, mag(K))*s;
|
s = Ek(Ea, k0, mag(K))*s;
|
||||||
|
|
||||||
complexVectorField up =
|
complexVectorField up
|
||||||
|
(
|
||||||
fft::reverseTransform
|
fft::reverseTransform
|
||||||
(
|
(
|
||||||
ComplexField(cos(constant::mathematical::twoPi*rndPhases)*s,
|
ComplexField(cos(constant::mathematical::twoPi*rndPhases)*s,
|
||||||
sin(constant::mathematical::twoPi*rndPhases)*s),
|
sin(constant::mathematical::twoPi*rndPhases)*s),
|
||||||
K.nn()
|
K.nn()
|
||||||
);
|
)
|
||||||
|
);
|
||||||
|
|
||||||
return ReImSum(up);
|
return ReImSum(up);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user