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

How to print the cell value row wise?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 20, 2019, 05:34
Default How to print the cell value row wise?
  #1
Member
 
FaRa
Join Date: Jul 2019
Posts: 33
Rep Power: 6
Fahmida is on a distinguished road
Hello everyone,

I want to print the volume fraction values (alpha) of each cell and print them in row wise. As fur as I know Openfoam calculates the whole domain during each iteration. But I want to have the values of 0.078x0.06 portion of the domain only during my simulation.

Something in C programming like...

Code:
for (i=0; i<0.078; i++)
{
 for (j=0; j<0.06; j++)
   {
        printf("%f ", alpha[j]);
   }
printf("\n");
}
Thank you
Attached Images
File Type: png 2DdomainValue.png (8.9 KB, 17 views)
Fahmida is offline   Reply With Quote

Old   November 29, 2019, 00:15
Default
  #2
Senior Member
 
Join Date: Jun 2012
Location: Germany, Bochum
Posts: 230
Rep Power: 15
Bazinga is on a distinguished road
Quote:
Originally Posted by Fahmida View Post
Hello everyone,

As fur as I know Openfoam calculates the whole domain during each iteration. But I want to have the values of 0.078x0.06 portion of the domain only during my simulation.
Can you please specify what you mean. Do you want OpenFOAM to only calculate a certain region of the domain at each time step? Or do you want the values in a certain region be printed to the terminal? Or something else?
Bazinga is offline   Reply With Quote

Old   December 22, 2019, 12:00
Default
  #3
Member
 
FaRa
Join Date: Jul 2019
Posts: 33
Rep Power: 6
Fahmida is on a distinguished road
Thank you for your reply.

Actually I want the second case that you have mentioned. I want the values of a certain region, specifically for the area 0.078x0.06 for post processing only.
Fahmida is offline   Reply With Quote

Old   December 22, 2019, 22:37
Default
  #4
Senior Member
 
Join Date: Jun 2012
Location: Germany, Bochum
Posts: 230
Rep Power: 15
Bazinga is on a distinguished road
You can define a probe in each of the cells to get time histories of your alpha.
Bazinga is offline   Reply With Quote

Old   December 26, 2019, 19:24
Default
  #5
Member
 
FaRa
Join Date: Jul 2019
Posts: 33
Rep Power: 6
Fahmida is on a distinguished road
Thank you for your reply.

Can you please explain a bit more on how to implement it?
Fahmida is offline   Reply With Quote

Old   December 27, 2019, 03:13
Default
  #6
Senior Member
 
Join Date: Jun 2012
Location: Germany, Bochum
Posts: 230
Rep Power: 15
Bazinga is on a distinguished road
Well, search this forum the tutorials and/or the user guide and you will find explanation there immediately.
Bazinga is offline   Reply With Quote

Reply


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
Set cell volume integrated field values to preserve integral Diro7 OpenFOAM Pre-Processing 2 June 3, 2018 10:44
Doubt about parallel processing vishwesh OpenFOAM Programming & Development 0 November 10, 2017 06:20
Partition: cell count = 0 metmet FLUENT 1 August 31, 2014 19:41
monitoring cell Jane Siemens 2 March 4, 2004 21:01
cell to cell relation CMB Siemens 1 December 4, 2003 04:05


All times are GMT -4. The time now is 01:32.