To run this tutorial, you need to install "make", which can be installed on Ubuntu with the command "sudo apt install make".
Case directory
$FOAM_TUTORIALS/mesh/refineMesh/refineFieldDirs
Summary
We will use the utility refineMesh to refine an existing mesh.
First, we use blockMesh to create an initial mesh as shown below. After that, the mesh is redivided 6 times in the Z direction and 3 times in the cylindrical coordinate system.
The initial mesh - the number of meshes is 1880
The meshes are as follows.
The mesh refined in the Z direction - the number of meshes is 50400
Finished mesh - the number of meshes is 197120
Commands
cp -r $FOAM_TUTORIALS/mesh/refineMesh/refineFieldDirs refineFieldDirs
cd refineFieldDirs
# Build and install calcRadiusField into the system
wmake calcRadiusField
wclean calcRadiusField
# Create initial mesh
blockMesh
mkdir 0
# Refine the mesh 6 times in the Z direction
calcRadiusField
topoSet -dict system/topoSetDict.tier1
refineMesh -dict system/refineMeshDict.tier1 -overwrite
rm -r 0/*
# Refine the mesh 3 times in the cylindrical coordinate system
calcRadiusField -calcDirections
topoSet -dict system/topoSetDict.range1
refineMesh -dict system/refineMeshDict.range1 -overwrite
rm -r 0/*