CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Post-Processing (https://www.cfd-online.com/Forums/openfoam-post-processing/)
-   -   plot of wall shear stress and turbulent properties (average of u'u', v'v', u'v' ) (https://www.cfd-online.com/Forums/openfoam-post-processing/180284-plot-wall-shear-stress-turbulent-properties-average-uu-vv-uv.html)

srv537 November 20, 2016 15:07

plot of wall shear stress and turbulent properties (average of u'u', v'v', u'v' )
 
i am beginner in OpenFoam CFD simulation and learning from youtube tutorial, i learned case setup and simple post processing in Paraview.

i used k-e and kw model but i cant able to plot fluctuating (prime) quantities, in paraview there is only mean pressure and velocity are available.

how can i create some variable that is not default in solver, i want to plot
1. wall shear stress or skin friction coefficient, coefficient of pressure, drag and lift coefficient.
2. turbulent properties (average of u'u', v'v', u'v' )

please help me, i cant able to plot all these result.

Thank you
Saurav kumar

alekhine December 28, 2016 08:24

Hey Foamers,

I have the same issue. A reply to this post would be really helpful.

Regards,
Dimitri

Bazinga December 29, 2016 02:52

When using RANS simualtions with k-epsilon or k-omega you are not calculating the Reynolds stresses - you are only modeling the fluctuations by the k-transport equation. Thus, you have no results for u'u' etc.
Pressure is calculated - in order to get the pressure coefficient you need to divide by the dynamic pressure of the flow. You can do that in Paraview, check some other threads here in the forum for that, or use the OpenFOAM tutorials.

Drag and lift coefficient can be automatically calculated during runtime by a functionObject in the controlDict file. Again, search the forum.

Hope that helps. If you have problems even after searching for the solutions let me know.

srv537 December 29, 2016 03:18

Hi Bazinga,

i can use wallShearStress to calculate stress and Skin Friction Coeff, it is working in simpleFoam but it is not working in icoFoam, what should i do?

i added energy equation in icoFoam and compared temperature and velocity profile at various section in streamwise direction with the fluent result both are exact same but the problem is i dont know to to calculate local Nusselt number at wall.
how can i calculate local Nusselt Number?

Thank you
Srv

Bazinga December 29, 2016 03:23

I have not yet calculated the Nusselt number but a simple google search gave me this report:

http://www.tfd.chalmers.se/~hani/kur...ssonReport.pdf

With regard to wallShearStress what is the error?

srv537 December 29, 2016 04:02

icoFoam -postProcess -func wallShearStress it gives me


Usage: icoFoam [OPTIONS]
options:
-case <dir> specify alternate case directory, default is the cwd
-noFunctionObjects
do not execute functionObjects
-parallel run in parallel
-roots <(dir1 .. dirN)>
slave root directories for distributed running
-srcDoc display source code in browser
-doc display application documentation in browser
-help print the usage

Using: OpenFOAM-4.1 (see www.OpenFOAM.org)
Build: 4.1



--> FOAM FATAL ERROR:
Wrong number of arguments, expected 0 found 1
Invalid option: -postProcess
Invalid option: -func


FOAM exiting

Bazinga December 29, 2016 06:15

You should start to first search for your problem in this board, then google and then ask your questions in your own threads.

One simple search, again, provided this link:

https://www.cfd-online.com/Forums/op...s-why-how.html

There you will find an answer to your problem.

Also, please do not create multiple threads/post with the same question. I found your thread (https://www.cfd-online.com/Forums/op...d-icofoam.html) while searching for your problem.

alekhine December 29, 2016 06:21

Hey Bazinga,

Thank you for your thorough explanation!

I have some results for the Reynolds stress from experiments and other numerical simulation and I thought I can get something out of OpenFOAM for comparison. You are right, the solved equations just give the variables you solve for. Maybe I can do some manual calculation with the outputted data to get the Reynolds stress.

Getting the coefficients works!

Cheers,
Dimitri

Bazinga December 29, 2016 06:28

Maybe you can validate the turbulent kinetic energy k. k = 0.5*(U'2+V'2+W'2) (check: https://en.wikipedia.org/wiki/Turbulence_kinetic_energy). If you know the RE-stresses from experiment, you can calculate k from the experiment and then validate with your simulation. :)

alekhine December 29, 2016 07:27

That would be an idea! I will try to do that for sure to have something for comparison.

I have an understanding problem though...if I use e.g. the Spalart Allmaras turbulence model, is there a way how I can get a value for my turbulent kinetic energy k? In my understanding, OpenFOAM does not compute k when the SA model is used.

Dimitri

Bazinga December 29, 2016 07:43

I would use the k-omega one, but if you need S.A. there is one way, but I don't think it is really accurate and never tried it.

IIRC S.A. calculates the eddy viscosity by means of a length scale, which is defined by the user, and k, which is modeled directly from this length scale in order to close the system of equations.

Look up the relation between those 3 values and I guess you get a k, but as said earlier,I never tried it.

alekhine December 29, 2016 10:44

That would be one way to get the kinetic energy. However, since Boussinesq approximation is used, you can calculate a posteriori the Reynolds stress from known, transported quantities. This calculation could be done manually.

However, I found two other ways how to get it directly from openFoam. The first way is to use the integrated post processing tools of OpenFOAM (http://cfd.direct/openfoam/user-guide/post-processing-cli/#x31-2270006.2).This gives the Reynolds stress tensor. The turbulent kinetic energy is proportional to the trace of the tensor.
The second way is to use a tool someone wrote (https://www.cfd-online.com/Forums/op...ields-les.html). I haven't tried it though.

This might also help you Saurav kumar.

Thank you for pointing me in the right direction Bazinga! :-)

Bazinga December 29, 2016 11:10

Quote:

Originally Posted by alekhine (Post 631525)
That would be one way to get the kinetic energy. However, since Boussinesq approximation is used, you can calculate a posteriori the Reynolds stress from known, transported quantities. This calculation could be done manually.

However, I found two other ways how to get it directly from openFoam. The first way is to use the integrated post processing tools of OpenFOAM (http://cfd.direct/openfoam/user-guide/post-processing-cli/#x31-2270006.2).This gives the Reynolds stress tensor. The turbulent kinetic energy is proportional to the trace of the tensor.
The second way is to use a tool someone wrote (https://www.cfd-online.com/Forums/op...ields-les.html). I haven't tried it though.

This might also help you Saurav kumar.

Thank you for pointing me in the right direction Bazinga! :-)

Ah, yes! Thanks for the update and good luck.


All times are GMT -4. The time now is 15:36.