CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   CFX (http://www.cfd-online.com/Forums/cfx/)
-   -   command line? & create batch file (http://www.cfd-online.com/Forums/cfx/112927-command-line-create-batch-file.html)

mansoor February 7, 2013 17:54

command line? & create batch file
 
Hi
I did this steps
step 1- Define the problem in Workbench (build geometry in DM, mesh in Mesh and assign BCs in Pre)
step 2- In Workbench, double click on Solution to launch Solver Manager which generates the definition (.def) file;

I follow 2 steps and in next step I've many problems that I can't create batch file! I don't know where must type ــــــــــcd C:\...... in below step :confused:

step 3 - Create a text batch file with the extension .bat with the following
cd C:\your_directory_path
"C:\Program Files\Ansys Inc\V121\CFX\bin\cfx5solve" -batch -def Fluid_Flow.def

my .def is save at this:
C:\Users\mansoor_PC\Desktop\Airfoil\abc_files\dp0\ CFX\CFX

And can anyone tell me the works for solve my problem?
ــــــــــــــــــــــــــــــــــــــــــــــــــ ــ
Thanks
Mansoor

rahulv February 8, 2013 02:02

try this
 
Write the code in a notepad file and save it as filename.bat

double click it


cd C:\Users\mansoor_PC\Desktop\Airfoil\abc_files\dp0\ CFX\CFX
"C:\Program Files\Ansys Inc\V121\CFX\bin\cfx5solve" -batch -def 1.def

cd C:\Users\mansoor_PC\Desktop\Airfoil\abc_files\dp0\ CFX\CFX
"C:\Program Files\Ansys Inc\V121\CFX\bin\cfx5solve" -batch -def 2.def

mansoor February 8, 2013 06:45

create Batch mode for several from one
 
First Thank you
Then I have a questions

It is for one airfoil with 16 point for define it. I displace randomly those points (with MATLAB) and create several airfoils.
in next step I should modify batch file and create it for new airfoils.
How do it?

mansoor February 9, 2013 01:26

Edit batch file
 
And is it possible to edit geometry from batch file? (with explanation in top)

ghorrocks February 9, 2013 06:15

If you modify the geometry you will need to run it through CFX-Pre as well. But CFX-pre can be scripted to run from the command line as well so you can still do this all in a single batch file.

mansoor February 9, 2013 13:50

Quote:

Originally Posted by ghorrocks (Post 406860)
If you modify the geometry you will need to run it through CFX-Pre as well. But CFX-pre can be scripted to run from the command line as well so you can still do this all in a single batch file.

Please tell me more, because I,m new new in cfx and a brief hint can help me to do it early.
Thank you

ghorrocks February 10, 2013 05:27

Record a session file in CFX-Pre. Then you can play that session file fro mthe command line using command line parameters. The command line is all described in the documentation.


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