diff --git a/applications/solvers/compressible/rhoCentralFoam/createFields.H b/applications/solvers/compressible/rhoCentralFoam/createFields.H index daf3a88435..fc65b3e5b4 100644 --- a/applications/solvers/compressible/rhoCentralFoam/createFields.H +++ b/applications/solvers/compressible/rhoCentralFoam/createFields.H @@ -7,7 +7,7 @@ autoPtr pThermo basicPsiThermo& thermo = pThermo(); volScalarField& p = thermo.p(); -volScalarField& h = thermo.h(); +volScalarField& e = thermo.e(); const volScalarField& T = thermo.T(); const volScalarField& psi = thermo.psi(); const volScalarField& mu = thermo.mu(); @@ -70,7 +70,7 @@ volScalarField rhoE IOobject::NO_READ, IOobject::NO_WRITE ), - rho*(h + 0.5*magSqr(U)) - p + rho*(e + 0.5*magSqr(U)) ); surfaceScalarField pos diff --git a/applications/solvers/compressible/rhoCentralFoam/rhoCentralFoam.C b/applications/solvers/compressible/rhoCentralFoam/rhoCentralFoam.C index f418f17637..f01a2d5a8a 100644 --- a/applications/solvers/compressible/rhoCentralFoam/rhoCentralFoam.C +++ b/applications/solvers/compressible/rhoCentralFoam/rhoCentralFoam.C @@ -76,10 +76,10 @@ int main(int argc, char *argv[]) surfaceScalarField rPsi_neg = fvc::interpolate(rPsi, neg, "reconstruct(T)"); - surfaceScalarField h_pos = - fvc::interpolate(h, pos, "reconstruct(T)"); - surfaceScalarField h_neg = - fvc::interpolate(h, neg, "reconstruct(T)"); + surfaceScalarField e_pos = + fvc::interpolate(e, pos, "reconstruct(T)"); + surfaceScalarField e_neg = + fvc::interpolate(e, neg, "reconstruct(T)"); surfaceVectorField U_pos = rhoU_pos/rho_pos; surfaceVectorField U_neg = rhoU_neg/rho_neg; @@ -132,8 +132,8 @@ int main(int argc, char *argv[]) + (a_pos*p_pos + a_neg*p_neg)*mesh.Sf(); surfaceScalarField phiEp = - aphiv_pos*rho_pos*(h_pos + 0.5*magSqr(U_pos)) - + aphiv_neg*rho_neg*(h_neg + 0.5*magSqr(U_neg)) + aphiv_pos*(rho_pos*(e_pos + 0.5*magSqr(U_pos)) + p_pos) + + aphiv_neg*(rho_neg*(e_neg + 0.5*magSqr(U_neg)) + p_neg) + aSf*p_pos - aSf*p_neg; volTensorField tauMC("tauMC", mu*dev2(fvc::grad(U)().T())); @@ -156,7 +156,7 @@ int main(int argc, char *argv[]) { solve ( - fvm::ddt(rho, U) - fvc::ddt(rho,U) + fvm::ddt(rho, U) - fvc::ddt(rho, U) - fvm::laplacian(mu, U) - fvc::div(tauMC) ); @@ -180,28 +180,27 @@ int main(int argc, char *argv[]) - fvc::div(sigmaDotU) ); - h = (rhoE + p)/rho - 0.5*magSqr(U); - h.correctBoundaryConditions(); + e = rhoE/rho - 0.5*magSqr(U); + e.correctBoundaryConditions(); thermo.correct(); rhoE.boundaryField() = rho.boundaryField()* ( - h.boundaryField() + 0.5*magSqr(U.boundaryField()) - ) - - p.boundaryField(); + e.boundaryField() + 0.5*magSqr(U.boundaryField()) + ); if (!inviscid) { volScalarField k("k", thermo.Cp()*mu/Pr); solve ( - fvm::ddt(rho, h) - fvc::ddt(rho, h) - - fvm::laplacian(thermo.alpha(), h) - + fvc::laplacian(thermo.alpha(), h) + fvm::ddt(rho, e) - fvc::ddt(rho, e) + - fvm::laplacian(thermo.alpha(), e) + + fvc::laplacian(thermo.alpha(), e) - fvc::laplacian(k, T) ); thermo.correct(); - rhoE = rho*(h + 0.5*magSqr(U)) - p; + rhoE = rho*(e + 0.5*magSqr(U)); } p.dimensionedInternalField() = diff --git a/src/thermophysicalModels/basic/psiThermo/ePsiThermo/ePsiThermos.C b/src/thermophysicalModels/basic/psiThermo/ePsiThermo/ePsiThermos.C index 0517a06ec2..886f703915 100644 --- a/src/thermophysicalModels/basic/psiThermo/ePsiThermo/ePsiThermos.C +++ b/src/thermophysicalModels/basic/psiThermo/ePsiThermo/ePsiThermos.C @@ -29,6 +29,7 @@ License #include "perfectGas.H" #include "eConstThermo.H" +#include "hConstThermo.H" #include "janafThermo.H" #include "specieThermo.H" @@ -63,6 +64,24 @@ makeBasicPsiThermo perfectGas ); +makeBasicPsiThermo +( + ePsiThermo, + pureMixture, + constTransport, + hConstThermo, + perfectGas +); + +makeBasicPsiThermo +( + ePsiThermo, + pureMixture, + sutherlandTransport, + hConstThermo, + perfectGas +); + makeBasicPsiThermo ( ePsiThermo, diff --git a/tutorials/compressible/rhoCentralFoam/LadenburgJet60psi/constant/thermophysicalProperties b/tutorials/compressible/rhoCentralFoam/LadenburgJet60psi/constant/thermophysicalProperties index b1205e97f4..55925db292 100644 --- a/tutorials/compressible/rhoCentralFoam/LadenburgJet60psi/constant/thermophysicalProperties +++ b/tutorials/compressible/rhoCentralFoam/LadenburgJet60psi/constant/thermophysicalProperties @@ -15,7 +15,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -thermoType hPsiThermo>>>>; +thermoType ePsiThermo>>>>; mixture air 1 28.96 1004.5 0 1.458e-06 110.4; diff --git a/tutorials/compressible/rhoCentralFoam/biconic25-55Run35/constant/thermophysicalProperties b/tutorials/compressible/rhoCentralFoam/biconic25-55Run35/constant/thermophysicalProperties index 235296e9d8..b156eb8224 100644 --- a/tutorials/compressible/rhoCentralFoam/biconic25-55Run35/constant/thermophysicalProperties +++ b/tutorials/compressible/rhoCentralFoam/biconic25-55Run35/constant/thermophysicalProperties @@ -17,7 +17,7 @@ FoamFile Pr Pr [ 0 0 0 0 0 0 0 ] 0.72; -thermoType hPsiThermo>>>>; +thermoType ePsiThermo>>>>; mixture N2 1 28.01348 100 10000 1000 2.9525407 0.0013968838 -4.9262577e-07 7.8600091e-11 -4.6074978e-15 -923.93753 5.8718221 3.5309628 -0.0001236595 -5.0299339e-07 2.4352768e-09 -1.4087954e-12 -1046.9637 2.9674391 1.458e-06 110; diff --git a/tutorials/compressible/rhoCentralFoam/forwardStep/constant/thermophysicalProperties b/tutorials/compressible/rhoCentralFoam/forwardStep/constant/thermophysicalProperties index b59bf35129..e2ad38ed54 100644 --- a/tutorials/compressible/rhoCentralFoam/forwardStep/constant/thermophysicalProperties +++ b/tutorials/compressible/rhoCentralFoam/forwardStep/constant/thermophysicalProperties @@ -15,7 +15,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -thermoType hPsiThermo>>>>; +thermoType ePsiThermo>>>>; mixture normalisedGas 1 11640.3 2.5 0 0 1; diff --git a/tutorials/compressible/rhoCentralFoam/obliqueShock/constant/thermophysicalProperties b/tutorials/compressible/rhoCentralFoam/obliqueShock/constant/thermophysicalProperties index b59bf35129..e2ad38ed54 100644 --- a/tutorials/compressible/rhoCentralFoam/obliqueShock/constant/thermophysicalProperties +++ b/tutorials/compressible/rhoCentralFoam/obliqueShock/constant/thermophysicalProperties @@ -15,7 +15,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -thermoType hPsiThermo>>>>; +thermoType ePsiThermo>>>>; mixture normalisedGas 1 11640.3 2.5 0 0 1; diff --git a/tutorials/compressible/rhoCentralFoam/shockTube/constant/thermophysicalProperties b/tutorials/compressible/rhoCentralFoam/shockTube/constant/thermophysicalProperties index b10f83c449..3992653087 100644 --- a/tutorials/compressible/rhoCentralFoam/shockTube/constant/thermophysicalProperties +++ b/tutorials/compressible/rhoCentralFoam/shockTube/constant/thermophysicalProperties @@ -15,7 +15,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -thermoType hPsiThermo>>>>; +thermoType ePsiThermo>>>>; mixture air 1 28.96 1004.5 2.544e+06 0 1; diff --git a/tutorials/compressible/rhoCentralFoam/wedge15Ma5/constant/thermophysicalProperties b/tutorials/compressible/rhoCentralFoam/wedge15Ma5/constant/thermophysicalProperties index b59bf35129..e2ad38ed54 100644 --- a/tutorials/compressible/rhoCentralFoam/wedge15Ma5/constant/thermophysicalProperties +++ b/tutorials/compressible/rhoCentralFoam/wedge15Ma5/constant/thermophysicalProperties @@ -15,7 +15,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -thermoType hPsiThermo>>>>; +thermoType ePsiThermo>>>>; mixture normalisedGas 1 11640.3 2.5 0 0 1;