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/)
-   -   Time history of wall Shear Stress. (https://www.cfd-online.com/Forums/openfoam-post-processing/128885-time-history-wall-shear-stress.html)

MaLa January 23, 2014 08:37

Time history of wall Shear Stress.
 
Hi

I need a little help. I wanted to observe how the wall Shear Stress changes over time for my case. To achieve that, I execute wallShearStress utility, which creates the wallShearStress field in all the (written) time-step folders (startTime startTime + writeInterval startTime +2*writeInterval ... and so on till endTime).

Does anybody know how I can extract the 'wall' patch value of wallShearStress from each of these folders and plot them as a function of iterations/time steps? Any comments are welcome!

alexeym January 23, 2014 09:45

Hi,

I guess there can be another solution but usually I do the following:

1. Sample values of a field (in your case wallShearStress) with sample utility; it will create folders postProcessing/surfaces/* with sampled data in them
2. Use python to iterate over created folders to read values in array [time, value]
3. Use matplotlib to plot values

Surely you can substitute python and matplotlib with preferred software.

But I is your wall shear stress constant over the wall patch?

MaLa January 29, 2014 11:25

Thanks Alexey

I did not think of using Python to extract the values from the folders, so that is a start.
I have just two cells in the x direction along the wall patch. The wallShearStress does not vary so much between them.

alexeym January 29, 2014 11:31

Hi,

Actually I've recalled more convenient way of doing what you want. There's an utility probeLocations. You create probesDict in system folder of your case (you can find example in $FOAM_APP/utilities/postProcessing/sampling/probeLocations), run the utility and it will create files in postProcessing/probes with time evolution of the field at a given location.


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