diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/U b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/U new file mode 100644 index 0000000000..1578cd5682 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/U @@ -0,0 +1,53 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volVectorField; + location "0"; + object U; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 1 -1 0 0 0 0]; + +internalField uniform (0 0 0); + +boundaryField +{ + left + { + type waveVelocity; + value uniform (0 0 0); + } + + right + { + type waveVelocity; + value uniform (0 0 0); + } + + sides + { + type slip; + } + + ground + { + type noSlip; + } + + top + { + type pressureInletOutletVelocity; + value uniform (0 0 0); + } +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/alpha.water b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/alpha.water new file mode 100644 index 0000000000..0d1342625b --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/alpha.water @@ -0,0 +1,52 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ 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 +{ + left + { + type waveAlpha; + value uniform 0; + } + + right + { + type zeroGradient; + } + + ground + { + type zeroGradient; + } + + sides + { + type zeroGradient; + } + + top + { + type inletOutlet; + inletValue uniform 0; + value uniform 0; + } +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/epsilon b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/epsilon new file mode 100644 index 0000000000..5d7be42d8a --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/epsilon @@ -0,0 +1,50 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + object epsilon; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 2 -3 0 0 0 0]; + +internalField uniform 0.0001; + +boundaryField +{ + left + { + type zeroGradient; + } + right + { + type zeroGradient; + } + sides + { + type slip; + } + + top + { + type inletOutlet; + inletValue uniform 0.0001; + value uniform 0.0001; + } + ground + { + type epsilonWallFunction; + value uniform 0.0001; + } +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/k b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/k new file mode 100644 index 0000000000..280b1eb77d --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/k @@ -0,0 +1,51 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class volScalarField; + location "0"; + object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 2 -2 0 0 0 0]; + +internalField uniform 0.001; + +boundaryField +{ + left + { + type zeroGradient; + } + right + { + type zeroGradient; + } + sides + { + type slip; + } + + top + { + type inletOutlet; + inletValue uniform 0.001; + value uniform 0.001; + } + ground + { + type kqRWallFunction; + value uniform 0.001; + } +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/nut b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/nut new file mode 100644 index 0000000000..570d1432f8 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/nut @@ -0,0 +1,52 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ 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 +{ + left + { + type calculated; + value uniform 0; + } + right + { + type calculated; + value uniform 0; + } + sides + { + type slip; + } + + top + { + type calculated; + value uniform 0; + } + ground + { + type nutkWallFunction; + value uniform 0; + } +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/p_rgh b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/p_rgh new file mode 100644 index 0000000000..84d15c7c0a --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/0.orig/p_rgh @@ -0,0 +1,60 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ 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 +{ + left + { + type fixedFluxPressure; + value uniform 0; + } + + right + { + type fixedFluxPressure; + value uniform 0; + } + + ground + { + type fixedFluxPressure; + value uniform 0; + } + + sides + { + type slip; + } + + top + { + type totalPressure; + U U; + phi rhoPhi; + rho rho; + psi none; + gamma 1; + p0 uniform 0; + value uniform 0; + } +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/Allclean b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/Allclean new file mode 100755 index 0000000000..705f91474c --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/Allclean @@ -0,0 +1,10 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # run from this directory + +# Source tutorial run functions +. $WM_PROJECT_DIR/bin/tools/CleanFunctions + +rm -rf 0 + +cleanCase + diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/Allrun b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/Allrun new file mode 100755 index 0000000000..7ce66c4a9c --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/Allrun @@ -0,0 +1,17 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # run from this directory + +# Source tutorial run functions +. $WM_PROJECT_DIR/bin/tools/RunFunctions + +restore0Dir + +runApplication blockMesh + +runApplication setFields + +runApplication topoSet + +runApplication decomposePar + +runParallel $(getApplication) diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/g b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/g new file mode 100644 index 0000000000..195dbea3f3 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/g @@ -0,0 +1,22 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class uniformDimensionedVectorField; + location "constant"; + object g; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [0 1 -2 0 0 0 0]; +value ( 0 0 -9.81 ); + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/transportProperties b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/transportProperties new file mode 100644 index 0000000000..eaf6dbd919 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/transportProperties @@ -0,0 +1,37 @@ +/*---------------------------------------------------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "constant"; + object transportProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +phases (water air); + +water +{ + transportModel Newtonian; + nu [0 2 -1 0 0 0 0] 1e-06; + rho [1 -3 0 0 0 0 0] 1000; +} + +air +{ + transportModel Newtonian; + nu [0 2 -1 0 0 0 0] 1.48e-05; + rho [1 -3 0 0 0 0 0] 1; +} + +sigma [1 0 -2 0 0 0 0] 0.07; + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/triSurface/seaweed.stl b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/triSurface/seaweed.stl new file mode 100644 index 0000000000..07c5b84cd3 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/triSurface/seaweed.stl @@ -0,0 +1,86 @@ +solid C +facet normal 0.0 1.0 0.0 + outer loop + vertex 4.065 0.5475 0.25 + vertex 5.7 0.5475 0.0 + vertex 4.065 0.5475 0.0 + endloop +endfacet +facet normal 0.0 1.0 0.0 + outer loop + vertex 5.7 0.5475 0.0 + vertex 4.065 0.5475 0.25 + vertex 5.7 0.5475 0.25 + endloop +endfacet +facet normal 1.0 0.0 0.0 + outer loop + vertex 5.7 0.5475 0.0 + vertex 5.7 0.0025 0.25 + vertex 5.7 0.0025 0.0 + endloop +endfacet +facet normal 1.0 0.0 0.0 + outer loop + vertex 5.7 0.0025 0.25 + vertex 5.7 0.5475 0.0 + vertex 5.7 0.5475 0.25 + endloop +endfacet +facet normal 1.63851263511957e-017 -1.0 0.0 + outer loop + vertex 5.7 0.0025 0.25 + vertex 4.065 0.00249999999999997 0.0 + vertex 5.7 0.0025 0.0 + endloop +endfacet +facet normal 1.63851263511957e-017 -1.0 0.0 + outer loop + vertex 4.065 0.00249999999999997 0.0 + vertex 5.7 0.0025 0.25 + vertex 4.065 0.00249999999999997 0.25 + endloop +endfacet +facet normal 0.0 0.0 -1.0 + outer loop + vertex 5.7 0.5475 0.0 + vertex 4.065 0.00249999999999997 0.0 + vertex 4.065 0.5475 0.0 + endloop +endfacet +facet normal 0.0 0.0 -1.0 + outer loop + vertex 4.065 0.00249999999999997 0.0 + vertex 5.7 0.5475 0.0 + vertex 5.7 0.0025 0.0 + endloop +endfacet +facet normal 0.0 0.0 1.0 + outer loop + vertex 5.7 0.0025 0.25 + vertex 4.065 0.5475 0.25 + vertex 4.065 0.00249999999999997 0.25 + endloop +endfacet +facet normal 0.0 0.0 1.0 + outer loop + vertex 4.065 0.5475 0.25 + vertex 5.7 0.0025 0.25 + vertex 5.7 0.5475 0.25 + endloop +endfacet +facet normal -1.0 0.0 0.0 + outer loop + vertex 4.065 0.5475 0.25 + vertex 4.065 0.00249999999999997 0.0 + vertex 4.065 0.00249999999999997 0.25 + endloop +endfacet +facet normal -1.0 0.0 0.0 + outer loop + vertex 4.065 0.00249999999999997 0.0 + vertex 4.065 0.5475 0.25 + vertex 4.065 0.5475 0.0 + endloop +endfacet +endsolid C diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/turbulenceProperties b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/turbulenceProperties new file mode 100644 index 0000000000..8fe9b5ed38 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/turbulenceProperties @@ -0,0 +1,30 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "constant"; + object turbulenceProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +simulationType RAS; + +RAS +{ + RASModel kEpsilon; + + turbulence on; + + printCoeffs on; +} + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/waveProperties b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/waveProperties new file mode 100644 index 0000000000..1870cb67eb --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/constant/waveProperties @@ -0,0 +1,43 @@ +/*---------------------------------------------------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "constant"; + object wavesProperties; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +left +{ + alpha alpha.water; + + waveModel Boussinesq; + + nPaddle 1; + + waveHeight 0.05; + + waveAngle 0.0; + + activeAbsorption yes; +} + +right +{ + alpha alpha.water; + + waveModel shallowWaterAbsorption; + + nPaddle 1; +} + +// ************************************************************************* // + diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/blockMeshDict b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/blockMeshDict new file mode 100644 index 0000000000..1feafa9b23 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/blockMeshDict @@ -0,0 +1,89 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object blockMeshDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +convertToMeters 1; + +vertices +( + ( 0.0 0.0 0.0) + ( 7.0 0.0 0.0) + ( 7.0 0.55 0.0) + ( 0.0 0.55 0.0) + ( 0.0 0.0 0.5) + ( 7.0 0.0 0.5) + ( 7.0 0.55 0.5) + ( 0.0 0.55 0.5) + +); + +blocks +( + hex (0 1 2 3 4 5 6 7) (350 28 42) simpleGrading (1 1 1) +); +edges +( +); + +boundary +( + left + { + type patch; + faces + ( + (0 4 7 3) + ); + } + right + { + type patch; + faces + ( + (1 5 6 2) + ); + } + ground + { + type wall; + faces + ( + (0 1 2 3) + ); + } + top + { + type patch; + faces + ( + (4 5 6 7) + ); + } + sides + { + type patch; + faces + ( + (0 1 5 4) + (3 2 6 7) + ); + } +); + +mergePatchPairs +( +); + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/controlDict b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/controlDict new file mode 100644 index 0000000000..0a025c4aaa --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/controlDict @@ -0,0 +1,158 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object controlDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +application interFoam; + +startFrom latestTime; + +startTime 0; + +stopAt endTime; + +endTime 10.0; + +deltaT 0.1; + +writeControl adjustableRunTime; + +writeInterval 0.1; + +purgeWrite 0; + +writeFormat ascii; + +writePrecision 6; + +writeCompression off; + +timeFormat general; + +timePrecision 6; + +runTimeModifiable yes; + +adjustTimeStep on; + +maxCo 0.4; +maxAlphaCo 0.4; + +maxDeltaT 0.01; + +functions +{ + // VOF sensors + line + { + type sets; + functionObjectLibs ("libsampling.so"); + enabled true; + writeControl writeTime; + + interpolationScheme cellPoint; + setFormat raw; + sets + ( + s1 + { + type uniform; + axis distance; + start ( 2.065 0.275 0.0 ); + end ( 2.065 0.275 0.5 ); + nPoints 101; + } + s2 + { + type uniform; + axis distance; + start ( 3.565 0.275 0.0 ); + end ( 3.565 0.275 0.5 ); + nPoints 101; + } + s3 + { + type uniform; + axis distance; + start ( 3.99 0.275 0.0 ); + end ( 3.99 0.275 0.5 ); + nPoints 101; + } + s4 + { + type uniform; + axis distance; + start ( 4.055 0.275 0.0 ); + end ( 4.055 0.275 0.5 ); + nPoints 101; + } + s5 + { + type uniform; + axis distance; + start ( 4.155 0.275 0.0 ); + end ( 4.155 0.275 0.5 ); + nPoints 101; + } + s6 + { + type uniform; + axis distance; + start ( 4.275 0.275 0.0 ); + end ( 4.275 0.275 0.5 ); + nPoints 101; + } + s7 + { + type uniform; + axis distance; + start ( 4.395 0.275 0.0 ); + end ( 4.395 0.275 0.5 ); + nPoints 101; + } + s8 + { + type uniform; + axis distance; + start ( 4.515 0.275 0.0 ); + end ( 4.515 0.275 0.5 ); + nPoints 101; + } + s9 + { + type uniform; + axis distance; + start ( 4.635 0.275 0.0 ); + end ( 4.635 0.275 0.5 ); + nPoints 101; + } + s10 + { + type uniform; + axis distance; + start ( 4.77 0.275 0.0 ); + end ( 4.77 0.275 0.5 ); + nPoints 101; + } + ); + fixedLocations false; + fields + ( + p p_rgh U alpha.water + ); + } +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/decomposeParDict b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/decomposeParDict new file mode 100644 index 0000000000..301d97027b --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/decomposeParDict @@ -0,0 +1,29 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object decomposeParDict; +} + +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +numberOfSubdomains 2; + +method hierarchical; + +hierarchicalCoeffs +{ + n (2 1 1); + delta 0.001; + order xyz; +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvOptions b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvOptions new file mode 100644 index 0000000000..361118f1a8 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvOptions @@ -0,0 +1,62 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "constant"; + object fvOptions; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +Mangroves +{ + type multiphaseMangrovesSource; + active yes; + + multiphaseMangrovesSourceCoeffs + { + regions + { + region1 + { + cellZone c0; + a 0.01; + N 560; + Cm 1; + Cd 1.52; + } + } + } +} + + +TurbulenciaMangroves +{ + type multiphaseMangrovesTurbulenceModel; + active yes; + + multiphaseMangrovesTurbulenceModelCoeffs + { + regions + { + region1 + { + cellZone c0; + a 0.01; + N 560; + Ckp 1; + Cep 3.5; + Cd 1.52; + } + } + } +} + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvSchemes b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvSchemes new file mode 100644 index 0000000000..b09b634496 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvSchemes @@ -0,0 +1,56 @@ + +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ 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 linearUpwind grad(U); + div(phi,alpha) Gauss vanLeer; + div(phirb,alpha) Gauss linear; + div(phi,k) Gauss upwind; + div(phi,epsilon) Gauss upwind; + div(((rho*nuEff)*dev2(T(grad(U))))) Gauss linear; +} + +laplacianSchemes +{ + default Gauss linear orthogonal; +} + +interpolationSchemes +{ + default linear; +} + +snGradSchemes +{ + default orthogonal; +} + + +// ************************************************************************* // + diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvSolution b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvSolution new file mode 100644 index 0000000000..c1e6799fc1 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/fvSolution @@ -0,0 +1,78 @@ + +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object fvSolution; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +solvers +{ + "alpha.water.*" + { + nAlphaCorr 1; + nAlphaSubCycles 3; + cAlpha 1; + } + + "pcorr.*" + { + solver PCG; + preconditioner DIC; + tolerance 1e-6; + relTol 0; + } + + p_rgh + { + solver PCG; + preconditioner DIC; + tolerance 1e-6; + relTol 0.1; + } + + p_rghFinal + { + solver GAMG; + smoother DIC; + tolerance 1e-7; + relTol 0; + } + + "(U|k|epsilon|omega)" + { + solver PBiCG; + preconditioner DILU; + tolerance 1e-6; + relTol 0.1; + } + + "(U|k|epsilon|omega)Final" + { + solver PBiCG; + preconditioner DILU; + tolerance 1e-6; + relTol 0; + } +} + +PIMPLE +{ + momentumPredictor no; + nCorrectors 2; + nNonOrthogonalCorrectors 0; +} + + +// ************************************************************************* // + diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/setFieldsDict b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/setFieldsDict new file mode 100644 index 0000000000..29ee77356a --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/setFieldsDict @@ -0,0 +1,55 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + location "system"; + object setFieldsDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +defaultFieldValues +( + volScalarFieldValue alpha.water 0 + volScalarFieldValue MangrovesIndex 0 + volVectorFieldValue U (0 0 0) +); + +regions +( + boxToCell + { + box (-10 -10 -10) (100 100 0.15); + fieldValues + ( + volScalarFieldValue alpha.water 1 + ); + } + + surfaceToCell + { + file "./constant/triSurface/seaweed.stl"; + outsidePoints ((2 0.25 0.15)); + includeCut true; + includeInside true; + includeOutside false; + nearDistance -1; + + curvature -100; + + fieldValues + ( + volScalarFieldValue MangrovesIndex 1 + ); + } +); + + +// ************************************************************************* // diff --git a/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/topoSetDict b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/topoSetDict new file mode 100644 index 0000000000..d3d9114bb0 --- /dev/null +++ b/tutorials/multiphase/interFoam/laminar/waveMangroveInteraction/system/topoSetDict @@ -0,0 +1,33 @@ +/*--------------------------------*- C++ -*----------------------------------*\ +| ========= | | +| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | +| \\ / O peration | Version: plus | +| \\ / A nd | Web: www.OpenFOAM.com | +| \\/ M anipulation | | +\*---------------------------------------------------------------------------*/ +FoamFile +{ + version 2.0; + format ascii; + class dictionary; + object topoSetDict; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +actions +( + { + name c0; + type cellZoneSet; + action new; + source fieldToCell; + sourceInfo + { + field MangrovesIndex; + min 0.5; + max 1.5; + } + } +); + +// ************************************************************************* //