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

time averaged data

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree6Likes
  • 1 Post By Amir
  • 1 Post By Amir
  • 1 Post By Amir
  • 3 Post By Amir

Reply
 
LinkBack Thread Tools Display Modes
Old   March 26, 2012, 07:42
Default time averaged data
  #1
Member
 
Musango Lungu
Join Date: Dec 2011
Location: China
Posts: 73
Rep Power: 5
Musa is on a distinguished road
I urgently need help to process simulation data and obtain time-averaged values. I am modeling a 2D gas-solid fluidized bed reactor. I have just come to learn about the data sampling for time statistics option in fluent but it is too late since the simulation has already been done. I will appreciate your comments and valuable suggestions.
Musa is offline   Reply With Quote

Old   March 26, 2012, 09:39
Default
  #2
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by Musa View Post
I urgently need help to process simulation data and obtain time-averaged values. I am modeling a 2D gas-solid fluidized bed reactor. I have just come to learn about the data sampling for time statistics option in fluent but it is too late since the simulation has already been done. I will appreciate your comments and valuable suggestions.
Dear Musango,

For this purpose, you can export FLUENT data in ASCII format then import them in MATLAB and finally write them in Tecplot format or interpolation format of FLUENT. Do not hesitate to ask if the procedure is not clear.

P.S. In order to automize the exporting data from FLUENT, you will need a simple journal file; additionally, a code for importing and averaging data in MATLAB.

Bests,
__________________
Amir
Amir is offline   Reply With Quote

Old   March 27, 2012, 00:52
Default
  #3
Member
 
Musango Lungu
Join Date: Dec 2011
Location: China
Posts: 73
Rep Power: 5
Musa is on a distinguished road
Thanx alot, Amir! I have sent you the case and data files to help me understand more clearly. Actually my programming skills are quite basic. I am a beginner.
Musa is offline   Reply With Quote

Old   March 27, 2012, 01:24
Default
  #4
Member
 
Musango Lungu
Join Date: Dec 2011
Location: China
Posts: 73
Rep Power: 5
Musa is on a distinguished road
I have exported the data in ASCII format, imported it into matlab and saved it in interpolation format. How do I now proceed to get the average data?
Musa is offline   Reply With Quote

Old   March 27, 2012, 04:28
Default
  #5
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by Musa View Post
I have exported the data in ASCII format, imported it into matlab and saved it in interpolation format. How do I now proceed to get the average data?
Hi,

You have to do such procedure for all of your time-dependent data; so you will need a tool to automize this procedure (exporting and importing) so you can use a journal file in FLUENT and a code for MATLAB. When you import all the data to MATLAB, you can simply compute the average flow field.

Bests,
__________________
Amir
Amir is offline   Reply With Quote

Old   March 27, 2012, 05:44
Default
  #6
Member
 
Musango Lungu
Join Date: Dec 2011
Location: China
Posts: 73
Rep Power: 5
Musa is on a distinguished road
Okay, as i said earlier my programming skills are quite basic and i would appreciate your assistance with the codes. I can modify them to suit my case. I have already sent the case and data files to you to have a look at. Thank you so much once again.
Musa is offline   Reply With Quote

Old   March 27, 2012, 09:07
Default
  #7
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by Musa View Post
Okay, as i said earlier my programming skills are quite basic and i would appreciate your assistance with the codes. I can modify them to suit my case. I have already sent the case and data files to you to have a look at. Thank you so much once again.
I attached 2 codes that you need for your purpose which I wrote in Fortran 90.
code1.f90 is a journal generator and code2.f90 is a MATLAB code generator.

Bests,
Attached Files
File Type: zip codes.zip (912 Bytes, 73 views)
passive likes this.
__________________
Amir
Amir is offline   Reply With Quote

Old   March 27, 2012, 09:15
Default
  #8
Member
 
Musango Lungu
Join Date: Dec 2011
Location: China
Posts: 73
Rep Power: 5
Musa is on a distinguished road
Thanx a million Amir, you are a life saver!!!
Musa is offline   Reply With Quote

Old   November 21, 2012, 12:56
Default
  #9
New Member
 
pari
Join Date: Nov 2012
Posts: 6
Rep Power: 4
passive is on a distinguished road
Quote:
Originally Posted by Amir View Post
I attached 2 codes that you need for your purpose which I wrote in Fortran 90.
code1.f90 is a journal generator and code2.f90 is a MATLAB code generator.

