CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM

how to sample the p_rgh in openfoam v2206

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 11, 2023, 02:20
Default how to sample the p_rgh in openfoam v2206
  #1
New Member
 
yuwei lin
Join Date: Mar 2023
Posts: 4
Rep Power: 3
Waynelin is on a distinguished road
hi! Im new to openfoam. So I was wondering how can I sample p_rgh as a file and can write like timestep in different file rather than all data in a text file.

for example I write a sampleDict to postprocess sample and the p_rgh file will go into the file postprocess and it can write as a independent file like
0.2 0.4 0.6 0.8 1.0 and every p_rgh file will go into the 0.2 0.4 0.6 ....file.

cause I need the data become the file that can put into the wssi upfoam to run.

sorry about the stupid question. can anyone help? Thanks!!

and by the way, the data I want to sample is patch bottom. how can I sample the bottom data p_rgh??
Waynelin is offline   Reply With Quote

Old   May 11, 2023, 09:12
Default
  #2
Senior Member
 
M
Join Date: Dec 2017
Posts: 694
Rep Power: 12
AtoHM is on a distinguished road
Hello,
I have a hard time following your "p_rgh goes into that" etc. text, but I think you want certain values put out over time (iteration) of your simulation.

In OpenFOAM you can use the surfaceFieldsValue (patches, faceZones, ...) or volFieldValue (cellSet, cellZone, region) function objects to get this output. The documentation is pretty straight-forward on this: https://www.openfoam.com/documentati...ieldValue.html


You can just add this to your controlDict as shown in the linked tutorial https://develop.openfoam.com/Develop...em/controlDict and the appropriate files will be written into the postProcess folder created at runtime.
Hope this answers your question.
AtoHM is offline   Reply With Quote

Old   September 8, 2023, 05:38
Default
  #3
New Member
 
yuwei lin
Join Date: Mar 2023
Posts: 4
Rep Power: 3
Waynelin is on a distinguished road
sorry for reply so late.

I've solve the problem. Thank you for the answer !
Waynelin is offline   Reply With Quote

Reply

Tags
sample data, sampledict, wave2foam


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting Started with OpenFOAM wyldckat OpenFOAM 26 June 21, 2024 06:54
OpenFOAM Training, London, Chicago, Munich, Sep-Oct 2015 cfd.direct OpenFOAM Announcements from Other Sources 2 August 31, 2015 13:36
interpolate 2-D sample planes in openfoam saeedi OpenFOAM Post-Processing 0 August 11, 2015 16:26
Modified OpenFOAM Forum Structure and New Mailing-List pete Site News & Announcements 0 June 29, 2009 05:56
Adventure of fisrst openfoam installation on Ubuntu 710 jussi OpenFOAM Installation 0 April 24, 2008 14:25


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