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

batch command to run fluent from nth time step

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By thomas

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 9, 2003, 15:04
Default batch command to run fluent from nth time step
  #1
solomon
Guest
 
Posts: n/a
What is the command to run fluent in batch mode starting from the nth time step case/data file. The nth time step is referring to the last time step a previous Fluent run is terminated.

  Reply With Quote

Old   November 10, 2003, 04:40
Default Re: batch command to run fluent from nth time step
  #2
thomas
Guest
 
Posts: n/a
Hi, you need to create a Journal file, you are gonna used in a shell script window by the following command: --------------------------------------------------- fluent 2d (or 3d) -g < Name of your journal file >& results.txt & ---------------------------------------------------

Now in your journal file here are the basic command to read a cas/dat, iterate a number of time step, write cas/dat and close fluent:

----------------------------------------------- rc 'Name_1'.cas (read case) rd 'Name_1'.dat (read data) nd (Number of time step) (Maximum Its per time step) wc 'Name_2'.cas (read case) wd 'Name_2'.dat (read data) Exit yes --------------------------------------------------

You should check for the command 'nd' I propose to you. For that read a unsteday case in Fluent and go in the 'iteration' section of the graphic user interface (GUI). You will find this command. Check if 'nd' is correct cause I have not use it for a while and I do not have Fluent to check by my own.

cheers, thomas yes
  Reply With Quote

Old   November 10, 2003, 18:14
Default Re: batch command to run fluent from nth time step
  #3
solomon
Guest
 
Posts: n/a
Just to make clear things, Thomas, you are suggesting to read all the previous case and data files one by one untill the nth case and data files inorder to continue from the time step the run teminated.

That sounds a tedious job as I have 600 case and data files from a fluent run of many timesteps. If this is the only option, I will tray to do so.

Thank you
  Reply With Quote

Old   November 11, 2003, 04:51
Default Re: batch command to run fluent from nth time step
  #4
thomas
Guest
 
Posts: n/a
Hi,

NO i am not suggesting such a thing. Read the initial cas/dat and then the command will execute your nth time step for this case. Then when the run is done save the cas/dat in a file.

thomas
  Reply With Quote

Old   November 12, 2003, 06:26
Default CORRECTION !!!
  #5
thomas
Guest
 
Posts: n/a
Hi, I am sorry but I have done a mistake in my previous message. The command to set a number of time step using a text command is not 'nd' but the following command:

s/d (numbre of time step) (maxiteration per time step)

I had access to fluent this morning and I checked it. thomas
  Reply With Quote

Old   November 12, 2003, 07:29
Default Re: CORRECTION !!!
  #6
solomon
Guest
 
Posts: n/a
Thomas, The issue that I have and I would like to address is that I have case and data files saved for up to 600 time steps. I want to proceed from where I stopped instead of running Fluent from the first time step. That is to start at 600th time step and go to 601,602, etc. in a batch mode.

I have the journal file to read case file and iterate and save results starting from the first time step. Here the issue is to start from some intermediary time step and proceed further.

thank You Solomon
  Reply With Quote

Old   November 12, 2003, 08:37
Default Re: CORRECTION !!!
  #7
thomas
Guest
 
Posts: n/a
Hi, Well this what I explain to you in my first answer. If I am assuming you have a data file already saved at the 600th iteration you have to read that file in your journal file. Then the iteration precedure 's/d' will continue from the 600 to ....

here is the Journal file you got to excexute

rc name.cas rd name.dat ( data at 600th time step ) s/d x y %x = number of time step %y = max iteration per time step wc final.cas wd final.dat (data file after the x time step) exit yes

To use that in batch mode here is the command: fluent 2/3d -g <journal_file_name> & res.txt & I do not think I can make it clearer. Hope this is what you wanted. thomas
  Reply With Quote

Old   November 12, 2003, 18:51
Default Re: batch command to run fluent from nth time step
  #8
solomon
Guest
 
Posts: n/a
Thomas, I get the 600th case and data files read and obtained results but it get starts counting from the first time step over writing previous results. That means it considers it as if it is a new case and data files though it is a continuation of previous run.

