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

How to consider earlier timesteps for time-averaged statistics?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 26, 2012, 09:44
Default How to consider earlier timesteps for time-averaged statistics?
  #1
Senior Member
 
OJ
Join Date: Apr 2012
Location: United Kindom
Posts: 473
Rep Power: 20
oj.bulmer will become famous soon enough
I am doing a transient simulation and am storing the transient statistics at the interval of 0.01 s. I have observed that as no. of trn results gets bigger, the response of CFX solver in Workbench is sluggish and at times even takes 15 minutes to start the solver run . Hence I prefer to start new simulation, with def file and initialization from earlier simulation.

As a result I have say 4 simulations from 0-30 s, 30-60 s, 60-90 s, 90-120 s. Now, when I open the 4th simulation in CFD post, it loads all the trn files (i.e 91 -120 s) but doesn't load the earlier ones.

Now, I want to see the time average result of a variable, say variable.Trnavg in CFD post for last 60 seconds. Is there a way to do it?

I have checked loading earlier time steps using time step selecter, but that doesn't influence the variable.Trnavg, meaning only the timesteps run for that simulation can influence the Trnavg.
oj.bulmer is offline   Reply With Quote

Old   June 26, 2012, 10:26
Default
  #2
Senior Member
 
Join Date: Jul 2011
Location: Berlin, Germany
Posts: 173
Rep Power: 14
monkey1 is on a distinguished road
as far as I know there is no way to get the trnavg variable "know" the previous time steps as it is always calculated during and only for a single run.
Getting transient averages would only work by playing a script file wich reads the required value from each trn file and averages it over the time interval.

For example the following code written in a file with a .cse extension can be "played" as a "Session" in CFX Post and will write you down the required value (here the r134.Mass concentration) at a specified point (Probe Point) for every time step in a .csv file. You will the have to do the time averaging by yourself in Excel or similar programs.

INTERNAL POINT:Probe Point
Option = XYZ
Point = 6.5 [m], 7.5 [m], 0.015 [m]
END

LIBRARY:
CEL:
EXPRESSIONS:
Konz ave1 = probe(r134a.Mass Concentration)@Probe Point
END
END
END
#
# Define outfile
#
!$outfile = "myEXPRESSION.csv";
#
# Open outfile
#
!open(OUT, ">$outfile");
#
# Get the timestep values from the current results file
#
!$timestepList = getValue("DATA READER", "Timestep List");
!@timesteps = split(/, /, $timestepList );
#
# Loop over timesteps
#
! foreach $ts ( @timesteps ) {
#
# Load current timestep
#
> load timestep=$ts
! $time = getValue( "DATA READER", "Current Timevalue");
! $time_formatted=sprintf("%.2f",$time);
! ($konzave1,$unit)=evaluate("Konz ave1");
! printf "%20s,%15.8e\n",$time_formatted, $konzave1;
! printf OUT "%20s,%15.8e\n",$time_formatted, $konzave1;
!}
!close(OUT);

Hope this helps.
monkey1 is offline   Reply With Quote

Old   June 26, 2012, 10:40
Default
  #3
Senior Member
 
OJ
Join Date: Apr 2012
Location: United Kindom
Posts: 473
Rep Power: 20
oj.bulmer will become famous soon enough
Thanks, I will have a look at it.

Though, from first thought, it seems like this will only give you the value at particular point. Is there a way to find the value at all domain? E.g. for finding out the time averaged contour plots or chart of the variable varying on line in CFD Post?

Regards
OJ
oj.bulmer is offline   Reply With Quote

Old   July 3, 2012, 05:24
Default
  #4
Senior Member
 
Join Date: Jul 2011
Location: Berlin, Germany
Posts: 173
Rep Power: 14
monkey1 is on a distinguished road
hmm
I would suggest you look for the set of functions available in cfx post and how and where (on a point, plane or domain) to use them. Should be written somewhere in the cfx user guide. Or you can try to record a session in post while clicking together whatever you want to do. Then you can have a look at the .cse file and see what the commands are. That's how I did it till now.
monkey1 is offline   Reply With Quote

Reply

Tags
transient average results


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
Incompressible LES tutorial (oodles) - time averaged statistics bernarde OpenFOAM 13 August 29, 2016 07:26
Transient post-processing, Time averaged pressure work Turbomachine CFX 1 January 3, 2011 17:01
Transient Statistics for turbo components Suzzn CFX 5 May 4, 2010 09:56
Displaying LES Time Averaged Statistics Ben FLUENT 1 May 12, 2004 06:18


All times are GMT -4. The time now is 20:00.