Commit 9f465451 authored by henry's avatar henry
Browse files

Get the application from the controlDict where necessary.

parent 4c3c9f2c
......@@ -50,7 +50,7 @@ elif [ -d "./system" ]
then
# Normal case.
parentDir=`dirname $PWD`
application=`basename $parentDir`
application=`getApplication`
runApplication blockMesh
runApplication $application
else
......
......@@ -29,6 +29,11 @@
#
#------------------------------------------------------------------------------
getApplication ()
{
grep application system/controlDict | sed "s/application *\([a-zA-Z]*\);/\1/"
}
runApplication ()
{
APP_RUN=$1; shift
......
......@@ -2,8 +2,8 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
application="dnsFoam"
# Get application name
application=`getApplication`
runApplication blockMesh
runApplication boxTurb
......
......@@ -2,8 +2,8 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application directory
application="laplacianFoam"
# Get application name
application=`getApplication`
runAnsysToFoam()
{
......
......@@ -2,7 +2,7 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application="potentialFoam"
application=`getApplication`
runApplication blockMesh
runApplication $application
......
......@@ -2,7 +2,7 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application="potentialFoam"
application=`getApplication`
runApplication blockMesh
runApplication $application
......
......@@ -2,7 +2,7 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
# Set application name
application="XiFoam"
setControlDict () {
......
......@@ -2,8 +2,8 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
application="engineFoam"
# Get application name
application=`getApplication`
runKivaToFoam ()
{
......
......@@ -2,8 +2,8 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
application=${PWD##*/}
# Get application name
application="rhoCentralFoam"
cases=" \
shockTube \
......
#!/bin/sh
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
application="rhoSonicFoam"
# Get application name
application=`getApplication`
runApplication blockMesh
runApplication setFields
......
......@@ -2,7 +2,7 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application="rhopSonicFoam"
application=`getApplication`
runApplication blockMesh
runApplication setFields
......
#!/bin/sh
set -x
(cd laminar && ./Allrun)
(cd ras && ./Allrun)
#!/bin/sh
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
application=sonicFoam
cases=" \
forwardStep \
shockTube \
"
for case in $cases
do
(cd $case && runApplication blockMesh)
#
if [ "$case" = "shockTube" ] ; then
(cd $case && ./Allrun)
else
(cd $case && runApplication $application)
fi
#
done
......@@ -2,7 +2,7 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application="sonicFoam"
application=`getApplication`
runApplication blockMesh
runApplication setFields
......
......@@ -2,8 +2,8 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
application=${PWD##*/}
# Get application name
application=`getApplication`
runStarToFoam ()
{
......@@ -15,15 +15,9 @@ runStarToFoam ()
fi
}
# Do prism
(cd prism && foamRunTutorials)
# Special handling for nacaAirfoil
cd nacaAirfoil
runStarToFoam prostar/nacaAirfoil
mv constant/polyMesh/boundary temp
sed -e s/"\([\t ]*type[\t ]*\)symmetryPlane"/"\1empty"/g \
temp > constant/polyMesh/boundary
rm temp
runApplication $application
cd ..
runStarToFoam prostar/nacaAirfoil
mv constant/polyMesh/boundary temp
sed -e s/"\([\t ]*type[\t ]*\)symmetryPlane"/"\1empty"/g \
temp > constant/polyMesh/boundary
rm temp
runApplication $application
......@@ -2,11 +2,7 @@ nacaAirfoil
~~~~~~~~~~~
* large domain with airfoil section near centre
* extremely non-orthogonal, highly skew mesh refined around the airfoil
* running at Mach 1.78
* running at Mach 1.78
* limited 0.5 on all laplacianSchemes because the mesh is so poor
* run to t = 0.02 with nextWrite; change to stopAt endTime to continue running
* deltaT can be increased later in the run to 2e-07
prism
~~~~~
* run to t = 0.0014 for convergence
* run to t = 0.02 with nextWrite; change to stopAt endTime to continue running
* deltaT can be increased later in the run to 2e-07
......@@ -2,8 +2,8 @@
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
# Get application name from directory
application=${PWD##*/}
# Set application name
application="sonicLiquidFoam"
setDecompressionTankFine ()
{
......
#!/bin/sh
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application="mdFoam"
cd nanoNozzle
runApplication blockMesh
runApplication decomposePar
hostname > system/machines
runParallel mdInitialise 4 system/machines
runParallel $application 4 system/machines
runApplication reconstructPar
cd ..
......@@ -3,8 +3,6 @@
# Source tutorial clean functions
. $WM_PROJECT_DIR/bin/tools/CleanFunctions
cd nanoNozzle
rm -rf constant/polyMesh/sets
rm -rf processor[0-9]
cleanCase
cd ..
rm -rf constant/polyMesh/sets
rm -rf processor[0-9]
cleanCase
#!/bin/sh
# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application=`getApplication`
runApplication blockMesh
runApplication decomposePar
hostname > system/machines
runParallel mdInitialise 4 system/machines
runParallel $application 4 system/machines
runApplication reconstructPar
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment