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

Batch Mode : re-defining boundary conditions

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 27, 2007, 10:55
Default Batch Mode : re-defining boundary conditions
  #1
MaxiFLOW
Guest
 
Posts: n/a
Hello, my question is based on a example : I study an airfoil for multiple configurations where incidence varies. How could I automatically (i.e. in batch mode) change my value then run the solver with the new def file ? The goal is to solve multiple incidence configuration during week end without assistance ?

Thanks a lot for your answers
  Reply With Quote

Old   March 27, 2007, 19:58
Default Re: Batch Mode : re-defining boundary conditions
  #2
Glenn Horrocks
Guest
 
Posts: n/a
Hi,

You can set up multiple CCL files and write them to the def file with the cfx5cmds command. If you want to get really tricky you could write the CCL files as part of the script, but I generally just prepare the CCL files in advance and use a batch file to run the multiple cases.

Glenn Horrocks
  Reply With Quote

Old   March 28, 2007, 04:44
Default Re: Batch Mode : re-defining boundary conditions
  #3
MaxiFLOW
Guest
 
Posts: n/a
Hi, thank you for the answer Mr Horrocks but could you give me your script for example ? Because the help concerning commands is not very detailed... and I search such an example !

Thank you
  Reply With Quote

Old   March 28, 2007, 10:35
Default Re: Batch Mode : re-defining boundary conditions
  #4
Bian
Guest
 
Posts: n/a
I usually generate a bunch of def files with different boundary conditions, then run them in a batch by perl script. If you do not know how to set batch mode, the following is an example (change path and version accordingly). You can use previous result as initial field as well. Get more details by typing "cfx5solve -help" in the command window.

Put the script in ***.pl, then run it in command window: perl ***.pl =================================== #! perl -w use strict;

my $solver = 'C:\Progra~1\ANSYSI~1\v110\CFX\bin\cfx5solve.exe'; die "Unable to find program '$solver'" if ! -f $solver;

system "$solver -def ******.def -par-dist \"machine1,machine2\" -start-method \"MPICH Distributed Parallel for Windows\""; ====================================
  Reply With Quote

Old   March 28, 2007, 19:00
Default Re: Batch Mode : re-defining boundary conditions
  #5
Glenn Horrocks
Guest
 
Posts: n/a
Hi,

It is described in detail in the documentation, see the modelling manual. Below is a script I ran yesterday:

cfx5cmds -write -definition Engine.def -text Engine_002.ccl cfx5solve -definition Engine.def -start-method "MPICH Distributed Parallel for Windows" -par-dist "wswr0076,wswr0001,wswr0009,wswr0010" -partition 4

The first line (cfx5cmds) writes a new ccl file into the def file, the second line (cfx5solve) runs it using distributed MPICH for windows over 4 machines.

Bian has shown a more advanced way of doing it using perl script and it provides much greater flexibility, but you need to know the basic command line syntax (and perl!) before you should try doing it in perl.

Glenn Horrocks
  Reply With Quote

Old   March 29, 2007, 04:33
Default Re: Batch Mode : re-defining boundary conditions
  #6
MaxiFLOW
Guest
 
Posts: n/a
Thank you Bian and Glenn for your help !
  Reply With Quote

Old   March 29, 2007, 09:41
Default Re: Batch Mode : re-defining boundary conditions
  #7
Bian
Guest
 
Posts: n/a
After all def files are created, the only place needs change in the script is the last line for cfx5solve. More lines of cfx5solve could be added for batch run.

No particular perl knowledge is required. command line syntax can be obtained from help manual.
  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
mesh file for flow over a circular cylinder Ardalan Main CFD Forum 7 December 15, 2020 14:06
Water subcooled boiling Attesz CFX 7 January 5, 2013 04:32
Fluent accuracy and boundary conditions Paolo Lampitella FLUENT 0 June 12, 2008 07:25
Defining Boundary Conditions in GAMBIT Tim R FLUENT 3 April 14, 2008 05:30
Please help with flow around car modelling! Tudor Miron CFX 17 March 19, 2004 20:23


All times are GMT -4. The time now is 11:39.