Run case with different settings
Hello Foamers
I had a quick look, but since I didn't find a single hit on google, I will ask the question right here: How can I run an OpenFOAM case automatically with different settings? Lets say I would like to compare different schemes. How can I programm this? Does this have to edited in the "Allrun"-shell? It would be desirable if I get all the results in the same main folder. And, after I run foamToVTK, I can load all results out of the same folder. Every input is warmly welcome! Thank you Triggin |
Run case with different settings
Hi Triggin,
OpenFoam uses text files, as you probably already know. I don't know of a facility within OpenFoam to run several jobs in the same run folder. You can, however, create different run folders. Using the Allrun script will help run them automatically. You will have to load the results out of different folders, however. HTH, Chris Quote:
|
Hi fisichel, thank you for the answer.
Okay. So probably i have to set a for-loop (e.g. for an array of different inlet velocities) in the Allrun-script. As soon as the calculation is finished, rename the solution folder and lets the case run again with the new velocity. At the end i could automatically move all .vtk-files into the same folder, to have all together. If anyone did something similar already, please let us know. I will start to do something like this and would post the script here (this won't happen before the mid of february). Best wishes Triggin |
Run case with different settings
Hi,
That sounds like a very reasonable approach. You don't necessarily have to use a shell script. Python, C, or some other language could be used. Like you pointed out, you just need to have file interrogation and file manipulation facilities to do what you need to do. It's too bad you have to wait blindly for the vtk files. Are you able to look at the output and decide on a new value? That might help direct your calculations better. OpenFoam can also output force files. They are easy to query. Best Regards, Chris Quote:
|
For the ones who are interested in:
I just made a shell script which is able to set up different simulations, based on different values (cf. the array rollVel and inletVel). Code:
#!/bin/sh Quote:
Thanks to Chris for your support :) Best regards Triggin |
Very cool. That's all there is to it. This is one of my favorite features of OpenFOAM. It's transparent. Good luck!
Best, Chris |
All times are GMT -4. The time now is 17:05. |