mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: Updated/created tutorial for rhoSimpleFoam
This commit is contained in:
@ -1 +0,0 @@
|
|||||||
../angledDuctImplicit/0
|
|
||||||
@ -1 +0,0 @@
|
|||||||
../angledDuctImplicit/Allrun
|
|
||||||
@ -9,12 +9,46 @@ FoamFile
|
|||||||
{
|
{
|
||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class dictionary;
|
class volScalarField;
|
||||||
location "constant";
|
object T;
|
||||||
object MRFProperties;
|
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
// 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;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
@ -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);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -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;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -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;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -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;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -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;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -9,31 +9,43 @@ FoamFile
|
|||||||
{
|
{
|
||||||
version 2.0;
|
version 2.0;
|
||||||
format ascii;
|
format ascii;
|
||||||
class dictionary;
|
class volScalarField;
|
||||||
location "constant";
|
object p;
|
||||||
object porosityProperties;
|
|
||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
porosity1
|
dimensions [1 -1 -2 0 0 0 0];
|
||||||
|
|
||||||
|
internalField uniform 1.0e5;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
{
|
{
|
||||||
type fixedCoeff;
|
front
|
||||||
active yes;
|
|
||||||
cellZone porosity;
|
|
||||||
|
|
||||||
fixedCoeffCoeffs
|
|
||||||
{
|
{
|
||||||
alpha alpha [0 0 -1 0 0 0 0] (500 -1000 -1000);
|
type zeroGradient;
|
||||||
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);
|
|
||||||
}
|
}
|
||||||
|
back
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
wall
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
porosityWall
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
|
||||||
|
inlet
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
outlet
|
||||||
|
{
|
||||||
|
type fixedValue;
|
||||||
|
value $internalField;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
14
tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/Allrun
Executable file
14
tutorials/compressible/rhoSimpleFoam/angledDuctExplicitFixedCoeff/Allrun
Executable file
@ -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
|
||||||
@ -15,7 +15,7 @@ FoamFile
|
|||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
source1
|
fixedTemperaure1
|
||||||
{
|
{
|
||||||
type fixedTemperatureSource;
|
type fixedTemperatureSource;
|
||||||
active true;
|
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);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
************************************************************************* //
|
||||||
@ -17,7 +17,7 @@ FoamFile
|
|||||||
|
|
||||||
thermoType
|
thermoType
|
||||||
{
|
{
|
||||||
type heRhoThermo;
|
type hePsiThermo;
|
||||||
mixture pureMixture;
|
mixture pureMixture;
|
||||||
transport sutherland;
|
transport sutherland;
|
||||||
thermo hConst;
|
thermo hConst;
|
||||||
@ -15,7 +15,7 @@ FoamFile
|
|||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
application rhoPorousSimpleFoam;
|
application rhoSimpleFoam;
|
||||||
|
|
||||||
startFrom startTime;
|
startFrom startTime;
|
||||||
|
|
||||||
@ -39,10 +39,9 @@ laplacianSchemes
|
|||||||
{
|
{
|
||||||
laplacian(muEff,U) Gauss linear corrected;
|
laplacian(muEff,U) Gauss linear corrected;
|
||||||
laplacian(alphaEff,e) 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(DepsilonEff,epsilon) Gauss linear corrected;
|
||||||
laplacian(DkEff,k) Gauss linear corrected;
|
laplacian(DkEff,k) Gauss linear corrected;
|
||||||
laplacian(1,p) Gauss linear corrected;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
interpolationSchemes
|
interpolationSchemes
|
||||||
Reference in New Issue
Block a user