Commit 6c7f869d authored by Andrew Heather's avatar Andrew Heather
Browse files

STYLE: refactored cp -> Cp

parent 325279dd
......@@ -148,8 +148,8 @@ void Foam::surfaceFilmModels::standardPhaseChange::correct
const scalar qDotInf = hInf[cellI]*(TInf[cellI] - T[cellI]);
const scalar qDotFilm = hFilm[cellI]*(T[cellI] - Tw[cellI]);
const scalar cp = liq.cp(pc, Tloc);
const scalar qCorr = availableMass[cellI]*cp*(T[cellI] - Tb_);
const scalar Cp = liq.Cp(pc, Tloc);
const scalar qCorr = availableMass[cellI]*Cp*(T[cellI] - Tb_);
dMass[cellI] =
dt*magSf[cellI]/hVap*(qDotInf + qDotFilm)
+ qCorr/hVap;
......
......@@ -1116,12 +1116,12 @@ Foam::surfaceFilmModels::kinematicSingleLayer::Tw() const
const Foam::volScalarField&
Foam::surfaceFilmModels::kinematicSingleLayer::cp() const
Foam::surfaceFilmModels::kinematicSingleLayer::Cp() const
{
FatalErrorIn
(
"const volScalarField& kinematicSingleLayer::cp() const"
) << "cp field not available for " << type() << abort(FatalError);
"const volScalarField& kinematicSingleLayer::Cp() const"
) << "Cp field not available for " << type() << abort(FatalError);
return volScalarField::null();
}
......
......@@ -401,7 +401,7 @@ public:
virtual const volScalarField& Tw() const;
//- Return the film specific heat capacity [J/kg/K]
virtual const volScalarField& cp() const;
virtual const volScalarField& Cp() const;
//- Return the film thermal conductivity [W/m/K]
virtual const volScalarField& kappa() const;
......
......@@ -199,10 +199,10 @@ const Foam::volScalarField& Foam::surfaceFilmModels::noFilm::Tw() const
}
const Foam::volScalarField& Foam::surfaceFilmModels::noFilm::cp() const
const Foam::volScalarField& Foam::surfaceFilmModels::noFilm::Cp() const
{
FatalErrorIn("const volScalarField& noFilm::cp() const")
<< "cp field not available for " << type() << abort(FatalError);
FatalErrorIn("const volScalarField& noFilm::Cp() const")
<< "Cp field not available for " << type() << abort(FatalError);
return volScalarField::null();
}
......
......@@ -148,7 +148,7 @@ public:
virtual const volScalarField& Tw() const;
//- Return the film specific heat capacity [J/kg/K]
virtual const volScalarField& cp() const;
virtual const volScalarField& Cp() const;
//- Return the film thermal conductivity [W/m/K]
virtual const volScalarField& kappa() const;
......
......@@ -242,7 +242,7 @@ public:
virtual const volScalarField& Tw() const = 0;
//- Return the film specific heat capacity [J/kg/K]
virtual const volScalarField& cp() const = 0;
virtual const volScalarField& Cp() const = 0;
//- Return the film thermal conductivity [W/m/K]
virtual const volScalarField& kappa() const = 0;
......
......@@ -74,7 +74,7 @@ void Foam::surfaceFilmModels::thermoSingleLayer::correctThermoFields()
rho_ == dimensionedScalar(coeffs_.lookup("rho0"));
mu_ == dimensionedScalar(coeffs_.lookup("mu0"));
sigma_ == dimensionedScalar(coeffs_.lookup("sigma0"));
cp_ == dimensionedScalar(coeffs_.lookup("cp0"));
Cp_ == dimensionedScalar(coeffs_.lookup("Cp0"));
kappa_ == dimensionedScalar(coeffs_.lookup("kappa0"));
break;
......@@ -89,14 +89,14 @@ void Foam::surfaceFilmModels::thermoSingleLayer::correctThermoFields()
rho_[cellI] = liq.rho(p, T);
mu_[cellI] = liq.mu(p, T);
sigma_[cellI] = liq.sigma(p, T);
cp_[cellI] = liq.cp(p, T);
Cp_[cellI] = liq.Cp(p, T);
kappa_[cellI] = liq.K(p, T);
}
rho_.correctBoundaryConditions();
mu_.correctBoundaryConditions();
sigma_.correctBoundaryConditions();
cp_.correctBoundaryConditions();
Cp_.correctBoundaryConditions();
kappa_.correctBoundaryConditions();
break;
......@@ -188,8 +188,8 @@ Foam::tmp<Foam::fvScalarMatrix> Foam::surfaceFilmModels::thermoSingleLayer::q
return
(
- fvm::Sp(htcs_->h()/cp_, hs) - htcs_->h()*(Tstd - TPrimary_)
- fvm::Sp(htcw_->h()/cp_, hs) - htcw_->h()*(Tstd - Tw_)
- fvm::Sp(htcs_->h()/Cp_, hs) - htcs_->h()*(Tstd - TPrimary_)
- fvm::Sp(htcw_->h()/Cp_, hs) - htcw_->h()*(Tstd - Tw_)
);
}
......@@ -236,18 +236,18 @@ Foam::surfaceFilmModels::thermoSingleLayer::thermoSingleLayer
kinematicSingleLayer(modelType, mesh, g),
thermo_(mesh.lookupObject<SLGThermo>("SLGThermo")),
liquidId_(thermo_.liquidId(coeffs_.lookup("liquid"))),
cp_
Cp_
(
IOobject
(
"cp",
"Cp",
time_.timeName(),
filmRegion_,
IOobject::NO_READ,
IOobject::AUTO_WRITE
),
filmRegion_,
dimensionedScalar("cp", dimEnergy/dimMass/dimTemperature, 0.0),
dimensionedScalar("Cp", dimEnergy/dimMass/dimTemperature, 0.0),
zeroGradientFvPatchScalarField::typeName
),
kappa_
......@@ -526,9 +526,9 @@ void Foam::surfaceFilmModels::thermoSingleLayer::evolveFilm()
const Foam::volScalarField&
Foam::surfaceFilmModels::thermoSingleLayer::cp() const
Foam::surfaceFilmModels::thermoSingleLayer::Cp() const
{
return cp_;
return Cp_;
}
......
......@@ -27,7 +27,7 @@ Class
Description
Thermodynamic form of single-cell layer surface film model
Note: defining enthalpy as cp(T - Tstd) - when using liquids from the
Note: defining enthalpy as Cp(T - Tstd) - when using liquids from the
thermophysical library, their enthalpies are calculated similarly, where
Tstd = 298.15 K
......@@ -90,7 +90,7 @@ protected:
// Fields
//- Specific heat capacity / [J/kg/K]
volScalarField cp_;
volScalarField Cp_;
//- Thermal conductivity / [W/m/K]
volScalarField kappa_;
......@@ -218,7 +218,7 @@ public:
// Fields
//- Return the film specific heat capacity [J/kg/K]
virtual const volScalarField& cp() const;
virtual const volScalarField& Cp() const;
//- Return the film thermal conductivity [W/m/K]
virtual const volScalarField& kappa() const;
......
......@@ -61,7 +61,7 @@ Foam::surfaceFilmModels::thermoSingleLayer::hs
IOobject::NO_READ,
IOobject::NO_WRITE
),
cp_*(T - Tstd),
Cp_*(T - Tstd),
zeroGradientFvPatchScalarField::typeName
)
);
......@@ -88,7 +88,7 @@ Foam::surfaceFilmModels::thermoSingleLayer::T
IOobject::NO_READ,
IOobject::NO_WRITE
),
hs/cp_ + Tstd,
hs/Cp_ + Tstd,
zeroGradientFvPatchScalarField::typeName
)
);
......
......@@ -256,25 +256,25 @@ Foam::scalar Foam::liquidMixture::hl
}
Foam::scalar Foam::liquidMixture::cp
Foam::scalar Foam::liquidMixture::Cp
(
const scalar p,
const scalar T,
const scalarField& x
) const
{
scalar cp = 0.0;
scalar Cp = 0.0;
forAll(properties_, i)
{
if (x[i] > SMALL)
{
scalar Ti = min(TrMax*properties_[i].Tc(), T);
cp += x[i]*properties_[i].cp(p, Ti)*properties_[i].W();
Cp += x[i]*properties_[i].Cp(p, Ti)*properties_[i].W();
}
}
return cp/W(x);
return Cp/W(x);
}
......
......@@ -207,7 +207,7 @@ public:
) const;
//- Calculate the mixture heat capacity [J/(kg K)]
scalar cp
scalar Cp
(
const scalar p,
const scalar T,
......
......@@ -57,7 +57,7 @@ Foam::Ar::Ar()
rho_(151.922244, 0.286, 150.86, 0.2984),
pv_(39.233, -1051.7, -3.5895, 5.0444e-05, 2),
hl_(150.86, 218509.061780314, 0.352, 0.0, 0.0, 0.0),
cp_(4562.43116050866, -70.7770101131471, 0.367477721037349, 0.0, 0.0, 0.0),
Cp_(4562.43116050866, -70.7770101131471, 0.367477721037349, 0.0, 0.0, 0.0),
h_
(
-1460974.49982473,
......@@ -67,7 +67,7 @@ Foam::Ar::Ar()
0.0,
0.0
),
cpg_(520.326424351657, 0.0, 0.0, 0.0, 0.0, 0.0),
Cpg_(520.326424351657, 0.0, 0.0, 0.0, 0.0, 0.0),
B_
(
0.000952488234705117,
......@@ -107,9 +107,9 @@ Foam::Ar::Ar
rho_(density),
pv_(vapourPressure),
hl_(heatOfVapourisation),
cp_(heatCapacity),
Cp_(heatCapacity),
h_(enthalpy),
cpg_(idealGasHeatCapacity),
Cpg_(idealGasHeatCapacity),
B_(secondVirialCoeff),
mu_(dynamicViscosity),
mug_(vapourDynamicViscosity),
......@@ -126,9 +126,9 @@ Foam::Ar::Ar(Istream& is)
rho_(is),
pv_(is),
hl_(is),
cp_(is),
Cp_(is),
h_(is),
cpg_(is),
Cpg_(is),
B_(is),
mu_(is),
mug_(is),
......@@ -145,9 +145,9 @@ Foam::Ar::Ar(const dictionary& dict)
rho_(dict.subDict("rho")),
pv_(dict.subDict("pv")),
hl_(dict.subDict("hl")),
cp_(dict.subDict("cp")),
Cp_(dict.subDict("Cp")),
h_(dict.subDict("h")),
cpg_(dict.subDict("cpg")),
Cpg_(dict.subDict("Cpg")),
B_(dict.subDict("B")),
mu_(dict.subDict("mu")),
mug_(dict.subDict("mug")),
......
......@@ -65,9 +65,9 @@ class Ar
NSRDSfunc5 rho_;
NSRDSfunc1 pv_;
NSRDSfunc6 hl_;
NSRDSfunc0 cp_;
NSRDSfunc0 Cp_;
NSRDSfunc0 h_;
NSRDSfunc0 cpg_;
NSRDSfunc0 Cpg_;
NSRDSfunc4 B_;
NSRDSfunc1 mu_;
NSRDSfunc2 mug_;
......@@ -126,13 +126,13 @@ public:
inline scalar hl(scalar p, scalar T) const;
//- Liquid heat capacity [J/(kg K)]
inline scalar cp(scalar p, scalar T) const;
inline scalar Cp(scalar p, scalar T) const;
//- Liquid Enthalpy [J/(kg)]
inline scalar h(scalar p, scalar T) const;
//- Ideal gas heat capacity [J/(kg K)]
inline scalar cpg(scalar p, scalar T) const;
inline scalar Cpg(scalar p, scalar T) const;
//- Second Virial Coefficient [m^3/kg]
inline scalar B(scalar p, scalar T) const;
......@@ -168,8 +168,8 @@ public:
rho_.writeData(os); os << nl;
pv_.writeData(os); os << nl;
hl_.writeData(os); os << nl;
cp_.writeData(os); os << nl;
cpg_.writeData(os); os << nl;
Cp_.writeData(os); os << nl;
Cpg_.writeData(os); os << nl;
B_.writeData(os); os << nl;
mu_.writeData(os); os << nl;
mug_.writeData(os); os << nl;
......
......@@ -41,9 +41,9 @@ inline Foam::scalar Foam::Ar::hl(scalar p, scalar T) const
}
inline Foam::scalar Foam::Ar::cp(scalar p, scalar T) const
inline Foam::scalar Foam::Ar::Cp(scalar p, scalar T) const
{
return cp_.f(p, T);
return Cp_.f(p, T);
}
......@@ -53,9 +53,9 @@ inline Foam::scalar Foam::Ar::h(scalar p, scalar T) const
}
inline Foam::scalar Foam::Ar::cpg(scalar p, scalar T) const
inline Foam::scalar Foam::Ar::Cpg(scalar p, scalar T) const
{
return cpg_.f(p, T);
return Cpg_.f(p, T);
}
......
......@@ -57,7 +57,7 @@ Foam::C10H22::C10H22()
rho_(60.94208835, 0.25745, 617.7, 0.28912),
pv_(112.73, -9749.6, -13.245, 7.1266e-06, 2.0),
hl_(617.70, 464743.296904101, 0.39797, 0.0, 0.0, 0.0),
cp_
Cp_
(
1958.18252099659,
-1.39094071757388,
......@@ -75,7 +75,7 @@ Foam::C10H22::C10H22()
0.0,
0.0
),
cpg_(1175.10630073444, 3762.16748076045, 1614.1, 2658.04547211582, 742),
Cpg_(1175.10630073444, 3762.16748076045, 1614.1, 2658.04547211582, 742),
B_
(
0.00337351091119935,
......@@ -115,9 +115,9 @@ Foam::C10H22::C10H22
rho_(density),
pv_(vapourPressure),
hl_(heatOfVapourisation),
cp_(heatCapacity),
Cp_(heatCapacity),
h_(enthalpy),
cpg_(idealGasHeatCapacity),
Cpg_(idealGasHeatCapacity),
B_(secondVirialCoeff),
mu_(dynamicViscosity),
mug_(vapourDynamicViscosity),
......@@ -134,9 +134,9 @@ Foam::C10H22::C10H22(Istream& is)
rho_(is),
pv_(is),
hl_(is),
cp_(is),
Cp_(is),
h_(is),
cpg_(is),
Cpg_(is),
B_(is),
mu_(is),
mug_(is),
......@@ -153,9 +153,9 @@ Foam::C10H22::C10H22(const dictionary& dict)
rho_(dict.subDict("rho")),
pv_(dict.subDict("pv")),
hl_(dict.subDict("hl")),
cp_(dict.subDict("cp")),
Cp_(dict.subDict("Cp")),
h_(dict.subDict("h")),
cpg_(dict.subDict("cpg")),
Cpg_(dict.subDict("Cpg")),
B_(dict.subDict("B")),
mu_(dict.subDict("mu")),
mug_(dict.subDict("mug")),
......
......@@ -65,9 +65,9 @@ class C10H22
NSRDSfunc5 rho_;
NSRDSfunc1 pv_;
NSRDSfunc6 hl_;
NSRDSfunc0 cp_;
NSRDSfunc0 Cp_;
NSRDSfunc0 h_;
NSRDSfunc7 cpg_;
NSRDSfunc7 Cpg_;
NSRDSfunc4 B_;
NSRDSfunc1 mu_;
NSRDSfunc2 mug_;
......@@ -126,13 +126,13 @@ public:
inline scalar hl(scalar p, scalar T) const;
//- Liquid heat capacity [J/(kg K)]
inline scalar cp(scalar p, scalar T) const;
inline scalar Cp(scalar p, scalar T) const;
//- Liquid Enthalpy [J/(kg)]
inline scalar h(scalar p, scalar T) const;
//- Ideal gas heat capacity [J/(kg K)]
inline scalar cpg(scalar p, scalar T) const;
inline scalar Cpg(scalar p, scalar T) const;
//- Second Virial Coefficient [m^3/kg]
inline scalar B(scalar p, scalar T) const;
......@@ -168,8 +168,8 @@ public:
rho_.writeData(os); os << nl;
pv_.writeData(os); os << nl;
hl_.writeData(os); os << nl;
cp_.writeData(os); os << nl;
cpg_.writeData(os); os << nl;
Cp_.writeData(os); os << nl;
Cpg_.writeData(os); os << nl;
B_.writeData(os); os << nl;
mu_.writeData(os); os << nl;
mug_.writeData(os); os << nl;
......
......@@ -41,9 +41,9 @@ inline Foam::scalar Foam::C10H22::hl(scalar p, scalar T) const
}
inline Foam::scalar Foam::C10H22::cp(scalar p, scalar T) const
inline Foam::scalar Foam::C10H22::Cp(scalar p, scalar T) const
{
return cp_.f(p, T);
return Cp_.f(p, T);
}
......@@ -53,9 +53,9 @@ inline Foam::scalar Foam::C10H22::h(scalar p, scalar T) const
}
inline Foam::scalar Foam::C10H22::cpg(scalar p, scalar T) const
inline Foam::scalar Foam::C10H22::Cpg(scalar p, scalar T) const
{
return cpg_.f(p, T);
return Cpg_.f(p, T);
}
......
......@@ -57,7 +57,7 @@ Foam::C12H26::C12H26()
rho_(60.53982858, 0.25511, 658.0, 0.29368),
pv_(137.47, -11976.0, -16.698, 8.0906e-06, 2.0),
hl_(658.0, 454020.829174935, 0.40681, 0.0, 0.0, 0.0),
cp_(2983.53861146661, -8.0352006011577, 0.018207916025784, 0.0, 0.0, 0.0),
Cp_(2983.53861146661, -8.0352006011577, 0.018207916025784, 0.0, 0.0, 0.0),
h_
(
-2755166.83820769,
......@@ -67,7 +67,7 @@ Foam::C12H26::C12H26()
0.0,
0.0
),
cpg_(1250.16144371778, 3894.02247296552, 1715.5, 2650.67101879792, 777.5),
Cpg_(1250.16144371778, 3894.02247296552, 1715.5, 2650.67101879792, 777.5),
B_
(
0.00516619896910848,
......@@ -107,9 +107,9 @@ Foam::C12H26::C12H26
rho_(density),
pv_(vapourPressure),
hl_(heatOfVapourisation),
cp_(heatCapacity),
Cp_(heatCapacity),
h_(enthalpy),
cpg_(idealGasHeatCapacity),
Cpg_(idealGasHeatCapacity),
B_(secondVirialCoeff),
mu_(dynamicViscosity),
mug_(vapourDynamicViscosity),
......@@ -126,9 +126,9 @@ Foam::C12H26::C12H26(Istream& is)
rho_(is),
pv_(is),
hl_(is),
cp_(is),
Cp_(is),
h_(is),
cpg_(is),
Cpg_(is),
B_(is),
mu_(is),
mug_(is),
......@@ -145,9 +145,9 @@ Foam::C12H26::C12H26(const dictionary& dict)
rho_(dict.subDict("rho")),
pv_(dict.subDict("pv")),
hl_(dict.subDict("hl")),
cp_(dict.subDict("cp")),
Cp_(dict.subDict("Cp")),
h_(dict.subDict("h")),
cpg_(dict.subDict("cpg")),
Cpg_(dict.subDict("Cpg")),
B_(dict.subDict("B")),
mu_(dict.subDict("mu")),
mug_(dict.subDict("mug")),
......
......@@ -65,9 +65,9 @@ class C12H26
NSRDSfunc5 rho_;
NSRDSfunc1 pv_;
NSRDSfunc6 hl_;
NSRDSfunc0 cp_;
NSRDSfunc0 Cp_;
NSRDSfunc0 h_;
NSRDSfunc7 cpg_;
NSRDSfunc7 Cpg_;
NSRDSfunc4 B_;
NSRDSfunc1 mu_;
NSRDSfunc2 mug_;
......@@ -126,13 +126,13 @@ public:
inline scalar hl(scalar p, scalar T) const;
//- Liquid heat capacity [J/(kg K)]
inline scalar cp(scalar p, scalar T) const;
inline scalar Cp(scalar p, scalar T) const;
//- Liquid Enthalpy [J/(kg)]
inline scalar h(scalar p, scalar T) const;
//- Ideal gas heat capacity [J/(kg K)]
inline scalar cpg(scalar p, scalar T) const;
inline scalar Cpg(scalar p, scalar T) const;
//- Second Virial Coefficient [m^3/kg]
inline scalar B(scalar p, scalar T) const;
......@@ -168,8 +168,8 @@ public:
rho_.writeData(os); os << nl;
pv_.writeData(os); os << nl;
hl_.writeData(os); os << nl;
cp_.writeData(os); os << nl;
cpg_.writeData(os); os << nl;
Cp_.writeData(os); os << nl;
Cpg_.writeData(os); os << nl;
B_.writeData(os); os << nl;
mu_.writeData(os); os << nl;
mug_.writeData(os); os << nl;
......
......@@ -41,9 +41,9 @@ inline Foam::scalar Foam::C12H26::hl(scalar p, scalar T) const
}
inline Foam::scalar Foam::C12H26::cp(scalar p, scalar T) const
inline Foam::scalar Foam::C12H26::Cp(scalar p, scalar T) const
{