From 277d8369af349ca3f50fbbbf88f381021ee165f8 Mon Sep 17 00:00:00 2001 From: Henry <Henry> Date: Mon, 12 May 2014 23:15:50 +0100 Subject: [PATCH] tutorials/multiphase/interFoam/ras/angledDuct: VoF tutorial to demonstrate porosity feature via fvOptions --- .../multiphase/interFoam/ras/angledDuct/0/U | 57 ++++++ .../interFoam/ras/angledDuct/0/alpha.water | 53 +++++ .../interFoam/ras/angledDuct/0/epsilon | 59 ++++++ .../multiphase/interFoam/ras/angledDuct/0/k | 59 ++++++ .../multiphase/interFoam/ras/angledDuct/0/nut | 57 ++++++ .../interFoam/ras/angledDuct/0/p_rgh | 55 +++++ .../interFoam/ras/angledDuct/Allrun | 10 + .../ras/angledDuct/constant/RASProperties | 25 +++ .../interFoam/ras/angledDuct/constant/g | 22 ++ .../constant/polyMesh/blockMeshDict.m4 | 189 ++++++++++++++++++ .../ras/angledDuct/constant/polyMesh/boundary | 62 ++++++ .../angledDuct/constant/transportProperties | 67 +++++++ .../angledDuct/constant/turbulenceProperties | 21 ++ .../ras/angledDuct/system/controlDict | 56 ++++++ .../interFoam/ras/angledDuct/system/fvOptions | 50 +++++ .../interFoam/ras/angledDuct/system/fvSchemes | 62 ++++++ .../ras/angledDuct/system/fvSolution | 108 ++++++++++ 17 files changed, 1012 insertions(+) create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/0/U create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/0/alpha.water create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/0/epsilon create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/0/k create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/0/nut create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/0/p_rgh create mode 100755 tutorials/multiphase/interFoam/ras/angledDuct/Allrun create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/constant/RASProperties create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/constant/g create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/constant/polyMesh/blockMeshDict.m4 create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/constant/polyMesh/boundary create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/constant/transportProperties create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/constant/turbulenceProperties create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/system/controlDict create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/system/fvOptions create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/system/fvSchemes create mode 100644 tutorials/multiphase/interFoam/ras/angledDuct/system/fvSolution diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/0/U b/tutorials/multiphase/interFoam/ras/angledDuct/0/U new file mode 100644 index 00000000000..d6561fa53e7 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/0/U @@ -0,0 +1,57 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volVectorField; + object U; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 1 -1 0 0 0 0]; + +internalField uniform (0 0 0); + +boundaryField +{ + front + { + type fixedValue; + value uniform (0 0 0); + } + back + { + type fixedValue; + value uniform (0 0 0); + } + walls + { + type fixedValue; + value uniform (0 0 0); + } + porosityWall + { + type slip; + value uniform (0 0 0); + } + inlet + { + type flowRateInletVelocity; + massFlowRate constant 0.1; + value uniform (0 0 0); + } + outlet + { + type pressureInletOutletVelocity; + value uniform (0 0 0); + inletValue uniform (0 0 0); + } +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/0/alpha.water b/tutorials/multiphase/interFoam/ras/angledDuct/0/alpha.water new file mode 100644 index 00000000000..3efd7b5b5c8 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/0/alpha.water @@ -0,0 +1,53 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + object alpha.water; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 0 0 0 0 0 0]; + +internalField uniform 0; + +boundaryField +{ + + front + { + type zeroGradient; + } + back + { + type zeroGradient; + } + walls + { + type zeroGradient; + } + porosityWall + { + type zeroGradient; + } + inlet + { + type fixedValue; + value uniform 1; + } + outlet + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/0/epsilon b/tutorials/multiphase/interFoam/ras/angledDuct/0/epsilon new file mode 100644 index 00000000000..efa9bb4ab4a --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/0/epsilon @@ -0,0 +1,59 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0"; + object epsilon; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 2 -3 0 0 0 0]; + +internalField uniform 200; + +boundaryField +{ + front + { + type epsilonWallFunction; + value uniform 200; + } + back + { + type epsilonWallFunction; + value uniform 200; + } + walls + { + type epsilonWallFunction; + value uniform 200; + } + porosityWall + { + type epsilonWallFunction; + value uniform 200; + } + inlet + { + type turbulentMixingLengthDissipationRateInlet; + mixingLength 0.005; + value uniform 200; + } + outlet + { + type inletOutlet; + inletValue uniform 200; + value uniform 200; + } +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/0/k b/tutorials/multiphase/interFoam/ras/angledDuct/0/k new file mode 100644 index 00000000000..9ea687dc6d4 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/0/k @@ -0,0 +1,59 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0"; + object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 2 -2 0 0 0 0]; + +internalField uniform 1; + +boundaryField +{ + front + { + type kqRWallFunction; + value uniform 1; + } + back + { + type kqRWallFunction; + value uniform 1; + } + walls + { + type kqRWallFunction; + value uniform 1; + } + porosityWall + { + type kqRWallFunction; + value uniform 1; + } + inlet + { + type turbulentIntensityKineticEnergyInlet; + intensity 0.05; + value uniform 1; + } + outlet + { + type inletOutlet; + inletValue uniform 1; + value uniform 1; + } +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/0/nut b/tutorials/multiphase/interFoam/ras/angledDuct/0/nut new file mode 100644 index 00000000000..043c71dde95 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/0/nut @@ -0,0 +1,57 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0"; + object nut; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 2 -1 0 0 0 0]; + +internalField uniform 0; + +boundaryField +{ + front + { + type nutkWallFunction; + value uniform 0; + } + back + { + type nutkWallFunction; + value uniform 0; + } + walls + { + type nutkWallFunction; + value uniform 0; + } + porosityWall + { + type nutkWallFunction; + value uniform 0; + } + inlet + { + type calculated; + value uniform 0; + } + outlet + { + type calculated; + value uniform 0; + } +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/0/p_rgh b/tutorials/multiphase/interFoam/ras/angledDuct/0/p_rgh new file mode 100644 index 00000000000..94b19aeb38c --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/0/p_rgh @@ -0,0 +1,55 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + object p_rgh; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [1 -1 -2 0 0 0 0]; + +internalField uniform 0; + +boundaryField +{ + front + { + type fixedFluxPressure; + value $internalField; + } + back + { + type fixedFluxPressure; + value $internalField; + } + walls + { + type fixedFluxPressure; + value $internalField; + } + porosityWall + { + type fixedFluxPressure; + value $internalField; + } + inlet + { + type fixedFluxPressure; + value $internalField; + } + outlet + { + type fixedValue; + value $internalField; + } +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/Allrun b/tutorials/multiphase/interFoam/ras/angledDuct/Allrun new file mode 100755 index 00000000000..c9fa9825575 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/Allrun @@ -0,0 +1,10 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # run from this directory + +m4 constant/polyMesh/blockMeshDict.m4 > constant/polyMesh/blockMeshDict + +# Source tutorial run functions +. $WM_PROJECT_DIR/bin/tools/RunFunctions + +runApplication blockMesh +runApplication `getApplication` diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/constant/RASProperties b/tutorials/multiphase/interFoam/ras/angledDuct/constant/RASProperties new file mode 100644 index 00000000000..d964d3c8627 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/constant/RASProperties @@ -0,0 +1,25 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "constant"; + object RASProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +RASModel kEpsilon; + +turbulence on; + +printCoeffs on; + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/constant/g b/tutorials/multiphase/interFoam/ras/angledDuct/constant/g new file mode 100644 index 00000000000..07c168261b7 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/constant/g @@ -0,0 +1,22 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + 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/multiphase/interFoam/ras/angledDuct/constant/polyMesh/blockMeshDict.m4 b/tutorials/multiphase/interFoam/ras/angledDuct/constant/polyMesh/blockMeshDict.m4 new file mode 100644 index 00000000000..3272a9437fa --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/constant/polyMesh/blockMeshDict.m4 @@ -0,0 +1,189 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + `format' ascii; + class dictionary; + object blockMeshDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // +// block definition for a porosity with an angled inlet/outlet +// the porosity is not aligned with the main axes +// +dnl> ----------------------------------------------------------------- +dnl> <STANDARD DEFINTIONS> +dnl> +changecom(//)changequote([,]) dnl> +define(calc, [esyscmd(perl -e 'print ($1)')]) dnl> +define(VCOUNT, 0) dnl> +define(vlabel, [[// ]pt VCOUNT ($1) define($1, VCOUNT)define([VCOUNT], incr(VCOUNT))]) dnl> +dnl> +define(hex2D, hex ($1b $2b $3b $4b $1f $2f $3f $4f)) dnl> +define(quad2D, ($1f $1b $2b $2f)) dnl> +define(frontQuad, ($1f $2f $3f $4f)) dnl> +define(backQuad, ($4b $3b $2b $1b)) dnl> +dnl> +dnl> </STANDARD DEFINTIONS> +dnl> ----------------------------------------------------------------- +dnl> +define(ncells, 20) dnl> +define(ninlet, 15) dnl> +define(nporo, 20) dnl> +define(noutlet, 20) dnl> +dnl> +define(x0,0) dnl> +define(y0,0) dnl> +define(y0,0) dnl> +define(Cos,0.7071067812) dnl> == cos(45) +define(Sin,0.7071067812) dnl> == sin(45) +dnl> +define(width,50) dnl> +define(zBack,calc(-width/2)) dnl> +define(zFront,calc(width/2)) dnl> +define(leninlet,150)dnl> +define(lenporo,100)dnl> +define(lenoutlet,100)dnl> +dnl> +define(xhyp,calc(Sin*width)) dnl> +define(yhyp,calc(Cos*width)) dnl> +define(xinlet,leninlet)dnl> +define(xporo,calc(Cos*lenporo)) dnl> +define(yporo,calc(Sin*lenporo)) dnl> +define(xoutlet,calc(xporo + Cos*lenoutlet)) dnl> +define(youtlet,calc(yporo + Sin*lenoutlet)) dnl> +dnl> + +convertToMeters 0.001; + +vertices +( + // inlet region + ( -xinlet y0 zBack ) vlabel(in1b) + ( -xinlet yhyp zBack ) vlabel(in2b) + ( -xinlet y0 zFront ) vlabel(in1f) + ( -xinlet yhyp zFront ) vlabel(in2f) + + // join inlet->outlet + ( x0 y0 zBack ) vlabel(join1b) + ( -xhyp yhyp zBack ) vlabel(join2b) + ( x0 y0 zFront ) vlabel(join1f) + ( -xhyp yhyp zFront ) vlabel(join2f) + + // porosity ends ->outlet + ( xporo yporo zBack ) vlabel(poro1b) + ( calc(xporo - xhyp) calc(yporo + yhyp) zBack ) vlabel(poro2b) + ( xporo yporo zFront ) vlabel(poro1f) + ( calc(xporo - xhyp) calc(yporo + yhyp) zFront ) vlabel(poro2f) + + // outlet + ( xoutlet youtlet zBack ) vlabel(out1b) + ( calc(xoutlet - xhyp) calc(youtlet + yhyp) zBack ) vlabel(out2b) + ( xoutlet youtlet zFront ) vlabel(out1f) + ( calc(xoutlet - xhyp) calc(youtlet + yhyp) zFront ) vlabel(out2f) +); + +blocks +( + // inlet block + hex2D(in1, join1, join2, in2) + inlet ( ninlet ncells ncells ) simpleGrading (1 1 1) + + // porosity block + hex2D(join1, poro1, poro2, join2) + porosity ( nporo ncells ncells ) simpleGrading (1 1 1) + + // outlet block + hex2D(poro1, out1, out2, poro2) + outlet ( noutlet ncells ncells ) simpleGrading (1 1 1) +); + +edges +( +); + +boundary +( + // is there no way of defining all my 'defaultFaces' to be 'wall'? + front + { + type wall; + faces + ( + // inlet block + frontQuad(in1, join1, join2, in2) + // outlet block + frontQuad(poro1, out1, out2, poro2) + ); + } + + back + { + type wall; + faces + ( + // inlet block + backQuad(in1, join1, join2, in2) + // outlet block + backQuad(poro1, out1, out2, poro2) + ); + } + + walls + { + type wall; + faces + ( + // inlet block + quad2D(in1, join1) + quad2D(join2, in2) + // outlet block + quad2D(poro1, out1) + quad2D(out2, poro2) + ); + } + + porosityWall + { + type wall; + faces + ( + // porosity block + frontQuad(join1, poro1, poro2, join2) + // porosity block + backQuad(join1, poro1, poro2, join2) + // porosity block + quad2D(join1, poro1) + quad2D(poro2, join2) + ); + } + + inlet + { + type patch; + faces + ( + quad2D(in2, in1) + ); + } + + outlet + { + type patch; + faces + ( + quad2D(out2, out1) + ); + } +); + +mergePatchPairs +( +); + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/constant/polyMesh/boundary b/tutorials/multiphase/interFoam/ras/angledDuct/constant/polyMesh/boundary new file mode 100644 index 00000000000..4ff78a49cbb --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/constant/polyMesh/boundary @@ -0,0 +1,62 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class polyBoundaryMesh; + location "constant/polyMesh"; + object boundary; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +6 +( + front + { + type wall; + inGroups 1(wall); + nFaces 700; + startFace 63400; + } + back + { + type wall; + inGroups 1(wall); + nFaces 700; + startFace 64100; + } + walls + { + type wall; + inGroups 1(wall); + nFaces 1400; + startFace 64800; + } + porosityWall + { + type wall; + inGroups 1(wall); + nFaces 1600; + startFace 66200; + } + inlet + { + type patch; + nFaces 400; + startFace 67800; + } + outlet + { + type patch; + nFaces 400; + startFace 68200; + } +) + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/constant/transportProperties b/tutorials/multiphase/interFoam/ras/angledDuct/constant/transportProperties new file mode 100644 index 00000000000..2f6fad860b8 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/constant/transportProperties @@ -0,0 +1,67 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "constant"; + object transportProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +phases (water air); + +water +{ + transportModel Newtonian; + nu nu [ 0 2 -1 0 0 0 0 ] 1e-06; + rho rho [ 1 -3 0 0 0 0 0 ] 1000; + CrossPowerLawCoeffs + { + nu0 nu0 [ 0 2 -1 0 0 0 0 ] 1e-06; + nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06; + m m [ 0 0 1 0 0 0 0 ] 1; + n n [ 0 0 0 0 0 0 0 ] 0; + } + + BirdCarreauCoeffs + { + nu0 nu0 [ 0 2 -1 0 0 0 0 ] 0.0142515; + nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06; + k k [ 0 0 1 0 0 0 0 ] 99.6; + n n [ 0 0 0 0 0 0 0 ] 0.1003; + } +} + +air +{ + transportModel Newtonian; + nu nu [ 0 2 -1 0 0 0 0 ] 1.48e-05; + rho rho [ 1 -3 0 0 0 0 0 ] 1; + CrossPowerLawCoeffs + { + nu0 nu0 [ 0 2 -1 0 0 0 0 ] 1e-06; + nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06; + m m [ 0 0 1 0 0 0 0 ] 1; + n n [ 0 0 0 0 0 0 0 ] 0; + } + + BirdCarreauCoeffs + { + nu0 nu0 [ 0 2 -1 0 0 0 0 ] 0.0142515; + nuInf nuInf [ 0 2 -1 0 0 0 0 ] 1e-06; + k k [ 0 0 1 0 0 0 0 ] 99.6; + n n [ 0 0 0 0 0 0 0 ] 0.1003; + } +} + +sigma sigma [ 1 0 -2 0 0 0 0 ] 0.07; + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/constant/turbulenceProperties b/tutorials/multiphase/interFoam/ras/angledDuct/constant/turbulenceProperties new file mode 100644 index 00000000000..fa68b2620ee --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/constant/turbulenceProperties @@ -0,0 +1,21 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "constant"; + object turbulenceProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +simulationType RASModel; + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/system/controlDict b/tutorials/multiphase/interFoam/ras/angledDuct/system/controlDict new file mode 100644 index 00000000000..b0244d5a61d --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/system/controlDict @@ -0,0 +1,56 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object controlDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +application interFoam; + +startFrom startTime; + +startTime 0; + +stopAt endTime; + +endTime 10; + +deltaT 0.001; + +writeControl adjustableRunTime; + +writeInterval 0.1; + +purgeWrite 0; + +writeFormat ascii; + +writePrecision 6; + +writeCompression uncompressed; + +timeFormat general; + +timePrecision 6; + +runTimeModifiable yes; + +adjustTimeStep on; + +maxCo 1; +maxAlphaCo 1; + +maxDeltaT 1; + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/system/fvOptions b/tutorials/multiphase/interFoam/ras/angledDuct/system/fvOptions new file mode 100644 index 00000000000..7352696f07f --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/system/fvOptions @@ -0,0 +1,50 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object fvOptions; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +porosity1 +{ + type explicitPorositySource; + active true; + selectionMode cellZone; + cellZone porosity; + + explicitPorositySourceCoeffs + { + type DarcyForchheimer; + + DarcyForchheimerCoeffs + { + d d [0 -2 0 0 0 0 0] (2e8 -1000 -1000); + f f [0 -1 0 0 0 0 0] (0 0 0); + + coordinateSystem + { + type cartesian; + origin (0 0 0); + coordinateRotation + { + type axesRotation; + e1 (0.70710678 0.70710678 0); + e2 (0 0 1); + } + } + } + } +} + + +//************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/system/fvSchemes b/tutorials/multiphase/interFoam/ras/angledDuct/system/fvSchemes new file mode 100644 index 00000000000..39485cf7291 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/system/fvSchemes @@ -0,0 +1,62 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object fvSchemes; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +ddtSchemes +{ + default Euler; +} + +gradSchemes +{ + default Gauss linear; +} + +divSchemes +{ + div(rhoPhi,U) Gauss upwind; + div(phi,alpha) Gauss vanLeer; + div(phirb,alpha) Gauss linear; + div(phi,k) Gauss upwind; + div(phi,epsilon) Gauss upwind; + div((muEff*dev(T(grad(U))))) Gauss linear; +} + +laplacianSchemes +{ + default Gauss linear corrected; +} + +interpolationSchemes +{ + default linear; +} + +snGradSchemes +{ + default corrected; +} + +fluxRequired +{ + default no; + p_rgh; + pcorr; + alpha.water; +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/ras/angledDuct/system/fvSolution b/tutorials/multiphase/interFoam/ras/angledDuct/system/fvSolution new file mode 100644 index 00000000000..b33c4085f46 --- /dev/null +++ b/tutorials/multiphase/interFoam/ras/angledDuct/system/fvSolution @@ -0,0 +1,108 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: 2.3.x | +| \\ / A nd | Web: www.OpenFOAM.org | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object fvSolution; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +solvers +{ + "alpha.water.*" + { + nAlphaCorr 2; + nAlphaSubCycles 1; + cAlpha 1; + + MULESCorr yes; + nLimiterIter 3; + + solver smoothSolver; + smoother symGaussSeidel; + tolerance 1e-8; + relTol 0; + } + + pcorr + { + solver PCG; + preconditioner + { + preconditioner GAMG; + tolerance 1e-5; + relTol 0; + smoother GaussSeidel; + nPreSweeps 0; + nPostSweeps 2; + nFinestSweeps 2; + cacheAgglomeration true; + nCellsInCoarsestLevel 10; + agglomerator faceAreaPair; + mergeLevels 1; + } + tolerance 1e-5; + relTol 0; + maxIter 50; + } + + p_rgh + { + solver GAMG; + tolerance 5e-9; + relTol 0.01; + + smoother GaussSeidel; + nPreSweeps 0; + nPostSweeps 2; + + cacheAgglomeration true; + + nCellsInCoarsestLevel 10; + agglomerator faceAreaPair; + mergeLevels 1; + + maxIter 50; + }; + + p_rghFinal + { + $p_rgh; + relTol 0; + } + + "(U|k|epsilon).*" + { + solver smoothSolver; + smoother symGaussSeidel; + tolerance 1e-06; + relTol 0; + minIter 1; + } +} + +PIMPLE +{ + momentumPredictor no; + nOuterCorrectors 1; + nCorrectors 3; + nNonOrthogonalCorrectors 0; +} + +relaxationFactors +{ + equations + { + ".*" 1; + } +} + +// ************************************************************************* // -- GitLab