CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   iterate from command line (https://www.cfd-online.com/Forums/fluent/70908-iterate-command-line.html)

jack1980 December 9, 2009 11:24

iterate from command line
 
Hi! For a VOF unsteady problem I can choose to: solve/iterate/ and enter, for example, time step = 0.1 s and number of time steps = 10.

Now, I would like to do this from the command line (to set up an inputfile and run simulation from batch mode). However, in the command line menu, if I chose solve/iterate this is a different command that will only ask for the number of iterations.

Question: What is the correct command line input for time step iteration?

Thanks!

coglione December 10, 2009 04:06

Hello jouke,

for transient runs use solve/dual-time-iterate

cheers

jack1980 December 10, 2009 08:20

Thanks for giving the correct command. However I still run into trouble. What I'm trying to do is write a simple inputfile as in Fluent User's Guide 1.3.1. It looks like this:

=== inputfile ===
rcd broken_dam_03.cas
solve/dual-time-iterate 9 20
wcd test.cas
exit
yes
============

When I run this sequence of commands from the command line in Fluent it works fine. However, when I run this inputfile from batch, the outputfile gives several errors, the first one being:

=========
[...]
Reading "broken_dam_03.dat"...
Done.
invalid command [
]
>
Error: eval: unbound variable
Error Object: 20
Invalid integer.
Number of iterations per time step [20]
[...]
=========

What could be wrong?

saeed December 10, 2009 09:36

hi
i run PEM fuel cell in fluent but resive an error:
Error:floating point;invalid number
please help me!

AnjaMiehe December 10, 2009 10:55

Quote:

Originally Posted by jack1980 (Post 239460)
Thanks for giving the correct command. However I still run into trouble. What I'm trying to do is write a simple inputfile as in Fluent User's Guide 1.3.1. It looks like this:

=== inputfile ===
rcd broken_dam_03.cas
solve/dual-time-iterate 9 20
wcd test.cas
exit
yes
============

When I run this sequence of commands from the command line in Fluent it works fine. However, when I run this inputfile from batch, the outputfile gives several errors, the first one being:

=========
[...]
Reading "broken_dam_03.dat"...
Done.
invalid command [
]
>
Error: eval: unbound variable
Error Object: 20
Invalid integer.
Number of iterations per time step [20]
[...]
=========

What could be wrong?

Hey,

I found a paper http://www.google.de/url?sa=t&source...a_Yutzd4RAyo4A (language: german) saying the command is:
Code:

/solve/dual-time-iterate [number-of-timesteps] [max-number-of-iterations-per-time-step]
where everything in the brackets including the brackets has to be replaced by a number. I tried it and it works.

Hope, it works for you too

dokeun July 16, 2010 02:32

Dear AnjaMiehe
Thank you so much~ That's what I'm looking for solving my prob

Chris D July 16, 2010 11:15

For the sake of posterity, you might have a problem if you write a script in windows and run it in unix/linux. The reason is that each os uses a different end of line character, so fluent will have some problem when it tries to read your script.

To see if this is your problem, you can open your script with a text editor (e.g., vi) and it will display some message at the bottom if it is in dos format. This took me an embarassingly long time to figure out, so hopefully I can save someone else the trouble!

The fix is to either
1) Write your script in linux with your favorite text editor, or...

2) Run the command dos2unix [input_file] to convert from dos format to unix/linux format.

aarvay February 28, 2011 15:27

Quote:

Originally Posted by Chris D (Post 267668)
For the sake of posterity, you might have a problem if you write a script in windows and run it in unix/linux. The reason is that each os uses a different end of line character, so fluent will have some problem when it tries to read your script.

To see if this is your problem, you can open your script with a text editor (e.g., vi) and it will display some message at the bottom if it is in dos format. This took me an embarassingly long time to figure out, so hopefully I can save someone else the trouble!

The fix is to either
1) Write your script in linux with your favorite text editor, or...

2) Run the command dos2unix [input_file] to convert from dos format to unix/linux format.

Gonna bump this old thread to say thanks for this. Typing in the individual commands worked fine, but once i tried loading the journal file I kept getting weirdness and errors such as

]nvalid command [

Doing the conversion with dos2unix fixed it. I had been using windows based notepad to write my script and it ran fine on my windows based fluent setup, but once i uploaded it to our unix cluster, it gave issues. So thanks again.


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