Bests,
Hi Amir;

I downloaded your codes but I don't know how to use them? How can I use journal file in fluent and how to import them in matlab?
can you explain more?

Thank you
pari
passive is offline   Reply With Quote

Old   November 21, 2012, 13:39
Default
  #10
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by passive View Post
Hi Amir;

I downloaded your codes but I don't know how to use them? How can I use journal file in fluent and how to import them in matlab?
can you explain more?

Thank you
pari
Dear Pari,

Before using these codes, you have to check whether they are necessary fro your case or not. These are designed just for post-run purposes, while you can do the same during the run with FLUENT primary options. However, you can refer to the manual to know how to use journal files.

Bests,
passive likes this.
__________________
Amir
Amir is offline   Reply With Quote

Old   November 21, 2012, 14:11
Default
  #11
New Member
 
pari
Join Date: Nov 2012
Posts: 6
Rep Power: 4
passive is on a distinguished road
Quote:
Originally Posted by Amir View Post
Dear Pari,

Before using these codes, you have to check whether they are necessary fro your case or not. These are designed just for post-run purposes, while you can do the same during the run with FLUENT primary options. However, you can refer to the manual to know how to use journal files.

Bests,
my case is to time average from all time steps for velocity and pressure .
I run journal creator code(fortran code) and then I read journal output file in fluent but I just obtain position cordinates and no velocity and pressure.what is my mistake?
passive is offline   Reply With Quote

Old   November 21, 2012, 16:53
Default
  #12
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by passive View Post
my case is to time average from all time steps for velocity and pressure .
I run journal creator code(fortran code) and then I read journal output file in fluent but I just obtain position cordinates and no velocity and pressure.what is my mistake?
Did you save the required data or now you want to start the run? If you haven't performed any run or it's not time consuming, it's much easier to use unsteady statistic data processing of FLUENT instead of this method; otherwise, you have to import the data to MATLAB for further processing.

Bests,
passive likes this.
__________________
Amir
Amir is offline   Reply With Quote

Old   November 22, 2012, 02:46
Default
  #13
New Member
 
pari
Join Date: Nov 2012
Posts: 6
Rep Power: 4
passive is on a distinguished road
Quote:
Originally Posted by Amir View Post
Did you save the required data or now you want to start the run? If you haven't performed any run or it's not time consuming, it's much easier to use unsteady statistic data processing of FLUENT instead of this method; otherwise, you have to import the data to MATLAB for further processing.

Bests,
all my runs were completed and i saved all case and data for every time step using autosave. it'll take too much time for me to run again.
if I know your solution you mean i can use unsteady data sampling icon which have been located in iteration panel,but this method only give me a few data,and I doubt this method.
I want to know more about journal file operation.I read journal file but just the position of nodes were resulted...
passive is offline   Reply With Quote

Old   November 22, 2012, 06:06
Default
  #14
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by passive View Post
all my runs were completed and i saved all case and data for every time step using autosave. it'll take too much time for me to run again.
if I know your solution you mean i can use unsteady data sampling icon which have been located in iteration panel,but this method only give me a few data,and I doubt this method.
I want to know more about journal file operation.I read journal file but just the position of nodes were resulted...
Yes, unsteady statistics method can provide few parameters.
Before using that journal file, you have to change it for your purpose; I mean number of files, names and .... I propose to check one step in TUI to find the issues, so notice to probable errors in FLUENT console, but as you see it's prepared to export 4 variables:
Code:
x-vel y-vel z-vel pressure
So check it just for one case by typing the commands in TUI and follow the instruction to eliminate the drawbacks.
Do not hesitate to ask if you face any problem.

Bests,
Far, Smaras and passive like this.
__________________
Amir
Amir is offline   Reply With Quote

Old   November 23, 2012, 05:10
Default
  #15
New Member
 
pari
Join Date: Nov 2012
Posts: 6
Rep Power: 4
passive is on a distinguished road
Quote:
Originally Posted by Amir View Post
Yes, unsteady statistics method can provide few parameters.
Before using that journal file, you have to change it for your purpose; I mean number of files, names and .... I propose to check one step in TUI to find the issues, so notice to probable errors in FLUENT console, but as you see it's prepared to export 4 variables:
Code:
x-vel y-vel z-vel pressure
So check it just for one case by typing the commands in TUI and follow the instruction to eliminate the drawbacks.
Do not hesitate to ask if you face any problem.