The case and data files should be saved ( I want them to be asaved ) as: filename601.cas,filename601.data, filename602.cas,filename602.data, filename603.cas,filename603.data,etc.

But I get them saved as the following as if it is a start run even though I started by reading the 600 th time step case and data files:

filename001.cas,filename001.data, filename002.cas,filename002.data, filename003.cas,filename003.data, etc.

This is important because I want to archieve the resulting files in their right order as I am going to have a huge number of them may be in the order of ten thousandths.

Thank You Solomon

  Reply With Quote

Old   November 13, 2003, 08:14
Default Re: batch command to run fluent from nth time step
  #9
thomas
Guest
 
Posts: n/a
Sorry I am confused. Would answer the following question : Does the filename referenced 001.cas/dat contains : -> the data for one time step after initialization ? -> the data of the 601 nth time step ?

You should post here your journal file text to let other people check your commands. Futhermore I encourage you to contact your area Fluent office.

Regards, thomas
  Reply With Quote

Old   November 13, 2003, 08:30
Default Re: batch command to run fluent from nth time step
  #10
varghese
Guest
 
Posts: n/a
Dear Solomon,

If it is just the problem of numbering, you can take the control of naming your case and data files through your journal. Ja, if you have 10000s of it, it would be again a problem. Another radical step will be to correct your time in the boundary condition file. At 600th time step apply file/write-bc. Check in the resulting file, the time defintion. You can edit it and apply file/read-bc. I hope it will allow you to continue from where you stopped.

Greetings Varghese
  Reply With Quote

Old   November 13, 2003, 08:37
Default Re: batch command to run fluent from nth time step
  #11
thomas
Guest
 
Posts: n/a
This is what I thought. I wondered and wanted to know if the saving is done by auto-save throught fluent or directly in the journal file.

thomas
  Reply With Quote

Old   November 16, 2003, 06:03
Default Re: batch command to run fluent from nth time step
  #12
solomon
Guest
 
Posts: n/a
Thomas,

The saving is done through fluent autosave feature and it is adjusted so that the case and data files are saved in 20 time steps interval:

filename020.cas

filename020.dat

filename040.cas

filename040.dat

etc

solomon
  Reply With Quote

Old   November 16, 2003, 08:38
Default Re: batch command to run fluent from nth time step
  #13
thomas
Guest
 
Posts: n/a
Hi, I agree with varghese, it is a problem of numbering. I I am sure your data/case file contain the right calculation but their names are different from what you think. To solve that problem either find a trick in your auto-save file name or do it in your journal file (command wcd) but it seems very heavy to do cause if I remember you have a lot of file to save.

Cheers thomas
maphd likes this.
  Reply With Quote

Old   August 25, 2015, 21:05
Default
  #14
Member
 
Join Date: May 2013
Posts: 32
Rep Power: 13
maphd is on a distinguished road
Hello Thomas,

I run a large eddy simulation in fluent 14. I saved my case and data files at different time steps every 50 time steps and I run the simulation for 1000 time steps. Could you tell me how I can find an average value of a variable lets say velocity from all of the files that I saved?

I do not want to open them one by one and put into excel or any other place to take the average of a variable. Is there any way that fluent can read those by itself and calculated the average? I think what you were suggesting above which is called a journal file make this job for me right? I appreciate your help.

Thank you,
maphd 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
Floating point exception error Alan OpenFOAM Running, Solving & CFD 11 July 1, 2021 22:51
Time step size and max iterations per time step pUl| FLUENT 31 October 23, 2020 23:50
SLTS+rhoPisoFoam: what is rDeltaT??? nileshjrane OpenFOAM Running, Solving & CFD 4 February 25, 2013 05:13
DPM UDF particle position using the macro P_POS(p)[i] dm2747 FLUENT 0 April 17, 2009 02:29
IcoFoam parallel woes msrinath80 OpenFOAM Running, Solving & CFD 9 July 22, 2007 03:58


All times are GMT -4. The time now is 07:03.