CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   rhoCentralFoam engergy equation (https://www.cfd-online.com/Forums/openfoam-programming-development/196542-rhocentralfoam-engergy-equation.html)

haoyuan December 7, 2017 07:47

rhoCentralFoam engergy equation
 
Hi Foamers,
I recently study the compressible solver rhoCentralFoam in OpenFOAM V4.1. I need to add some non-linear turbulence model in this solver, the viscous term in the present solver is not capable of the non-linear shear stress.

I replace " - fvm::laplacian(muEff, U) - fvc::div(tauMC)' in the momentum equation with turbulence->divDevRhoReff, and it seems to work fine.

However, I replace the "sigmaDotU" in the energy equation with (fvc::dotInterpolate(mesh.Sf(), -devRhoReff))& (a_pos*U_pos + a_neg*U_neg), it goes wrong.

In my opinion, "(muEff)*fvc::grad(U) + tauMC" is the same as "-devRhoReff", which is "((this->alpha_*this->rho_*this->nuEff()))*dev(twoSymm(fvc::grad(this->U_)))" .

Please note that there is a "-" in the functions of "devRhoReff".

Am I right? Does anyone have a similar experience about this?

Regards,

Haoyuan


All times are GMT -4. The time now is 16:24.