#!/bin/sh
cd ${0%/*} || exit 1    # Run from this directory

# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions

application=$(getApplication)

runApplication blockMesh

#------------------------------------------------------------------------------
echo -e "   - Extract the face zone in which the rapture disc is located"
topoSet >> logMeshing


#------------------------------------------------------------------------------
echo -e "   - Use the face zone to create 4 duplications of the internal faces"
echo -e "     2x cyclic and 2x walls"
createBaffles -overwrite >> logMeshing


#------------------------------------------------------------------------------
echo -e "   - Merge the two walls into one patch"
createPatch -overwrite >> logMeshing

runApplication setFields
runApplication $application
runApplication -s sample  postProcess -func sample

#------------------------------------------------------------------------------
