See http://www.openfoam.org/mantisbt/view.php?id=2076 - .org is the file extension for emacs org-mode as well - .orig is more to the point (.org isn't always recognized as "original") - .original is too long, although more consistent with the convention of source code file naming Update script contributed by Bruno Santos
31 lines
989 B
Bash
Executable File
31 lines
989 B
Bash
Executable File
#!/bin/sh
|
|
cd ${0%/*} || exit 1 # Run from this directory
|
|
|
|
# Source tutorial run functions
|
|
. $WM_PROJECT_DIR/bin/tools/RunFunctions
|
|
|
|
# Make 3D mesh in slab of cells.
|
|
cd wingMotion_snappyHexMesh
|
|
runApplication blockMesh
|
|
runApplication snappyHexMesh -overwrite
|
|
|
|
# Make a 2D mesh by extruding a patch and solve to steady state.
|
|
cd ../wingMotion2D_simpleFoam
|
|
runApplication extrudeMesh
|
|
runApplication createPatch -overwrite
|
|
cp -r 0.orig 0
|
|
runApplication simpleFoam
|
|
|
|
# Copy the mesh from the steady state case and map the results to a
|
|
# mesh motion case, then solve transient.
|
|
cd ../wingMotion2D_pimpleDyMFoam
|
|
cp -r ../wingMotion2D_simpleFoam/constant/polyMesh constant
|
|
cp -r 0.orig 0
|
|
runApplication mapFields ../wingMotion2D_simpleFoam -sourceTime latestTime -consistent
|
|
mv 0/pointDisplacement.unmapped 0/pointDisplacement
|
|
runApplication decomposePar
|
|
runParallel `getApplication`
|
|
runApplication reconstructPar
|
|
|
|
#------------------------------------------------------------------------------
|