From 096b9dc52e5124b1931729bcf3bf46bd5d75e07a Mon Sep 17 00:00:00 2001 From: Mark Olesen <Mark.Olesen@esi-group.com> Date: Thu, 17 Jun 2021 10:20:10 +0200 Subject: [PATCH] TUT: add parallel version for various squareBend cases - adjust commented-out evaluation to avoid warnings. With code like this ``` #if 0 nxin #eval{ round($nxin / 5) }; #endif ``` The handling of the "#if 0 / #endif" clause uses the plain ISstream parser to tokenize. This means that the "round(" is parsed as a word with a mismatched closing ')', whereas the "#eval" parser will slurp everything in until the closing brace and send it off as a string to the expression parser. --- .../parallelOverset/heatTransfer/Allclean | 4 +-- applications/test/volField/cavity/Allclean | 1 + etc/templates/axisymmetricJet/Allclean | 8 +++-- etc/templates/axisymmetricJet/Allrun | 5 +-- .../rhoPimpleFoam/RAS/squareBendLiq/Allclean | 8 ----- .../rhoPimpleFoam/RAS/squareBendLiq/Allrun | 6 +--- .../RAS/squareBendLiq/Allrun-parallel} | 8 +++-- .../RAS/squareBendLiq/Allrun.pre} | 8 +++-- .../RAS/squareBendLiq/system/blockMeshDict | 8 ++--- .../rhoSimpleFoam/squareBend/Allrun | 25 +-------------- .../rhoSimpleFoam/squareBend/Allrun-parallel | 12 +++++++ .../rhoSimpleFoam/squareBend/Allrun.pre | 32 +++++++++++++++++++ .../rhoSimpleFoam/squareBendLiq/Allrun | 6 +--- .../squareBendLiq/Allrun-parallel | 12 +++++++ .../Allclean => squareBendLiq/Allrun.pre} | 8 +++-- .../squareBendLiq/system/blockMeshDict | 8 ++--- .../squareBendLiqNoNewtonian/Allrun | 6 +--- .../squareBendLiqNoNewtonian/Allrun-parallel | 12 +++++++ .../Allrun.pre} | 8 +++-- .../system/blockMeshDict | 8 ++--- .../LES/periodicHill/transient/Allclean | 8 ----- .../simpleFoam/squareBend/Allrun | 12 +------ .../simpleFoam/squareBend/Allrun-parallel | 12 +++++++ .../simpleFoam/squareBend/Allrun.pre | 18 +++++++++++ .../squareBend/system/blockMeshDict | 8 ++--- 25 files changed, 151 insertions(+), 100 deletions(-) delete mode 100755 tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allclean rename tutorials/compressible/{rhoSimpleFoam/squareBendLiqNoNewtonian/Allclean => rhoPimpleFoam/RAS/squareBendLiq/Allrun-parallel} (62%) rename tutorials/{incompressible/simpleFoam/squareBend/Allclean => compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun.pre} (64%) create mode 100755 tutorials/compressible/rhoSimpleFoam/squareBend/Allrun-parallel create mode 100755 tutorials/compressible/rhoSimpleFoam/squareBend/Allrun.pre create mode 100755 tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun-parallel rename tutorials/compressible/rhoSimpleFoam/{squareBend/Allclean => squareBendLiq/Allrun.pre} (64%) create mode 100755 tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun-parallel rename tutorials/compressible/rhoSimpleFoam/{squareBendLiq/Allclean => squareBendLiqNoNewtonian/Allrun.pre} (64%) delete mode 100755 tutorials/incompressible/pimpleFoam/LES/periodicHill/transient/Allclean create mode 100755 tutorials/incompressible/simpleFoam/squareBend/Allrun-parallel create mode 100755 tutorials/incompressible/simpleFoam/squareBend/Allrun.pre diff --git a/applications/test/parallelOverset/heatTransfer/Allclean b/applications/test/parallelOverset/heatTransfer/Allclean index 2f87da61e0f..3f55a994865 100755 --- a/applications/test/parallelOverset/heatTransfer/Allclean +++ b/applications/test/parallelOverset/heatTransfer/Allclean @@ -3,10 +3,8 @@ cd "${0%/*}" || exit # Run from this directory . ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions #------------------------------------------------------------------------------ -cleanCase +cleanCase0 rm -f constant/polyMesh/boundary rm -f constant/polyMesh/zoneID -rm -rf 0 - #------------------------------------------------------------------------------ diff --git a/applications/test/volField/cavity/Allclean b/applications/test/volField/cavity/Allclean index 67037edd0a8..9b26b998366 100755 --- a/applications/test/volField/cavity/Allclean +++ b/applications/test/volField/cavity/Allclean @@ -1,6 +1,7 @@ #!/bin/sh cd "${0%/*}" || exit # Run from this directory . ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions +#------------------------------------------------------------------------------ cleanCase diff --git a/etc/templates/axisymmetricJet/Allclean b/etc/templates/axisymmetricJet/Allclean index 08a28bfa7eb..c44edd49362 100755 --- a/etc/templates/axisymmetricJet/Allclean +++ b/etc/templates/axisymmetricJet/Allclean @@ -1,8 +1,10 @@ #!/bin/sh -cd "${0%/*}" || exit # Run from this directory -. $WM_PROJECT_DIR/bin/tools/CleanFunctions # Tutorial clean functions +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions +#------------------------------------------------------------------------------ cleanCase -rm constant/polyMesh/boundary + +rm -f constant/polyMesh/boundary #------------------------------------------------------------------------------ diff --git a/etc/templates/axisymmetricJet/Allrun b/etc/templates/axisymmetricJet/Allrun index 110caeb3626..ebca64303fa 100755 --- a/etc/templates/axisymmetricJet/Allrun +++ b/etc/templates/axisymmetricJet/Allrun @@ -1,6 +1,7 @@ #!/bin/sh -cd "${0%/*}" || exit # Run from this directory -. $WM_PROJECT_DIR/bin/tools/RunFunctions # Tutorial run functions +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions +#------------------------------------------------------------------------------ runApplication blockMesh runApplication extrudeMesh diff --git a/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allclean b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allclean deleted file mode 100755 index fb1f3847301..00000000000 --- a/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allclean +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -cd "${0%/*}" || exit # Run from this directory -. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions -#------------------------------------------------------------------------------ - -cleanCase0 - -#------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun index b1499edc525..78d5debbe7f 100755 --- a/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun +++ b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun @@ -3,11 +3,7 @@ cd "${0%/*}" || exit # Run from this directory . ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -restore0Dir - -runApplication blockMesh - -runApplication topoSet +./Allrun.pre runApplication $(getApplication) diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allclean b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun-parallel similarity index 62% rename from tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allclean rename to tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun-parallel index fb1f3847301..f9aa96400d9 100755 --- a/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allclean +++ b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun-parallel @@ -1,8 +1,12 @@ #!/bin/sh cd "${0%/*}" || exit # Run from this directory -. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -cleanCase0 +./Allrun.pre + +runApplication decomposePar + +runParallel $(getApplication) #------------------------------------------------------------------------------ diff --git a/tutorials/incompressible/simpleFoam/squareBend/Allclean b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun.pre similarity index 64% rename from tutorials/incompressible/simpleFoam/squareBend/Allclean rename to tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun.pre index 4afce75b5c8..0063b9c3a6c 100755 --- a/tutorials/incompressible/simpleFoam/squareBend/Allclean +++ b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/Allrun.pre @@ -1,10 +1,12 @@ #!/bin/sh cd "${0%/*}" || exit # Run from this directory -. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -cleanCase0 +restore0Dir -rm -rf constant/triSurface +runApplication blockMesh + +runApplication topoSet #------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/system/blockMeshDict b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/system/blockMeshDict index 65973db7716..5985abc63d2 100644 --- a/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/system/blockMeshDict +++ b/tutorials/compressible/rhoPimpleFoam/RAS/squareBendLiq/system/blockMeshDict @@ -1,7 +1,7 @@ /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: v2012 | +| \\ / O peration | Version: v2106 | | \\ / A nd | Website: www.openfoam.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ @@ -34,9 +34,9 @@ xin #eval{ $xin / 5 }; xout #eval{ $xout / 5 }; zmax #eval{ $zmax / 5 }; -nxin #eval{ round($nxin / 5) }; -nxout #eval{ round($nxout / 5) }; -nz #eval{ round($nz / 5) }; +nxin #eval{ round ($nxin / 5) }; +nxout #eval{ round ($nxout / 5) }; +nz #eval{ round ($nz / 5) }; #endif zmin #eval{ -$zmax }; diff --git a/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun b/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun index 6624f4bbfd8..78d5debbe7f 100755 --- a/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun +++ b/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun @@ -3,30 +3,7 @@ cd "${0%/*}" || exit # Run from this directory . ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -restore0Dir - -cp -rf \ - "$FOAM_TUTORIALS"/resources/geometry/squareBend \ - constant/triSurface - -runApplication blockMesh - -# Extract some faces for sampling -runApplication surfaceMeshExtract \ - -patches inlet -time 0 \ - constant/triSurface/inlet_sample0.obj - -# Recentre and inflate -runApplication surfaceTransformPoints \ - -recentre \ - -scale 3.5 \ - constant/triSurface/inlet_sample0.obj \ - constant/triSurface/inlet_sample1.obj - -# Finer mesh -runApplication surfaceRefineRedGreen \ - constant/triSurface/inlet_sample1.obj \ - constant/triSurface/oversized_sample.obj +./Allrun.pre runApplication $(getApplication) diff --git a/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun-parallel b/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun-parallel new file mode 100755 index 00000000000..f9aa96400d9 --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun-parallel @@ -0,0 +1,12 @@ +#!/bin/sh +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions +#------------------------------------------------------------------------------ + +./Allrun.pre + +runApplication decomposePar + +runParallel $(getApplication) + +#------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun.pre b/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun.pre new file mode 100755 index 00000000000..b1dc24c3270 --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/squareBend/Allrun.pre @@ -0,0 +1,32 @@ +#!/bin/sh +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions +#------------------------------------------------------------------------------ + +restore0Dir + +cp -rf \ + "$FOAM_TUTORIALS"/resources/geometry/squareBend \ + constant/triSurface + +runApplication blockMesh + +# Extract some faces for sampling +runApplication surfaceMeshExtract \ + -patches inlet -time 0 \ + constant/triSurface/inlet_sample0.obj + +# Recentre and inflate +runApplication surfaceTransformPoints \ + -recentre \ + -scale 3.5 \ + constant/triSurface/inlet_sample0.obj \ + constant/triSurface/inlet_sample1.obj + +# Finer mesh +runApplication surfaceRefineRedGreen \ + constant/triSurface/inlet_sample1.obj \ + constant/triSurface/oversized_sample.obj + + +#------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun index b1499edc525..78d5debbe7f 100755 --- a/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun @@ -3,11 +3,7 @@ cd "${0%/*}" || exit # Run from this directory . ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -restore0Dir - -runApplication blockMesh - -runApplication topoSet +./Allrun.pre runApplication $(getApplication) diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun-parallel b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun-parallel new file mode 100755 index 00000000000..f9aa96400d9 --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun-parallel @@ -0,0 +1,12 @@ +#!/bin/sh +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions +#------------------------------------------------------------------------------ + +./Allrun.pre + +runApplication decomposePar + +runParallel $(getApplication) + +#------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoSimpleFoam/squareBend/Allclean b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun.pre similarity index 64% rename from tutorials/compressible/rhoSimpleFoam/squareBend/Allclean rename to tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun.pre index 4afce75b5c8..0063b9c3a6c 100755 --- a/tutorials/compressible/rhoSimpleFoam/squareBend/Allclean +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allrun.pre @@ -1,10 +1,12 @@ #!/bin/sh cd "${0%/*}" || exit # Run from this directory -. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -cleanCase0 +restore0Dir -rm -rf constant/triSurface +runApplication blockMesh + +runApplication topoSet #------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiq/system/blockMeshDict b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/system/blockMeshDict index 65973db7716..5985abc63d2 100644 --- a/tutorials/compressible/rhoSimpleFoam/squareBendLiq/system/blockMeshDict +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiq/system/blockMeshDict @@ -1,7 +1,7 @@ /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: v2012 | +| \\ / O peration | Version: v2106 | | \\ / A nd | Website: www.openfoam.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ @@ -34,9 +34,9 @@ xin #eval{ $xin / 5 }; xout #eval{ $xout / 5 }; zmax #eval{ $zmax / 5 }; -nxin #eval{ round($nxin / 5) }; -nxout #eval{ round($nxout / 5) }; -nz #eval{ round($nz / 5) }; +nxin #eval{ round ($nxin / 5) }; +nxout #eval{ round ($nxout / 5) }; +nz #eval{ round ($nz / 5) }; #endif zmin #eval{ -$zmax }; diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun index b1499edc525..78d5debbe7f 100755 --- a/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun @@ -3,11 +3,7 @@ cd "${0%/*}" || exit # Run from this directory . ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -restore0Dir - -runApplication blockMesh - -runApplication topoSet +./Allrun.pre runApplication $(getApplication) diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun-parallel b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun-parallel new file mode 100755 index 00000000000..f9aa96400d9 --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun-parallel @@ -0,0 +1,12 @@ +#!/bin/sh +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions +#------------------------------------------------------------------------------ + +./Allrun.pre + +runApplication decomposePar + +runParallel $(getApplication) + +#------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allclean b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun.pre similarity index 64% rename from tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allclean rename to tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun.pre index fb1f3847301..0063b9c3a6c 100755 --- a/tutorials/compressible/rhoSimpleFoam/squareBendLiq/Allclean +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/Allrun.pre @@ -1,8 +1,12 @@ #!/bin/sh cd "${0%/*}" || exit # Run from this directory -. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -cleanCase0 +restore0Dir + +runApplication blockMesh + +runApplication topoSet #------------------------------------------------------------------------------ diff --git a/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/system/blockMeshDict b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/system/blockMeshDict index adc941d8025..6f7ea300a6e 100644 --- a/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/system/blockMeshDict +++ b/tutorials/compressible/rhoSimpleFoam/squareBendLiqNoNewtonian/system/blockMeshDict @@ -1,7 +1,7 @@ /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: v2012 | +| \\ / O peration | Version: v2106 | | \\ / A nd | Website: www.openfoam.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ @@ -34,9 +34,9 @@ xin #eval{ $xin / 5 }; xout #eval{ $xout / 5 }; zmax #eval{ $zmax / 5 }; -nxin #eval{ round($nxin / 5) }; -nxout #eval{ round($nxout / 5) }; -nz #eval{ round($nz / 5) }; +nxin #eval{ round ($nxin / 5) }; +nxout #eval{ round ($nxout / 5) }; +nz #eval{ round ($nz / 5) }; #endif zmin #eval{ -$zmax }; diff --git a/tutorials/incompressible/pimpleFoam/LES/periodicHill/transient/Allclean b/tutorials/incompressible/pimpleFoam/LES/periodicHill/transient/Allclean deleted file mode 100755 index 426e7ad42e7..00000000000 --- a/tutorials/incompressible/pimpleFoam/LES/periodicHill/transient/Allclean +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -cd "${0%/*}" || exit # Run from this directory -. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions -#------------------------------------------------------------------------------ - -cleanCase - -#------------------------------------------------------------------------------ diff --git a/tutorials/incompressible/simpleFoam/squareBend/Allrun b/tutorials/incompressible/simpleFoam/squareBend/Allrun index 9f3b08bc332..78d5debbe7f 100755 --- a/tutorials/incompressible/simpleFoam/squareBend/Allrun +++ b/tutorials/incompressible/simpleFoam/squareBend/Allrun @@ -3,17 +3,7 @@ cd "${0%/*}" || exit # Run from this directory . ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions #------------------------------------------------------------------------------ -mkdir -p constant/triSurface - -cp -f \ - "$FOAM_TUTORIALS"/resources/geometry/angledPlane.obj.gz \ - constant/triSurface - -restore0Dir - -runApplication blockMesh - -runApplication topoSet +./Allrun.pre runApplication $(getApplication) diff --git a/tutorials/incompressible/simpleFoam/squareBend/Allrun-parallel b/tutorials/incompressible/simpleFoam/squareBend/Allrun-parallel new file mode 100755 index 00000000000..f9aa96400d9 --- /dev/null +++ b/tutorials/incompressible/simpleFoam/squareBend/Allrun-parallel @@ -0,0 +1,12 @@ +#!/bin/sh +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions +#------------------------------------------------------------------------------ + +./Allrun.pre + +runApplication decomposePar + +runParallel $(getApplication) + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressible/simpleFoam/squareBend/Allrun.pre b/tutorials/incompressible/simpleFoam/squareBend/Allrun.pre new file mode 100755 index 00000000000..949833760db --- /dev/null +++ b/tutorials/incompressible/simpleFoam/squareBend/Allrun.pre @@ -0,0 +1,18 @@ +#!/bin/sh +cd "${0%/*}" || exit # Run from this directory +. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions +#------------------------------------------------------------------------------ + +mkdir -p constant/triSurface + +cp -f \ + "$FOAM_TUTORIALS"/resources/geometry/angledPlane.obj.gz \ + constant/triSurface + +restore0Dir + +runApplication blockMesh + +runApplication topoSet + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressible/simpleFoam/squareBend/system/blockMeshDict b/tutorials/incompressible/simpleFoam/squareBend/system/blockMeshDict index 65973db7716..5985abc63d2 100644 --- a/tutorials/incompressible/simpleFoam/squareBend/system/blockMeshDict +++ b/tutorials/incompressible/simpleFoam/squareBend/system/blockMeshDict @@ -1,7 +1,7 @@ /*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: v2012 | +| \\ / O peration | Version: v2106 | | \\ / A nd | Website: www.openfoam.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ @@ -34,9 +34,9 @@ xin #eval{ $xin / 5 }; xout #eval{ $xout / 5 }; zmax #eval{ $zmax / 5 }; -nxin #eval{ round($nxin / 5) }; -nxout #eval{ round($nxout / 5) }; -nz #eval{ round($nz / 5) }; +nxin #eval{ round ($nxin / 5) }; +nxout #eval{ round ($nxout / 5) }; +nz #eval{ round ($nz / 5) }; #endif zmin #eval{ -$zmax }; -- GitLab