calculation of alpha and alphat

calculation of alpha and alphat in the thermophysical and trubulence library

background

  • ν\nu, kinematic viscosity, [m^2/s]
  • μ\mu, dynamic viscosity, [kg/(m*s)]
  • α\alpha, thermal diffusivity of enthalpy, [kg/(m*s)], α=λCp\alpha=\frac{\lambda}{C_p}
  • κ\kappa (OF uses kappa), i.e. λ\lambda (some papers use lambda), Thermal conductivity, [W/(m*K)]
  • Pr=νDtP_r=\frac{\nu}{D_t} diffusivity of momentum ν\nu over thermal diffusivity DtD_t, Dt=λρCpD_t=\frac{\lambda}{\rho C_p}. Yields Pr=νDt=νλ/(ρCp)=μλ/Cp=μαP_r=\frac{\nu}{D_t}=\frac{\nu}{\lambda/(\rho C_p)}=\frac{\mu}{\lambda /C_p}=\frac{\mu}{\alpha}
  • Le=DtDkL_e=\frac{D_t}{D_k} thermal diffusivity DtD_t over mass diffusion coefficient
  • Sc=νDkS_c=\frac{\nu}{D_k} diffusivity of momentum ν\nu over mass diffusion coefficient
    Assume Pr=1P_r=1, we get λ=μCp\lambda=\mu C_p, and α=μ\alpha=\mu
    Assume Le=1L_e=1, we get Dk=λρCpD_k=\frac{\lambda}{\rho C_p}
    Assume Sc=1S_c=1, we get Dk=νD_k=\nu

in OpenFOAM

moleWeight_ can be accessed by W(), [kg/kmol]
cp, [J/(kmolK)]
C_p=\frac{cv}{W}, [J/(kg
K)], general use this in many books.
h_s, [J/kmol]
H_s, [J/kg]

calculation of alpha and alphat

本文代码几乎全部在 /src/thermophysicalModels 文件夹下。

代码在 /basic/psiThermo/hePsiThermo.C 中:

forAll(TCells, celli)
{
const typename MixtureType::thermoType& mixture_ =
this->cellMixture(celli);
TCells[celli] = mixture_.THE
(
hCells[celli],
pCells[celli],
TCells[celli]
);
psiCells[celli] = mixture_.psi(pCells[celli], TCells[celli]);
muCells[celli] = mixture_.mu(pCells[celli], TCells[celli]);
alphaCells[celli] = mixture_.alphah(pCells[celli], TCells[celli]);
}

/specie/transport/sutherland/sutherlandTransportI.H

template<class Thermo>
inline Foam::scalar Foam::sutherlandTransport<Thermo>::alphah
(
const scalar p,
const scalar T
) const
{
return kappa(p, T)/this->Cp(p, T);
}

RASModel.H

virtual tmp<volScalarField> alphaEff() const
{
return thermo().alphaEff(alphat());
}

heThermo.C

template<class BasicThermo, class MixtureType>
Foam::tmp<Foam::volScalarField>
Foam::heThermo<BasicThermo, MixtureType>::alphaEff
(
const volScalarField& alphat
) const
{
tmp<Foam::volScalarField> alphaEff(this->CpByCpv()*(this->alpha_ + alphat));
alphaEff().rename("alphaEff");
return alphaEff;
}
其中理想气体的 CpByCpv 等于 1

这里的 alpha_ 是层流的,另外alpha()函数会返回alpha_,通过修改aloha()函数也能更新alpha_

alphat()在哪里计算?

KEpsilon.H

//- Return the turbulence thermal diffusivity
virtual tmp<volScalarField> alphat() const
{
return alphat_;
}

KEpsilon.C在构造函数里边:

mut_ = Cmu_*rho_*sqr(k_)/epsilon_;
alphat_ = mut_/Prt_;
Author: Yan Zhang
Link: https://openfoam.top/alpha/
Copyright Notice: All articles in this blog are licensed under CC BY-NC-SA 4.0 unless stating additionally.
微信打赏