amir.mofakham |
April 7, 2020 09:32 |
I just want to add if you want to use refineMesh more than one time make sure to set the startFrom in controlDict to latestTime. Because each time refineMesh creates a mesh at a new time step and if startFrom is not set to latestTime refineshMesh does not read the refined mesh.
Cheers.
Quote:
Originally Posted by nlinder
(Post 402605)
Yes i use a script.
You need several cellSet files called cellSetDict.1, cellSetDict.2 .... I created them manually.
Then I use the following script (credits to the one who wrote it, I actually don't know)
Code:
refineMeshByCellSet()
{
while [ $# -ge 1 ]
do
echo "creating cell set for primary zone - $1"
cp system/cellSetDict.$1 system/cellSetDict
cellSet > log.cellSet.$1 2>&1
echo "refining primary zone - $1"
refineMesh -dict -overwrite > log.refineMesh.$1 2>&1
shift
done
}
runApplication blockMesh
echo "BlockMesh finish"
refineMeshByCellSet 1 2 3
echo "refineMeshByCellSet finish"
The second last line defines how often it will be refined..
Greetings
|
|