diff --git a/tutorials/compressibleVoF/damBreak/0/T b/tutorials/compressibleVoF/damBreak/0/T index 237bd2d44b..24155c3d2e 100644 --- a/tutorials/compressibleVoF/damBreak/0/T +++ b/tutorials/compressibleVoF/damBreak/0/T @@ -9,6 +9,7 @@ FoamFile { format ascii; class volScalarField; + location "0"; object T; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -46,4 +47,5 @@ boundaryField } } + // ************************************************************************* // diff --git a/tutorials/compressibleVoF/damBreak/0/U b/tutorials/compressibleVoF/damBreak/0/U index 4a0752a083..adf3c5a7e5 100644 --- a/tutorials/compressibleVoF/damBreak/0/U +++ b/tutorials/compressibleVoF/damBreak/0/U @@ -38,7 +38,7 @@ boundaryField atmosphere { type pressureInletOutletVelocity; - value uniform (0 0 0); + value $internalField; } defaultFaces diff --git a/tutorials/compressibleVoF/damBreak/0/alpha.water.orig b/tutorials/compressibleVoF/damBreak/0/alpha.water.orig index 3c85d4cf85..93680700de 100644 --- a/tutorials/compressibleVoF/damBreak/0/alpha.water.orig +++ b/tutorials/compressibleVoF/damBreak/0/alpha.water.orig @@ -9,6 +9,7 @@ FoamFile { format ascii; class volScalarField; + location "0"; object alpha.water; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -37,8 +38,8 @@ boundaryField atmosphere { type inletOutlet; - inletValue uniform 0; - value uniform 0; + inletValue $internalField; + value $internalField; } defaultFaces @@ -47,4 +48,5 @@ boundaryField } } + // ************************************************************************* // diff --git a/tutorials/compressibleVoF/damBreak/0/epsilon b/tutorials/compressibleVoF/damBreak/0/epsilon index d2274c799f..e40d6cb3be 100644 --- a/tutorials/compressibleVoF/damBreak/0/epsilon +++ b/tutorials/compressibleVoF/damBreak/0/epsilon @@ -23,26 +23,26 @@ boundaryField leftWall { type epsilonWallFunction; - value uniform 0.1; + value $internalField; } rightWall { type epsilonWallFunction; - value uniform 0.1; + value $internalField; } lowerWall { type epsilonWallFunction; - value uniform 0.1; + value $internalField; } atmosphere { type inletOutlet; - inletValue uniform 0.1; - value uniform 0.1; + inletValue $internalField; + value $internalField; } defaultFaces diff --git a/tutorials/compressibleVoF/damBreak/0/k b/tutorials/compressibleVoF/damBreak/0/k index 8f9fa10d44..8f99eaab4f 100644 --- a/tutorials/compressibleVoF/damBreak/0/k +++ b/tutorials/compressibleVoF/damBreak/0/k @@ -23,26 +23,26 @@ boundaryField leftWall { type kqRWallFunction; - value uniform 0.1; + value $internalField; } rightWall { type kqRWallFunction; - value uniform 0.1; + value $internalField; } lowerWall { type kqRWallFunction; - value uniform 0.1; + value $internalField; } atmosphere { type inletOutlet; - inletValue uniform 0.1; - value uniform 0.1; + inletValue $internalField; + value $internalField; } defaultFaces diff --git a/tutorials/compressibleVoF/damBreak/0/nuTilda b/tutorials/compressibleVoF/damBreak/0/nuTilda index 29affa4161..5f398147fa 100644 --- a/tutorials/compressibleVoF/damBreak/0/nuTilda +++ b/tutorials/compressibleVoF/damBreak/0/nuTilda @@ -9,6 +9,7 @@ FoamFile { format ascii; class volScalarField; + location "0"; object nuTilda; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -37,8 +38,8 @@ boundaryField atmosphere { type inletOutlet; - inletValue uniform 0; - value uniform 0; + inletValue $internalField; + value $internalField; } defaultFaces @@ -47,4 +48,5 @@ boundaryField } } + // ************************************************************************* // diff --git a/tutorials/compressibleVoF/damBreak/0/nut b/tutorials/compressibleVoF/damBreak/0/nut index 5d5442849f..be5b245ae8 100644 --- a/tutorials/compressibleVoF/damBreak/0/nut +++ b/tutorials/compressibleVoF/damBreak/0/nut @@ -23,25 +23,25 @@ boundaryField leftWall { type nutkWallFunction; - value uniform 0; + value $internalField; } rightWall { type nutkWallFunction; - value uniform 0; + value $internalField; } lowerWall { type nutkWallFunction; - value uniform 0; + value $internalField; } atmosphere { type calculated; - value uniform 0; + value $internalField; } defaultFaces diff --git a/tutorials/compressibleVoF/damBreak/0/omega b/tutorials/compressibleVoF/damBreak/0/omega index 3a148be4e5..08bef7f8be 100644 --- a/tutorials/compressibleVoF/damBreak/0/omega +++ b/tutorials/compressibleVoF/damBreak/0/omega @@ -16,33 +16,33 @@ FoamFile dimensions [0 0 -1 0 0 0 0]; -internalField uniform 0.1; +internalField uniform 11.1; boundaryField { leftWall { type omegaWallFunction; - value uniform 0.1; + value $internalField; } rightWall { type omegaWallFunction; - value uniform 0.1; + value $internalField; } lowerWall { type omegaWallFunction; - value uniform 0.1; + value $internalField; } atmosphere { type inletOutlet; - inletValue uniform 0.1; - value uniform 0.1; + inletValue $internalField; + value $internalField; } defaultFaces diff --git a/tutorials/compressibleVoF/damBreak/0/p b/tutorials/compressibleVoF/damBreak/0/p index be8509509a..c94ab4091e 100644 --- a/tutorials/compressibleVoF/damBreak/0/p +++ b/tutorials/compressibleVoF/damBreak/0/p @@ -9,6 +9,7 @@ FoamFile { format ascii; class volScalarField; + location "0"; object p_rgh; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -49,4 +50,5 @@ boundaryField } } + // ************************************************************************* // diff --git a/tutorials/compressibleVoF/damBreak/0/p_rgh b/tutorials/compressibleVoF/damBreak/0/p_rgh index 71a3671bff..87a30690bf 100644 --- a/tutorials/compressibleVoF/damBreak/0/p_rgh +++ b/tutorials/compressibleVoF/damBreak/0/p_rgh @@ -9,6 +9,7 @@ FoamFile { format ascii; class volScalarField; + location "0"; object p_rgh; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -49,4 +50,5 @@ boundaryField } } + // ************************************************************************* // diff --git a/tutorials/compressibleVoF/damBreak/system/fvSchemes b/tutorials/compressibleVoF/damBreak/system/fvSchemes index 3b8ab02076..3c14d0213b 100644 --- a/tutorials/compressibleVoF/damBreak/system/fvSchemes +++ b/tutorials/compressibleVoF/damBreak/system/fvSchemes @@ -28,7 +28,7 @@ divSchemes { div(phi,alpha) Gauss interfaceCompression vanLeer 1; - div(rhoPhi,U) Gauss linearUpwind grad(U);Gauss upwind; + div(rhoPhi,U) Gauss linearUpwind grad(U); div(alphaRhoPhi,e) Gauss upwind; div(alphaRhoPhi,T) Gauss upwind; @@ -38,7 +38,7 @@ divSchemes div(rhoPhi,k) Gauss upwind; div(rhoPhi,epsilon) Gauss upwind; - div(rhoPhi,omega) Gauss upwind; + div(rhoPhi,omega) Gauss upwind; div(((rho*nuEff)*dev2(T(grad(U))))) Gauss linear; } diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/U.orig b/tutorials/incompressibleVoF/damBreak/0/U similarity index 99% rename from tutorials/incompressibleVoF/damBreakPorousBaffle/0/U.orig rename to tutorials/incompressibleVoF/damBreak/0/U index 7f1d3f468f..adf3c5a7e5 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/U.orig +++ b/tutorials/incompressibleVoF/damBreak/0/U @@ -24,19 +24,23 @@ boundaryField { type noSlip; } + rightWall { type noSlip; } + lowerWall { type noSlip; } + atmosphere { type pressureInletOutletVelocity; value $internalField; } + defaultFaces { type empty; diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/alpha.water.orig b/tutorials/incompressibleVoF/damBreak/0/alpha.water.orig similarity index 99% rename from tutorials/incompressibleVoF/damBreakPorousBaffle/0/alpha.water.orig rename to tutorials/incompressibleVoF/damBreak/0/alpha.water.orig index d072df5d3c..93680700de 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/alpha.water.orig +++ b/tutorials/incompressibleVoF/damBreak/0/alpha.water.orig @@ -24,20 +24,24 @@ boundaryField { type zeroGradient; } + rightWall { type zeroGradient; } + lowerWall { type zeroGradient; } + atmosphere { type inletOutlet; inletValue $internalField; value $internalField; } + defaultFaces { type empty; diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/epsilon b/tutorials/incompressibleVoF/damBreak/0/epsilon similarity index 84% rename from tutorials/incompressibleVoF/damBreak/damBreak/0/epsilon rename to tutorials/incompressibleVoF/damBreak/0/epsilon index 21bfbbc012..e40d6cb3be 100644 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/epsilon +++ b/tutorials/incompressibleVoF/damBreak/0/epsilon @@ -23,24 +23,28 @@ boundaryField leftWall { type epsilonWallFunction; - value uniform 0.1; + value $internalField; } + rightWall { type epsilonWallFunction; - value uniform 0.1; + value $internalField; } + lowerWall { type epsilonWallFunction; - value uniform 0.1; + value $internalField; } + atmosphere { type inletOutlet; - inletValue uniform 0.1; - value uniform 0.1; + inletValue $internalField; + value $internalField; } + defaultFaces { type empty; diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/k.orig b/tutorials/incompressibleVoF/damBreak/0/k similarity index 99% rename from tutorials/incompressibleVoF/damBreakPorousBaffle/0/k.orig rename to tutorials/incompressibleVoF/damBreak/0/k index 2bc1a2b7d5..8f99eaab4f 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/k.orig +++ b/tutorials/incompressibleVoF/damBreak/0/k @@ -25,22 +25,26 @@ boundaryField type kqRWallFunction; value $internalField; } + rightWall { type kqRWallFunction; value $internalField; } + lowerWall { type kqRWallFunction; value $internalField; } + atmosphere { type inletOutlet; inletValue $internalField; value $internalField; } + defaultFaces { type empty; diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/nuTilda b/tutorials/incompressibleVoF/damBreak/0/nuTilda similarity index 91% rename from tutorials/incompressibleVoF/damBreak/damBreak/0/nuTilda rename to tutorials/incompressibleVoF/damBreak/0/nuTilda index 29affa4161..5f398147fa 100644 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/nuTilda +++ b/tutorials/incompressibleVoF/damBreak/0/nuTilda @@ -9,6 +9,7 @@ FoamFile { format ascii; class volScalarField; + location "0"; object nuTilda; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -37,8 +38,8 @@ boundaryField atmosphere { type inletOutlet; - inletValue uniform 0; - value uniform 0; + inletValue $internalField; + value $internalField; } defaultFaces @@ -47,4 +48,5 @@ boundaryField } } + // ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/nut.orig b/tutorials/incompressibleVoF/damBreak/0/nut similarity index 99% rename from tutorials/incompressibleVoF/damBreakPorousBaffle/0/nut.orig rename to tutorials/incompressibleVoF/damBreak/0/nut index decf4d526b..be5b245ae8 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/nut.orig +++ b/tutorials/incompressibleVoF/damBreak/0/nut @@ -25,21 +25,25 @@ boundaryField type nutkWallFunction; value $internalField; } + rightWall { type nutkWallFunction; value $internalField; } + lowerWall { type nutkWallFunction; value $internalField; } + atmosphere { type calculated; value $internalField; } + defaultFaces { type empty; diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/omega b/tutorials/incompressibleVoF/damBreak/0/omega similarity index 84% rename from tutorials/incompressibleVoF/damBreak/damBreak/0/omega rename to tutorials/incompressibleVoF/damBreak/0/omega index 2ad26cfa0a..08bef7f8be 100644 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/omega +++ b/tutorials/incompressibleVoF/damBreak/0/omega @@ -23,24 +23,28 @@ boundaryField leftWall { type omegaWallFunction; - value uniform 11.1; + value $internalField; } + rightWall { type omegaWallFunction; - value uniform 11.1; + value $internalField; } + lowerWall { type omegaWallFunction; - value uniform 11.1; + value $internalField; } + atmosphere { type inletOutlet; - inletValue uniform 11.1; - value uniform 11.1; + inletValue $internalField; + value $internalField; } + defaultFaces { type empty; diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/p_rgh.orig b/tutorials/incompressibleVoF/damBreak/0/p_rgh similarity index 96% rename from tutorials/incompressibleVoF/damBreakPorousBaffle/0/p_rgh.orig rename to tutorials/incompressibleVoF/damBreak/0/p_rgh index 36e2e03849..e19f2d98f9 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/p_rgh.orig +++ b/tutorials/incompressibleVoF/damBreak/0/p_rgh @@ -25,22 +25,25 @@ boundaryField type fixedFluxPressure; value $internalField; } + rightWall { type fixedFluxPressure; value $internalField; } + lowerWall { type fixedFluxPressure; value $internalField; } + atmosphere { type prghTotalPressure; p0 $internalField; - value $internalField; } + defaultFaces { type empty; diff --git a/tutorials/incompressibleVoF/damBreak/Allclean b/tutorials/incompressibleVoF/damBreak/Allclean index efbd66e1c2..170a3cfe1e 100755 --- a/tutorials/incompressibleVoF/damBreak/Allclean +++ b/tutorials/incompressibleVoF/damBreak/Allclean @@ -4,17 +4,6 @@ cd ${0%/*} || exit 1 # Run from this directory # Source tutorial clean functions . $WM_PROJECT_DIR/bin/tools/CleanFunctions -keepCases="damBreak" -loseCases="damBreakFine" - -for case in $keepCases -do - (cd $case && foamCleanTutorials) -done - -for case in $loseCases -do - removeCase $case -done +cleanVoFCase #------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreak/Allrun b/tutorials/incompressibleVoF/damBreak/Allrun index ede8f8d8c1..ed61ac5435 100755 --- a/tutorials/incompressibleVoF/damBreak/Allrun +++ b/tutorials/incompressibleVoF/damBreak/Allrun @@ -4,43 +4,8 @@ cd ${0%/*} || exit 1 # Run from this directory # Source tutorial run functions . $WM_PROJECT_DIR/bin/tools/RunFunctions -setDamBreakFine () -{ - blockMeshDict="system/blockMeshDict" - controlDict="system/controlDict" - sed \ - -e s/"23 8"/"46 10"/g \ - -e s/"19 8"/"40 10"/g \ - -e s/"23 42\(.*\) 1 1)"/"46 76\1 2 1)"/g \ - -e s/"4 42\(.*\) 1 1)"/"4 76\1 2 1)"/g \ - -e s/"19 42\(.*\) 1 1)"/"40 76\1 2 1)"/g \ - $blockMeshDict > temp.$$ - mv temp.$$ $blockMeshDict - sed \ - -e s/"\(deltaT[ \t]*\) 0.001;"/"\1 5e-04;"/g \ - -e s/"\(endTime[ \t]*\) 1;"/"\1 0.4;"/g \ - $controlDict > temp.$$ - mv temp.$$ $controlDict -} - -# Do damBreak -(cd damBreak && foamRunTutorials) - -# Clone case -cloneCase damBreak damBreakFine - -( - cd damBreakFine || exit - - # Modify case - setDamBreakFine - cp ../damBreak/0/alpha.water.orig 0/alpha.water - # And execute - runApplication blockMesh - runApplication setFields - runApplication decomposePar - runParallel $(getApplication) - runApplication reconstructPar -) +runApplication blockMesh +runApplication setFields +runApplication $(getApplication) #------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/constant/fvModels b/tutorials/incompressibleVoF/damBreak/constant/fvModels similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/constant/fvModels rename to tutorials/incompressibleVoF/damBreak/constant/fvModels diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/constant/g b/tutorials/incompressibleVoF/damBreak/constant/g similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/constant/g rename to tutorials/incompressibleVoF/damBreak/constant/g diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/constant/momentumTransport b/tutorials/incompressibleVoF/damBreak/constant/momentumTransport similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/constant/momentumTransport rename to tutorials/incompressibleVoF/damBreak/constant/momentumTransport diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/constant/phaseProperties b/tutorials/incompressibleVoF/damBreak/constant/phaseProperties similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/constant/phaseProperties rename to tutorials/incompressibleVoF/damBreak/constant/phaseProperties diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/constant/physicalProperties.air b/tutorials/incompressibleVoF/damBreak/constant/physicalProperties.air similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/constant/physicalProperties.air rename to tutorials/incompressibleVoF/damBreak/constant/physicalProperties.air diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/constant/physicalProperties.water b/tutorials/incompressibleVoF/damBreak/constant/physicalProperties.water similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/constant/physicalProperties.water rename to tutorials/incompressibleVoF/damBreak/constant/physicalProperties.water diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/U b/tutorials/incompressibleVoF/damBreak/damBreak/0/U deleted file mode 100644 index 478d50ee79..0000000000 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/U +++ /dev/null @@ -1,47 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volVectorField; - location "0"; - object U; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 1 -1 0 0 0 0]; - -internalField uniform (0 0 0); - -boundaryField -{ - leftWall - { - type noSlip; - } - rightWall - { - type noSlip; - } - lowerWall - { - type noSlip; - } - atmosphere - { - type pressureInletOutletVelocity; - value uniform (0 0 0); - } - defaultFaces - { - type empty; - } -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/alpha.water.orig b/tutorials/incompressibleVoF/damBreak/damBreak/0/alpha.water.orig deleted file mode 100644 index 3c85d4cf85..0000000000 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/alpha.water.orig +++ /dev/null @@ -1,50 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - object alpha.water; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions []; - -internalField uniform 0; - -boundaryField -{ - leftWall - { - type zeroGradient; - } - - rightWall - { - type zeroGradient; - } - - lowerWall - { - type zeroGradient; - } - - atmosphere - { - type inletOutlet; - inletValue uniform 0; - value uniform 0; - } - - defaultFaces - { - type empty; - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/k b/tutorials/incompressibleVoF/damBreak/damBreak/0/k deleted file mode 100644 index 55b6da3f6a..0000000000 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/k +++ /dev/null @@ -1,51 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - location "0"; - object k; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 2 -2 0 0 0 0]; - -internalField uniform 0.1; - -boundaryField -{ - leftWall - { - type kqRWallFunction; - value uniform 0.1; - } - rightWall - { - type kqRWallFunction; - value uniform 0.1; - } - lowerWall - { - type kqRWallFunction; - value uniform 0.1; - } - atmosphere - { - type inletOutlet; - inletValue uniform 0.1; - value uniform 0.1; - } - defaultFaces - { - type empty; - } -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/nut b/tutorials/incompressibleVoF/damBreak/damBreak/0/nut deleted file mode 100644 index 0b69ea2866..0000000000 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/nut +++ /dev/null @@ -1,50 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - location "0"; - object nut; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 2 -1 0 0 0 0]; - -internalField uniform 0; - -boundaryField -{ - leftWall - { - type nutkWallFunction; - value uniform 0; - } - rightWall - { - type nutkWallFunction; - value uniform 0; - } - lowerWall - { - type nutkWallFunction; - value uniform 0; - } - atmosphere - { - type calculated; - value uniform 0; - } - defaultFaces - { - type empty; - } -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/0/p_rgh b/tutorials/incompressibleVoF/damBreak/damBreak/0/p_rgh deleted file mode 100644 index 6e232cb9eb..0000000000 --- a/tutorials/incompressibleVoF/damBreak/damBreak/0/p_rgh +++ /dev/null @@ -1,52 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - object p_rgh; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [1 -1 -2 0 0 0 0]; - -internalField uniform 0; - -boundaryField -{ - leftWall - { - type fixedFluxPressure; - value uniform 0; - } - - rightWall - { - type fixedFluxPressure; - value uniform 0; - } - - lowerWall - { - type fixedFluxPressure; - value uniform 0; - } - - atmosphere - { - type prghTotalPressure; - p0 uniform 0; - } - - defaultFaces - { - type empty; - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/Allrun b/tutorials/incompressibleVoF/damBreak/damBreak/Allrun deleted file mode 100755 index b18d70e448..0000000000 --- a/tutorials/incompressibleVoF/damBreak/damBreak/Allrun +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -cd ${0%/*} || exit 1 # Run from this directory - -# Source tutorial run functions -. $WM_PROJECT_DIR/bin/tools/RunFunctions - -# Get application name -application=$(getApplication) - -runApplication blockMesh -runApplication setFields -runApplication $application - -#------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/system/decomposeParDict b/tutorials/incompressibleVoF/damBreak/damBreak/system/decomposeParDict deleted file mode 100644 index 3729549d21..0000000000 --- a/tutorials/incompressibleVoF/damBreak/damBreak/system/decomposeParDict +++ /dev/null @@ -1,42 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object decomposeParDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 4; - -method simple; - -simpleCoeffs -{ - n (2 2 1); -} - -hierarchicalCoeffs -{ - n (1 1 1); - order xyz; -} - -manualCoeffs -{ - dataFile ""; -} - -distributed no; - -roots ( ); - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/system/blockMeshDict b/tutorials/incompressibleVoF/damBreak/system/blockMeshDict similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/system/blockMeshDict rename to tutorials/incompressibleVoF/damBreak/system/blockMeshDict diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/system/controlDict b/tutorials/incompressibleVoF/damBreak/system/controlDict similarity index 98% rename from tutorials/incompressibleVoF/damBreak/damBreak/system/controlDict rename to tutorials/incompressibleVoF/damBreak/system/controlDict index ea65bc5517..7931e5fbec 100644 --- a/tutorials/incompressibleVoF/damBreak/damBreak/system/controlDict +++ b/tutorials/incompressibleVoF/damBreak/system/controlDict @@ -46,7 +46,7 @@ timePrecision 6; runTimeModifiable yes; -adjustTimeStep on; +adjustTimeStep yes; maxCo 1; maxAlphaCo 1; diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/system/fvSchemes b/tutorials/incompressibleVoF/damBreak/system/fvSchemes similarity index 93% rename from tutorials/incompressibleVoF/damBreak/damBreak/system/fvSchemes rename to tutorials/incompressibleVoF/damBreak/system/fvSchemes index 8d24d042e7..aed37eacbe 100644 --- a/tutorials/incompressibleVoF/damBreak/damBreak/system/fvSchemes +++ b/tutorials/incompressibleVoF/damBreak/system/fvSchemes @@ -26,17 +26,20 @@ gradSchemes divSchemes { - div(rhoPhi,U) Gauss linearUpwind grad(U); div(phi,alpha) Gauss interfaceCompression vanLeer 1; + + div(rhoPhi,U) Gauss linearUpwind grad(U); + div(phi,k) Gauss upwind; div(phi,epsilon) Gauss upwind; div(phi,omega) Gauss upwind; + div(((rho*nuEff)*dev2(T(grad(U))))) Gauss linear; } laplacianSchemes { - default Gauss linear corrected; + default Gauss linear uncorrected; } interpolationSchemes @@ -46,7 +49,7 @@ interpolationSchemes snGradSchemes { - default corrected; + default uncorrected; } diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/system/fvSolution b/tutorials/incompressibleVoF/damBreak/system/fvSolution similarity index 99% rename from tutorials/incompressibleVoF/damBreak/damBreak/system/fvSolution rename to tutorials/incompressibleVoF/damBreak/system/fvSolution index cdefa8cd11..2e4f5ee747 100644 --- a/tutorials/incompressibleVoF/damBreak/damBreak/system/fvSolution +++ b/tutorials/incompressibleVoF/damBreak/system/fvSolution @@ -78,4 +78,5 @@ relaxationFactors } } + // ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/system/setFieldsDict b/tutorials/incompressibleVoF/damBreak/system/setFieldsDict similarity index 100% rename from tutorials/incompressibleVoF/damBreak/damBreak/system/setFieldsDict rename to tutorials/incompressibleVoF/damBreak/system/setFieldsDict diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/0/U.orig b/tutorials/incompressibleVoF/damBreak3D/0/U similarity index 89% rename from tutorials/incompressibleVoF/damBreakWithObstacle/0/U.orig rename to tutorials/incompressibleVoF/damBreak3D/0/U index bad7461462..360a8d00e9 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/0/U.orig +++ b/tutorials/incompressibleVoF/damBreak3D/0/U @@ -10,7 +10,7 @@ FoamFile format ascii; class volVectorField; location "0"; - object U.orig; + object U; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // @@ -23,13 +23,12 @@ boundaryField atmosphere { type pressureInletOutletVelocity; - value uniform (0 0 0); + value $internalField; } walls { type uniformFixedValue; uniformValue constant (0 0 0); - value uniform (0 0 0); } } diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/0/alpha.water.orig b/tutorials/incompressibleVoF/damBreak3D/0/alpha.water.orig similarity index 91% rename from tutorials/incompressibleVoF/damBreakWithObstacle/0/alpha.water.orig rename to tutorials/incompressibleVoF/damBreak3D/0/alpha.water.orig index e1a0fd9799..15860087c7 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/0/alpha.water.orig +++ b/tutorials/incompressibleVoF/damBreak3D/0/alpha.water.orig @@ -23,8 +23,8 @@ boundaryField atmosphere { type inletOutlet; - inletValue uniform 0; - value uniform 0; + inletValue $internalField; + value $internalField; } walls { diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/0/k b/tutorials/incompressibleVoF/damBreak3D/0/k similarity index 87% rename from tutorials/incompressibleVoF/damBreakWithObstacle/0/k rename to tutorials/incompressibleVoF/damBreak3D/0/k index 9162c916b2..dbd530e170 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/0/k +++ b/tutorials/incompressibleVoF/damBreak3D/0/k @@ -23,13 +23,13 @@ boundaryField atmosphere { type inletOutlet; - inletValue uniform 0.00015; - value uniform 0.00015; + inletValue $internalField; + value $internalField; } walls { type kqRWallFunction; - value uniform 0.00015; + value $internalField; } } diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/0/nut b/tutorials/incompressibleVoF/damBreak3D/0/nut similarity index 96% rename from tutorials/incompressibleVoF/damBreakWithObstacle/0/nut rename to tutorials/incompressibleVoF/damBreak3D/0/nut index 5fd898d563..79d889fbb9 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/0/nut +++ b/tutorials/incompressibleVoF/damBreak3D/0/nut @@ -29,7 +29,7 @@ boundaryField type nutkRoughWallFunction; Ks uniform 0.0001; Cs uniform 0.5; - value uniform 5e-07; + value $internalField; } } diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/0/omega b/tutorials/incompressibleVoF/damBreak3D/0/omega similarity index 87% rename from tutorials/incompressibleVoF/damBreakWithObstacle/0/omega rename to tutorials/incompressibleVoF/damBreak3D/0/omega index 4b731c1f62..36ca295604 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/0/omega +++ b/tutorials/incompressibleVoF/damBreak3D/0/omega @@ -23,13 +23,13 @@ boundaryField atmosphere { type inletOutlet; - inletValue uniform 2; - value uniform 2; + inletValue $internalField; + value $internalField; } walls { type omegaWallFunction; - value uniform 2; + value $internalField; } } diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/0/p_rgh b/tutorials/incompressibleVoF/damBreak3D/0/p_rgh similarity index 85% rename from tutorials/incompressibleVoF/damBreakWithObstacle/0/p_rgh rename to tutorials/incompressibleVoF/damBreak3D/0/p_rgh index 25d378edfe..32b00de7a0 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/0/p_rgh +++ b/tutorials/incompressibleVoF/damBreak3D/0/p_rgh @@ -25,14 +25,14 @@ boundaryField type prghTotalPressure; psi none; gamma 1; - p0 uniform 0; - value uniform 0; + p0 $internalField; + value $internalField; } walls { type fixedFluxPressure; - gradient uniform 0; - value uniform 0; + gradient $internalField; + value $internalField; } } diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/Allclean b/tutorials/incompressibleVoF/damBreak3D/Allclean similarity index 100% rename from tutorials/incompressibleVoF/damBreakWithObstacle/Allclean rename to tutorials/incompressibleVoF/damBreak3D/Allclean diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/Allrun b/tutorials/incompressibleVoF/damBreak3D/Allrun similarity index 100% rename from tutorials/incompressibleVoF/damBreakWithObstacle/Allrun rename to tutorials/incompressibleVoF/damBreak3D/Allrun diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/dynamicMeshDict b/tutorials/incompressibleVoF/damBreak3D/constant/dynamicMeshDict similarity index 100% rename from tutorials/incompressibleVoF/damBreakWithObstacle/constant/dynamicMeshDict rename to tutorials/incompressibleVoF/damBreak3D/constant/dynamicMeshDict diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/g b/tutorials/incompressibleVoF/damBreak3D/constant/g similarity index 100% rename from tutorials/incompressibleVoF/damBreakWithObstacle/constant/g rename to tutorials/incompressibleVoF/damBreak3D/constant/g diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/momentumTransport b/tutorials/incompressibleVoF/damBreak3D/constant/momentumTransport similarity index 100% rename from tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/momentumTransport rename to tutorials/incompressibleVoF/damBreak3D/constant/momentumTransport diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/phaseProperties b/tutorials/incompressibleVoF/damBreak3D/constant/phaseProperties similarity index 100% rename from tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/phaseProperties rename to tutorials/incompressibleVoF/damBreak3D/constant/phaseProperties diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/physicalProperties.air b/tutorials/incompressibleVoF/damBreak3D/constant/physicalProperties.air similarity index 100% rename from tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/physicalProperties.air rename to tutorials/incompressibleVoF/damBreak3D/constant/physicalProperties.air diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/physicalProperties.water b/tutorials/incompressibleVoF/damBreak3D/constant/physicalProperties.water similarity index 100% rename from tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/physicalProperties.water rename to tutorials/incompressibleVoF/damBreak3D/constant/physicalProperties.water diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/system/blockMeshDict b/tutorials/incompressibleVoF/damBreak3D/system/blockMeshDict similarity index 97% rename from tutorials/incompressibleVoF/damBreakWithObstacle/system/blockMeshDict rename to tutorials/incompressibleVoF/damBreak3D/system/blockMeshDict index 9b4c294abb..6758df2a9c 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/system/blockMeshDict +++ b/tutorials/incompressibleVoF/damBreak3D/system/blockMeshDict @@ -9,6 +9,7 @@ FoamFile { format ascii; class dictionary; + location "system"; object blockMeshDict; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/system/controlDict b/tutorials/incompressibleVoF/damBreak3D/system/controlDict similarity index 100% rename from tutorials/incompressibleVoF/damBreakWithObstacle/system/controlDict rename to tutorials/incompressibleVoF/damBreak3D/system/controlDict diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/phaseProperties b/tutorials/incompressibleVoF/damBreak3D/system/decomposeParDict similarity index 84% rename from tutorials/incompressibleVoF/damBreakWithObstacle/constant/phaseProperties rename to tutorials/incompressibleVoF/damBreak3D/system/decomposeParDict index 234504e0d1..b3f653cbde 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/phaseProperties +++ b/tutorials/incompressibleVoF/damBreak3D/system/decomposeParDict @@ -9,14 +9,14 @@ FoamFile { format ascii; class dictionary; - location "constant"; - object phaseProperties; + location "system"; + object decomposeParDict; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -phases (water air); +numberOfSubdomains 6; -sigma 0.07; +method scotch; // ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/system/fvSchemes b/tutorials/incompressibleVoF/damBreak3D/system/fvSchemes similarity index 100% rename from tutorials/incompressibleVoF/damBreakWithObstacle/system/fvSchemes rename to tutorials/incompressibleVoF/damBreak3D/system/fvSchemes diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/system/fvSolution b/tutorials/incompressibleVoF/damBreak3D/system/fvSolution similarity index 95% rename from tutorials/incompressibleVoF/damBreakWithObstacle/system/fvSolution rename to tutorials/incompressibleVoF/damBreak3D/system/fvSolution index c4fde5c4dc..560a94b18c 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/system/fvSolution +++ b/tutorials/incompressibleVoF/damBreak3D/system/fvSolution @@ -67,16 +67,13 @@ PIMPLE momentumPredictor no; nCorrectors 3; nNonOrthogonalCorrectors 0; - - pRefPoint (0.51 0.51 0.51); - pRefValue 0; } relaxationFactors { equations { - ".*" 1; + ".*" 1; } } diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/system/setFieldsDict b/tutorials/incompressibleVoF/damBreak3D/system/setFieldsDict similarity index 96% rename from tutorials/incompressibleVoF/damBreakWithObstacle/system/setFieldsDict rename to tutorials/incompressibleVoF/damBreak3D/system/setFieldsDict index a675f2b784..1f80846914 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/system/setFieldsDict +++ b/tutorials/incompressibleVoF/damBreak3D/system/setFieldsDict @@ -17,7 +17,6 @@ FoamFile defaultFieldValues ( volScalarFieldValue alpha.water 0 - volVectorFieldValue U (0 0 0) ); regions diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/system/topoSetDict b/tutorials/incompressibleVoF/damBreak3D/system/topoSetDict similarity index 100% rename from tutorials/incompressibleVoF/damBreakWithObstacle/system/topoSetDict rename to tutorials/incompressibleVoF/damBreak3D/system/topoSetDict diff --git a/tutorials/incompressibleVoF/damBreakFine/Allclean b/tutorials/incompressibleVoF/damBreakFine/Allclean new file mode 100755 index 0000000000..3d819c9a8c --- /dev/null +++ b/tutorials/incompressibleVoF/damBreakFine/Allclean @@ -0,0 +1,15 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # Run from this directory + +# Source tutorial clean functions +. $WM_PROJECT_DIR/bin/tools/CleanFunctions + +cleanVoFCase + +rm -rf 0 constant + +find system -type f -not \( \ + -name blockMeshDict.fine -or -name decomposeParDict \ + \) -delete + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakFine/Allrun b/tutorials/incompressibleVoF/damBreakFine/Allrun new file mode 100755 index 0000000000..f43fe4b9d0 --- /dev/null +++ b/tutorials/incompressibleVoF/damBreakFine/Allrun @@ -0,0 +1,23 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # Run from this directory + +# Source tutorial run functions +. $WM_PROJECT_DIR/bin/tools/RunFunctions + +# Copy the case +isTest "$@" && path=.. || path=$FOAM_TUTORIALS/incompressibleVoF +cp -rn $path/damBreak/0 $path/damBreak/constant $path/damBreak/system . +rm -f 0/alpha.water + +# Set a new time-step +runApplication foamDictionary system/controlDict \ + -entry deltaT -set 5e-4 + +# Run +runApplication blockMesh -dict system/blockMeshDict.fine +runApplication setFields +runApplication decomposePar +runParallel $(getApplication) +runApplication reconstructPar + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/setFieldsDict b/tutorials/incompressibleVoF/damBreakFine/system/blockMeshDict.fine similarity index 62% rename from tutorials/incompressibleVoF/damBreakPorousBaffle/system/setFieldsDict rename to tutorials/incompressibleVoF/damBreakFine/system/blockMeshDict.fine index 8b7f4c8cd5..d896dbfa49 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/setFieldsDict +++ b/tutorials/incompressibleVoF/damBreakFine/system/blockMeshDict.fine @@ -9,26 +9,19 @@ FoamFile { format ascii; class dictionary; - location "system"; - object setFieldsDict; + object blockMeshDict; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -defaultFieldValues -( - volScalarFieldValue alpha.water 0 -); +#include "blockMeshDict" -regions +blocks ( - boxToCell - { - box (0 0 -1) (0.1461 0.292 1); - fieldValues - ( - volScalarFieldValue alpha.water 1 - ); - } + hex (0 1 5 4 12 13 17 16) (46 10 1) simpleGrading (1 1 1) + hex (2 3 7 6 14 15 19 18) (40 10 1) simpleGrading (1 1 1) + hex (4 5 9 8 16 17 21 20) (46 76 1) simpleGrading (1 2 1) + hex (5 6 10 9 17 18 22 21) (4 76 1) simpleGrading (1 2 1) + hex (6 7 11 10 18 19 23 22) (40 76 1) simpleGrading (1 2 1) ); diff --git a/tutorials/compressibleVoF/damBreak/system/decomposeParDict b/tutorials/incompressibleVoF/damBreakFine/system/decomposeParDict similarity index 82% rename from tutorials/compressibleVoF/damBreak/system/decomposeParDict rename to tutorials/incompressibleVoF/damBreakFine/system/decomposeParDict index 3729549d21..2445e2736e 100644 --- a/tutorials/compressibleVoF/damBreak/system/decomposeParDict +++ b/tutorials/incompressibleVoF/damBreakFine/system/decomposeParDict @@ -23,20 +23,5 @@ simpleCoeffs n (2 2 1); } -hierarchicalCoeffs -{ - n (1 1 1); - order xyz; -} - -manualCoeffs -{ - dataFile ""; -} - -distributed no; - -roots ( ); - // ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/Allclean b/tutorials/incompressibleVoF/damBreakLaminar/Allclean index efbd66e1c2..7b06dc70e3 100755 --- a/tutorials/incompressibleVoF/damBreakLaminar/Allclean +++ b/tutorials/incompressibleVoF/damBreakLaminar/Allclean @@ -4,17 +4,12 @@ cd ${0%/*} || exit 1 # Run from this directory # Source tutorial clean functions . $WM_PROJECT_DIR/bin/tools/CleanFunctions -keepCases="damBreak" -loseCases="damBreakFine" +cleanVoFCase -for case in $keepCases -do - (cd $case && foamCleanTutorials) -done +rm -rf 0 system -for case in $loseCases -do - removeCase $case -done +find constant -type f -not \( \ + -name fvModels -or -name momentumTransport \ + \) -delete #------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakLaminar/Allrun b/tutorials/incompressibleVoF/damBreakLaminar/Allrun index ede8f8d8c1..6bb259ecec 100755 --- a/tutorials/incompressibleVoF/damBreakLaminar/Allrun +++ b/tutorials/incompressibleVoF/damBreakLaminar/Allrun @@ -4,43 +4,18 @@ cd ${0%/*} || exit 1 # Run from this directory # Source tutorial run functions . $WM_PROJECT_DIR/bin/tools/RunFunctions -setDamBreakFine () -{ - blockMeshDict="system/blockMeshDict" - controlDict="system/controlDict" - sed \ - -e s/"23 8"/"46 10"/g \ - -e s/"19 8"/"40 10"/g \ - -e s/"23 42\(.*\) 1 1)"/"46 76\1 2 1)"/g \ - -e s/"4 42\(.*\) 1 1)"/"4 76\1 2 1)"/g \ - -e s/"19 42\(.*\) 1 1)"/"40 76\1 2 1)"/g \ - $blockMeshDict > temp.$$ - mv temp.$$ $blockMeshDict - sed \ - -e s/"\(deltaT[ \t]*\) 0.001;"/"\1 5e-04;"/g \ - -e s/"\(endTime[ \t]*\) 1;"/"\1 0.4;"/g \ - $controlDict > temp.$$ - mv temp.$$ $controlDict -} +# Copy the case +isTest "$@" && path=.. || path=$FOAM_TUTORIALS/incompressibleVoF +cp -rn $path/damBreak/0 $path/damBreak/constant $path/damBreak/system . +rm -f 0/alpha.water -# Do damBreak -(cd damBreak && foamRunTutorials) +# Increase the number of limiter iterations +runApplication foamDictionary system/fvSolution \ + -entry solvers/"alpha.water.*"/nLimiterIter -set 5 -# Clone case -cloneCase damBreak damBreakFine - -( - cd damBreakFine || exit - - # Modify case - setDamBreakFine - cp ../damBreak/0/alpha.water.orig 0/alpha.water - # And execute - runApplication blockMesh - runApplication setFields - runApplication decomposePar - runParallel $(getApplication) - runApplication reconstructPar -) +# Run +runApplication blockMesh +runApplication setFields +runApplication $(getApplication) #------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/momentumTransport b/tutorials/incompressibleVoF/damBreakLaminar/constant/fvModels similarity index 80% rename from tutorials/incompressibleVoF/damBreakWithObstacle/constant/momentumTransport rename to tutorials/incompressibleVoF/damBreakLaminar/constant/fvModels index 8278c989ec..c5416f6b46 100644 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/momentumTransport +++ b/tutorials/incompressibleVoF/damBreakLaminar/constant/fvModels @@ -7,14 +7,13 @@ \*---------------------------------------------------------------------------*/ FoamFile { - format ascii; - class dictionary; - location "constant"; - object momentumTransport; + format ascii; + class dictionary; + location "constant"; + object fvModels; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -simulationType laminar; // ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/momentumTransport b/tutorials/incompressibleVoF/damBreakLaminar/constant/momentumTransport similarity index 80% rename from tutorials/incompressibleVoF/damBreakPorousBaffle/constant/momentumTransport rename to tutorials/incompressibleVoF/damBreakLaminar/constant/momentumTransport index 4c5d358a4a..c7745a3880 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/momentumTransport +++ b/tutorials/incompressibleVoF/damBreakLaminar/constant/momentumTransport @@ -7,21 +7,19 @@ \*---------------------------------------------------------------------------*/ FoamFile { - format ascii; - class dictionary; - location "constant"; - object momentumTransport; + format ascii; + class dictionary; + location "constant"; + object momentumTransport; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -simulationType RAS; +simulationType laminar; RAS { model kEpsilon; - turbulence on; - printCoeffs on; } diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/U b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/U deleted file mode 100644 index 478d50ee79..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/U +++ /dev/null @@ -1,47 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volVectorField; - location "0"; - object U; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 1 -1 0 0 0 0]; - -internalField uniform (0 0 0); - -boundaryField -{ - leftWall - { - type noSlip; - } - rightWall - { - type noSlip; - } - lowerWall - { - type noSlip; - } - atmosphere - { - type pressureInletOutletVelocity; - value uniform (0 0 0); - } - defaultFaces - { - type empty; - } -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/alpha.water.orig b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/alpha.water.orig deleted file mode 100644 index 3c85d4cf85..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/alpha.water.orig +++ /dev/null @@ -1,50 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - object alpha.water; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions []; - -internalField uniform 0; - -boundaryField -{ - leftWall - { - type zeroGradient; - } - - rightWall - { - type zeroGradient; - } - - lowerWall - { - type zeroGradient; - } - - atmosphere - { - type inletOutlet; - inletValue uniform 0; - value uniform 0; - } - - defaultFaces - { - type empty; - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/p_rgh b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/p_rgh deleted file mode 100644 index 6e232cb9eb..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/0/p_rgh +++ /dev/null @@ -1,52 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - object p_rgh; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [1 -1 -2 0 0 0 0]; - -internalField uniform 0; - -boundaryField -{ - leftWall - { - type fixedFluxPressure; - value uniform 0; - } - - rightWall - { - type fixedFluxPressure; - value uniform 0; - } - - lowerWall - { - type fixedFluxPressure; - value uniform 0; - } - - atmosphere - { - type prghTotalPressure; - p0 uniform 0; - } - - defaultFaces - { - type empty; - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/Allrun b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/Allrun deleted file mode 100755 index b18d70e448..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/Allrun +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -cd ${0%/*} || exit 1 # Run from this directory - -# Source tutorial run functions -. $WM_PROJECT_DIR/bin/tools/RunFunctions - -# Get application name -application=$(getApplication) - -runApplication blockMesh -runApplication setFields -runApplication $application - -#------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/g b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/g deleted file mode 100644 index 770a56192e..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/constant/g +++ /dev/null @@ -1,21 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class uniformDimensionedVectorField; - location "constant"; - object g; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 1 -2 0 0 0 0]; -value (0 -9.81 0); - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/blockMeshDict b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/blockMeshDict deleted file mode 100644 index 6f27d83a17..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/blockMeshDict +++ /dev/null @@ -1,105 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - object blockMeshDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -convertToMeters 0.146; - -vertices -( - (0 0 0) - (2 0 0) - (2.16438 0 0) - (4 0 0) - (0 0.32876 0) - (2 0.32876 0) - (2.16438 0.32876 0) - (4 0.32876 0) - (0 4 0) - (2 4 0) - (2.16438 4 0) - (4 4 0) - (0 0 0.1) - (2 0 0.1) - (2.16438 0 0.1) - (4 0 0.1) - (0 0.32876 0.1) - (2 0.32876 0.1) - (2.16438 0.32876 0.1) - (4 0.32876 0.1) - (0 4 0.1) - (2 4 0.1) - (2.16438 4 0.1) - (4 4 0.1) -); - -blocks -( - hex (0 1 5 4 12 13 17 16) (23 8 1) simpleGrading (1 1 1) - hex (2 3 7 6 14 15 19 18) (19 8 1) simpleGrading (1 1 1) - hex (4 5 9 8 16 17 21 20) (23 42 1) simpleGrading (1 1 1) - hex (5 6 10 9 17 18 22 21) (4 42 1) simpleGrading (1 1 1) - hex (6 7 11 10 18 19 23 22) (19 42 1) simpleGrading (1 1 1) -); - -defaultPatch -{ - type empty; -} - -boundary -( - leftWall - { - type wall; - faces - ( - (0 12 16 4) - (4 16 20 8) - ); - } - rightWall - { - type wall; - faces - ( - (7 19 15 3) - (11 23 19 7) - ); - } - lowerWall - { - type wall; - faces - ( - (0 1 13 12) - (1 5 17 13) - (5 6 18 17) - (2 14 18 6) - (2 3 15 14) - ); - } - atmosphere - { - type patch; - faces - ( - (8 20 21 9) - (9 21 22 10) - (10 22 23 11) - ); - } -); - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/controlDict b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/controlDict deleted file mode 100644 index 10d9160632..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/controlDict +++ /dev/null @@ -1,57 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object controlDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -application foamRun; - -solver incompressibleVoF; - -startFrom startTime; - -startTime 0; - -stopAt endTime; - -endTime 1; - -deltaT 0.001; - -writeControl adjustableRunTime; - -writeInterval 0.05; - -purgeWrite 0; - -writeFormat binary; - -writePrecision 6; - -writeCompression off; - -timeFormat general; - -timePrecision 6; - -runTimeModifiable yes; - -adjustTimeStep yes; - -maxCo 1; -maxAlphaCo 1; - -maxDeltaT 1; - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/decomposeParDict b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/decomposeParDict deleted file mode 100644 index 3729549d21..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/decomposeParDict +++ /dev/null @@ -1,42 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object decomposeParDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 4; - -method simple; - -simpleCoeffs -{ - n (2 2 1); -} - -hierarchicalCoeffs -{ - n (1 1 1); - order xyz; -} - -manualCoeffs -{ - dataFile ""; -} - -distributed no; - -roots ( ); - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/fvSchemes b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/fvSchemes deleted file mode 100644 index dce765815f..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/fvSchemes +++ /dev/null @@ -1,50 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object fvSchemes; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -ddtSchemes -{ - default Euler; -} - -gradSchemes -{ - default Gauss linear; -} - -divSchemes -{ - div(rhoPhi,U) Gauss linearUpwind grad(U); - div(phi,alpha) Gauss interfaceCompression vanLeer 1; - div(((rho*nuEff)*dev2(T(grad(U))))) Gauss linear; -} - -laplacianSchemes -{ - default Gauss linear corrected; -} - -interpolationSchemes -{ - default linear; -} - -snGradSchemes -{ - default corrected; -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/fvSolution b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/fvSolution deleted file mode 100644 index fc7f1d5626..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/fvSolution +++ /dev/null @@ -1,81 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object fvSolution; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -solvers -{ - "alpha.water.*" - { - nAlphaCorr 2; - nAlphaSubCycles 1; - - MULESCorr yes; - nLimiterIter 5; - - solver smoothSolver; - smoother symGaussSeidel; - tolerance 1e-8; - relTol 0; - } - - "pcorr.*" - { - solver PCG; - preconditioner DIC; - tolerance 1e-5; - relTol 0; - } - - p_rgh - { - solver PCG; - preconditioner DIC; - tolerance 1e-07; - relTol 0.05; - } - - p_rghFinal - { - $p_rgh; - relTol 0; - } - - U - { - solver smoothSolver; - smoother symGaussSeidel; - tolerance 1e-06; - relTol 0; - } -} - -PIMPLE -{ - momentumPredictor no; - nOuterCorrectors 1; - nCorrectors 3; - nNonOrthogonalCorrectors 0; -} - -relaxationFactors -{ - equations - { - ".*" 1; - } -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/setFieldsDict b/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/setFieldsDict deleted file mode 100644 index 8b7f4c8cd5..0000000000 --- a/tutorials/incompressibleVoF/damBreakLaminar/damBreak/system/setFieldsDict +++ /dev/null @@ -1,35 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object setFieldsDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -defaultFieldValues -( - volScalarFieldValue alpha.water 0 -); - -regions -( - boxToCell - { - box (0 0 -1) (0.1461 0.292 1); - fieldValues - ( - volScalarFieldValue alpha.water 1 - ); - } -); - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreak/damBreak/Allclean b/tutorials/incompressibleVoF/damBreakLaminarFine/Allclean similarity index 84% rename from tutorials/incompressibleVoF/damBreak/damBreak/Allclean rename to tutorials/incompressibleVoF/damBreakLaminarFine/Allclean index 6b45f82a41..1a8f93c68e 100755 --- a/tutorials/incompressibleVoF/damBreak/damBreak/Allclean +++ b/tutorials/incompressibleVoF/damBreakLaminarFine/Allclean @@ -4,6 +4,8 @@ cd ${0%/*} || exit 1 # Run from this directory # Source tutorial clean functions . $WM_PROJECT_DIR/bin/tools/CleanFunctions -cleanCase +cleanVoFCase + +rm -rf 0 constant system #------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakLaminarFine/Allrun b/tutorials/incompressibleVoF/damBreakLaminarFine/Allrun new file mode 100755 index 0000000000..c054bebb51 --- /dev/null +++ b/tutorials/incompressibleVoF/damBreakLaminarFine/Allrun @@ -0,0 +1,28 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # Run from this directory + +# Source tutorial run functions +. $WM_PROJECT_DIR/bin/tools/RunFunctions + +# Copy the case +isTest "$@" && path=.. || path=$FOAM_TUTORIALS/incompressibleVoF +cp -rn $path/damBreakLaminar/constant $path/damBreakFine/system . +cp -rn $path/damBreak/0 $path/damBreak/constant $path/damBreak/system . +rm -f 0/alpha.water + +# Set a new time-step +runApplication -s controlDict foamDictionary system/controlDict \ + -entry deltaT -set 5e-4 + +# Increase the number of limiter iterations +runApplication -s fvSolution foamDictionary system/fvSolution \ + -entry solvers/"alpha.water.*"/nLimiterIter -set 5 + +# Run +runApplication blockMesh -dict system/blockMeshDict.fine +runApplication setFields +runApplication decomposePar +runParallel $(getApplication) +runApplication reconstructPar + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/epsilon.orig b/tutorials/incompressibleVoF/damBreakPorousBaffle/0/epsilon.orig deleted file mode 100644 index 75066408e4..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/epsilon.orig +++ /dev/null @@ -1,51 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - location "0"; - object epsilon; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 2 -3 0 0 0 0]; - -internalField uniform 0.1; - -boundaryField -{ - leftWall - { - type epsilonWallFunction; - value $internalField; - } - rightWall - { - type epsilonWallFunction; - value $internalField; - } - lowerWall - { - type epsilonWallFunction; - value $internalField; - } - atmosphere - { - type inletOutlet; - inletValue $internalField; - value $internalField; - } - defaultFaces - { - type empty; - } -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/nuTilda.orig b/tutorials/incompressibleVoF/damBreakPorousBaffle/0/nuTilda.orig deleted file mode 100644 index c1c72580a8..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/0/nuTilda.orig +++ /dev/null @@ -1,48 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class volScalarField; - location "0"; - object nuTilda; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 2 -1 0 0 0 0]; - -internalField uniform 0; - -boundaryField -{ - leftWall - { - type zeroGradient; - } - rightWall - { - type zeroGradient; - } - lowerWall - { - type zeroGradient; - } - atmosphere - { - type inletOutlet; - inletValue $internalField; - value $internalField; - } - defaultFaces - { - type empty; - } -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/Allclean b/tutorials/incompressibleVoF/damBreakPorousBaffle/Allclean new file mode 100755 index 0000000000..8639fb1ac4 --- /dev/null +++ b/tutorials/incompressibleVoF/damBreakPorousBaffle/Allclean @@ -0,0 +1,13 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # Run from this directory + +# Source tutorial clean functions +. $WM_PROJECT_DIR/bin/tools/CleanFunctions + +cleanVoFCase + +rm -rf 0 constant + +find system -type f -not -name createBafflesDict -delete + +#------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/Allrun b/tutorials/incompressibleVoF/damBreakPorousBaffle/Allrun index cdc9763e1b..72349ffcf7 100755 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/Allrun +++ b/tutorials/incompressibleVoF/damBreakPorousBaffle/Allrun @@ -4,14 +4,23 @@ cd ${0%/*} || exit 1 # Run from this directory # Source tutorial run functions . $WM_PROJECT_DIR/bin/tools/RunFunctions -# Get application name -application=$(getApplication) +# Copy the case +isTest "$@" && path=.. || path=$FOAM_TUTORIALS/incompressibleVoF +cp -rn $path/damBreak/0 $path/damBreak/constant $path/damBreak/system . +rm -f 0/alpha.water +# Change Courant numbers +runApplication -s controlDict foamDictionary system/controlDict \ + -set "maxCo=0.1, maxAlphaCo=0.1" + +# Change numbers of correctors +runApplication -s fvSolution foamDictionary system/fvSolution \ + -set "PIMPLE/nOuterCorrectors=3, PIMPLE/nCorrectors=1" + +# Run runApplication blockMesh runApplication setFields - runApplication createBaffles -overwrite - -runApplication $application +runApplication $(getApplication) #------------------------------------------------------------------------------ diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/g b/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/g deleted file mode 100644 index 770a56192e..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/g +++ /dev/null @@ -1,21 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class uniformDimensionedVectorField; - location "constant"; - object g; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -dimensions [0 1 -2 0 0 0 0]; -value (0 -9.81 0); - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/phaseProperties b/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/phaseProperties deleted file mode 100644 index 234504e0d1..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/phaseProperties +++ /dev/null @@ -1,22 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "constant"; - object phaseProperties; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -phases (water air); - -sigma 0.07; - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/physicalProperties.air b/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/physicalProperties.air deleted file mode 100644 index fab7bde58b..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/physicalProperties.air +++ /dev/null @@ -1,24 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "constant"; - object physicalProperties.air; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -viscosityModel constant; - -nu 1.48e-05; - -rho 1; - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/physicalProperties.water b/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/physicalProperties.water deleted file mode 100644 index e9b9d7dc4e..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/constant/physicalProperties.water +++ /dev/null @@ -1,24 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "constant"; - object physicalProperties.water; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -viscosityModel constant; - -nu 1e-06; - -rho 1000; - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/blockMeshDict b/tutorials/incompressibleVoF/damBreakPorousBaffle/system/blockMeshDict deleted file mode 100644 index 6f27d83a17..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/blockMeshDict +++ /dev/null @@ -1,105 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - object blockMeshDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -convertToMeters 0.146; - -vertices -( - (0 0 0) - (2 0 0) - (2.16438 0 0) - (4 0 0) - (0 0.32876 0) - (2 0.32876 0) - (2.16438 0.32876 0) - (4 0.32876 0) - (0 4 0) - (2 4 0) - (2.16438 4 0) - (4 4 0) - (0 0 0.1) - (2 0 0.1) - (2.16438 0 0.1) - (4 0 0.1) - (0 0.32876 0.1) - (2 0.32876 0.1) - (2.16438 0.32876 0.1) - (4 0.32876 0.1) - (0 4 0.1) - (2 4 0.1) - (2.16438 4 0.1) - (4 4 0.1) -); - -blocks -( - hex (0 1 5 4 12 13 17 16) (23 8 1) simpleGrading (1 1 1) - hex (2 3 7 6 14 15 19 18) (19 8 1) simpleGrading (1 1 1) - hex (4 5 9 8 16 17 21 20) (23 42 1) simpleGrading (1 1 1) - hex (5 6 10 9 17 18 22 21) (4 42 1) simpleGrading (1 1 1) - hex (6 7 11 10 18 19 23 22) (19 42 1) simpleGrading (1 1 1) -); - -defaultPatch -{ - type empty; -} - -boundary -( - leftWall - { - type wall; - faces - ( - (0 12 16 4) - (4 16 20 8) - ); - } - rightWall - { - type wall; - faces - ( - (7 19 15 3) - (11 23 19 7) - ); - } - lowerWall - { - type wall; - faces - ( - (0 1 13 12) - (1 5 17 13) - (5 6 18 17) - (2 14 18 6) - (2 3 15 14) - ); - } - atmosphere - { - type patch; - faces - ( - (8 20 21 9) - (9 21 22 10) - (10 22 23 11) - ); - } -); - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/controlDict b/tutorials/incompressibleVoF/damBreakPorousBaffle/system/controlDict deleted file mode 100644 index 6722c2ef34..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/controlDict +++ /dev/null @@ -1,57 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object controlDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -application foamRun; - -solver incompressibleVoF; - -startFrom startTime; - -startTime 0; - -stopAt endTime; - -endTime 1; - -deltaT 0.001; - -writeControl adjustableRunTime; - -writeInterval 0.05; - -purgeWrite 0; - -writeFormat ascii; - -writePrecision 6; - -writeCompression off; - -timeFormat general; - -timePrecision 6; - -runTimeModifiable yes; - -adjustTimeStep on; - -maxCo 0.1; -maxAlphaCo 0.1; - -maxDeltaT 1; - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/createBafflesDict b/tutorials/incompressibleVoF/damBreakPorousBaffle/system/createBafflesDict index 22482c4f96..05bd259406 100644 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/createBafflesDict +++ b/tutorials/incompressibleVoF/damBreakPorousBaffle/system/createBafflesDict @@ -24,7 +24,7 @@ baffles type searchableSurface; surface searchablePlate; origin (0.3042 0.0493 -100); - span (0 0.1584 200); + span (0 0.1584 200); owner { diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/fvSchemes b/tutorials/incompressibleVoF/damBreakPorousBaffle/system/fvSchemes deleted file mode 100644 index fd999c7e5c..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/fvSchemes +++ /dev/null @@ -1,52 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object fvSchemes; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -ddtSchemes -{ - default Euler; -} - -gradSchemes -{ - default Gauss linear; -} - -divSchemes -{ - div(rhoPhi,U) Gauss linearUpwind grad(U); - div(phi,alpha) Gauss interfaceCompression vanLeer 1; - div(phi,k) Gauss upwind; - div(phi,epsilon) Gauss upwind; - div(((rho*nuEff)*dev2(T(grad(U))))) Gauss linear; -} - -laplacianSchemes -{ - default Gauss linear corrected; -} - -interpolationSchemes -{ - default linear; -} - -snGradSchemes -{ - default corrected; -} - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/fvSolution b/tutorials/incompressibleVoF/damBreakPorousBaffle/system/fvSolution deleted file mode 100644 index 79e8b5bccb..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/fvSolution +++ /dev/null @@ -1,81 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object fvSolution; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -solvers -{ - "alpha.water.*" - { - nAlphaCorr 2; - nAlphaSubCycles 1; - - MULESCorr yes; - nLimiterIter 3; - - solver smoothSolver; - smoother symGaussSeidel; - tolerance 1e-8; - relTol 0; - } - - "pcorr.*" - { - solver PCG; - preconditioner DIC; - tolerance 1e-5; - relTol 0; - } - - p_rgh - { - solver PCG; - preconditioner DIC; - tolerance 1e-07; - relTol 0.05; - } - - p_rghFinal - { - $p_rgh; - relTol 0; - } - - "(U|k|epsilon).*" - { - solver smoothSolver; - smoother symGaussSeidel; - tolerance 1e-06; - relTol 0; - minIter 1; - } -} - -PIMPLE -{ - momentumPredictor no; - nOuterCorrectors 3; - nCorrectors 1; - nNonOrthogonalCorrectors 0; -} - -relaxationFactors -{ - equations - { - ".*" 1; - } -} - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/topoSetDict b/tutorials/incompressibleVoF/damBreakPorousBaffle/system/topoSetDict deleted file mode 100644 index 1adfe0b9e0..0000000000 --- a/tutorials/incompressibleVoF/damBreakPorousBaffle/system/topoSetDict +++ /dev/null @@ -1,45 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - object topoSetDict; -} - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -actions -( - { - name cyclicFacesFaceSet; - type faceSet; - action new; - source boxToFace; - box (0.3015 0.0493 -1) (0.3069 0.2077 1); - } - - { - name cyclicFacesSlaveCells; - type cellSet; - action new; - source boxToCell; - box (-1 0 -1) (0.305 0.31 1); - } - - { - name cyclicZoneFaces; - type faceZoneSet; - action new; - source setsToFaceZone; - faceSet cyclicFacesFaceSet; - cellSet cyclicFacesSlaveCells; - } -); - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/physicalProperties.air b/tutorials/incompressibleVoF/damBreakWithObstacle/constant/physicalProperties.air deleted file mode 100644 index fab7bde58b..0000000000 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/physicalProperties.air +++ /dev/null @@ -1,24 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "constant"; - object physicalProperties.air; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -viscosityModel constant; - -nu 1.48e-05; - -rho 1; - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/physicalProperties.water b/tutorials/incompressibleVoF/damBreakWithObstacle/constant/physicalProperties.water deleted file mode 100644 index e9b9d7dc4e..0000000000 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/constant/physicalProperties.water +++ /dev/null @@ -1,24 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "constant"; - object physicalProperties.water; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -viscosityModel constant; - -nu 1e-06; - -rho 1000; - - -// ************************************************************************* // diff --git a/tutorials/incompressibleVoF/damBreakWithObstacle/system/decomposeParDict b/tutorials/incompressibleVoF/damBreakWithObstacle/system/decomposeParDict deleted file mode 100644 index 8b030fd8ab..0000000000 --- a/tutorials/incompressibleVoF/damBreakWithObstacle/system/decomposeParDict +++ /dev/null @@ -1,42 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ - ========= | - \\ / F ield | OpenFOAM: The Open Source CFD Toolbox - \\ / O peration | Website: https://openfoam.org - \\ / A nd | Version: dev - \\/ M anipulation | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - format ascii; - class dictionary; - location "system"; - object decomposeParDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 6; - -method scotch; - -simpleCoeffs -{ - n (2 2 1); -} - -hierarchicalCoeffs -{ - n (2 2 1); - order xyz; -} - -manualCoeffs -{ - dataFile ""; -} - -distributed no; - -roots ( ); - - -// ************************************************************************* //