CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   Production of Turbulent Kinetic Energy (http://www.cfd-online.com/Forums/openfoam/83068-production-turbulent-kinetic-energy.html)

johndeas December 13, 2010 17:07

Production of Turbulent Kinetic Energy
 
Hi,

I need to compute the term \overline{u'_iu'_j}\frac{\partial \overline{u}_i}{\partial x_j}. If R is the volSymmTensorField containing the Reynolds stress, and Umean the mean velocity vector, is this the correct way to compute it ?

Code:

R.component(tensor::XX)*fvc::grad(Umean)().component(tensor::XX)+
R.component(tensor::XY)*fvc::grad(Umean)().component(tensor::XY)+
R.component(tensor::XZ)*fvc::grad(Umean)().component(tensor::XZ)+
R.component(tensor::YX)*fvc::grad(Umean)().component(tensor::YX)+
R.component(tensor::YY)*fvc::grad(Umean)().component(tensor::YY)+
R.component(tensor::YZ)*fvc::grad(Umean)().component(tensor::YZ)+
R.component(tensor::ZX)*fvc::grad(Umean)().component(tensor::ZX)+
R.component(tensor::ZY)*fvc::grad(Umean)().component(tensor::ZY)+
R.component(tensor::ZZ)*fvc::grad(Umean)().component(tensor::ZZ)

Thanks,

JD

boger December 14, 2010 09:22

Okay, but you might first have a look at the available operators. For example, something like
Code:

R && fvc::grad(Umean)
might be cleaner.


All times are GMT -4. The time now is 11:57.