mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: more consistent use of dimensioned Zero, scalar decimal points
- use scalar(0) instead of scalar(0.0) etc
This commit is contained in:
@ -142,10 +142,10 @@ Foam::XiEqModel::calculateSchelkinEffect(const scalar uPrimeCoef) const
|
|||||||
|
|
||||||
const scalarField upLocal(uPrimeCoef*sqrt((U & CT & U)*cellWidth));
|
const scalarField upLocal(uPrimeCoef*sqrt((U & CT & U)*cellWidth));
|
||||||
|
|
||||||
const scalarField deltaUp(upLocal*(max(scalar(1.0), pow(nr, 0.5)) - 1.0));
|
const scalarField deltaUp(upLocal*(max(scalar(1), pow(nr, 0.5)) - 1.0));
|
||||||
|
|
||||||
// Re use tN
|
// Re use tN
|
||||||
N.primitiveFieldRef() = upLocal*(max(scalar(1.0), pow(nr, 0.5)) - 1.0);
|
N.primitiveFieldRef() = upLocal*(max(scalar(1), pow(nr, 0.5)) - 1.0);
|
||||||
|
|
||||||
return tN;
|
return tN;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -170,7 +170,7 @@ License
|
|||||||
rDeltaT = max
|
rDeltaT = max
|
||||||
(
|
(
|
||||||
rDeltaT,
|
rDeltaT,
|
||||||
(scalar(1.0) - rDeltaTDampingCoeff)*rDeltaT0
|
(scalar(1) - rDeltaTDampingCoeff)*rDeltaT0
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -120,7 +120,7 @@ Foam::maxwellSlipUFvPatchVectorField::maxwellSlipUFvPatchVectorField
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
this->refValue() = *this;
|
this->refValue() = *this;
|
||||||
this->valueFraction() = scalar(1.0);
|
this->valueFraction() = scalar(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -95,7 +95,7 @@
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
solidRegions[i],
|
solidRegions[i],
|
||||||
dimensionedScalar("1", dimless, scalar(1.0))
|
dimensionedScalar("1", dimless, scalar(1))
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -101,7 +101,7 @@ if (mesh.changing())
|
|||||||
pcorrEqn.setReferences
|
pcorrEqn.setReferences
|
||||||
(
|
(
|
||||||
validCells,
|
validCells,
|
||||||
scalar(0.0),
|
scalar(0),
|
||||||
true
|
true
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -122,7 +122,7 @@ License
|
|||||||
rDeltaT = max
|
rDeltaT = max
|
||||||
(
|
(
|
||||||
rDeltaT,
|
rDeltaT,
|
||||||
(scalar(1.0) - rDeltaTDampingCoeff)*rDeltaT0
|
(scalar(1) - rDeltaTDampingCoeff)*rDeltaT0
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -121,7 +121,7 @@ License
|
|||||||
rDeltaT = max
|
rDeltaT = max
|
||||||
(
|
(
|
||||||
rDeltaT,
|
rDeltaT,
|
||||||
(scalar(1.0) - rDeltaTDampingCoeff)*rDeltaT0
|
(scalar(1) - rDeltaTDampingCoeff)*rDeltaT0
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -126,7 +126,7 @@
|
|||||||
rDeltaT = max
|
rDeltaT = max
|
||||||
(
|
(
|
||||||
rDeltaT,
|
rDeltaT,
|
||||||
(scalar(1.0) - rDeltaTDampingCoeff)*rDeltaT0
|
(scalar(1) - rDeltaTDampingCoeff)*rDeltaT0
|
||||||
);
|
);
|
||||||
|
|
||||||
Info<< "Damped flow time scale min/max = "
|
Info<< "Damped flow time scale min/max = "
|
||||||
|
|||||||
@ -25,7 +25,7 @@
|
|||||||
mesh
|
mesh
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar("zero", dimless/dimTime, 0.0)
|
dimensionedScalar(dimless/dimTime, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
Sps.set
|
Sps.set
|
||||||
@ -40,7 +40,7 @@
|
|||||||
mesh
|
mesh
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar("zero", dimless/dimTime, 0.0)
|
dimensionedScalar(dimless/dimTime, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -90,7 +90,7 @@ Foam::InterfaceCompositionModel<Thermo, OtherThermo>::getSpecieMassFraction
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar("zero", dimless, 0),
|
dimensionedScalar(dimless, Zero),
|
||||||
zeroGradientFvPatchScalarField::typeName
|
zeroGradientFvPatchScalarField::typeName
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
@ -126,7 +126,7 @@ Foam::InterfaceCompositionModel<Thermo, OtherThermo>::getSpecieMassFraction
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar("zero", dimless, 1),
|
dimensionedScalar("one", dimless, 1),
|
||||||
zeroGradientFvPatchScalarField::typeName
|
zeroGradientFvPatchScalarField::typeName
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
@ -251,7 +251,7 @@ Foam::InterfaceCompositionModel<Thermo, OtherThermo>::D
|
|||||||
p.mesh()
|
p.mesh()
|
||||||
),
|
),
|
||||||
p.mesh(),
|
p.mesh(),
|
||||||
dimensionedScalar("zero", dimArea/dimTime, 0)
|
dimensionedScalar(dimArea/dimTime, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -297,7 +297,7 @@ Foam::InterfaceCompositionModel<Thermo, OtherThermo>::L
|
|||||||
p.mesh()
|
p.mesh()
|
||||||
),
|
),
|
||||||
p.mesh(),
|
p.mesh(),
|
||||||
dimensionedScalar("zero", dimEnergy/dimMass, 0),
|
dimensionedScalar(dimEnergy/dimMass, Zero),
|
||||||
zeroGradientFvPatchScalarField::typeName
|
zeroGradientFvPatchScalarField::typeName
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|||||||
@ -166,7 +166,7 @@ Foam::meltingEvaporationModels::kineticGasEvaporation<Thermo, OtherThermo>
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar("zero", dimDensity, 0)
|
dimensionedScalar(dimDensity, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
volScalarField& rhom = tRhom.ref();
|
volScalarField& rhom = tRhom.ref();
|
||||||
@ -184,7 +184,7 @@ Foam::meltingEvaporationModels::kineticGasEvaporation<Thermo, OtherThermo>
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar("zero", dimTemperature, 0)
|
dimensionedScalar(dimTemperature, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
volScalarField& tDelta = tTdelta.ref();
|
volScalarField& tDelta = tTdelta.ref();
|
||||||
@ -198,7 +198,7 @@ Foam::meltingEvaporationModels::kineticGasEvaporation<Thermo, OtherThermo>
|
|||||||
tDelta = max
|
tDelta = max
|
||||||
(
|
(
|
||||||
(T*Tmask - Tactivate_),
|
(T*Tmask - Tactivate_),
|
||||||
dimensionedScalar("T0", dimTemperature, 0.0)
|
dimensionedScalar("T0", dimTemperature, Zero)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -210,7 +210,7 @@ Foam::meltingEvaporationModels::kineticGasEvaporation<Thermo, OtherThermo>
|
|||||||
tDelta = max
|
tDelta = max
|
||||||
(
|
(
|
||||||
Tmask*(Tactivate_ - T),
|
Tmask*(Tactivate_ - T),
|
||||||
dimensionedScalar("T0", dimTemperature, 0.0)
|
dimensionedScalar("T0", dimTemperature, Zero)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -62,7 +62,7 @@ Foam::MassTransferPhaseSystem<BasePhaseSystem>::MassTransferPhaseSystem
|
|||||||
IOobject::AUTO_WRITE
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
this->mesh(),
|
this->mesh(),
|
||||||
dimensionedScalar("zero", dimDensity/dimTime, 0)
|
dimensionedScalar(dimDensity/dimTime, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -95,7 +95,7 @@ Foam::MassTransferPhaseSystem<BasePhaseSystem>::calculateL
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
this->mesh(),
|
this->mesh(),
|
||||||
dimensionedScalar("zero", dimEnergy/dimMass, 0)
|
dimensionedScalar(dimEnergy/dimMass, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
volScalarField& L = tL.ref();
|
volScalarField& L = tL.ref();
|
||||||
@ -155,7 +155,7 @@ Foam::MassTransferPhaseSystem<BasePhaseSystem>::dmdt
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
this->mesh(),
|
this->mesh(),
|
||||||
dimensionedScalar("zero", dimDensity/dimTime, 0)
|
dimensionedScalar(dimDensity/dimTime, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -221,12 +221,7 @@ Foam::MassTransferPhaseSystem<BasePhaseSystem>::heatTransfer
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
this->mesh(),
|
this->mesh(),
|
||||||
dimensionedScalar
|
dimensionedScalar(dimDensity/dimTime, Zero)
|
||||||
(
|
|
||||||
"zero",
|
|
||||||
dimDensity/dimTime,
|
|
||||||
0
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
volScalarField& dmdtNetki = tdmdtNetki.ref();
|
volScalarField& dmdtNetki = tdmdtNetki.ref();
|
||||||
|
|||||||
@ -60,7 +60,7 @@ Foam::MovingPhaseModel<BasePhaseModel>::MovingPhaseModel
|
|||||||
fluid.mesh()
|
fluid.mesh()
|
||||||
),
|
),
|
||||||
fluid.mesh(),
|
fluid.mesh(),
|
||||||
dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0)
|
dimensionedScalar(dimensionSet(0, 3, -1, 0, 0), Zero)
|
||||||
)
|
)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
@ -127,7 +127,7 @@ diffNo() const
|
|||||||
U_.mesh()
|
U_.mesh()
|
||||||
),
|
),
|
||||||
U_.mesh(),
|
U_.mesh(),
|
||||||
dimensionedScalar("0", dimless, 0.0)
|
dimensionedScalar(dimless, Zero)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -52,7 +52,7 @@ Foam::StaticPhaseModel<BasePhaseModel>::StaticPhaseModel
|
|||||||
fluid.mesh()
|
fluid.mesh()
|
||||||
),
|
),
|
||||||
fluid.mesh(),
|
fluid.mesh(),
|
||||||
dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0)
|
dimensionedScalar(dimensionSet(0, 3, -1, 0, 0), Zero)
|
||||||
),
|
),
|
||||||
alphaPhi_
|
alphaPhi_
|
||||||
(
|
(
|
||||||
@ -63,7 +63,7 @@ Foam::StaticPhaseModel<BasePhaseModel>::StaticPhaseModel
|
|||||||
fluid.mesh()
|
fluid.mesh()
|
||||||
),
|
),
|
||||||
fluid.mesh(),
|
fluid.mesh(),
|
||||||
dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0)
|
dimensionedScalar(dimensionSet(0, 3, -1, 0, 0), Zero)
|
||||||
)
|
)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
@ -90,7 +90,7 @@ Foam::StaticPhaseModel<BasePhaseModel>::phi() const
|
|||||||
U_.mesh()
|
U_.mesh()
|
||||||
),
|
),
|
||||||
U_.mesh(),
|
U_.mesh(),
|
||||||
dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0)
|
dimensionedScalar(dimensionSet(0, 3, -1, 0, 0), Zero)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -99,7 +99,7 @@ template<class BasePhaseModel>
|
|||||||
const Foam::surfaceScalarField&
|
const Foam::surfaceScalarField&
|
||||||
Foam::StaticPhaseModel<BasePhaseModel>::phi()
|
Foam::StaticPhaseModel<BasePhaseModel>::phi()
|
||||||
{
|
{
|
||||||
phi_ = dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0);
|
phi_ = dimensionedScalar(dimensionSet(0, 3, -1, 0, 0), Zero);
|
||||||
return phi_;
|
return phi_;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -119,7 +119,7 @@ Foam::StaticPhaseModel<BasePhaseModel>::alphaPhi() const
|
|||||||
U_.mesh()
|
U_.mesh()
|
||||||
),
|
),
|
||||||
U_.mesh(),
|
U_.mesh(),
|
||||||
dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0)
|
dimensionedScalar(dimensionSet(0, 3, -1, 0, 0), Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -129,7 +129,7 @@ template<class BasePhaseModel>
|
|||||||
Foam::surfaceScalarField&
|
Foam::surfaceScalarField&
|
||||||
Foam::StaticPhaseModel<BasePhaseModel>::alphaPhi()
|
Foam::StaticPhaseModel<BasePhaseModel>::alphaPhi()
|
||||||
{
|
{
|
||||||
alphaPhi_ = dimensionedScalar("0", dimensionSet(0, 3, -1, 0, 0), 0);
|
alphaPhi_ = dimensionedScalar(dimensionSet(0, 3, -1, 0, 0), Zero);
|
||||||
return alphaPhi_;
|
return alphaPhi_;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -149,7 +149,7 @@ Foam::StaticPhaseModel<BasePhaseModel>::U() const
|
|||||||
U_.mesh()
|
U_.mesh()
|
||||||
),
|
),
|
||||||
U_.mesh(),
|
U_.mesh(),
|
||||||
dimensionedVector("zero", dimVelocity, vector::zero)
|
dimensionedVector(dimVelocity, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -221,7 +221,7 @@ Foam::phaseSystem::phaseSystem
|
|||||||
IOobject::AUTO_WRITE
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("zero", dimVolume/dimTime, 0.0)
|
dimensionedScalar(dimVolume/dimTime, Zero)
|
||||||
),
|
),
|
||||||
rhoPhi_
|
rhoPhi_
|
||||||
(
|
(
|
||||||
@ -234,7 +234,7 @@ Foam::phaseSystem::phaseSystem
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("zero", dimMass/dimTime, 0.0)
|
dimensionedScalar(dimMass/dimTime, Zero)
|
||||||
),
|
),
|
||||||
phaseModels_(generatePhaseModels(phaseNames_)),
|
phaseModels_(generatePhaseModels(phaseNames_)),
|
||||||
phasePairs_(),
|
phasePairs_(),
|
||||||
@ -945,12 +945,7 @@ Foam::phaseSystem::surfaceTensionForce() const
|
|||||||
mesh_
|
mesh_
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar
|
dimensionedScalar(dimensionSet(1, -2, -2, 0, 0), Zero)
|
||||||
(
|
|
||||||
"surfaceTensionForce",
|
|
||||||
dimensionSet(1, -2, -2, 0, 0),
|
|
||||||
0.0
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
@ -1118,7 +1113,7 @@ Foam::tmp<Foam::volScalarField> Foam::phaseSystem::nearInterface() const
|
|||||||
mesh_
|
mesh_
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("zero", dimless, 0.0)
|
dimensionedScalar(dimless, Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -355,7 +355,7 @@ Foam::tmp<Foam::scalarField> Foam::twoPhaseMixtureEThermo::rho
|
|||||||
|
|
||||||
return
|
return
|
||||||
(
|
(
|
||||||
alpha1p*rho1().value() + (scalar(1.0) - alpha1p)*rho2().value()
|
alpha1p*rho1().value() + (scalar(1) - alpha1p)*rho2().value()
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -110,7 +110,7 @@
|
|||||||
pcorrEqn.setReferences
|
pcorrEqn.setReferences
|
||||||
(
|
(
|
||||||
validCells,
|
validCells,
|
||||||
scalar(0.0),
|
scalar(0),
|
||||||
true
|
true
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -129,9 +129,9 @@ Foam::tmp<Foam::volScalarField> Foam::blendingMethods::linear::f1
|
|||||||
(
|
(
|
||||||
(phase1 - maxFullAlpha)
|
(phase1 - maxFullAlpha)
|
||||||
/(maxPartAlpha - maxFullAlpha + SMALL),
|
/(maxPartAlpha - maxFullAlpha + SMALL),
|
||||||
scalar(0.0)
|
scalar(0)
|
||||||
),
|
),
|
||||||
scalar(1.0)
|
scalar(1)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -154,9 +154,9 @@ Foam::tmp<Foam::volScalarField> Foam::blendingMethods::linear::f2
|
|||||||
(
|
(
|
||||||
(maxPartAlpha - phase2)
|
(maxPartAlpha - phase2)
|
||||||
/(maxPartAlpha - maxFullAlpha + SMALL),
|
/(maxPartAlpha - maxFullAlpha + SMALL),
|
||||||
scalar(0.0)
|
scalar(0)
|
||||||
),
|
),
|
||||||
scalar(1.0)
|
scalar(1)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -65,7 +65,7 @@ scalar getMergeDistance
|
|||||||
args.readIfPresent("mergeTol", mergeTol);
|
args.readIfPresent("mergeTol", mergeTol);
|
||||||
|
|
||||||
scalar writeTol =
|
scalar writeTol =
|
||||||
Foam::pow(scalar(10.0), -scalar(IOstream::defaultPrecision()));
|
Foam::pow(scalar(10), -scalar(IOstream::defaultPrecision()));
|
||||||
|
|
||||||
Info<< "Merge tolerance : " << mergeTol << nl
|
Info<< "Merge tolerance : " << mergeTol << nl
|
||||||
<< "Write tolerance : " << writeTol << endl;
|
<< "Write tolerance : " << writeTol << endl;
|
||||||
|
|||||||
@ -554,7 +554,7 @@ scalar getMergeDistance(const polyMesh& mesh, const scalar mergeTol)
|
|||||||
{
|
{
|
||||||
const scalar writeTol = std::pow
|
const scalar writeTol = std::pow
|
||||||
(
|
(
|
||||||
scalar(10.0),
|
scalar(10),
|
||||||
-scalar(IOstream::defaultPrecision())
|
-scalar(IOstream::defaultPrecision())
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -99,7 +99,7 @@ void Foam::writeFields
|
|||||||
(
|
(
|
||||||
radToDeg
|
radToDeg
|
||||||
(
|
(
|
||||||
Foam::acos(min(scalar(1.0), faceOrthogonality))
|
Foam::acos(min(scalar(1), faceOrthogonality))
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -106,7 +106,7 @@ scalar getMergeDistance
|
|||||||
args.readIfPresent("mergeTol", mergeTol);
|
args.readIfPresent("mergeTol", mergeTol);
|
||||||
|
|
||||||
const scalar writeTol =
|
const scalar writeTol =
|
||||||
Foam::pow(scalar(10.0), -scalar(IOstream::defaultPrecision()));
|
Foam::pow(scalar(10), -scalar(IOstream::defaultPrecision()));
|
||||||
|
|
||||||
Info<< "Merge tolerance : " << mergeTol << nl
|
Info<< "Merge tolerance : " << mergeTol << nl
|
||||||
<< "Write tolerance : " << writeTol << endl;
|
<< "Write tolerance : " << writeTol << endl;
|
||||||
|
|||||||
@ -174,7 +174,7 @@ tmp<volScalarField> kkLOmega::phiBP(const volScalarField& Omega) const
|
|||||||
- CbpCrit_,
|
- CbpCrit_,
|
||||||
scalar(0)
|
scalar(0)
|
||||||
),
|
),
|
||||||
scalar(50.0)
|
scalar(50)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -48,7 +48,7 @@ tmp<volScalarField> LaunderSharmaKE<BasicTurbulenceModel>::f2() const
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
scalar(1)
|
scalar(1)
|
||||||
- 0.3*exp(-min(sqr(sqr(k_)/(this->nu()*epsilon_)), scalar(50.0)));
|
- 0.3*exp(-min(sqr(sqr(k_)/(this->nu()*epsilon_)), scalar(50)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -106,7 +106,7 @@ tmp<volScalarField> SpalartAllmaras<BasicTurbulenceModel>::fw
|
|||||||
)
|
)
|
||||||
*sqr(kappa_*y_)
|
*sqr(kappa_*y_)
|
||||||
),
|
),
|
||||||
scalar(10.0)
|
scalar(10)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
r.boundaryFieldRef() == 0.0;
|
r.boundaryFieldRef() == 0.0;
|
||||||
|
|||||||
@ -341,7 +341,7 @@ void v2f<BasicTurbulenceModel>::correct()
|
|||||||
const volScalarField Ceps1
|
const volScalarField Ceps1
|
||||||
(
|
(
|
||||||
"Ceps1",
|
"Ceps1",
|
||||||
1.4*(1.0 + 0.05*min(sqrt(k_/v2_), scalar(100.0)))
|
1.4*(1.0 + 0.05*min(sqrt(k_/v2_), scalar(100)))
|
||||||
);
|
);
|
||||||
|
|
||||||
// Update epsilon (and possibly G) at the wall
|
// Update epsilon (and possibly G) at the wall
|
||||||
|
|||||||
@ -578,7 +578,7 @@ void Foam::polyMeshFilter::checkMeshEdgesAndRelaxEdges
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
syncTools::syncEdgeList(mesh_, minEdgeLen_, minEqOp<scalar>(), scalar(0.0));
|
syncTools::syncEdgeList(mesh_, minEdgeLen_, minEqOp<scalar>(), scalar(0));
|
||||||
|
|
||||||
for (label smoothIter = 0; smoothIter < maxSmoothIters(); ++smoothIter)
|
for (label smoothIter = 0; smoothIter < maxSmoothIters(); ++smoothIter)
|
||||||
{
|
{
|
||||||
@ -614,7 +614,7 @@ void Foam::polyMeshFilter::checkMeshEdgesAndRelaxEdges
|
|||||||
mesh_,
|
mesh_,
|
||||||
minEdgeLen_,
|
minEdgeLen_,
|
||||||
minEqOp<scalar>(),
|
minEqOp<scalar>(),
|
||||||
scalar(0.0)
|
scalar(0)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -824,7 +824,7 @@ void Foam::polyMeshFilter::mapOldMeshEdgeFieldToNewMesh
|
|||||||
newMesh,
|
newMesh,
|
||||||
newMeshMinEdgeLen,
|
newMeshMinEdgeLen,
|
||||||
maxEqOp<scalar>(),
|
maxEqOp<scalar>(),
|
||||||
scalar(0.0)
|
scalar(0)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -169,7 +169,7 @@ void Foam::flowRateInletVelocityFvPatchVectorField::updateValues
|
|||||||
Up -= nUp*n;
|
Up -= nUp*n;
|
||||||
|
|
||||||
// Remove any reverse flow
|
// Remove any reverse flow
|
||||||
nUp = min(nUp, scalar(0.0));
|
nUp = min(nUp, scalar(0));
|
||||||
|
|
||||||
const scalar flowRate = flowRate_->value(t);
|
const scalar flowRate = flowRate_->value(t);
|
||||||
const scalar estimatedFlowRate = -gSum(rho*(this->patch().magSf()*nUp));
|
const scalar estimatedFlowRate = -gSum(rho*(this->patch().magSf()*nUp));
|
||||||
|
|||||||
@ -160,7 +160,7 @@ void Foam::flowRateOutletVelocityFvPatchVectorField::updateValues
|
|||||||
Up -= nUp*n;
|
Up -= nUp*n;
|
||||||
|
|
||||||
// Remove any reverse flow
|
// Remove any reverse flow
|
||||||
nUp = max(nUp, scalar(0.0));
|
nUp = max(nUp, scalar(0));
|
||||||
|
|
||||||
const scalar flowRate = flowRate_->value(t);
|
const scalar flowRate = flowRate_->value(t);
|
||||||
const scalar estimatedFlowRate = gSum(rho*(this->patch().magSf()*nUp));
|
const scalar estimatedFlowRate = gSum(rho*(this->patch().magSf()*nUp));
|
||||||
|
|||||||
@ -148,9 +148,9 @@ void Foam::phaseHydrostaticPressureFvPatchScalarField::updateCoeffs()
|
|||||||
db().lookupObject<uniformDimensionedVectorField>("g");
|
db().lookupObject<uniformDimensionedVectorField>("g");
|
||||||
|
|
||||||
// scalar rhor = 1000;
|
// scalar rhor = 1000;
|
||||||
// scalarField alphap1 = max(min(alphap, 1.0), 0.0);
|
// scalarField alphap1 = max(min(alphap, scalar(1)), scalar(0));
|
||||||
// valueFraction() = alphap1/(alphap1 + rhor*(1.0 - alphap1));
|
// valueFraction() = alphap1/(alphap1 + rhor*(1.0 - alphap1));
|
||||||
valueFraction() = max(min(alphap, scalar(1.0)), scalar(0.0));
|
valueFraction() = max(min(alphap, scalar(1)), scalar(0));
|
||||||
|
|
||||||
refValue() =
|
refValue() =
|
||||||
pRefValue_
|
pRefValue_
|
||||||
|
|||||||
@ -897,7 +897,7 @@ void Foam::isoAdvection::applyBruteForceBounding()
|
|||||||
|
|
||||||
if (dict_.lookupOrDefault("clip", true))
|
if (dict_.lookupOrDefault("clip", true))
|
||||||
{
|
{
|
||||||
alpha1_ = min(scalar(1.0), max(scalar(0.0), alpha1_));
|
alpha1_ = min(scalar(1), max(scalar(0), alpha1_));
|
||||||
alpha1Changed = true;
|
alpha1Changed = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -249,7 +249,7 @@ public:
|
|||||||
|
|
||||||
return
|
return
|
||||||
bf*tScheme1_().weights(vf)
|
bf*tScheme1_().weights(vf)
|
||||||
+ (scalar(1.0) - bf)*tScheme2_().weights(vf);
|
+ (scalar(1) - bf)*tScheme2_().weights(vf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -265,7 +265,7 @@ public:
|
|||||||
|
|
||||||
return
|
return
|
||||||
bf*tScheme1_().interpolate(vf)
|
bf*tScheme1_().interpolate(vf)
|
||||||
+ (scalar(1.0) - bf)*tScheme2_().interpolate(vf);
|
+ (scalar(1) - bf)*tScheme2_().interpolate(vf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -294,7 +294,7 @@ public:
|
|||||||
(
|
(
|
||||||
bf
|
bf
|
||||||
* tScheme1_().correction(vf)
|
* tScheme1_().correction(vf)
|
||||||
+ (scalar(1.0) - bf)
|
+ (scalar(1) - bf)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -311,7 +311,7 @@ public:
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
(
|
(
|
||||||
(scalar(1.0) - bf)
|
(scalar(1) - bf)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -276,7 +276,7 @@ public:
|
|||||||
|
|
||||||
return
|
return
|
||||||
bf*tScheme1_().weights(vf)
|
bf*tScheme1_().weights(vf)
|
||||||
+ (scalar(1.0) - bf)*tScheme2_().weights(vf);
|
+ (scalar(1) - bf)*tScheme2_().weights(vf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -292,7 +292,7 @@ public:
|
|||||||
|
|
||||||
return
|
return
|
||||||
bf*tScheme1_().interpolate(vf)
|
bf*tScheme1_().interpolate(vf)
|
||||||
+ (scalar(1.0) - bf)*tScheme2_().interpolate(vf);
|
+ (scalar(1) - bf)*tScheme2_().interpolate(vf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -321,7 +321,7 @@ public:
|
|||||||
(
|
(
|
||||||
bf
|
bf
|
||||||
* tScheme1_().correction(vf)
|
* tScheme1_().correction(vf)
|
||||||
+ (scalar(1.0) - bf)
|
+ (scalar(1) - bf)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -338,7 +338,7 @@ public:
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
(
|
(
|
||||||
(scalar(1.0) - bf)
|
(scalar(1) - bf)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -176,7 +176,7 @@ public:
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
blendingFactor_*tScheme1_().weights(vf)
|
blendingFactor_*tScheme1_().weights(vf)
|
||||||
+ (scalar(1.0) - blendingFactor_)*tScheme2_().weights(vf);
|
+ (scalar(1) - blendingFactor_)*tScheme2_().weights(vf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -190,7 +190,7 @@ public:
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
blendingFactor_*tScheme1_().interpolate(vf)
|
blendingFactor_*tScheme1_().interpolate(vf)
|
||||||
+ (scalar(1.0) - blendingFactor_)*tScheme2_().interpolate(vf);
|
+ (scalar(1) - blendingFactor_)*tScheme2_().interpolate(vf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -217,7 +217,7 @@ public:
|
|||||||
(
|
(
|
||||||
blendingFactor_
|
blendingFactor_
|
||||||
* tScheme1_().correction(vf)
|
* tScheme1_().correction(vf)
|
||||||
+ (scalar(1.0) - blendingFactor_)
|
+ (scalar(1) - blendingFactor_)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -234,7 +234,7 @@ public:
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
(
|
(
|
||||||
(scalar(1.0) - blendingFactor_)
|
(scalar(1) - blendingFactor_)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -197,7 +197,7 @@ public:
|
|||||||
(
|
(
|
||||||
blendingFactor
|
blendingFactor
|
||||||
* tScheme1_().correction(vf)
|
* tScheme1_().correction(vf)
|
||||||
+ (scalar(1.0) - blendingFactor)
|
+ (scalar(1) - blendingFactor)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -214,7 +214,7 @@ public:
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
(
|
(
|
||||||
(scalar(1.0) - blendingFactor)
|
(scalar(1) - blendingFactor)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -209,7 +209,7 @@ public:
|
|||||||
(
|
(
|
||||||
blendingFactor
|
blendingFactor
|
||||||
* tScheme1_().correction(vf)
|
* tScheme1_().correction(vf)
|
||||||
+ (scalar(1.0) - blendingFactor)
|
+ (scalar(1) - blendingFactor)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -226,7 +226,7 @@ public:
|
|||||||
{
|
{
|
||||||
return
|
return
|
||||||
(
|
(
|
||||||
(scalar(1.0) - blendingFactor)
|
(scalar(1) - blendingFactor)
|
||||||
* tScheme2_().correction(vf)
|
* tScheme2_().correction(vf)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -130,7 +130,7 @@ void Foam::functionObjects::residuals::writeField(const word& fieldName) const
|
|||||||
false
|
false
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("0", dimless, 0),
|
dimensionedScalar(dimless, Zero),
|
||||||
zeroGradientFvPatchField<scalar>::typeName
|
zeroGradientFvPatchField<scalar>::typeName
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -106,7 +106,7 @@ void reactingOneDim::updateqr()
|
|||||||
|
|
||||||
// qr is positive going in the solid
|
// qr is positive going in the solid
|
||||||
// If the surface is emitting the radiative flux is set to zero
|
// If the surface is emitting the radiative flux is set to zero
|
||||||
qrBf[patchi] = max(qrBf[patchi], scalar(0.0));
|
qrBf[patchi] = max(qrBf[patchi], scalar(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
const vectorField& cellC = regionMesh().cellCentres();
|
const vectorField& cellC = regionMesh().cellCentres();
|
||||||
|
|||||||
@ -336,9 +336,9 @@ void filmPyrolysisRadiativeCoupledMixedFvPatchScalarField::updateCoeffs()
|
|||||||
max
|
max
|
||||||
(
|
(
|
||||||
(filmDelta - filmDeltaDry_)/(filmDeltaWet_ - filmDeltaDry_),
|
(filmDelta - filmDeltaDry_)/(filmDeltaWet_ - filmDeltaDry_),
|
||||||
scalar(0.0)
|
scalar(0)
|
||||||
),
|
),
|
||||||
scalar(1.0)
|
scalar(1)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -212,7 +212,7 @@ tmp<scalarField> curvatureSeparation::calcCosAngle
|
|||||||
volCosAngle.write();
|
volCosAngle.write();
|
||||||
}
|
}
|
||||||
|
|
||||||
return max(min(cosAngle, scalar(1.0)), scalar(-1.0));
|
return max(min(cosAngle, scalar(1)), scalar(-1));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -155,7 +155,7 @@ void thixotropicViscosity::correct
|
|||||||
max
|
max
|
||||||
(
|
(
|
||||||
-film.rhoSp(),
|
-film.rhoSp(),
|
||||||
dimensionedScalar("zero", film.rhoSp().dimensions(), 0)
|
dimensionedScalar(film.rhoSp().dimensions(), Zero)
|
||||||
)/(deltaRho + deltaRho0),
|
)/(deltaRho + deltaRho0),
|
||||||
lambda_
|
lambda_
|
||||||
)
|
)
|
||||||
|
|||||||
@ -123,7 +123,7 @@ waxSolventViscosity::waxSolventViscosity
|
|||||||
IOobject::AUTO_WRITE
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
film.regionMesh(),
|
film.regionMesh(),
|
||||||
dimensionedScalar("zero", dimDynamicViscosity, 0),
|
dimensionedScalar(dimDynamicViscosity, Zero),
|
||||||
zeroGradientFvPatchScalarField::typeName
|
zeroGradientFvPatchScalarField::typeName
|
||||||
),
|
),
|
||||||
muWaxModel_
|
muWaxModel_
|
||||||
@ -146,7 +146,7 @@ waxSolventViscosity::waxSolventViscosity
|
|||||||
IOobject::AUTO_WRITE
|
IOobject::AUTO_WRITE
|
||||||
),
|
),
|
||||||
film.regionMesh(),
|
film.regionMesh(),
|
||||||
dimensionedScalar("zero", dimDynamicViscosity, 0),
|
dimensionedScalar(dimDynamicViscosity, Zero),
|
||||||
zeroGradientFvPatchScalarField::typeName
|
zeroGradientFvPatchScalarField::typeName
|
||||||
),
|
),
|
||||||
muSolventModel_
|
muSolventModel_
|
||||||
|
|||||||
@ -196,7 +196,7 @@ void waxSolventEvaporation::correctModel
|
|||||||
false
|
false
|
||||||
),
|
),
|
||||||
film.regionMesh(),
|
film.regionMesh(),
|
||||||
dimensionedScalar("zero", dimDensity*dimVelocity, 0)
|
dimensionedScalar(dimDensity*dimVelocity, Zero)
|
||||||
);
|
);
|
||||||
|
|
||||||
volScalarField::Internal evapRateInf
|
volScalarField::Internal evapRateInf
|
||||||
@ -211,7 +211,7 @@ void waxSolventEvaporation::correctModel
|
|||||||
false
|
false
|
||||||
),
|
),
|
||||||
film.regionMesh(),
|
film.regionMesh(),
|
||||||
dimensionedScalar("zero", dimDensity*dimVelocity, 0)
|
dimensionedScalar(dimDensity*dimVelocity, Zero)
|
||||||
);
|
);
|
||||||
|
|
||||||
bool filmPresent = false;
|
bool filmPresent = false;
|
||||||
@ -321,7 +321,7 @@ void waxSolventEvaporation::correctModel
|
|||||||
max
|
max
|
||||||
(
|
(
|
||||||
-film.rhoSp()(),
|
-film.rhoSp()(),
|
||||||
dimensionedScalar("zero", film.rhoSp().dimensions(), 0)
|
dimensionedScalar(film.rhoSp().dimensions(), Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -209,12 +209,7 @@ Foam::basicThermo::basicThermo
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar
|
dimensionedScalar(dimensionSet(1, -1, -1, 0, 0), Zero)
|
||||||
(
|
|
||||||
"zero",
|
|
||||||
dimensionSet(1, -1, -1, 0, 0),
|
|
||||||
Zero
|
|
||||||
)
|
|
||||||
),
|
),
|
||||||
|
|
||||||
dpdt_(lookupOrDefault<Switch>("dpdt", true))
|
dpdt_(lookupOrDefault<Switch>("dpdt", true))
|
||||||
@ -259,12 +254,7 @@ Foam::basicThermo::basicThermo
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar
|
dimensionedScalar(dimensionSet(1, -1, -1, 0, 0), Zero)
|
||||||
(
|
|
||||||
"zero",
|
|
||||||
dimensionSet(1, -1, -1, 0, 0),
|
|
||||||
Zero
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
@ -306,12 +296,7 @@ Foam::basicThermo::basicThermo
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh,
|
mesh,
|
||||||
dimensionedScalar
|
dimensionedScalar(dimensionSet(1, -1, -1, 0, 0), Zero)
|
||||||
(
|
|
||||||
"zero",
|
|
||||||
dimensionSet(1, -1, -1, 0, 0),
|
|
||||||
Zero
|
|
||||||
)
|
|
||||||
),
|
),
|
||||||
|
|
||||||
dpdt_(lookupOrDefault<Switch>("dpdt", true))
|
dpdt_(lookupOrDefault<Switch>("dpdt", true))
|
||||||
|
|||||||
@ -169,7 +169,7 @@ void Foam::radiation::MarshakRadiationFvPatchScalarField::updateCoeffs()
|
|||||||
|
|
||||||
const scalarField& emissivity = temissivity();
|
const scalarField& emissivity = temissivity();
|
||||||
|
|
||||||
const scalarField Ep(emissivity/(2.0*(scalar(2.0) - emissivity)));
|
const scalarField Ep(emissivity/(2.0*(scalar(2) - emissivity)));
|
||||||
|
|
||||||
// Set value fraction
|
// Set value fraction
|
||||||
valueFraction() = 1.0/(1.0 + gamma*patch().deltaCoeffs()/Ep);
|
valueFraction() = 1.0/(1.0 + gamma*patch().deltaCoeffs()/Ep);
|
||||||
|
|||||||
@ -168,7 +168,7 @@ updateCoeffs()
|
|||||||
|
|
||||||
const scalarField& emissivity = temissivity();
|
const scalarField& emissivity = temissivity();
|
||||||
|
|
||||||
const scalarField Ep(emissivity/(2.0*(scalar(2.0) - emissivity)));
|
const scalarField Ep(emissivity/(2.0*(scalar(2) - emissivity)));
|
||||||
|
|
||||||
// Set value fraction
|
// Set value fraction
|
||||||
valueFraction() = 1.0/(1.0 + gamma*patch().deltaCoeffs()/Ep);
|
valueFraction() = 1.0/(1.0 + gamma*patch().deltaCoeffs()/Ep);
|
||||||
|
|||||||
@ -212,7 +212,7 @@ updateCoeffs()
|
|||||||
valueFraction()[faceI] = 1.0;
|
valueFraction()[faceI] = 1.0;
|
||||||
refValue()[faceI] =
|
refValue()[faceI] =
|
||||||
(
|
(
|
||||||
Ir[faceI]*(scalar(1.0) - emissivity[faceI])
|
Ir[faceI]*(scalar(1) - emissivity[faceI])
|
||||||
+ emissivity[faceI]*physicoChemical::sigma.value()
|
+ emissivity[faceI]*physicoChemical::sigma.value()
|
||||||
* pow4(Tp[faceI])
|
* pow4(Tp[faceI])
|
||||||
)/pi;
|
)/pi;
|
||||||
|
|||||||
@ -532,7 +532,7 @@ Foam::radiation::fvDOM::Ru() const
|
|||||||
false
|
false
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("zero", dimensionSet(1, -1, -3, 0, 0), 0)
|
dimensionedScalar(dimensionSet(1, -1, -3, 0, 0), Zero)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -144,11 +144,11 @@ void Foam::singleStepReactingMixture<ThermoType>::fresCorrect()
|
|||||||
const label speciei = reaction.lhs()[i].index;
|
const label speciei = reaction.lhs()[i].index;
|
||||||
if (speciei == fuelIndex_)
|
if (speciei == fuelIndex_)
|
||||||
{
|
{
|
||||||
fres_[speciei] = max(YFuel - YO2/s_, scalar(0.0));
|
fres_[speciei] = max(YFuel - YO2/s_, scalar(0));
|
||||||
}
|
}
|
||||||
else if (speciei == O2Index)
|
else if (speciei == O2Index)
|
||||||
{
|
{
|
||||||
fres_[speciei] = max(YO2 - YFuel*s_, scalar(0.0));
|
fres_[speciei] = max(YO2 - YFuel*s_, scalar(0));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -194,8 +194,8 @@ heSolidThermo
|
|||||||
|
|
||||||
// TBD. initialise psi, mu (at heThermo level) since these do not
|
// TBD. initialise psi, mu (at heThermo level) since these do not
|
||||||
// get initialised. Move to heThermo constructor?
|
// get initialised. Move to heThermo constructor?
|
||||||
this->mu_ == dimensionedScalar("zero", this->mu_.dimensions(), 0.0);
|
this->mu_ == dimensionedScalar(this->mu_.dimensions(), Zero);
|
||||||
this->psi_ == dimensionedScalar("zero", this->psi_.dimensions(), 0.0);
|
this->psi_ == dimensionedScalar(this->psi_.dimensions(), Zero);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -63,7 +63,7 @@ Foam::viscosityModels::powerLaw::calcNu() const
|
|||||||
dimensionedScalar("one", dimTime, 1.0)*strainRate(),
|
dimensionedScalar("one", dimTime, 1.0)*strainRate(),
|
||||||
dimensionedScalar("SMALL", dimless, SMALL)
|
dimensionedScalar("SMALL", dimless, SMALL)
|
||||||
),
|
),
|
||||||
n_.value() - scalar(1.0)
|
n_.value() - scalar(1)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|||||||
@ -64,7 +64,7 @@ Foam::fv::multiphaseMangrovesSource::dragCoeff(const volVectorField& U) const
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("0", dimless/dimTime, 0)
|
dimensionedScalar(dimless/dimTime, Zero)
|
||||||
);
|
);
|
||||||
|
|
||||||
volScalarField& dragCoeff = tdragCoeff.ref();
|
volScalarField& dragCoeff = tdragCoeff.ref();
|
||||||
@ -110,7 +110,7 @@ Foam::fv::multiphaseMangrovesSource::inertiaCoeff() const
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("0", dimless, 0)
|
dimensionedScalar(dimless, Zero)
|
||||||
);
|
);
|
||||||
|
|
||||||
volScalarField& inertiaCoeff = tinertiaCoeff.ref();
|
volScalarField& inertiaCoeff = tinertiaCoeff.ref();
|
||||||
|
|||||||
@ -66,7 +66,7 @@ Foam::fv::multiphaseMangrovesTurbulenceModel::kCoeff
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("0", dimless/dimTime, 0)
|
dimensionedScalar(dimless/dimTime, Zero)
|
||||||
);
|
);
|
||||||
|
|
||||||
volScalarField& kCoeff = tkCoeff.ref();
|
volScalarField& kCoeff = tkCoeff.ref();
|
||||||
@ -112,7 +112,7 @@ Foam::fv::multiphaseMangrovesTurbulenceModel::epsilonCoeff
|
|||||||
IOobject::NO_WRITE
|
IOobject::NO_WRITE
|
||||||
),
|
),
|
||||||
mesh_,
|
mesh_,
|
||||||
dimensionedScalar("0", dimless/dimTime, 0)
|
dimensionedScalar(dimless/dimTime, Zero)
|
||||||
);
|
);
|
||||||
|
|
||||||
volScalarField& epsilonCoeff = tepsilonCoeff.ref();
|
volScalarField& epsilonCoeff = tepsilonCoeff.ref();
|
||||||
|
|||||||
@ -112,7 +112,7 @@ int main(int argc, char *argv[])
|
|||||||
),
|
),
|
||||||
mesh.C()/magSqr(mesh.C())
|
mesh.C()/magSqr(mesh.C())
|
||||||
);
|
);
|
||||||
radialDirection.replace(vector::Z, scalar(0.0));
|
radialDirection.replace(vector::Z, scalar(0));
|
||||||
radialDirection /= sqrt(magSqr(radialDirection));
|
radialDirection /= sqrt(magSqr(radialDirection));
|
||||||
radialDirection.write();
|
radialDirection.write();
|
||||||
|
|
||||||
@ -135,7 +135,7 @@ int main(int argc, char *argv[])
|
|||||||
),
|
),
|
||||||
transform2Tangencial & mesh.C()
|
transform2Tangencial & mesh.C()
|
||||||
);
|
);
|
||||||
angularDirection.replace(vector::Z, scalar(0.0));
|
angularDirection.replace(vector::Z, scalar(0));
|
||||||
angularDirection /= sqrt(magSqr(angularDirection));
|
angularDirection /= sqrt(magSqr(angularDirection));
|
||||||
angularDirection.write();
|
angularDirection.write();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user