Merge branch 'master' of ssh://opencfd@repo.or.cz/srv/git/OpenFOAM-1.5.x
[OpenFOAM-1.5.x.git] / tutorials / XiFoam / Allrun
blobc32a0b032edb5ecdfa90aa78bce3064eba52c4f4
1 #!/bin/sh
2 # Source tutorial run functions
3 . $WM_PROJECT_DIR/bin/tools/RunFunctions
5 # Get application name from directory
6 application=`basename $PWD`
8 setControlDict () {
9 controlDict="system/controlDict"
10 sed \
11 -e s/"\(deltaT[ \t]*\) 5e-06;"/"\1 1e-05;"/g \
12 -e s/"\(endTime[ \t]*\) 0.005;"/"\1 0.015;"/g \
13 -e s/"\(writeInterval[ \t]*\) 10;"/"\1 50;"/g \
14 $controlDict > temp.$$
15 mv temp.$$ $controlDict
18 # Do moriyoshiHomogeneous
19 (cd moriyoshiHomogeneous && foamRunTutorials)
21 # Clone case
22 cloneCase moriyoshiHomogeneous moriyoshiHomogeneousPart2
23 # Modify and execute
24 cd moriyoshiHomogeneousPart2
25 cp -r ../moriyoshiHomogeneous/0.005 .
26 setControlDict
27 runApplication $application
28 cd ..