From a963f82dbf4da0b8e36a33db718d8e0a34e5565b Mon Sep 17 00:00:00 2001 From: Will Bainbridge Date: Wed, 30 May 2018 16:43:56 +0100 Subject: [PATCH] chtMultiRegionFoam: Simplified multiRegionHeater tutorial The changeDictonary setup has been removed and replaced with a more typical boundary condition setup. Dictionary variables and wildcards have been used to reduce repetition of the simulation parameters. --- .../multiRegionHeater/0/bottomWater/T | 52 ++++++ .../multiRegionHeater/0/{ => bottomWater}/U | 25 ++- .../0/{T => bottomWater/alphat} | 12 +- .../multiRegionHeater/0/bottomWater/epsilon | 50 ++++++ .../multiRegionHeater/0/bottomWater/k | 50 ++++++ .../multiRegionHeater/0/{ => bottomWater}/p | 10 +- .../multiRegionHeater/0/bottomWater/p_rgh | 49 +++++ .../multiRegionHeater/0/heater/T | 41 +++++ .../multiRegionHeater/0/{p_rgh => heater/p} | 17 +- .../multiRegionHeater/0/leftSolid/T | 41 +++++ .../multiRegionHeater/0/leftSolid/p | 39 ++++ .../multiRegionHeater/0/rightSolid/T | 41 +++++ .../multiRegionHeater/0/rightSolid/p | 39 ++++ .../multiRegionHeater/0/topAir/T | 52 ++++++ .../multiRegionHeater/0/topAir/U | 47 +++++ .../0/{epsilon => topAir/alphat} | 11 +- .../multiRegionHeater/0/topAir/epsilon | 50 ++++++ .../multiRegionHeater/0/topAir/k | 50 ++++++ .../multiRegionHeater/0/{k => topAir/p} | 11 +- .../multiRegionHeater/0/topAir/p_rgh | 49 +++++ .../multiRegionHeater/Allclean | 19 +- .../multiRegionHeater/Allrun | 37 ++-- .../multiRegionHeater/README.txt | 2 - .../multiRegionHeater/system/README | 3 - .../system/bottomWater/changeDictionaryDict | 169 ------------------ .../system/bottomWater/decomposeParDict | 73 +------- .../multiRegionHeater/system/decomposeParDict | 35 ---- .../system/heater/changeDictionaryDict | 70 -------- .../system/heater/decomposeParDict | 45 +---- .../system/leftSolid/changeDictionaryDict | 60 ------- .../system/leftSolid/decomposeParDict | 45 +---- .../system/leftSolid/fvSolution | 41 +---- .../system/rightSolid/changeDictionaryDict | 50 ------ .../system/rightSolid/decomposeParDict | 45 +---- .../system/rightSolid/fvSolution | 41 +---- .../system/topAir/changeDictionaryDict | 167 ----------------- .../system/topAir/decomposeParDict | 73 +------- .../system/topAir/fvSolution | 84 +-------- .../snappyMultiRegionHeater/0/topAir/T | 12 +- .../snappyMultiRegionHeater/0/topAir/U | 10 +- .../snappyMultiRegionHeater/0/topAir/epsilon | 12 +- .../snappyMultiRegionHeater/0/topAir/k | 12 +- .../snappyMultiRegionHeater/0/topAir/p_rgh | 12 +- .../snappyMultiRegionHeater/Allrun | 2 +- 44 files changed, 742 insertions(+), 1113 deletions(-) create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/T rename tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/{ => bottomWater}/U (65%) rename tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/{T => bottomWater/alphat} (81%) create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/epsilon create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/k rename tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/{ => bottomWater}/p (83%) create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/p_rgh create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/heater/T rename tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/{p_rgh => heater/p} (75%) create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/T create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/p create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/T create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/p create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/T create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/U rename tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/{epsilon => topAir/alphat} (81%) create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/epsilon create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/k rename tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/{k => topAir/p} (81%) create mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/p_rgh delete mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/README.txt delete mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/README delete mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/changeDictionaryDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/decomposeParDict delete mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/changeDictionaryDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/decomposeParDict delete mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/changeDictionaryDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/decomposeParDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/fvSolution delete mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/changeDictionaryDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/decomposeParDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/fvSolution delete mode 100644 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/changeDictionaryDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/decomposeParDict mode change 100644 => 120000 tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/fvSolution diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/T b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/T new file mode 100644 index 000000000..5b8e8a225 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/T @@ -0,0 +1,52 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/bottomAir"; + object T; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 0 0 1 0 0 0 ]; + +internalField uniform 300; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } + "(min|max)(Y|Z)" + { + type zeroGradient; + value $internalField; + } + ".*_to_.*" + { + type compressible::turbulentTemperatureCoupledBaffleMixed; + value $internalField; + Tnbr T; + kappaMethod fluidThermo; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/U b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/U similarity index 65% rename from tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/U rename to tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/U index 5c6a42bb1..f139f48da 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/U +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/U @@ -10,21 +10,38 @@ FoamFile version 2.0; format ascii; class volVectorField; + location "0/bottomAir"; object U; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -dimensions [0 1 -1 0 0 0 0]; +dimensions [ 0 1 -1 0 0 0 0 ]; -internalField uniform (0.01 0 0); +internalField uniform (0.001 0 0); boundaryField { + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type pressureInletOutletVelocity; + value $internalField; + } + "(min|max)(Y|Z)" + { + type noSlip; + } ".*" { - type calculated; - value uniform (0.01 0 0); + type noSlip; } } + // ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/T b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/alphat similarity index 81% rename from tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/T rename to tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/alphat index a2e5fd849..bc648de41 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/T +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/alphat @@ -10,21 +10,25 @@ FoamFile version 2.0; format ascii; class volScalarField; - object T; + location "0/bottomAir"; + object alphat; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -dimensions [0 0 0 1 0 0 0]; +dimensions [1 -1 -1 0 0 0 0]; -internalField uniform 300; +internalField uniform 0; boundaryField { + #includeEtc "caseDicts/setConstraintTypes" + ".*" { type calculated; - value uniform 300; + value $internalField; } } + // ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/epsilon b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/epsilon new file mode 100644 index 000000000..7883fda47 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/epsilon @@ -0,0 +1,50 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/bottomAir"; + object epsilon; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -3 0 0 0 0 ]; + +internalField uniform 0.01; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } + "(min|max)(Y|Z)" + { + type epsilonWallFunction; + value $internalField; + } + ".*_to_.*" + { + type epsilonWallFunction; + value $internalField; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/k b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/k new file mode 100644 index 000000000..a426f5e3a --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/k @@ -0,0 +1,50 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/bottomAir"; + object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -2 0 0 0 0 ]; + +internalField uniform 0.1; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } + "(min|max)(Y|Z)" + { + type kqRWallFunction; + value $internalField; + } + ".*_to_.*" + { + type kqRWallFunction; + value $internalField; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/p b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/p similarity index 83% rename from tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/p rename to tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/p index 3e9721596..5d553447c 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/p +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/p @@ -10,21 +10,25 @@ FoamFile version 2.0; format ascii; class volScalarField; + location "0/bottomAir"; object p; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -dimensions [1 -1 -2 0 0 0 0]; +dimensions [ 1 -1 -2 0 0 0 0 ]; -internalField uniform 1e5; +internalField uniform 0; boundaryField { + #includeEtc "caseDicts/setConstraintTypes" + ".*" { type calculated; - value uniform 1e5; + value $internalField; } } + // ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/p_rgh b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/p_rgh new file mode 100644 index 000000000..ccccc34db --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/bottomWater/p_rgh @@ -0,0 +1,49 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/bottomAir"; + object p_rgh; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 1 -1 -2 0 0 0 0 ]; + +internalField uniform 0; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedFluxPressure; + value $internalField; + } + maxX + { + type fixedValue; + value $internalField; + } + "(min|max)(Y|Z)" + { + type fixedFluxPressure; + value $internalField; + } + ".*_to_.*" + { + type fixedFluxPressure; + value $internalField; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/heater/T b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/heater/T new file mode 100644 index 000000000..e38a222e2 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/heater/T @@ -0,0 +1,41 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/heater"; + object T; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 0 0 1 0 0 0 ]; + +internalField uniform 300; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + "(min|max)(X|Y|Z)" + { + type fixedValue; + value uniform 500; + } + ".*_to_.*" + { + type compressible::turbulentTemperatureCoupledBaffleMixed; + value $internalField; + Tnbr T; + kappaMethod solidThermo; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/p_rgh b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/heater/p similarity index 75% rename from tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/p_rgh rename to tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/heater/p index 8673f6e9b..23c3a7e0f 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/p_rgh +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/heater/p @@ -10,21 +10,30 @@ FoamFile version 2.0; format ascii; class volScalarField; - object p_rgh; + location "0/heater"; + object p; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [1 -1 -2 0 0 0 0]; -internalField uniform 1e5; +internalField uniform 100000; boundaryField { - ".*" + #includeEtc "caseDicts/setConstraintTypes" + + "(min|max)(X|Y|Z)" { type calculated; - value uniform 1e5; + value $internalField; + } + ".*_to_.*" + { + type calculated; + value uniform 0; } } + // ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/T b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/T new file mode 100644 index 000000000..ee1890dbf --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/T @@ -0,0 +1,41 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/leftSolid"; + object T; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 0 0 1 0 0 0 ]; + +internalField uniform 300; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + "(min|max)(X|Y|Z)" + { + type zeroGradient; + value $internalField; + } + ".*_to_.*" + { + type compressible::turbulentTemperatureCoupledBaffleMixed; + value $internalField; + Tnbr T; + kappaMethod solidThermo; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/p b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/p new file mode 100644 index 000000000..0f2d23fcb --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/leftSolid/p @@ -0,0 +1,39 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/leftSolid"; + object p; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [1 -1 -2 0 0 0 0]; + +internalField uniform 100000; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + "(min|max)(X|Y|Z)" + { + type calculated; + value $internalField; + } + ".*_to_.*" + { + type calculated; + value uniform 0; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/T b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/T new file mode 100644 index 000000000..f6df00f1f --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/T @@ -0,0 +1,41 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/rightSolid"; + object T; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 0 0 1 0 0 0 ]; + +internalField uniform 300; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + "(min|max)(X|Y|Z)" + { + type zeroGradient; + value $internalField; + } + ".*_to_.*" + { + type compressible::turbulentTemperatureCoupledBaffleMixed; + value $internalField; + Tnbr T; + kappaMethod solidThermo; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/p b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/p new file mode 100644 index 000000000..caf5eac4d --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/rightSolid/p @@ -0,0 +1,39 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/rightSolid"; + object p; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [1 -1 -2 0 0 0 0]; + +internalField uniform 100000; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + "(min|max)(X|Y|Z)" + { + type calculated; + value $internalField; + } + ".*_to_.*" + { + type calculated; + value uniform 0; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/T b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/T new file mode 100644 index 000000000..5f2bf163d --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/T @@ -0,0 +1,52 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/topAir"; + object T; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 0 0 1 0 0 0 ]; + +internalField uniform 300; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } + "(min|max)(Y|Z)" + { + type zeroGradient; + value $internalField; + } + ".*_to_.*" + { + type compressible::turbulentTemperatureCoupledBaffleMixed; + value $internalField; + Tnbr T; + kappaMethod fluidThermo; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/U b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/U new file mode 100644 index 000000000..ca9e44838 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/U @@ -0,0 +1,47 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volVectorField; + location "0/topAir"; + object U; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 1 -1 0 0 0 0 ]; + +internalField uniform (0.1 0 0); + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type pressureInletOutletVelocity; + value $internalField; + } + "(min|max)(Y|Z)" + { + type noSlip; + } + ".*_to_.*" + { + type noSlip; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/epsilon b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/alphat similarity index 81% rename from tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/epsilon rename to tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/alphat index e20d66145..6f5552d08 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/epsilon +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/alphat @@ -10,20 +10,23 @@ FoamFile version 2.0; format ascii; class volScalarField; - object epsilon; + location "0/topAir"; + object alphat; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -dimensions [0 2 -3 0 0 0 0]; +dimensions [1 -1 -1 0 0 0 0]; -internalField uniform 0.01; +internalField uniform 0; boundaryField { + #includeEtc "caseDicts/setConstraintTypes" + ".*" { type calculated; - value uniform 0.01; + value $internalField; } } diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/epsilon b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/epsilon new file mode 100644 index 000000000..26baa3ef5 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/epsilon @@ -0,0 +1,50 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/topAir"; + object epsilon; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -3 0 0 0 0 ]; + +internalField uniform 0.01; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } + "(min|max)(Y|Z)" + { + type epsilonWallFunction; + value $internalField; + } + ".*_to_.*" + { + type epsilonWallFunction; + value $internalField; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/k b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/k new file mode 100644 index 000000000..55dbb2801 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/k @@ -0,0 +1,50 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/topAir"; + object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -2 0 0 0 0 ]; + +internalField uniform 0.1; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedValue; + value $internalField; + } + maxX + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } + "(min|max)(Y|Z)" + { + type kqRWallFunction; + value $internalField; + } + ".*_to_.*" + { + type kqRWallFunction; + value $internalField; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/k b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/p similarity index 81% rename from tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/k rename to tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/p index 351dfc560..48b9debbb 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/k +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/p @@ -10,20 +10,23 @@ FoamFile version 2.0; format ascii; class volScalarField; - object k; + location "0/topAir"; + object p; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -dimensions [0 2 -2 0 0 0 0]; +dimensions [ 1 -1 -2 0 0 0 0 ]; -internalField uniform 0.1; +internalField uniform 100000; boundaryField { + #includeEtc "caseDicts/setConstraintTypes" + ".*" { type calculated; - value uniform 0.1; + value $internalField; } } diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/p_rgh b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/p_rgh new file mode 100644 index 000000000..394b9e56b --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/0/topAir/p_rgh @@ -0,0 +1,49 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: dev | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0/topAir"; + object p_rgh; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 1 -1 -2 0 0 0 0 ]; + +internalField uniform 100000; + +boundaryField +{ + #includeEtc "caseDicts/setConstraintTypes" + + minX + { + type fixedFluxPressure; + value $internalField; + } + maxX + { + type fixedValue; + value $internalField; + } + "(min|max)(Y|Z)" + { + type fixedFluxPressure; + value $internalField; + } + ".*_to_.*" + { + type fixedFluxPressure; + value $internalField; + } +} + + +// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allclean b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allclean index b5cfeac7b..e3587bf2c 100755 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allclean +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allclean @@ -1,22 +1,13 @@ #!/bin/sh -cd ${0%/*} || exit 1 # Run from this directory +cd ${0%/*} || exit 1 # Run from this directory # Source tutorial clean functions . $WM_PROJECT_DIR/bin/tools/CleanFunctions cleanCase -rm -rf VTK -rm -rf constant/cellToRegion constant/polyMesh/sets -rm -rf 0/bottomWater -rm -rf 0/topAir -rm -rf 0/heater -rm -rf 0/leftSolid -rm -rf 0/rightSolid -rm -f 0/cellToRegion -rm -rf constant/bottomWater/polyMesh -rm -rf constant/topAir/polyMesh -rm -rf constant/heater/polyMesh -rm -rf constant/leftSolid/polyMesh -rm -rf constant/rightSolid/polyMesh +rm -rf \ + constant/*/polyMesh \ + constant/extendedFeatureEdgeMesh \ + constant/triSurface/*.eMesh #------------------------------------------------------------------------------ diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allrun b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allrun index 8d53d67eb..e561a704f 100755 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allrun +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/Allrun @@ -1,43 +1,26 @@ #!/bin/sh -cd ${0%/*} || exit 1 # Run from this directory - +cd ${0%/*} || exit 1 # Run from this directory # Source tutorial run functions . $WM_PROJECT_DIR/bin/tools/RunFunctions +# Meshing runApplication blockMesh runApplication topoSet -runApplication splitMeshRegions -cellZones -overwrite +runApplication decomposePar -copyZero +runParallel splitMeshRegions -cellZones -overwrite -# remove fluid fields from solid regions (important for post-processing) -for i in heater leftSolid rightSolid -do - rm -f 0*/$i/{nut,alphat,epsilon,k,U,p_rgh} -done - - -for i in bottomWater topAir heater leftSolid rightSolid -do - runApplication -s $i changeDictionary -region $i -done - - -#-- Run on single processor -#runApplication $(getApplication) - -# Decompose -runApplication decomposePar -allRegions - -# Run +# Simulation runParallel $(getApplication) # Reconstruct +for region in bottomWater topAir heater leftSolid rightSolid +do + runApplication -s $region reconstructParMesh -constant -region $region +done runApplication reconstructPar -allRegions - -echo -echo "creating files for paraview post-processing" -echo +# Post-process paraFoam -touchAll #------------------------------------------------------------------------------ diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/README.txt b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/README.txt deleted file mode 100644 index 647f11981..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/README.txt +++ /dev/null @@ -1,2 +0,0 @@ -The 0/ field files contain nonsense patchFields. All interesting -work is done using the changeDictionaryDicts. diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/README b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/README deleted file mode 100644 index 5a81b9a57..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/README +++ /dev/null @@ -1,3 +0,0 @@ -fvSolution is used for outer correctors specification. -fvSchemes is only so that pre-processing activities can proceed - diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/changeDictionaryDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/changeDictionaryDict deleted file mode 100644 index 925c3f742..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/changeDictionaryDict +++ /dev/null @@ -1,169 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -U -{ - internalField uniform (0.001 0 0); - - boundaryField - { - minX - { - type fixedValue; - value uniform (0.001 0 0); - } - - maxX - { - type inletOutlet; - inletValue uniform (0 0 0); - } - - ".*" - { - type fixedValue; - value uniform (0 0 0); - } - } -} - -T -{ - internalField uniform 300; - - boundaryField - { - minX - { - type fixedValue; - value uniform 300; - } - - maxX - { - type inletOutlet; - inletValue uniform 300; - } - - ".*" - { - type zeroGradient; - value uniform 300; - } - - "bottomWater_to_.*" - { - type compressible::turbulentTemperatureCoupledBaffleMixed; - Tnbr T; - kappaMethod fluidThermo; - value uniform 300; - } - } -} - -epsilon -{ - internalField uniform 0.01; - - boundaryField - { - minX - { - type fixedValue; - value uniform 0.01; - } - - maxX - { - type inletOutlet; - inletValue uniform 0.01; - } - - ".*" - { - type epsilonWallFunction; - value uniform 0.01; - } - } -} - -k -{ - internalField uniform 0.1; - - boundaryField - { - minX - { - type inletOutlet; - inletValue uniform 0.1; - } - - maxX - { - type zeroGradient; - value uniform 0.1; - } - - ".*" - { - type kqRWallFunction; - value uniform 0.1; - } - } -} - -p_rgh -{ - internalField uniform 0; - - boundaryField - { - minX - { - type zeroGradient; - value uniform 0; - } - - maxX - { - type fixedValue; - value uniform 0; - } - - ".*" - { - type fixedFluxPressure; - value uniform 0; - } - } -} - -p -{ - internalField uniform 0; - - boundaryField - { - ".*" - { - type calculated; - value uniform 0; - } - } -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/decomposeParDict deleted file mode 100644 index e028e1c2a..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/decomposeParDict +++ /dev/null @@ -1,72 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - note "mesh decomposition control dictionary"; - location "system"; - object decomposeParDict; -} - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 4; - -//- Keep owner and neighbour on same processor for faces in zones: -// preserveFaceZones (heater solid1 solid3); - -method scotch; -// method hierarchical; -// method simple; -// method manual; - -simpleCoeffs -{ - n (2 2 1); - delta 0.001; -} - -hierarchicalCoeffs -{ - n (2 2 1); - delta 0.001; - order xyz; -} - -scotchCoeffs -{ - // processorWeights - //( - // 1 - // 1 - // 1 - // 1 - //); - // writeGraph true; - // strategy "b"; -} - -manualCoeffs -{ - dataFile "decompositionData"; -} - - -//// Is the case distributed -//distributed yes; -//// Per slave (so nProcs-1 entries) the directory above the case. -//roots -//( -// "/tmp" -// "/tmp" -//); - - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/decomposeParDict new file mode 120000 index 000000000..46638e60f --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/bottomWater/decomposeParDict @@ -0,0 +1 @@ +../decomposeParDict \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/decomposeParDict index 3eb54ba02..c063349c2 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/decomposeParDict +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/decomposeParDict @@ -19,42 +19,7 @@ FoamFile numberOfSubdomains 4; -//- Keep owner and neighbour on same processor for faces in zones: -// preserveFaceZones (heater solid1 solid3); - method scotch; -// method hierarchical; -// method simple; -// method manual; - -simpleCoeffs -{ - n (2 2 1); - delta 0.001; -} - -hierarchicalCoeffs -{ - n (2 2 1); - delta 0.001; - order xyz; -} - - -manualCoeffs -{ - dataFile "decompositionData"; -} - - -//// Is the case distributed -//distributed yes; -//// Per slave (so nProcs-1 entries) the directory above the case. -//roots -//( -// "/tmp" -// "/tmp" -//); // ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/changeDictionaryDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/changeDictionaryDict deleted file mode 100644 index 2a58a037c..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/changeDictionaryDict +++ /dev/null @@ -1,70 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -boundary -{ - minY - { - type patch; - } - minZ - { - type patch; - } - maxZ - { - type patch; - } -} - -T -{ - internalField uniform 300; - - boundaryField - { - ".*" - { - type zeroGradient; - value uniform 300; - } - "heater_to_.*" - { - type compressible::turbulentTemperatureCoupledBaffleMixed; - Tnbr T; - kappaMethod solidThermo; - value uniform 300; - } - - heater_to_leftSolid - { - type compressible::turbulentTemperatureCoupledBaffleMixed; - Tnbr T; - kappaMethod solidThermo; - thicknessLayers (1e-3); - kappaLayers (5e-4); - value uniform 300; - } - - minY - { - type fixedValue; - value uniform 500; - } - } -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/decomposeParDict deleted file mode 100644 index e405fc009..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/decomposeParDict +++ /dev/null @@ -1,44 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - location "system"; - object decomposeParDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 4; - -method scotch; - -simpleCoeffs -{ - n (2 2 1); - delta 0.001; -} - -hierarchicalCoeffs -{ - n (2 2 1); - delta 0.001; - order xyz; -} - -scotchCoeffs -{ -} - -manualCoeffs -{ - dataFile "decompositionData"; -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/decomposeParDict new file mode 120000 index 000000000..46638e60f --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/heater/decomposeParDict @@ -0,0 +1 @@ +../decomposeParDict \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/changeDictionaryDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/changeDictionaryDict deleted file mode 100644 index a3132386a..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/changeDictionaryDict +++ /dev/null @@ -1,60 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -boundary -{ - minZ - { - type patch; - } - maxZ - { - type patch; - } -} - -T -{ - internalField uniform 300; - - boundaryField - { - ".*" - { - type zeroGradient; - value uniform 300; - } - "leftSolid_to_.*" - { - type compressible::turbulentTemperatureCoupledBaffleMixed; - Tnbr T; - kappaMethod solidThermo; - value uniform 300; - } - - leftSolid_to_heater - { - type compressible::turbulentTemperatureCoupledBaffleMixed; - Tnbr T; - kappaMethod solidThermo; - thicknessLayers (1e-3); - kappaLayers (5e-4); - value uniform 300; - } - } -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/decomposeParDict deleted file mode 100644 index e405fc009..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/decomposeParDict +++ /dev/null @@ -1,44 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - location "system"; - object decomposeParDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 4; - -method scotch; - -simpleCoeffs -{ - n (2 2 1); - delta 0.001; -} - -hierarchicalCoeffs -{ - n (2 2 1); - delta 0.001; - order xyz; -} - -scotchCoeffs -{ -} - -manualCoeffs -{ - dataFile "decompositionData"; -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/decomposeParDict new file mode 120000 index 000000000..46638e60f --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/decomposeParDict @@ -0,0 +1 @@ +../decomposeParDict \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/fvSolution b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/fvSolution deleted file mode 100644 index ccb0d3183..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/fvSolution +++ /dev/null @@ -1,40 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object fvSolution; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -solvers -{ - h - { - solver PCG; - preconditioner DIC; - tolerance 1e-06; - relTol 0.1; - } - - hFinal - { - $h; - tolerance 1e-06; - relTol 0; - } -} - -PIMPLE -{ - nNonOrthogonalCorrectors 0; -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/fvSolution b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/fvSolution new file mode 120000 index 000000000..0bde0fc62 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/leftSolid/fvSolution @@ -0,0 +1 @@ +../heater/fvSolution \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/changeDictionaryDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/changeDictionaryDict deleted file mode 100644 index 236a6006e..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/changeDictionaryDict +++ /dev/null @@ -1,50 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -boundary -{ - minZ - { - type patch; - } - maxZ - { - type patch; - } -} - -T -{ - internalField uniform 300; - - boundaryField - { - ".*" - { - type zeroGradient; - value uniform 300; - } - "rightSolid_to_.*" - { - type compressible::turbulentTemperatureCoupledBaffleMixed; - Tnbr T; - kappaMethod solidThermo; - value uniform 300; - } - } -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/decomposeParDict deleted file mode 100644 index e405fc009..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/decomposeParDict +++ /dev/null @@ -1,44 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - location "system"; - object decomposeParDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 4; - -method scotch; - -simpleCoeffs -{ - n (2 2 1); - delta 0.001; -} - -hierarchicalCoeffs -{ - n (2 2 1); - delta 0.001; - order xyz; -} - -scotchCoeffs -{ -} - -manualCoeffs -{ - dataFile "decompositionData"; -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/decomposeParDict new file mode 120000 index 000000000..46638e60f --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/decomposeParDict @@ -0,0 +1 @@ +../decomposeParDict \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/fvSolution b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/fvSolution deleted file mode 100644 index ccb0d3183..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/fvSolution +++ /dev/null @@ -1,40 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object fvSolution; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -solvers -{ - h - { - solver PCG; - preconditioner DIC; - tolerance 1e-06; - relTol 0.1; - } - - hFinal - { - $h; - tolerance 1e-06; - relTol 0; - } -} - -PIMPLE -{ - nNonOrthogonalCorrectors 0; -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/fvSolution b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/fvSolution new file mode 120000 index 000000000..0bde0fc62 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/rightSolid/fvSolution @@ -0,0 +1 @@ +../heater/fvSolution \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/changeDictionaryDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/changeDictionaryDict deleted file mode 100644 index a0a316a8e..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/changeDictionaryDict +++ /dev/null @@ -1,167 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object changeDictionaryDict; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -U -{ - internalField uniform (0.1 0 0); - - boundaryField - { - ".*" - { - type fixedValue; - value uniform (0 0 0); - } - minX - { - type fixedValue; - value uniform (0.1 0 0); - } - maxX - { - type inletOutlet; - inletValue uniform (0 0 0); - value uniform (0.1 0 0); - } - } -} - -T -{ - internalField uniform 300; - - boundaryField - { - ".*" - { - type zeroGradient; - } - - minX - { - type fixedValue; - value uniform 300; - } - maxX - { - type inletOutlet; - inletValue uniform 300; - value uniform 300; - } - - "topAir_to_.*" - { - type compressible::turbulentTemperatureCoupledBaffleMixed; - Tnbr T; - kappaMethod fluidThermo; - value uniform 300; - } - } -} - -epsilon -{ - internalField uniform 0.01; - - boundaryField - { - ".*" - { - type epsilonWallFunction; - value uniform 0.01; - } - - minX - { - type fixedValue; - value uniform 0.01; - } - maxX - { - type inletOutlet; - inletValue uniform 0.01; - value uniform 0.01; - } - } -} - -k -{ - internalField uniform 0.1; - - boundaryField - { - ".*" - { - type kqRWallFunction; - value uniform 0.1; - } - - minX - { - type fixedValue; - value uniform 0.1; - } - maxX - { - type inletOutlet; - inletValue uniform 0.1; - value uniform 0.1; - } - } -} - -p_rgh -{ - internalField uniform 1e5; - - boundaryField - { - ".*" - { - type fixedFluxPressure; - value uniform 1e5; - } - - maxX - { - type fixedValue; - value uniform 1e5; - } - } -} - -p -{ - internalField uniform 1e5; - - boundaryField - { - ".*" - { - type calculated; - value uniform 1e5; - } - - maxX - { - type calculated; - value uniform 1e5; - } - } -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/decomposeParDict deleted file mode 100644 index e028e1c2a..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/decomposeParDict +++ /dev/null @@ -1,72 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - note "mesh decomposition control dictionary"; - location "system"; - object decomposeParDict; -} - -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -numberOfSubdomains 4; - -//- Keep owner and neighbour on same processor for faces in zones: -// preserveFaceZones (heater solid1 solid3); - -method scotch; -// method hierarchical; -// method simple; -// method manual; - -simpleCoeffs -{ - n (2 2 1); - delta 0.001; -} - -hierarchicalCoeffs -{ - n (2 2 1); - delta 0.001; - order xyz; -} - -scotchCoeffs -{ - // processorWeights - //( - // 1 - // 1 - // 1 - // 1 - //); - // writeGraph true; - // strategy "b"; -} - -manualCoeffs -{ - dataFile "decompositionData"; -} - - -//// Is the case distributed -//distributed yes; -//// Per slave (so nProcs-1 entries) the directory above the case. -//roots -//( -// "/tmp" -// "/tmp" -//); - - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/decomposeParDict b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/decomposeParDict new file mode 120000 index 000000000..46638e60f --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/decomposeParDict @@ -0,0 +1 @@ +../decomposeParDict \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/fvSolution b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/fvSolution deleted file mode 100644 index 0eb178deb..000000000 --- a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/fvSolution +++ /dev/null @@ -1,83 +0,0 @@ -/*--------------------------------*- C++ -*----------------------------------*\ -| ========= | | -| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | -| \\ / O peration | Version: dev | -| \\ / A nd | Web: www.OpenFOAM.org | -| \\/ M anipulation | | -\*---------------------------------------------------------------------------*/ -FoamFile -{ - version 2.0; - format ascii; - class dictionary; - object fvSolution; -} -// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // - -solvers -{ - rho - { - solver PCG; - preconditioner DIC; - tolerance 1e-7; - relTol 0.1; - } - - rhoFinal - { - $rho; - tolerance 1e-7; - relTol 0; - } - - p_rgh - { - solver GAMG; - tolerance 1e-7; - relTol 0.01; - - smoother GaussSeidel; - - } - - p_rghFinal - { - $p_rgh; - tolerance 1e-7; - relTol 0; - } - - "(U|h|k|epsilon|R)" - { - solver PBiCGStab; - preconditioner DILU; - tolerance 1e-7; - relTol 0.1; - } - - "(U|h|k|epsilon|R)Final" - { - $U; - tolerance 1e-7; - relTol 0; - } -} - -PIMPLE -{ - momentumPredictor yes; - nCorrectors 2; - nNonOrthogonalCorrectors 0; -} - -relaxationFactors -{ - equations - { - "h.*" 1; - "U.*" 1; - } -} - -// ************************************************************************* // diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/fvSolution b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/fvSolution new file mode 120000 index 000000000..90d9c9234 --- /dev/null +++ b/tutorials/heatTransfer/chtMultiRegionFoam/multiRegionHeater/system/topAir/fvSolution @@ -0,0 +1 @@ +../bottomWater/fvSolution \ No newline at end of file diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/T b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/T index 127e69c16..5f2bf163d 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/T +++ b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/T @@ -23,11 +23,6 @@ boundaryField { #includeEtc "caseDicts/setConstraintTypes" - maxY - { - type zeroGradient; - value $internalField; - } minX { type fixedValue; @@ -39,12 +34,7 @@ boundaryField value $internalField; inletValue $internalField; } - minZ - { - type zeroGradient; - value $internalField; - } - maxZ + "(min|max)(Y|Z)" { type zeroGradient; value $internalField; diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/U b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/U index 28fe948c8..ca9e44838 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/U +++ b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/U @@ -23,10 +23,6 @@ boundaryField { #includeEtc "caseDicts/setConstraintTypes" - maxY - { - type noSlip; - } minX { type fixedValue; @@ -37,11 +33,7 @@ boundaryField type pressureInletOutletVelocity; value $internalField; } - minZ - { - type noSlip; - } - maxZ + "(min|max)(Y|Z)" { type noSlip; } diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/epsilon b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/epsilon index aceaa7fad..26baa3ef5 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/epsilon +++ b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/epsilon @@ -23,11 +23,6 @@ boundaryField { #includeEtc "caseDicts/setConstraintTypes" - maxY - { - type epsilonWallFunction; - value $internalField; - } minX { type fixedValue; @@ -39,12 +34,7 @@ boundaryField value $internalField; inletValue $internalField; } - minZ - { - type epsilonWallFunction; - value $internalField; - } - maxZ + "(min|max)(Y|Z)" { type epsilonWallFunction; value $internalField; diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/k b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/k index 19119e049..55dbb2801 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/k +++ b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/k @@ -23,11 +23,6 @@ boundaryField { #includeEtc "caseDicts/setConstraintTypes" - maxY - { - type kqRWallFunction; - value $internalField; - } minX { type fixedValue; @@ -39,12 +34,7 @@ boundaryField value $internalField; inletValue $internalField; } - minZ - { - type kqRWallFunction; - value $internalField; - } - maxZ + "(min|max)(Y|Z)" { type kqRWallFunction; value $internalField; diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/p_rgh b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/p_rgh index 4bdbae0f1..394b9e56b 100644 --- a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/p_rgh +++ b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/0/topAir/p_rgh @@ -23,11 +23,6 @@ boundaryField { #includeEtc "caseDicts/setConstraintTypes" - maxY - { - type fixedFluxPressure; - value $internalField; - } minX { type fixedFluxPressure; @@ -38,12 +33,7 @@ boundaryField type fixedValue; value $internalField; } - minZ - { - type fixedFluxPressure; - value $internalField; - } - maxZ + "(min|max)(Y|Z)" { type fixedFluxPressure; value $internalField; diff --git a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/Allrun b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/Allrun index 564e9fec9..89c907c15 100755 --- a/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/Allrun +++ b/tutorials/heatTransfer/chtMultiRegionFoam/snappyMultiRegionHeater/Allrun @@ -19,7 +19,7 @@ for region in bottomAir topAir heater leftSolid rightSolid do runApplication -s $region reconstructParMesh -constant -region $region done -reconstructPar -allRegions +runApplication reconstructPar -allRegions # Post-process paraFoam -touchAll