|
[Sponsors] | |||||
|
|
|
#1 |
|
New Member
Xavier Lamboley
Join Date: Jan 2015
Location: Bordeaux, France
Posts: 13
Rep Power: 12 ![]() |
Hello Foamers,
I want to calculate y+ = y u* / nu and u+ = u / u* with functionObjects in Openfoam. I managed to retrieve y as a wallDist, nu from the turbulence model and U. I also get u* as a volScalarField, defined only on the wall patch (zero elsewhere), with another functionObject. Now in order to calculate u+ and y+ in the whole field, I need to use for every cell the value of u* on the closest face on the boundary. I don t have any clue on how to do that... You will find attached the code of my 3 functionObjects for u*, y+ and u+, which use for now the average of u* on the patch. Any help would be greatly appreciated. X. Lamboley turbulence_functionObjects.tar.gz |
|
|
|
|
|
|
|
|
#2 |
|
New Member
Xavier Lamboley
Join Date: Jan 2015
Location: Bordeaux, France
Posts: 13
Rep Power: 12 ![]() |
After some investigation I found a solution by looping over the mesh points. You will find attached the updated code.
The method is to loop over the mesh points, then looping over the surface faces. I keep the nearest x on the surface for each mesh point, and assign its wallShearStress. This works well, if the point are sufficiently aligned along the vertical. Cheers, X. Lamboley |
|
|
|
|
|
|
|
|
#3 |
|
Senior Member
Joachim Herb
Join Date: Sep 2010
Posts: 650
Rep Power: 23 ![]() |
Thank you for sharing the code. Could you please also give an example, how to use this in the controlDict. Or how do you else use function objects?
|
|
|
|
|
|
|
|
|
#4 |
|
Senior Member
Jianrui Zeng
Join Date: May 2018
Location: China
Posts: 157
Rep Power: 9 ![]() |
I am also in u+ calculation. Could you give more explanation? Thanks.
|
|
|
|
|
|
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Dynamic mesh adaption in parallel calculation | xh110120 | FLUENT | 1 | March 12, 2016 09:05 |
| Determining the calculation sequence of the regions in multe regions calculation | peterhess | OpenFOAM Running, Solving & CFD | 4 | March 9, 2016 04:07 |
| Increase in CPU number during the FIRE calculation | amin_u50 | AVL FIRE | 0 | August 6, 2014 09:34 |
| MRF and Heat transfer calculation | Susan YU | FLUENT | 0 | June 2, 2010 09:46 |
| Warning 097- | AB | Siemens | 6 | November 15, 2004 05:41 |