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

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

# Copy propeller surface from resources directory
cp $FOAM_TUTORIALS/resources/geometry/propeller.obj.gz constant/triSurface/

# Meshing
runApplication blockMesh
runApplication surfaceFeatures
runApplication snappyHexMesh -overwrite

# Create the inlet/outlet and AMI patches
runApplication createBaffles -overwrite
runApplication mergeOrSplitBaffles -split -overwrite

# Renumbering
runApplication renumberMesh -noFields -overwrite

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