Bests,
Hi amir
I did what you said.when i copy journal text in TUI. after being shown somethings in TUI ,it appeare ASCII scalar(1)> what should i write in this step? my journal file that i copy In TUI is
rcd cav-0001.cas
/file/ex/ascii cav-0001 () x-vel y-vel z-vel pressure ()
rcd cav-0002.cas
yes
/file/ex/ascii cav-0002 () x-vel y-vel z-vel pressure ()
rcd cav-0003.cas
yes
/file/ex/ascii cav-0003 () x-vel y-vel z-vel pressure ()
rcd cav-0004.cas
yes
/file/ex/ascii cav-0004 () x-vel y-vel z-vel pressure ()
rcd cav-0005.cas
yes
/file/ex/ascii cav-0005 () x-vel y-vel z-vel pressure ()


*** cav is the name of sample project
passive is offline   Reply With Quote

Old   November 23, 2012, 05:50
Default
  #16
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by passive View Post
Hi amir
I did what you said.when i copy journal text in TUI. after being shown somethings in TUI ,it appeare ASCII scalar(1)> what should i write in this step? my journal file that i copy In TUI is
rcd cav-0001.cas
/file/ex/ascii cav-0001 () x-vel y-vel z-vel pressure ()
rcd cav-0002.cas
yes
/file/ex/ascii cav-0002 () x-vel y-vel z-vel pressure ()
rcd cav-0003.cas
yes
/file/ex/ascii cav-0003 () x-vel y-vel z-vel pressure ()
rcd cav-0004.cas
yes
/file/ex/ascii cav-0004 () x-vel y-vel z-vel pressure ()
rcd cav-0005.cas
yes
/file/ex/ascii cav-0005 () x-vel y-vel z-vel pressure ()


*** cav is the name of sample project
Hi,

That's the first scalar you want to report! Press enter in this step to see the available options.

Bests,
__________________
Amir
Amir is offline   Reply With Quote

Old   November 23, 2012, 11:55
Default
  #17
New Member
 
pari
Join Date: Nov 2012
Posts: 6
Rep Power: 4
passive is on a distinguished road
Quote:
Originally Posted by Amir View Post
Hi,

That's the first scalar you want to report! Press enter in this step to see the available options.

Bests,
I did what you say.I wrote for example x-velocity after ASCII scalar(1) then y-velocity after ASCII scalar(2) and... how can I break this ASCII' sss? and where are these data stored?
passive is offline   Reply With Quote

Old   November 23, 2012, 14:42
Default
  #18
Senior Member
 
Amir's Avatar
 
Amir
Join Date: May 2009
Location: Shiraz, Iran
Posts: 739
Blog Entries: 1
Rep Power: 14
Amir is on a distinguished road
Quote:
Originally Posted by passive View Post
I did what you say.I wrote for example x-velocity after ASCII scalar(1) then y-velocity after ASCII scalar(2) and... how can I break this ASCII' sss? and where are these data stored?
You can get your answer by referring to he provided code! By using ().
__________________
Amir
Amir is offline   Reply With Quote

Old   November 24, 2012, 13:19
Default
  #19
New Member
 
pari
Join Date: Nov 2012
Posts: 6
Rep Power: 4
passive is on a distinguished road
Quote:
Originally Posted by Amir View Post
You can get your answer by referring to he provided code! By using ().
Hi Amir
I wrote 2 udf for my purpose to get time average data.I attach these two udf.if it's possible help me to correct them,please.
I check them with data sampling time statics of fluent, the results are close but not exactly the same.I used udm and just for x-velocity.
Attached Files
File Type: c pari average.c (446 Bytes, 24 views)
File Type: c average 2.c (434 Bytes, 22 views)
passive is offline   Reply With Quote

Reply

Thread Tools
Display Modes

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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Moving mesh Niklas Wikstrom (Wikstrom) OpenFOAM Running, Solving & CFD 122 June 15, 2014 06:20
how to calculate the averaged mass flow along a line over time ? iampolaris OpenFOAM Post-Processing 0 March 10, 2011 23:03
Modeling in micron scale using icoFoam m9819348 OpenFOAM Running, Solving & CFD 7 October 27, 2007 00:36
IcoFoam parallel woes msrinath80 OpenFOAM Running, Solving & CFD 9 July 22, 2007 02:58
AMG versus ICCG msrinath80 OpenFOAM Running, Solving & CFD 2 November 7, 2006 16:15


All times are GMT -4. The time now is 09:34.