|
[Sponsors] |
Incompressible LES tutorial (oodles) - time averaged statistics |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
July 8, 2009, 10:45 |
Incompressible LES tutorial (oodles) - time averaged statistics
|
#1 |
Member
Bernard Esterhuyse
Join Date: Mar 2009
Location: Pretoria, South Africa
Posts: 50
Rep Power: 17 |
Good day
I have completed the Incompressible LES tutorial (oodles pitzDaily). Viewing the results in paraFoam gives me the field values at discrete time steps throughout the simulation. However, I would like to view the average over say the last 100 steps, to view the statistics of the solution. Is there a way I can do this in paraFoam? Also, how is convergence judged in this example? Normally I judge conversion in a LES by looking at velocity at a probe point and observing the instance when this velocity starts fluctuating around a constant value. Any help on this greatly appreciated. Regards |
|
July 10, 2009, 05:47 |
|
#2 |
Senior Member
Dr. Fabian Schlegel
Join Date: Apr 2009
Location: Dresden, Germany
Posts: 222
Rep Power: 18 |
Hi,
put this in your controlDict for averaging: functions ( fieldAverage1 { // Type of functionObject type fieldAverage; // Where to load it from (if not already in solver) functionObjectLibs ("libfieldAverage.so"); // Fields to be averaged - runTime modifiable fields ( U { mean on; prime2Mean on; base time; } p { mean on; prime2Mean on; base time; } ); } ); If you want to probe points during calculation, there exists another funktion you can turn on in your controlDict: probes1 { // Type of functionObject type probes; // Where to load it from (if not already in solver) functionObjectLibs ("libsampling.so"); // Locations to be probed. runTime modifiable! probeLocations ( (0.0 0.0 0.0) ); // Fields to be probed. runTime modifiable! fields ( U p ); } |
|
July 10, 2009, 06:05 |
|
#3 |
Member
Bernard Esterhuyse
Join Date: Mar 2009
Location: Pretoria, South Africa
Posts: 50
Rep Power: 17 |
Thanks. I figured out how to do this. The problem I have was more to view the averaged values in paraView. I found that you required the UMean and PMean files in the /0 folder to enable paraFoam to load them into the postprocessor.
|
|
July 10, 2009, 06:25 |
|
#4 |
Senior Member
Dr. Fabian Schlegel
Join Date: Apr 2009
Location: Dresden, Germany
Posts: 222
Rep Power: 18 |
I do not using paraview. I prefer Tecplot, but if you turn on the fieldAverage1 function I mentioned above, you will get at every time step you write out during a run a Umean, Pmean UprimeToMean and PprimeToMean file. I am sure that paraview will load Umean and Pmean, because Tecplot does that to (to be more acurate: the foamToTecplot converter treat this fields). May be paraview will get problems with the symmetic tensor field UPrimeToMean, like the foamToTecplot converter, but I dont think so.
|
|
July 10, 2009, 07:40 |
|
#5 |
Member
Leonardo Giampani Morita
Join Date: Apr 2009
Location: Paris, France
Posts: 58
Rep Power: 17 |
Once your case is finished, I don't think it's possible to access averages if you didn't turn on fieldAverage function during runtime...neither it is possible to do an averaging like you said, over a specific period of time.
|
|
July 10, 2009, 08:01 |
|
#6 |
Member
Bernard Esterhuyse
Join Date: Mar 2009
Location: Pretoria, South Africa
Posts: 50
Rep Power: 17 |
Yes, I understand that you need to turn on averaging if you require this for your postprocessing. However, it must be possible to start averaging only after a certain time, say once you have reached psudo-convergence.
|
|
July 10, 2009, 08:37 |
|
#7 |
Member
Leonardo Giampani Morita
Join Date: Apr 2009
Location: Paris, France
Posts: 58
Rep Power: 17 |
Sure, you can follow a variable with probes and once you judge it has "converged", you go to the controlDict and change "off" to "on". So that averaging will start at that time. Then you can check averaging time in the file <time>/uniform/fieldAveragingProperties.
One important thing to know is that if you change off/on once again, averaging will restart. |
|
July 10, 2009, 08:49 |
|
#8 |
Member
Bernard Esterhuyse
Join Date: Mar 2009
Location: Pretoria, South Africa
Posts: 50
Rep Power: 17 |
Thanks, this is what I was looking for, will give it a try. How do you monitor the probe variables - do you make use of paraFoam, or do you just view the values in the console? It would be ideal to plot them.
|
|
July 10, 2009, 08:54 |
|
#9 |
Member
Leonardo Giampani Morita
Join Date: Apr 2009
Location: Paris, France
Posts: 58
Rep Power: 17 |
Since a text file is created, I open it with excel, for example, and plot data.
Hint: try to follow more than one point, at "strategic" positions, in order to make sure (or almost) a "steady-state" has been reached. |
|
July 10, 2009, 09:03 |
|
#10 |
Member
Bernard Esterhuyse
Join Date: Mar 2009
Location: Pretoria, South Africa
Posts: 50
Rep Power: 17 |
Thanks man, I'll try the excel method. I agree, more than one point is better. Still, it's sometimes hard to be certain if a "steady state" has really been reached.
|
|
July 13, 2009, 07:39 |
|
#11 |
Senior Member
Dr. Fabian Schlegel
Join Date: Apr 2009
Location: Dresden, Germany
Posts: 222
Rep Power: 18 |
Allright, it seems to me your problem is solved. OpenFoam reread the controlDict every timestep, if you have set runTimeModifiable to yes. So you can start averaging by switching between on/off. I prefer to comment out the fieldAverage1-function.
|
|
August 26, 2016, 15:57 |
time average velocity calculation LES openfoam
|
#12 |
New Member
sudhakar singh
Join Date: Jun 2016
Posts: 12
Rep Power: 10 |
Hi fs82
i am using OF3.0. when I am putting fieldAverage in controlDict file, it is showing the following error: --> FOAM FATAL ERROR: Unknown function type fieldAverage Valid functions are : 4 ( patchProbes probes sets surfaces ) How i can calculate average velocity using paraFoam in OF3.0?? I am new to openfoam, please help |
|
August 29, 2016, 03:40 |
|
#13 |
Senior Member
Dr. Fabian Schlegel
Join Date: Apr 2009
Location: Dresden, Germany
Posts: 222
Rep Power: 18 |
Please check if there is a functionOpnject available in
$FOAM_SRC/postProcessing/functionObjects/field/fieldAverage You will find some piece of code an an example controlDict how to use this fieldAverage functionObject. Furthermore, you can do a "grep -R fieldAverage" on the tutorials directory and find an tutorial case using the fieldAverage functionObject. |
|
August 29, 2016, 08:26 |
fieldAveraging OF3.0
|
#14 |
New Member
sudhakar singh
Join Date: Jun 2016
Posts: 12
Rep Power: 10 |
Hello fs82,
thanku 4 quick response. fieldAverage is there in OF3.0 also. but i have one more doubt that, the Umean we are calculating using fieldaverage is time average velocity field or something else? |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Computational time | sunnysun | OpenFOAM Running, Solving & CFD | 5 | March 16, 2009 04:32 |
Bug in Dynamic 1Eq Eddy Viscosity LES Model Incompressible flow | harishg | OpenFOAM Bugs | 5 | December 2, 2008 19:18 |
Differences between serial and parallel runs | carsten | OpenFOAM Bugs | 11 | September 12, 2008 12:16 |
CFL number and time accuracy for LES | Li Yang | Main CFD Forum | 2 | August 1, 2002 07:11 |
time averaged heat transfer in oscillating flow | Matthieu Ubas | Main CFD Forum | 2 | November 5, 1999 15:20 |