|
[Sponsors] |
November 15, 2018, 08:06 |
how to write a CFX batch file in linux?
|
#1 |
New Member
gengchen
Join Date: May 2018
Posts: 14
Rep Power: 8 |
hello, everyone. I want to know how to run a series of cases with the same model, the only difference is boundary conditions. say a mass flow rate changing from 1kg,2kg,3kg……10kg. I don't want to set the boundary conditions one by one. Is there a way to realize it? can you give me an example file with the correct format? thanks!!!
|
|
November 15, 2018, 16:33 |
|
#2 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,828
Rep Power: 144 |
Generate a CCL file. Then generate copies of the CCL file with the boundary condition modified to have 1kg/s, 2kg/s etc. Then do a batch script to run them all, something like
cfx5solve -ccl run1.ccl cfx5solve -ccl run2.ccl Alternately you can do this with parametric modelling in workbench.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
November 16, 2018, 09:31 |
|
#3 |
Senior Member
Join Date: Jun 2009
Posts: 1,859
Rep Power: 33 |
There are many ways to answer this question. Here are some (skipping CEL to minimize them)
1 - Glenn's suggestion: generate one command file per value of the BC, and use the command line repeatedly 2 - Create a script in any language (Perl, csh/bash/ksh, Python) that will do: Extract the command file (using cfx5cmds -def ...) Loop over the values of interest Search for value to be replaced Replace such value Submit simulation using cfx5solve -def .. -ccl new_file.ccl 3 - Use the latest version of the software, and use the new feature for this intended purpose (Operating Maps). Read the documentation, and you will be on your way, i.e. interpreting results. Hope the above helps, |
|
Tags |
batch, cfx, linux |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[foam-extend.org] Problems installing foam-extend-4.0 on openSUSE 42.2 and Ubuntu 16.04 | ordinary | OpenFOAM Installation | 19 | September 3, 2019 18:13 |
[swak4Foam] swak4foam building problem | GGerber | OpenFOAM Community Contributions | 54 | April 24, 2015 16:02 |
[swak4Foam] build problem swak4Foam OF 2.2.0 | mcathela | OpenFOAM Community Contributions | 14 | April 23, 2013 13:59 |
pisoFoam compiling error with OF 1.7.1 on MAC OSX | Greg Givogue | OpenFOAM Programming & Development | 3 | March 4, 2011 17:18 |
DecomposePar links against liblamso0 with OpenMPI | jens_klostermann | OpenFOAM Bugs | 11 | June 28, 2007 17:51 |