mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: Use scalar lookup instead of dimensionedScalar lookup
This commit is contained in:
@ -38,8 +38,8 @@ Foam::COxidationDiffusionLimitedRate<CloudType>::COxidationDiffusionLimitedRate
|
||||
)
|
||||
:
|
||||
SurfaceReactionModel<CloudType>(dict, owner, typeName),
|
||||
Sb_(dimensionedScalar(this->coeffDict().lookup("Sb")).value()),
|
||||
D_(dimensionedScalar(this->coeffDict().lookup("D")).value()),
|
||||
Sb_(readScalar(this->coeffDict().lookup("Sb"))),
|
||||
D_(readScalar(this->coeffDict().lookup("D"))),
|
||||
CsLocalId_(-1),
|
||||
O2GlobalId_(owner.composition().globalCarrierId("O2")),
|
||||
CO2GlobalId_(owner.composition().globalCarrierId("CO2")),
|
||||
|
||||
@ -42,9 +42,9 @@ COxidationKineticDiffusionLimitedRate
|
||||
owner,
|
||||
typeName
|
||||
),
|
||||
C1_(dimensionedScalar(this->coeffDict().lookup("C1")).value()),
|
||||
C2_(dimensionedScalar(this->coeffDict().lookup("C2")).value()),
|
||||
E_(dimensionedScalar(this->coeffDict().lookup("E")).value()),
|
||||
C1_(readScalar(this->coeffDict().lookup("C1"))),
|
||||
C2_(readScalar(this->coeffDict().lookup("C2"))),
|
||||
E_(readScalar(this->coeffDict().lookup("E"))),
|
||||
CsLocalId_(-1),
|
||||
O2GlobalId_(owner.composition().globalCarrierId("O2")),
|
||||
CO2GlobalId_(owner.composition().globalCarrierId("CO2")),
|
||||
|
||||
@ -50,14 +50,14 @@ Foam::COxidationMurphyShaddix<CloudType>::COxidationMurphyShaddix
|
||||
owner,
|
||||
typeName
|
||||
),
|
||||
D0_(dimensionedScalar(this->coeffDict().lookup("D0")).value()),
|
||||
rho0_(dimensionedScalar(this->coeffDict().lookup("rho0")).value()),
|
||||
T0_(dimensionedScalar(this->coeffDict().lookup("T0")).value()),
|
||||
Dn_(dimensionedScalar(this->coeffDict().lookup("Dn")).value()),
|
||||
A_(dimensionedScalar(this->coeffDict().lookup("A")).value()),
|
||||
E_(dimensionedScalar(this->coeffDict().lookup("E")).value()),
|
||||
n_(dimensionedScalar(this->coeffDict().lookup("n")).value()),
|
||||
WVol_(dimensionedScalar(this->coeffDict().lookup("WVol")).value()),
|
||||
D0_(readScalar(this->coeffDict().lookup("D0"))),
|
||||
rho0_(readScalar(this->coeffDict().lookup("rho0"))),
|
||||
T0_(readScalar(this->coeffDict().lookup("T0"))),
|
||||
Dn_(readScalar(this->coeffDict().lookup("Dn"))),
|
||||
A_(readScalar(this->coeffDict().lookup("A"))),
|
||||
E_(readScalar(this->coeffDict().lookup("E"))),
|
||||
n_(readScalar(this->coeffDict().lookup("n"))),
|
||||
WVol_(readScalar(this->coeffDict().lookup("WVol"))),
|
||||
CsLocalId_(-1),
|
||||
O2GlobalId_(owner.composition().globalCarrierId("O2")),
|
||||
CO2GlobalId_(owner.composition().globalCarrierId("CO2")),
|
||||
|
||||
@ -89,9 +89,9 @@ Foam::PairSpringSliderDashpot<CloudType>::PairSpringSliderDashpot
|
||||
PairModel<CloudType>(dict, cloud, typeName),
|
||||
Estar_(),
|
||||
Gstar_(),
|
||||
alpha_(dimensionedScalar(this->coeffDict().lookup("alpha")).value()),
|
||||
b_(dimensionedScalar(this->coeffDict().lookup("b")).value()),
|
||||
mu_(dimensionedScalar(this->coeffDict().lookup("mu")).value()),
|
||||
alpha_(readScalar(this->coeffDict().lookup("alpha"))),
|
||||
b_(readScalar(this->coeffDict().lookup("b"))),
|
||||
mu_(readScalar(this->coeffDict().lookup("mu"))),
|
||||
collisionResolutionSteps_
|
||||
(
|
||||
readScalar
|
||||
|
||||
@ -224,26 +224,19 @@ Foam::WallLocalSpringSliderDashpot<CloudType>::WallLocalSpringSliderDashpot
|
||||
|
||||
patchMap_[wallPatchIndices[wPI]] = wPI;
|
||||
|
||||
scalar nu = dimensionedScalar
|
||||
(
|
||||
patchCoeffDict.lookup("poissonsRatio")
|
||||
).value();
|
||||
scalar nu = readScalar(patchCoeffDict.lookup("poissonsRatio"));
|
||||
|
||||
scalar E = dimensionedScalar
|
||||
(
|
||||
patchCoeffDict.lookup("youngsModulus")
|
||||
).value();
|
||||
scalar E = readScalar(patchCoeffDict.lookup("youngsModulus"));
|
||||
|
||||
Estar_[wPI] = 1/((1 - sqr(pNu))/pE + (1 - sqr(nu))/E);
|
||||
|
||||
Gstar_[wPI] = 1/(2*((2 + pNu - sqr(pNu))/pE + (2 + nu - sqr(nu))/E));
|
||||
|
||||
alpha_[wPI] =
|
||||
dimensionedScalar(patchCoeffDict.lookup("alpha")).value();
|
||||
alpha_[wPI] = readScalar(patchCoeffDict.lookup("alpha"));
|
||||
|
||||
b_[wPI] = dimensionedScalar(patchCoeffDict.lookup("b")).value();
|
||||
b_[wPI] = readScalar(patchCoeffDict.lookup("b"));
|
||||
|
||||
mu_[wPI] = dimensionedScalar(patchCoeffDict.lookup("mu")).value();
|
||||
mu_[wPI] = readScalar(patchCoeffDict.lookup("mu"));
|
||||
|
||||
if (Estar_[wPI] > maxEstar)
|
||||
{
|
||||
|
||||
@ -154,9 +154,9 @@ Foam::WallSpringSliderDashpot<CloudType>::WallSpringSliderDashpot
|
||||
WallModel<CloudType>(dict, cloud, typeName),
|
||||
Estar_(),
|
||||
Gstar_(),
|
||||
alpha_(dimensionedScalar(this->coeffDict().lookup("alpha")).value()),
|
||||
b_(dimensionedScalar(this->coeffDict().lookup("b")).value()),
|
||||
mu_(dimensionedScalar(this->coeffDict().lookup("mu")).value()),
|
||||
alpha_(readScalar(this->coeffDict().lookup("alpha"))),
|
||||
b_(readScalar(this->coeffDict().lookup("b"))),
|
||||
mu_(readScalar(this->coeffDict().lookup("mu"))),
|
||||
collisionResolutionSteps_
|
||||
(
|
||||
readScalar
|
||||
@ -172,15 +172,9 @@ Foam::WallSpringSliderDashpot<CloudType>::WallSpringSliderDashpot
|
||||
volumeFactor_ = readScalar(this->coeffDict().lookup("volumeFactor"));
|
||||
}
|
||||
|
||||
scalar nu = dimensionedScalar
|
||||
(
|
||||
this->coeffDict().lookup("poissonsRatio")
|
||||
).value();
|
||||
scalar nu = readScalar(this->coeffDict().lookup("poissonsRatio"));
|
||||
|
||||
scalar E = dimensionedScalar
|
||||
(
|
||||
this->coeffDict().lookup("youngsModulus")
|
||||
).value();
|
||||
scalar E = readScalar(this->coeffDict().lookup("youngsModulus"));
|
||||
|
||||
scalar pNu = this->owner().constProps().poissonsRatio();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user