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

Need a macro to run every timestep

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 19, 2008, 19:37
Default Need a macro to run every timestep
  #1
Nate
Guest
 
Posts: n/a
1.) Do macros automatically run every timestep? 2.) Does anyone have a sample of such a macro?

I need to come up with my own macro to export XYZ tables each timestep but I'm not sure how to go about getting the macro to run every step.

Thanks!
  Reply With Quote

Old   March 24, 2008, 17:37
Default Re: Need a macro to run every timestep
  #2
Steve
Guest
 
Posts: n/a
it is pretty easy to do

firstly setup your model then record a macro that contains

1) the pressing of the step button. This makes the simulation take one timestep/iteration

2) the post processing steps you want (exports etc)

Stop the recording and open up the java file. The next step is to wrap this code in a java for or while statement, for example

int imax=100; //maximum number of steps

for(i=0&#59i&#60imax&#59i++){

// insert your recorded macro code here

}

Any java book or a bit of work with google should sort you out.

  Reply With Quote

Old   March 24, 2008, 19:13
Default Re: Need a macro to run every timestep
  #3
Nate
Guest
 
Posts: n/a
Thanks Steve!

I guess that was kind of a no-brainer. I hadn't though about the fact that you can step just once like that.

  Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
load sheme macro (Solv Execute Command macro) manu FLUENT 2 March 13, 2008 02:00
Macro Trouble -Winows Explorer Crashes with Macro Martin Castillo FLUENT 1 July 25, 2007 05:18
timestep ousegui CFX 0 March 18, 2005 09:43
Call a macro from a macro Flav Siemens 2 July 1, 2004 06:42
timestep Eugenio Mayol CFX 2 February 8, 2001 02:39


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