From ef1d4a2a963a2fd01a0ae953bb4b8ff06f5de5d5 Mon Sep 17 00:00:00 2001 From: andy <andy> Date: Wed, 5 Dec 2012 17:01:58 +0000 Subject: [PATCH] ENH: Updated/created tutorial for rhoSimpleFoam --- .../angledDuctExplicitFixedCoeff/0 | 1 - .../angledDuctExplicitFixedCoeff/Allrun | 1 - .../angledDuctExplicitFixedCoeff/0/T} | 42 ++++++++++-- .../angledDuctExplicitFixedCoeff/0/U | 57 +++++++++++++++++ .../angledDuctExplicitFixedCoeff/0/alphat | 57 +++++++++++++++++ .../angledDuctExplicitFixedCoeff/0/epsilon | 64 +++++++++++++++++++ .../angledDuctExplicitFixedCoeff/0/k | 64 +++++++++++++++++++ .../angledDuctExplicitFixedCoeff/0/mut | 62 ++++++++++++++++++ .../angledDuctExplicitFixedCoeff/0/p} | 48 ++++++++------ .../angledDuctExplicitFixedCoeff/Allrun | 14 ++++ .../constant/RASProperties | 0 .../constant/polyMesh/blockMeshDict.m4 | 0 .../constant/polyMesh/boundary | 0 .../constant/sourcesProperties | 35 +++++++++- .../constant/thermophysicalProperties | 2 +- .../system/controlDict | 2 +- .../system/fvSchemes | 3 +- .../system/fvSolution | 0 18 files changed, 422 insertions(+), 30 deletions(-) delete mode 120000 tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/0 delete mode 120000 tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/Allrun rename tutorials/compressible/{rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/MRFProperties => rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/T} (55%) create mode 100644 tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/U create mode 100644 tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/alphat create mode 100644 tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/epsilon create mode 100644 tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/k create mode 100644 tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/mut rename tutorials/compressible/{rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/porosityProperties => rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/p} (60%) create mode 100755 tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/Allrun rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/constant/RASProperties (100%) rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/constant/polyMesh/blockMeshDict.m4 (100%) rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/constant/polyMesh/boundary (100%) rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/constant/sourcesProperties (58%) rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/constant/thermophysicalProperties (97%) rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/system/controlDict (97%) rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/system/fvSchemes (94%) rename tutorials/compressible/{rhoPorousSimpleFoam => rhoSimpleFoam}/angledDuctExplicitFixedCoeff/system/fvSolution (100%) diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/0 b/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/0 deleted file mode 120000 index f1c4a884b51..00000000000 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/0 +++ /dev/null @@ -1 +0,0 @@ -../angledDuctImplicit/0 \ No newline at end of file diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/Allrun b/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/Allrun deleted file mode 120000 index 09efeaf930d..00000000000 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/Allrun +++ /dev/null @@ -1 +0,0 @@ -../angledDuctImplicit/Allrun \ No newline at end of file diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/MRFProperties b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/T similarity index 55% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/MRFProperties rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/T index fd749d03963..561ca236be3 100644 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/MRFProperties +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/T @@ -9,12 +9,46 @@ FoamFile { version 2.0; format ascii; - class dictionary; - location "constant"; - object MRFProperties; + class volScalarField; + object T; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -// none +dimensions [0 0 0 1 0 0 0]; + +internalField uniform 293; + +boundaryField +{ + + front + { + type zeroGradient; + } + back + { + type zeroGradient; + } + wall + { + type zeroGradient; + } + porosityWall + { + type zeroGradient; + } + + inlet + { + type fixedValue; + value $internalField; + } + outlet + { + type inletOutlet; + value $internalField; + inletValue $internalField; + } +} // ************************************************************************* // diff --git a/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/U b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/U new file mode 100644 index 00000000000..20e25d12a8c --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/U @@ -0,0 +1,57 @@ +/*--------------------------------*- 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; + 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); + } + wall + { + 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 inletOutlet; + value uniform (0 0 0); + inletValue uniform (0 0 0); + } +} + +// ************************************************************************* // diff --git a/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/alphat b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/alphat new file mode 100644 index 00000000000..f609fa6c14c --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/alphat @@ -0,0 +1,57 @@ +/*--------------------------------*- 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"; + object alphat; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [1 -1 -1 0 0 0 0]; + +internalField uniform 0; + +boundaryField +{ + front + { + type alphatWallFunction; + value uniform 0; + } + back + { + type alphatWallFunction; + value uniform 0; + } + wall + { + type alphatWallFunction; + value uniform 0; + } + porosityWall + { + type alphatWallFunction; + value uniform 0; + } + inlet + { + type calculated; + value uniform 0; + } + outlet + { + type calculated; + value uniform 0; + } +} + + +// ************************************************************************* // diff --git a/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/epsilon b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/epsilon new file mode 100644 index 00000000000..7588e13063f --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/epsilon @@ -0,0 +1,64 @@ +/*--------------------------------*- 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"; + object epsilon; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -3 0 0 0 0 ]; + +internalField uniform 200; + +boundaryField +{ + front + { + type compressible::epsilonWallFunction; + value uniform 200; + } + + back + { + type compressible::epsilonWallFunction; + value uniform 200; + } + + wall + { + type compressible::epsilonWallFunction; + value uniform 200; + } + + porosityWall + { + type compressible::epsilonWallFunction; + value uniform 200; + } + + inlet + { + type compressible::turbulentMixingLengthDissipationRateInlet; + mixingLength 0.005; + value uniform 200; + } + + outlet + { + type inletOutlet; + inletValue uniform 200; + value uniform 200; + } +} + + +// ************************************************************************* // diff --git a/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/k b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/k new file mode 100644 index 00000000000..85df9b83c3b --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/k @@ -0,0 +1,64 @@ +/*--------------------------------*- 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"; + object k; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 0 2 -2 0 0 0 0 ]; + +internalField uniform 1; + +boundaryField +{ + front + { + type compressible::kqRWallFunction; + value uniform 1; + } + + back + { + type compressible::kqRWallFunction; + value uniform 1; + } + + wall + { + type compressible::kqRWallFunction; + value uniform 1; + } + + porosityWall + { + type compressible::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/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/mut b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/mut new file mode 100644 index 00000000000..2ba718d5b53 --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/mut @@ -0,0 +1,62 @@ +/*--------------------------------*- 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"; + object mut; +} +// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // + +dimensions [ 1 -1 -1 0 0 0 0 ]; + +internalField uniform 0; + +boundaryField +{ + front + { + type mutkWallFunction; + value uniform 0; + } + + back + { + type mutkWallFunction; + value uniform 0; + } + + wall + { + type mutkWallFunction; + value uniform 0; + } + + porosityWall + { + type mutkWallFunction; + value uniform 0; + } + + inlet + { + type calculated; + value uniform 0; + } + + outlet + { + type calculated; + value uniform 0; + } +} + + +// ************************************************************************* // diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/porosityProperties b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/p similarity index 60% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/porosityProperties rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/p index adc5ef3cc21..21db04d6109 100644 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/porosityProperties +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/0/p @@ -9,31 +9,43 @@ FoamFile { version 2.0; format ascii; - class dictionary; - location "constant"; - object porosityProperties; + class volScalarField; + object p; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -porosity1 -{ - type fixedCoeff; - active yes; - cellZone porosity; +dimensions [1 -1 -2 0 0 0 0]; + +internalField uniform 1.0e5; - fixedCoeffCoeffs +boundaryField +{ + front + { + type zeroGradient; + } + back + { + type zeroGradient; + } + wall { - alpha alpha [0 0 -1 0 0 0 0] (500 -1000 -1000); - beta beta [0 -1 0 0 0 0 0] (0 0 0); - rhoRef 1; + type zeroGradient; + } + porosityWall + { + type zeroGradient; + } - coordinateSystem - { - e1 (0.70710678 0.70710678 0); - e2 (0 0 1); - } + inlet + { + type zeroGradient; + } + outlet + { + type fixedValue; + value $internalField; } } - // ************************************************************************* // diff --git a/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/Allrun b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/Allrun new file mode 100755 index 00000000000..e51c24da589 --- /dev/null +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/Allrun @@ -0,0 +1,14 @@ +#!/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 + +application=`getApplication` + +runApplication blockMesh +runApplication $application + +# ----------------------------------------------------------------- end-of-file diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/RASProperties b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/RASProperties similarity index 100% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/RASProperties rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/RASProperties diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/blockMeshDict.m4 b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/blockMeshDict.m4 similarity index 100% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/blockMeshDict.m4 rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/blockMeshDict.m4 diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/boundary b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/boundary similarity index 100% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/boundary rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/polyMesh/boundary diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/sourcesProperties b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/sourcesProperties similarity index 58% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/sourcesProperties rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/sourcesProperties index ddd2bf9c9fa..d4d41da47fb 100644 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/sourcesProperties +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/sourcesProperties @@ -15,7 +15,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -source1 +fixedTemperaure1 { type fixedTemperatureSource; active true; @@ -32,4 +32,35 @@ source1 } -// ************************************************************************* // +porosity1 +{ + type explicitPorositySource; + active true; + timeStart 0; + duration 1000000; + selectionMode cellZone; + cellZone porosity; + + explicitPorositySourceCoeffs + { + type fixedCoeff; + active yes; + cellZone porosity; + + fixedCoeffCoeffs + { + alpha alpha [0 0 -1 0 0 0 0] (500 -1000 -1000); + beta beta [0 -1 0 0 0 0 0] (0 0 0); + rhoRef 1; + + coordinateSystem + { + e1 (0.70710678 0.70710678 0); + e2 (0 0 1); + } + } + } +} + + +************************************************************************* // diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/thermophysicalProperties b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/thermophysicalProperties similarity index 97% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/thermophysicalProperties rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/thermophysicalProperties index 920fff435c7..db1f5947af0 100644 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/constant/thermophysicalProperties +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/constant/thermophysicalProperties @@ -17,7 +17,7 @@ FoamFile thermoType { - type heRhoThermo; + type hePsiThermo; mixture pureMixture; transport sutherland; thermo hConst; diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/controlDict b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/controlDict similarity index 97% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/controlDict rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/controlDict index 4974079c9d7..2ec29c29a85 100644 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/controlDict +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/controlDict @@ -15,7 +15,7 @@ FoamFile } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // -application rhoPorousSimpleFoam; +application rhoSimpleFoam; startFrom startTime; diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSchemes b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSchemes similarity index 94% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSchemes rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSchemes index e106336cb2d..576b46fe86e 100644 --- a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSchemes +++ b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSchemes @@ -39,10 +39,9 @@ laplacianSchemes { laplacian(muEff,U) Gauss linear corrected; laplacian(alphaEff,e) Gauss linear corrected; - laplacian((rho*rAU),p) Gauss linear corrected; + laplacian((rho*(1|A(U))),p) Gauss linear corrected; laplacian(DepsilonEff,epsilon) Gauss linear corrected; laplacian(DkEff,k) Gauss linear corrected; - laplacian(1,p) Gauss linear corrected; } interpolationSchemes diff --git a/tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSolution b/tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSolution similarity index 100% rename from tutorials/compressible/rhoPorousSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSolution rename to tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/system/fvSolution -- GitLab