|
[Sponsors] |
Sample of Reynolds Stress Normal to Wall |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
January 4, 2017, 09:04 |
Sample of Reynolds Stress Normal to Wall
|
#1 |
New Member
DimitriF
Join Date: Dec 2016
Location: London
Posts: 19
Rep Power: 10 |
Dear Foamers,
I want to plot the Reynolds stress along the wall normal direction y. The case is turbulent (SA model) and calculated by the simpleFoam solver. After the simulates has converged, I ran the post processing utility of OpenFOAM to calculate the Reynold stress and sample it afterwards. The velocity and pressure are sampled as expected but it does not work for the Reynold stress. Below are the sampling dictionary and the error when executed. simpleFoam -postProcess -func 'turbulenceFields(R)' -latestTime simpleFoam -postProcess -func sampleVel_-6p531 -latestTime Code:
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | foam-extend: Open Source CFD | | \\ / O peration | Version: 3.0 | | \\ / A nd | Web: http://www.extend-project.de | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; location "system"; object sample; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // file got from CFD course Ulg libs ("libsampling.so"); setFormat raw; surfaceFormat raw; start (-0.4572 0.07 0); end (-0.4572 0.10708 0); fields (U p turbulenceProperties:R); // Sampling and I/O settings #includeEtc "caseDicts/postProcessing/graphs/sampleDict.cfg" // Override settings here, e.g. setConfig { interpolationScheme cellPoint; axis xyz; } // Must be last entry #includeEtc "caseDicts/postProcessing/graphs/graph.cfg" // ************************************************************ // Code:
--> FOAM Warning : From function Foam::label Foam::sampledSets::classifyFields() in file sampledSet/sampledSets/sampledSetsGrouping.C at line 140 Cannot find registered field matching turbulenceProperties:R --> FOAM Warning : From function Foam::label Foam::sampledSets::classifyFields() in file sampledSet/sampledSets/sampledSetsGrouping.C at line 140 Cannot find registered field matching turbulenceProperties:R I would highly appreciate your help! Dimitri |
|
January 4, 2017, 13:32 |
|
#2 |
New Member
DimitriF
Join Date: Dec 2016
Location: London
Posts: 19
Rep Power: 10 |
Any ideas?
I have tried to use simpleFoam -postProcess -func 'components(turbulenceProperties:R)' -latestTimestep but I get -> FOAM Warning : functionObject components: Cannot find required field turbulenceProperties:R I use OpenFOAM version 4.1 Please help!! Dimitri |
|
January 4, 2017, 13:52 |
|
#3 |
New Member
DimitriF
Join Date: Dec 2016
Location: London
Posts: 19
Rep Power: 10 |
Ok, problem solved.
If I use postProcess -func sampleVel_-6p531 -latestTime OR postProcess -func 'components(turbulenceProperties:R)' -latestTimestep instead of simpleFoam -postProcess -func sampleVel_-6p531 -latestTime OR simpleFoam -postProcess -func 'components(turbulenceProperties:R)' it works. I don't know the difference at the moment though. However, this thread can be considered closed. :-) Dimitri |
|
January 5, 2017, 17:50 |
|
#4 |
Member
Bashar
Join Date: Jul 2015
Posts: 74
Rep Power: 11 |
Dimitri,
Hi, Did you manage to plot your data in paraview? if yes, please can you share the procedure? Thank you . Bashar |
|
January 5, 2017, 17:58 |
|
#5 |
New Member
DimitriF
Join Date: Dec 2016
Location: London
Posts: 19
Rep Power: 10 |
Hi Basher,
I post-process my results in gnuplat and Matlab. You can extract the values as I posted above and load everything in your post-processing tool of choice. Dimitri |
|
January 5, 2017, 18:12 |
|
#6 | |
Member
Bashar
Join Date: Jul 2015
Posts: 74
Rep Power: 11 |
Thank you for the fast response.
I just want to make sure of something. So, when I computed the Reynolds Stress, I just type "R" i.e. I used the post-process utility . below are sample of the calculation. Is this is the wright way to do that? I have know in each data file an R file with the matrix inside . Quote:
|
||
January 5, 2017, 18:21 |
|
#7 |
New Member
DimitriF
Join Date: Dec 2016
Location: London
Posts: 19
Rep Power: 10 |
It looks right to me. Depending on the version of OpenFOAM you use, the command is a bit different. I believe in the earlier versions (I use V4.1), it is sufficient to simply type 'R' or something similar. The output should be a symmetric tensor <symmTensor> in your write directories.
Afterwards, you can sample this tensor and extract values. Hope that helps. Dimitri |
|
January 5, 2017, 18:31 |
|
#8 |
Member
Bashar
Join Date: Jul 2015
Posts: 74
Rep Power: 11 |
Thanks again and sorry to ask you again, I am really still not that good in openfoam.
So, know I need to extract the data using your method? So, basically I need to execute the command in my terminal or you mean different thing? Sorry to ask this basic questions. Bashar |
|
January 5, 2017, 18:42 |
|
#9 |
New Member
DimitriF
Join Date: Dec 2016
Location: London
Posts: 19
Rep Power: 10 |
No need for an excuse, I also started using OpenFOAM not long ago and had to learn the hard way.
What you can do is copy my the first code of the first post to your ./system directory and name it yourSample. There you specify the line where you want to extract the values and what quantities. start (-0.4572 0.07 0); end (-0.4572 0.10708 0); fields (U p turbulenceProperties:R); If needed, you can change the interpolation scheme, type, axis etc. You can look this up in the official OpenFOAM documentation. In my case, I selected // Override settings here, e.g. setConfig { interpolationScheme cellPoint; axis xyz; } Afterwards you go to your case directory and execute the following in the terminal postProcess -func yourSample -latestTime You can replace -latestTime by -time XXX if you want to sample at a specific time or just postProcess -func yourSample -latestTime if you want to sample at all types. Dimitri body,div,table,thead,tbody,tfoot,tr,th,td,p { font-family:"Liberation Sans"; font-size:x-small } a.comment-indicator:hover + comment { background:#ffd; position:absolute; display:block; border:1px solid black; padding:0.5em; } a.comment-indicator { background:red; display:inline-block; border:1px solid black; width:0.5em; height:0.5em; } comment { display:none; } |
|
January 5, 2017, 18:47 |
|
#10 |
Member
Bashar
Join Date: Jul 2015
Posts: 74
Rep Power: 11 |
Thank you so much , you make it really clear for me.
best wishes to you and happy new year . Bashar |
|
January 5, 2017, 18:48 |
|
#11 |
New Member
DimitriF
Join Date: Dec 2016
Location: London
Posts: 19
Rep Power: 10 |
Happy to help
Thanks, to you too! Dimitri |
|
September 27, 2018, 06:31 |
|
#12 |
New Member
Yixiang Liao
Join Date: Sep 2018
Posts: 2
Rep Power: 0 |
Hello Bashar,
could you please share how do you use the post-process utility"R"? I used it like: postProcess -func "R", and got an error message "the turbulence model not found in database, deactivating". thanks a lot in advance! Regards, Yixiang |
|
November 13, 2018, 10:37 |
|
#13 |
New Member
Join Date: May 2017
Posts: 2
Rep Power: 0 |
Hi Yixiang, you have to input the name of your solver before the postProcess command. For example:
simpleFoam -postProcess -func R Cheers, -Aaron |
|
May 29, 2023, 13:17 |
|
#14 | |
Member
Uttam
Join Date: May 2020
Location: Southampton, United Kingdom
Posts: 35
Rep Power: 6 |
Quote:
__________________
Best Regards Uttam ----------------------------------------------------------------- “When everything seem to be going against you, remember that the airplane takes off against the wind, not with it.” – Henry Ford. |
||
Tags |
reynolds stress tensor, sampling |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Enhanced Wall Treatment | paduchev | FLUENT | 24 | January 8, 2018 12:55 |
Calculation of Wall Shear Stress | Dave442 | CFX | 36 | July 12, 2016 05:12 |
Water subcooled boiling | Attesz | CFX | 7 | January 5, 2013 04:32 |
UDF for wall slipping | HFLUENT | Fluent UDF and Scheme Programming | 0 | April 27, 2011 13:03 |
reynolds normal and shear stress components | saran | Siemens | 0 | August 28, 2006 01:54 |