mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' of github.com:OpenFOAM/OpenFOAM-dev
This commit is contained in:
40
etc/templates/axisymmetricJet/0/U
Normal file
40
etc/templates/axisymmetricJet/0/U
Normal file
@ -0,0 +1,40 @@
|
||||
/*--------------------------------*- 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;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
Uinlet (10 0 0);
|
||||
|
||||
dimensions [0 1 -1 0 0 0 0];
|
||||
|
||||
internalField uniform (0 0 0);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform $Uinlet;
|
||||
}
|
||||
|
||||
atmosphere
|
||||
{
|
||||
type pressureInletOutletVelocity;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
35
etc/templates/axisymmetricJet/0/epsilon
Normal file
35
etc/templates/axisymmetricJet/0/epsilon
Normal file
@ -0,0 +1,35 @@
|
||||
/*--------------------------------*- 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;
|
||||
object omega;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
epsilonInlet 0.002;
|
||||
|
||||
dimensions [0 2 -3 0 0 0 0];
|
||||
|
||||
internalField uniform $epsilonInlet;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
"(inlet|atmosphere)"
|
||||
{
|
||||
type turbulentMixingLengthDissipationRateInlet;
|
||||
mixingLength 0.1;
|
||||
value uniform $epsilonInlet;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
42
etc/templates/axisymmetricJet/0/k
Normal file
42
etc/templates/axisymmetricJet/0/k
Normal file
@ -0,0 +1,42 @@
|
||||
/*--------------------------------*- 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;
|
||||
object k;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
kInlet 0.01;
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform $kInlet;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type turbulentIntensityKineticEnergyInlet;
|
||||
intensity 0.02;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
atmosphere
|
||||
{
|
||||
type inletOutlet;
|
||||
inletValue uniform $kInlet;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
38
etc/templates/axisymmetricJet/0/nut
Normal file
38
etc/templates/axisymmetricJet/0/nut
Normal file
@ -0,0 +1,38 @@
|
||||
/*--------------------------------*- 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;
|
||||
object nut;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
atmosphere
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
35
etc/templates/axisymmetricJet/0/omega
Normal file
35
etc/templates/axisymmetricJet/0/omega
Normal file
@ -0,0 +1,35 @@
|
||||
/*--------------------------------*- 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;
|
||||
object omega;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
omegaInlet 1.0;
|
||||
|
||||
dimensions [0 0 -1 0 0 0 0];
|
||||
|
||||
internalField uniform $omegaInlet;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
"(inlet|atmosphere)"
|
||||
{
|
||||
type turbulentMixingLengthFrequencyInlet;
|
||||
mixingLength 0.1;
|
||||
value uniform $omegaInlet;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
38
etc/templates/axisymmetricJet/0/p
Normal file
38
etc/templates/axisymmetricJet/0/p
Normal file
@ -0,0 +1,38 @@
|
||||
/*--------------------------------*- 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;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
atmosphere
|
||||
{
|
||||
type totalPressure;
|
||||
gamma 1.4;
|
||||
p0 uniform 0;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
8
etc/templates/axisymmetricJet/Allclean
Executable file
8
etc/templates/axisymmetricJet/Allclean
Executable file
@ -0,0 +1,8 @@
|
||||
#!/bin/sh
|
||||
cd ${0%/*} || exit 1 # run from this directory
|
||||
|
||||
# Source tutorial clean functions
|
||||
. $WM_PROJECT_DIR/bin/tools/CleanFunctions
|
||||
|
||||
cleanCase
|
||||
rm constant/polyMesh/boundary
|
||||
14
etc/templates/axisymmetricJet/Allrun
Executable file
14
etc/templates/axisymmetricJet/Allrun
Executable file
@ -0,0 +1,14 @@
|
||||
#!/bin/sh
|
||||
cd ${0%/*} || exit 1 # run from this directory
|
||||
|
||||
# Source tutorial run functions
|
||||
. $WM_PROJECT_DIR/bin/tools/RunFunctions
|
||||
|
||||
application=`getApplication`
|
||||
|
||||
runApplication blockMesh
|
||||
runApplication extrudeMesh
|
||||
|
||||
runApplication $application
|
||||
|
||||
# ----------------------------------------------------------------- end-of-file
|
||||
25
etc/templates/axisymmetricJet/README
Normal file
25
etc/templates/axisymmetricJet/README
Normal file
@ -0,0 +1,25 @@
|
||||
Overview
|
||||
========
|
||||
+ Template case for axisymmetric jet flow
|
||||
+ The main purpose of this template is to demonstrate a simple, reliable meshing
|
||||
strategy for axisymmetric flow
|
||||
|
||||
Meshing
|
||||
=======
|
||||
+ The blockMeshDict file contains a backgroundMesh subditionary
|
||||
+ In backgroundMesh set the geometry radius and length and jet radius
|
||||
+ Set the number of cells in the length and radial directions
|
||||
+ Run blockMesh to generate a 2D "slab" mesh
|
||||
+ Run extrudeMesh to convert the mesh into a 2D axisymmetric mesh with wedge
|
||||
front and back patches
|
||||
|
||||
Initialisation
|
||||
==============
|
||||
+ In the field files in the 0 directory, set inlet values
|
||||
+ For example, in 0/U, set the inlet velocity Uinlet
|
||||
+ Set the viscosity in constant/transportProperties
|
||||
|
||||
Output
|
||||
======
|
||||
+ Graph data of field values along the centreline are written to files in
|
||||
postProcessing/graph
|
||||
23
etc/templates/axisymmetricJet/constant/RASProperties
Normal file
23
etc/templates/axisymmetricJet/constant/RASProperties
Normal file
@ -0,0 +1,23 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object RASProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
RASModel kOmegaSST;
|
||||
|
||||
turbulence on;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
// ************************************************************************* //
|
||||
109
etc/templates/axisymmetricJet/constant/polyMesh/blockMeshDict
Normal file
109
etc/templates/axisymmetricJet/constant/polyMesh/blockMeshDict
Normal file
@ -0,0 +1,109 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
backgroundMesh
|
||||
{
|
||||
length 25;
|
||||
rA 0.5; // radius of inlet patch
|
||||
rB 4; // outer radius
|
||||
lengthCells 250;
|
||||
rAcells 10;
|
||||
rBcells 50;
|
||||
}
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
( 0 0 -1)
|
||||
($:backgroundMesh.length 0 -1)
|
||||
( 0 $:backgroundMesh.rA -1)
|
||||
($:backgroundMesh.length $:backgroundMesh.rA -1)
|
||||
( 0 $:backgroundMesh.rB -1)
|
||||
($:backgroundMesh.length $:backgroundMesh.rB -1)
|
||||
|
||||
( 0 0 0)
|
||||
($:backgroundMesh.length 0 0)
|
||||
( 0 $:backgroundMesh.rA 0)
|
||||
($:backgroundMesh.length $:backgroundMesh.rA 0)
|
||||
( 0 $:backgroundMesh.rB 0)
|
||||
($:backgroundMesh.length $:backgroundMesh.rB 0)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 3 2 6 7 9 8)
|
||||
($:backgroundMesh.lengthCells $:backgroundMesh.rAcells 1)
|
||||
simpleGrading (1 1 1)
|
||||
|
||||
hex (2 3 5 4 8 9 11 10)
|
||||
($:backgroundMesh.lengthCells $:backgroundMesh.rBcells 1)
|
||||
simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
boundary
|
||||
(
|
||||
inlet
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(0 6 8 2)
|
||||
);
|
||||
}
|
||||
|
||||
front
|
||||
{
|
||||
type symmetry;
|
||||
faces
|
||||
(
|
||||
(6 7 9 8)
|
||||
(8 9 11 10)
|
||||
);
|
||||
}
|
||||
|
||||
back
|
||||
{
|
||||
type symmetry;
|
||||
faces
|
||||
(
|
||||
(0 1 3 2)
|
||||
(2 3 5 4)
|
||||
);
|
||||
}
|
||||
|
||||
atmosphere
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(2 8 10 4)
|
||||
(4 5 11 10)
|
||||
(5 3 9 11)
|
||||
(3 1 7 9)
|
||||
);
|
||||
}
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
21
etc/templates/axisymmetricJet/constant/transportProperties
Normal file
21
etc/templates/axisymmetricJet/constant/transportProperties
Normal file
@ -0,0 +1,21 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object transportProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
transportModel Newtonian;
|
||||
|
||||
nu nu [ 0 2 -1 0 0 0 0 ] 1.5e-05;
|
||||
|
||||
// ************************************************************************* //
|
||||
19
etc/templates/axisymmetricJet/constant/turbulenceProperties
Normal file
19
etc/templates/axisymmetricJet/constant/turbulenceProperties
Normal file
@ -0,0 +1,19 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object turbulenceProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
simulationType RASModel;
|
||||
|
||||
// ************************************************************************* //
|
||||
56
etc/templates/axisymmetricJet/system/controlDict
Normal file
56
etc/templates/axisymmetricJet/system/controlDict
Normal file
@ -0,0 +1,56 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application simpleFoam;
|
||||
|
||||
startFrom latestTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 1000;
|
||||
|
||||
deltaT 1;
|
||||
|
||||
writeControl timeStep;
|
||||
|
||||
writeInterval 50;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 12;
|
||||
|
||||
writeCompression off;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable true;
|
||||
|
||||
// adjustTimeStep yes;
|
||||
|
||||
// maxCo 1;
|
||||
|
||||
functions
|
||||
{
|
||||
#include "graph"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
35
etc/templates/axisymmetricJet/system/extrudeMeshDict
Normal file
35
etc/templates/axisymmetricJet/system/extrudeMeshDict
Normal file
@ -0,0 +1,35 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object extrudeProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
constructFrom patch;
|
||||
sourceCase "$FOAM_CASE";
|
||||
|
||||
sourcePatches (front);
|
||||
exposedPatchName back;
|
||||
|
||||
extrudeModel wedge;
|
||||
|
||||
sectorCoeffs
|
||||
{
|
||||
axisPt (0 0 0);
|
||||
axis (1 0 0);
|
||||
angle 1;
|
||||
}
|
||||
|
||||
flipNormals false;
|
||||
mergeFaces false;
|
||||
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
67
etc/templates/axisymmetricJet/system/fvSchemes
Normal file
67
etc/templates/axisymmetricJet/system/fvSchemes
Normal file
@ -0,0 +1,67 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSchemes;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
ddtSchemes
|
||||
{
|
||||
default steadyState;
|
||||
}
|
||||
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
|
||||
limited cellLimited Gauss linear 1;
|
||||
grad(U) $limited;
|
||||
grad(k) $limited;
|
||||
grad(omega) $limited;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default none;
|
||||
|
||||
div(phi,U) bounded Gauss linearUpwind limited;
|
||||
|
||||
turbulence bounded Gauss limitedLinear 1;
|
||||
div(phi,k) $turbulence;
|
||||
div(phi,omega) $turbulence;
|
||||
div(phi,epsilon) $turbulence;
|
||||
|
||||
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
{
|
||||
default corrected;
|
||||
}
|
||||
|
||||
fluxRequired
|
||||
{
|
||||
default no;
|
||||
p ;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
93
etc/templates/axisymmetricJet/system/fvSolution
Normal file
93
etc/templates/axisymmetricJet/system/fvSolution
Normal file
@ -0,0 +1,93 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSolution;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvers
|
||||
{
|
||||
p
|
||||
{
|
||||
solver GAMG;
|
||||
smoother GaussSeidel;
|
||||
cacheAgglomeration on; // Need to make this default?
|
||||
agglomerator faceAreaPair; // Need to make this default?
|
||||
nCellsInCoarsestLevel 10; // Need to make this default?
|
||||
mergeLevels 1; // Need to make this default
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)"
|
||||
{
|
||||
solver smoothSolver;
|
||||
smoother symGaussSeidel;
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
pFinal
|
||||
{
|
||||
$p;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)Final"
|
||||
{
|
||||
$U;
|
||||
relTol 0;
|
||||
}
|
||||
}
|
||||
|
||||
"(PIMPLE|PISO)"
|
||||
{
|
||||
nOuterCorrectors 1;
|
||||
nCorrectors 2;
|
||||
nNonOrthogonalCorrectors 1;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
|
||||
SIMPLE
|
||||
{
|
||||
residualControl
|
||||
{
|
||||
p 1e-4;
|
||||
U 1e-4;
|
||||
"(k|omega|epsilon)" 1e-4;
|
||||
}
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
|
||||
}
|
||||
|
||||
potentialFlow
|
||||
{
|
||||
nNonOrthogonalCorrectors 10;
|
||||
}
|
||||
|
||||
relaxationFactors
|
||||
{
|
||||
fields
|
||||
{
|
||||
p 0.3;
|
||||
}
|
||||
equations
|
||||
{
|
||||
U 0.7;
|
||||
"(k|omega|epsilon)" 0.7;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
42
etc/templates/axisymmetricJet/system/graph
Normal file
42
etc/templates/axisymmetricJet/system/graph
Normal file
@ -0,0 +1,42 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object ;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
graph
|
||||
{
|
||||
type sets;
|
||||
functionObjectLibs ("libsampling.so");
|
||||
outputControl outputTime;
|
||||
|
||||
interpolationScheme cellPointFace;
|
||||
|
||||
setFormat raw;
|
||||
|
||||
sets
|
||||
(
|
||||
centreline
|
||||
{
|
||||
type uniform;
|
||||
axis x;
|
||||
start ( 0 1e-6 0);
|
||||
end (25 1e-6 0);
|
||||
nPoints 250;
|
||||
}
|
||||
);
|
||||
|
||||
fields ( U );
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
36
etc/templates/closedVolume/0/T
Normal file
36
etc/templates/closedVolume/0/T
Normal file
@ -0,0 +1,36 @@
|
||||
/*--------------------------------*- 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;
|
||||
object T;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 0 0 1 0 0 0];
|
||||
|
||||
internalField uniform 300;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
<patchName>
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform 400;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type fixedValue;
|
||||
value $internalField;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
30
etc/templates/closedVolume/0/U
Normal file
30
etc/templates/closedVolume/0/U
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- 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
|
||||
{
|
||||
wall
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
31
etc/templates/closedVolume/0/alphat
Normal file
31
etc/templates/closedVolume/0/alphat
Normal file
@ -0,0 +1,31 @@
|
||||
/*--------------------------------*- 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;
|
||||
object alphat;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type alphatJayatillekeWallFunction;
|
||||
Prt 0.85;
|
||||
value $internalField;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
32
etc/templates/closedVolume/0/epsilon
Normal file
32
etc/templates/closedVolume/0/epsilon
Normal file
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- 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;
|
||||
object epsilon;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
epsilonInitial 0.001;
|
||||
|
||||
dimensions [0 2 -3 0 0 0 0];
|
||||
|
||||
internalField uniform $epsilonInitial;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type epsilonWallFunction;
|
||||
value uniform $epsilonInitial;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
32
etc/templates/closedVolume/0/k
Normal file
32
etc/templates/closedVolume/0/k
Normal file
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- 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;
|
||||
object k;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
kInitial 0.005;
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform $kInitial;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type kqRWallFunction;
|
||||
value uniform $kInitial;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
30
etc/templates/closedVolume/0/nut
Normal file
30
etc/templates/closedVolume/0/nut
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- 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;
|
||||
object nut;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type nutkWallFunction;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
32
etc/templates/closedVolume/0/omega
Normal file
32
etc/templates/closedVolume/0/omega
Normal file
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- 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;
|
||||
object omega;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
omegaInitial 0.1;
|
||||
|
||||
dimensions [0 0 -1 0 0 0 0];
|
||||
|
||||
internalField uniform $omegaInitial;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type omegaWallFunction;
|
||||
value uniform $omegaInitial;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
29
etc/templates/closedVolume/0/p
Normal file
29
etc/templates/closedVolume/0/p
Normal file
@ -0,0 +1,29 @@
|
||||
/*--------------------------------*- 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;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
31
etc/templates/closedVolume/0/p_rgh
Normal file
31
etc/templates/closedVolume/0/p_rgh
Normal file
@ -0,0 +1,31 @@
|
||||
/*--------------------------------*- 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;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type fixedFluxPressure;
|
||||
rho rhok;
|
||||
value $internalField;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
24
etc/templates/closedVolume/README
Normal file
24
etc/templates/closedVolume/README
Normal file
@ -0,0 +1,24 @@
|
||||
Overview
|
||||
=======
|
||||
+ This is a template case for a closed volume
|
||||
+ Setup to run buoyantBoussinesqSimpleFoam
|
||||
+ The case is designed to be meshed with snappyHexMesh
|
||||
+ snappyHexMesh is setup to use a single trisurface file named CAD.obj
|
||||
+ Copy the CAD.obj file to the constant/triSurface directory
|
||||
+ The CAD.obj can contain one or more regions to create patches in the mesh
|
||||
+ The user can then specify different boundary condition on T on these patches
|
||||
|
||||
Meshing
|
||||
=======
|
||||
+ Meshing is setup as in the inflowOutflow template
|
||||
+ See $FOAM_ETC/templates/inflowOutflow/README for details
|
||||
+ The setup includes an example for one named patch to be generated in the mesh
|
||||
+ In snappyHexMeshDict, replace <CADregionName> with the name of region in the
|
||||
trisurface; replace <patchName> with the name of the resulting mesh patch
|
||||
|
||||
Initialisation
|
||||
==============
|
||||
+ In the field files in the 0 directory, set initial values
|
||||
+ The template includes a fixedValue boundary condition on <patchName> in 0/T
|
||||
+ The user can replace <patchName> with a real mesh patch name and apply a
|
||||
fixed temperature on that patch
|
||||
23
etc/templates/closedVolume/constant/RASProperties
Normal file
23
etc/templates/closedVolume/constant/RASProperties
Normal file
@ -0,0 +1,23 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object RASProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
RASModel kEpsilon;
|
||||
|
||||
turbulence on;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
// ************************************************************************* //
|
||||
20
etc/templates/closedVolume/constant/g
Normal file
20
etc/templates/closedVolume/constant/g
Normal file
@ -0,0 +1,20 @@
|
||||
/*--------------------------------*- 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 uniformDimensionedVectorField;
|
||||
object g;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 1 -2 0 0 0 0];
|
||||
value ( 0 -9.81 0 );
|
||||
|
||||
// ************************************************************************* //
|
||||
68
etc/templates/closedVolume/constant/polyMesh/blockMeshDict
Normal file
68
etc/templates/closedVolume/constant/polyMesh/blockMeshDict
Normal file
@ -0,0 +1,68 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
backgroundMesh
|
||||
{
|
||||
xMin -1;
|
||||
xMax 1;
|
||||
yMin -1;
|
||||
yMax 1;
|
||||
zMin -1;
|
||||
zMax 1;
|
||||
xCells 20;
|
||||
yCells 20;
|
||||
zCells 20;
|
||||
}
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7)
|
||||
(
|
||||
$:backgroundMesh.xCells
|
||||
$:backgroundMesh.yCells
|
||||
$:backgroundMesh.zCells
|
||||
)
|
||||
simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
boundary
|
||||
(
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
34
etc/templates/closedVolume/constant/transportProperties
Normal file
34
etc/templates/closedVolume/constant/transportProperties
Normal file
@ -0,0 +1,34 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object transportProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
transportModel Newtonian;
|
||||
|
||||
// Laminar viscosity
|
||||
nu nu [0 2 -1 0 0 0 0] 1e-05;
|
||||
|
||||
// Thermal expansion coefficient
|
||||
beta beta [0 0 0 -1 0 0 0] 3e-03;
|
||||
|
||||
// Reference temperature
|
||||
TRef TRef [0 0 0 1 0 0 0] 300;
|
||||
|
||||
// Laminar Prandtl number
|
||||
Pr Pr [0 0 0 0 0 0 0] 0.9;
|
||||
|
||||
// Turbulent Prandtl number
|
||||
Prt Prt [0 0 0 0 0 0 0] 0.7;
|
||||
|
||||
// ************************************************************************* //
|
||||
19
etc/templates/closedVolume/constant/turbulenceProperties
Normal file
19
etc/templates/closedVolume/constant/turbulenceProperties
Normal file
@ -0,0 +1,19 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object turbulenceProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
simulationType RASModel;
|
||||
|
||||
// ************************************************************************* //
|
||||
55
etc/templates/closedVolume/system/controlDict
Normal file
55
etc/templates/closedVolume/system/controlDict
Normal file
@ -0,0 +1,55 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application buoyantBoussinesqSimpleFoam;
|
||||
|
||||
startFrom latestTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 1000;
|
||||
|
||||
deltaT 1;
|
||||
|
||||
writeControl timeStep;
|
||||
|
||||
writeInterval 50;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 8;
|
||||
|
||||
writeCompression off;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable true;
|
||||
|
||||
// adjustTimeStep yes;
|
||||
|
||||
// maxCo 1;
|
||||
|
||||
functions
|
||||
{
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
69
etc/templates/closedVolume/system/fvSchemes
Normal file
69
etc/templates/closedVolume/system/fvSchemes
Normal file
@ -0,0 +1,69 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSchemes;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
ddtSchemes
|
||||
{
|
||||
default steadyState;
|
||||
}
|
||||
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
|
||||
limited cellLimited Gauss linear 1;
|
||||
grad(U) $limited;
|
||||
grad(k) $limited;
|
||||
grad(omega) $limited;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default none;
|
||||
|
||||
div(phi,U) bounded Gauss linearUpwind limited;
|
||||
|
||||
turbulence bounded Gauss limitedLinear 1;
|
||||
div(phi,k) $turbulence;
|
||||
div(phi,omega) $turbulence;
|
||||
div(phi,epsilon) $turbulence;
|
||||
|
||||
div(phi,T) $turbulence;
|
||||
|
||||
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
{
|
||||
default corrected;
|
||||
}
|
||||
|
||||
fluxRequired
|
||||
{
|
||||
default no;
|
||||
p_rgh ;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
95
etc/templates/closedVolume/system/fvSolution
Normal file
95
etc/templates/closedVolume/system/fvSolution
Normal file
@ -0,0 +1,95 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSolution;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvers
|
||||
{
|
||||
p_rgh
|
||||
{
|
||||
solver GAMG;
|
||||
smoother GaussSeidel;
|
||||
cacheAgglomeration on; // Need to make this default?
|
||||
agglomerator faceAreaPair; // Need to make this default?
|
||||
nCellsInCoarsestLevel 10; // Need to make this default?
|
||||
mergeLevels 1; // Need to make this default
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
"(U|T|k|omega|epsilon)"
|
||||
{
|
||||
solver smoothSolver;
|
||||
smoother symGaussSeidel;
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
p_rghFinal
|
||||
{
|
||||
$p;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)Final"
|
||||
{
|
||||
$U;
|
||||
relTol 0;
|
||||
}
|
||||
}
|
||||
|
||||
"(PIMPLE|PISO)"
|
||||
{
|
||||
nOuterCorrectors 1;
|
||||
nCorrectors 2;
|
||||
nNonOrthogonalCorrectors 1;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
|
||||
SIMPLE
|
||||
{
|
||||
residualControl
|
||||
{
|
||||
p 1e-4;
|
||||
U 1e-4;
|
||||
T 1e-4;
|
||||
"(k|omega|epsilon)" 1e-4;
|
||||
}
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
|
||||
}
|
||||
|
||||
potentialFlow
|
||||
{
|
||||
nNonOrthogonalCorrectors 10;
|
||||
}
|
||||
|
||||
relaxationFactors
|
||||
{
|
||||
fields
|
||||
{
|
||||
p_rgh 0.7;
|
||||
}
|
||||
equations
|
||||
{
|
||||
U 0.3;
|
||||
T 0.5;
|
||||
"(k|omega|epsilon)" 0.7;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
22
etc/templates/closedVolume/system/meshQualityDict
Normal file
22
etc/templates/closedVolume/system/meshQualityDict
Normal file
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object meshQualityDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/meshQualityDict.cfg"
|
||||
|
||||
//- minFaceWeight (0 -> 0.5)
|
||||
//minFaceWeight 0.02;
|
||||
|
||||
// ************************************************************************* //
|
||||
104
etc/templates/closedVolume/system/snappyHexMeshDict
Normal file
104
etc/templates/closedVolume/system/snappyHexMeshDict
Normal file
@ -0,0 +1,104 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object snappyHexMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/snappyHexMeshDict.cfg"
|
||||
|
||||
castellatedMesh on;
|
||||
snap off;
|
||||
addLayers off;
|
||||
|
||||
geometry
|
||||
{
|
||||
CAD.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name CAD;
|
||||
regions
|
||||
{
|
||||
<CADregionName> { name <patchName>; }
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
castellatedMeshControls
|
||||
{
|
||||
features
|
||||
(
|
||||
// { file "CAD.eMesh"; level 1; }
|
||||
);
|
||||
|
||||
refinementSurfaces
|
||||
{
|
||||
CAD
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type wall; }
|
||||
}
|
||||
}
|
||||
|
||||
refinementRegions
|
||||
{
|
||||
CAD
|
||||
{
|
||||
mode inside;
|
||||
levels ((1E15 2));
|
||||
}
|
||||
}
|
||||
|
||||
locationInMesh (1e-5 1e-5 1e-5); // Offset from (0 0 0) to avoid
|
||||
// coinciding with face or edge
|
||||
}
|
||||
|
||||
snapControls
|
||||
{
|
||||
// explicitFeatureSnap true;
|
||||
// implicitFeatureSnap false;
|
||||
}
|
||||
|
||||
addLayersControls
|
||||
{
|
||||
layers
|
||||
{
|
||||
"CAD.*"
|
||||
{
|
||||
nSurfaceLayers 2;
|
||||
}
|
||||
}
|
||||
|
||||
relativeSizes true; // false, usually with firstLayerThickness
|
||||
expansionRatio 1.2;
|
||||
finalLayerThickness 0.5;
|
||||
minThickness 1e-3;
|
||||
// firstLayerThickness 0.01;
|
||||
|
||||
// maxThicknessToMedialRatio 0.6;
|
||||
}
|
||||
|
||||
meshQualityControls
|
||||
{
|
||||
// minTetQuality -1e+30;
|
||||
}
|
||||
|
||||
writeFlags
|
||||
(
|
||||
scalarLevels
|
||||
layerSets
|
||||
layerFields
|
||||
);
|
||||
|
||||
mergeTolerance 1e-6;
|
||||
|
||||
// ************************************************************************* //
|
||||
35
etc/templates/closedVolume/system/surfaceFeatureExtractDict
Normal file
35
etc/templates/closedVolume/system/surfaceFeatureExtractDict
Normal file
@ -0,0 +1,35 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object surfaceFeatureExtractDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
CAD.obj
|
||||
{
|
||||
extractionMethod extractFromSurface;
|
||||
|
||||
extractFromSurfaceCoeffs
|
||||
{
|
||||
includedAngle 150;
|
||||
}
|
||||
|
||||
subsetFeatures
|
||||
{
|
||||
nonManifoldEdges yes;
|
||||
openEdges yes;
|
||||
}
|
||||
|
||||
writeObj yes;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
35
etc/templates/closedVolumeRotating/0/U
Normal file
35
etc/templates/closedVolumeRotating/0/U
Normal file
@ -0,0 +1,35 @@
|
||||
/*--------------------------------*- 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
|
||||
{
|
||||
rotating
|
||||
{
|
||||
type movingWallVelocity;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
wall
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
32
etc/templates/closedVolumeRotating/0/k
Normal file
32
etc/templates/closedVolumeRotating/0/k
Normal file
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- 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;
|
||||
object k;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
kInitial 0.1;
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform $kInitial;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type kqRWallFunction;
|
||||
value uniform $kInitial;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
30
etc/templates/closedVolumeRotating/0/nut
Normal file
30
etc/templates/closedVolumeRotating/0/nut
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- 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;
|
||||
object nut;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type nutkWallFunction;
|
||||
value uniform 0;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
32
etc/templates/closedVolumeRotating/0/omega
Normal file
32
etc/templates/closedVolumeRotating/0/omega
Normal file
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- 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;
|
||||
object omega;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
omegaInitial 1.0;
|
||||
|
||||
dimensions [0 0 -1 0 0 0 0];
|
||||
|
||||
internalField uniform $omegaInitial;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type omegaWallFunction;
|
||||
value uniform $omegaInitial;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
29
etc/templates/closedVolumeRotating/0/p
Normal file
29
etc/templates/closedVolumeRotating/0/p
Normal file
@ -0,0 +1,29 @@
|
||||
/*--------------------------------*- 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;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
7
etc/templates/closedVolumeRotating/README
Normal file
7
etc/templates/closedVolumeRotating/README
Normal file
@ -0,0 +1,7 @@
|
||||
Overview
|
||||
========
|
||||
+ Template case for rotating geometry flow for a closed geometry
|
||||
+ Can be used for MRF or AMI simulations
|
||||
+ Setup to run the simpleFoam solver
|
||||
+ Set up is like inflowOutflowRotating but without inlet and outlet
|
||||
+ See $FOAM_ETC/templates/closedVolumeRotating/README for details of use
|
||||
23
etc/templates/closedVolumeRotating/constant/RASProperties
Normal file
23
etc/templates/closedVolumeRotating/constant/RASProperties
Normal file
@ -0,0 +1,23 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object RASProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
RASModel kOmegaSST;
|
||||
|
||||
turbulence on;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
// ************************************************************************* //
|
||||
30
etc/templates/closedVolumeRotating/constant/dynamicMeshDict
Normal file
30
etc/templates/closedVolumeRotating/constant/dynamicMeshDict
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object dynamicMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dynamicFvMesh solidBodyMotionFvMesh;
|
||||
|
||||
solidBodyMotionFvMeshCoeffs
|
||||
{
|
||||
cellZone rotatingZone;
|
||||
|
||||
solidBodyMotionFunction rotatingMotion;
|
||||
rotatingMotionCoeffs
|
||||
{
|
||||
#include "rotatingZoneProperties"
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,68 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
backgroundMesh
|
||||
{
|
||||
xMin -1;
|
||||
xMax 1;
|
||||
yMin -1;
|
||||
yMax 1;
|
||||
zMin -1;
|
||||
zMax 1;
|
||||
xCells 20;
|
||||
yCells 20;
|
||||
zCells 20;
|
||||
}
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7)
|
||||
(
|
||||
$:backgroundMesh.xCells
|
||||
$:backgroundMesh.yCells
|
||||
$:backgroundMesh.zCells
|
||||
)
|
||||
simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
boundary
|
||||
(
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object rotatingZoneProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
origin (0 0 0);
|
||||
axis (0 0 1);
|
||||
omega constant <rad/s>;
|
||||
nonRotatingPatches (fixed);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,21 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object transportProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
transportModel Newtonian;
|
||||
|
||||
nu nu [ 0 2 -1 0 0 0 0 ] 1.5e-05;
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,19 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object turbulenceProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
simulationType RASModel;
|
||||
|
||||
// ************************************************************************* //
|
||||
55
etc/templates/closedVolumeRotating/system/controlDict
Normal file
55
etc/templates/closedVolumeRotating/system/controlDict
Normal file
@ -0,0 +1,55 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application simpleFoam;
|
||||
|
||||
startFrom latestTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 1000;
|
||||
|
||||
deltaT 1;
|
||||
|
||||
writeControl timeStep;
|
||||
|
||||
writeInterval 50;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 8;
|
||||
|
||||
writeCompression off;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable true;
|
||||
|
||||
// adjustTimeStep yes;
|
||||
|
||||
// maxCo 1;
|
||||
|
||||
functions
|
||||
{
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
46
etc/templates/closedVolumeRotating/system/createBafflesDict
Normal file
46
etc/templates/closedVolumeRotating/system/createBafflesDict
Normal file
@ -0,0 +1,46 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object createBafflesDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
internalFacesOnly true;
|
||||
|
||||
baffles
|
||||
{
|
||||
baffleFaces
|
||||
{
|
||||
type faceZone;
|
||||
zoneName rotatingZone;
|
||||
|
||||
patches
|
||||
{
|
||||
master
|
||||
{
|
||||
name AMI1;
|
||||
type cyclicAMI;
|
||||
matchTolerance 0.0001;
|
||||
neighbourPatch AMI2;
|
||||
transform noOrdering;
|
||||
}
|
||||
slave
|
||||
{
|
||||
$master;
|
||||
name AMI2;
|
||||
neighbourPatch AMI1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
30
etc/templates/closedVolumeRotating/system/fvOptions
Normal file
30
etc/templates/closedVolumeRotating/system/fvOptions
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvOptions;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
MRF1
|
||||
{
|
||||
type MRFSource;
|
||||
selectionMode cellZone;
|
||||
cellZone rotatingZone;
|
||||
active yes;
|
||||
|
||||
MRFSourceCoeffs
|
||||
{
|
||||
#include "${FOAM_CASE}/constant/rotatingZoneProperties"
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
67
etc/templates/closedVolumeRotating/system/fvSchemes
Normal file
67
etc/templates/closedVolumeRotating/system/fvSchemes
Normal file
@ -0,0 +1,67 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSchemes;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
ddtSchemes
|
||||
{
|
||||
default steadyState;
|
||||
}
|
||||
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
|
||||
limited cellLimited Gauss linear 1;
|
||||
grad(U) $limited;
|
||||
grad(k) $limited;
|
||||
grad(omega) $limited;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default none;
|
||||
|
||||
div(phi,U) bounded Gauss linearUpwind limited;
|
||||
|
||||
turbulence bounded Gauss limitedLinear 1;
|
||||
div(phi,k) $turbulence;
|
||||
div(phi,omega) $turbulence;
|
||||
div(phi,epsilon) $turbulence;
|
||||
|
||||
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
{
|
||||
default corrected;
|
||||
}
|
||||
|
||||
fluxRequired
|
||||
{
|
||||
default no;
|
||||
p ;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
93
etc/templates/closedVolumeRotating/system/fvSolution
Normal file
93
etc/templates/closedVolumeRotating/system/fvSolution
Normal file
@ -0,0 +1,93 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSolution;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvers
|
||||
{
|
||||
p
|
||||
{
|
||||
solver GAMG;
|
||||
smoother GaussSeidel;
|
||||
cacheAgglomeration on; // Need to make this default?
|
||||
agglomerator faceAreaPair; // Need to make this default?
|
||||
nCellsInCoarsestLevel 10; // Need to make this default?
|
||||
mergeLevels 1; // Need to make this default
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)"
|
||||
{
|
||||
solver smoothSolver;
|
||||
smoother symGaussSeidel;
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
pFinal
|
||||
{
|
||||
$p;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)Final"
|
||||
{
|
||||
$U;
|
||||
relTol 0;
|
||||
}
|
||||
}
|
||||
|
||||
"(PIMPLE|PISO)"
|
||||
{
|
||||
nOuterCorrectors 1;
|
||||
nCorrectors 2;
|
||||
nNonOrthogonalCorrectors 1;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
|
||||
SIMPLE
|
||||
{
|
||||
residualControl
|
||||
{
|
||||
p 1e-4;
|
||||
U 1e-4;
|
||||
"(k|omega|epsilon)" 1e-4;
|
||||
}
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
|
||||
}
|
||||
|
||||
potentialFlow
|
||||
{
|
||||
nNonOrthogonalCorrectors 10;
|
||||
}
|
||||
|
||||
relaxationFactors
|
||||
{
|
||||
fields
|
||||
{
|
||||
p 0.3;
|
||||
}
|
||||
equations
|
||||
{
|
||||
U 0.7;
|
||||
"(k|omega|epsilon)" 0.7;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
22
etc/templates/closedVolumeRotating/system/meshQualityDict
Normal file
22
etc/templates/closedVolumeRotating/system/meshQualityDict
Normal file
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object meshQualityDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/meshQualityDict.cfg"
|
||||
|
||||
//- minFaceWeight (0 -> 0.5)
|
||||
//minFaceWeight 0.02;
|
||||
|
||||
// ************************************************************************* //
|
||||
126
etc/templates/closedVolumeRotating/system/snappyHexMeshDict
Normal file
126
etc/templates/closedVolumeRotating/system/snappyHexMeshDict
Normal file
@ -0,0 +1,126 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object snappyHexMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/snappyHexMeshDict.cfg"
|
||||
|
||||
castellatedMesh on;
|
||||
snap on;
|
||||
addLayers off;
|
||||
|
||||
geometry
|
||||
{
|
||||
fixed.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name fixed;
|
||||
}
|
||||
rotating.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name rotating;
|
||||
}
|
||||
rotatingZone.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name rotatingZone;
|
||||
}
|
||||
};
|
||||
|
||||
castellatedMeshControls
|
||||
{
|
||||
features
|
||||
(
|
||||
{ file "fixed.eMesh"; level 1; }
|
||||
{ file "rotating.eMesh"; level 1; }
|
||||
{ file "rotatingZone.eMesh"; level 1; }
|
||||
);
|
||||
|
||||
refinementSurfaces
|
||||
{
|
||||
fixed
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type wall; }
|
||||
}
|
||||
rotating
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type wall; }
|
||||
}
|
||||
rotatingZone
|
||||
{
|
||||
level (2 2);
|
||||
faceZone rotatingZone;
|
||||
cellZone rotatingZone;
|
||||
cellZoneInside inside;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
refinementRegions
|
||||
{
|
||||
/*
|
||||
rotatingZone
|
||||
{
|
||||
mode inside;
|
||||
levels ((1E15 2));
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
locationInMesh (1e-5 1e-5 1e-5); // Offset from (0 0 0) to avoid
|
||||
// coinciding with face or edge
|
||||
}
|
||||
|
||||
snapControls
|
||||
{
|
||||
explicitFeatureSnap true;
|
||||
}
|
||||
|
||||
addLayersControls
|
||||
{
|
||||
layers
|
||||
{
|
||||
"(rotating|fixed)"
|
||||
{
|
||||
nSurfaceLayers 2;
|
||||
}
|
||||
}
|
||||
|
||||
relativeSizes true; // false, usually with firstLayerThickness
|
||||
expansionRatio 1.2;
|
||||
finalLayerThickness 0.5;
|
||||
minThickness 1e-3;
|
||||
// firstLayerThickness 0.01;
|
||||
|
||||
// maxThicknessToMedialRatio 0.6;
|
||||
}
|
||||
|
||||
meshQualityControls
|
||||
{
|
||||
// minTetQuality -1e+30;
|
||||
}
|
||||
|
||||
writeFlags
|
||||
(
|
||||
scalarLevels
|
||||
layerSets
|
||||
layerFields
|
||||
);
|
||||
|
||||
mergeTolerance 1e-6;
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,32 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object surfaceFeatureExtractDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
fixed.obj
|
||||
{
|
||||
#includeEtc "caseDicts/surface/surfaceFeatureExtractDict.cfg"
|
||||
}
|
||||
|
||||
rotating.obj
|
||||
{
|
||||
#includeEtc "caseDicts/surface/surfaceFeatureExtractDict.cfg"
|
||||
}
|
||||
|
||||
rotatingZone.obj
|
||||
{
|
||||
#includeEtc "caseDicts/surface/surfaceFeatureExtractDict.cfg"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
46
etc/templates/inflowOutflow/0/U
Normal file
46
etc/templates/inflowOutflow/0/U
Normal file
@ -0,0 +1,46 @@
|
||||
/*--------------------------------*- 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;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
Uinlet (10 0 0);
|
||||
|
||||
dimensions [0 1 -1 0 0 0 0];
|
||||
|
||||
internalField uniform (0 0 0);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform $Uinlet;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type pressureInletOutletVelocity;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
47
etc/templates/inflowOutflow/0/k
Normal file
47
etc/templates/inflowOutflow/0/k
Normal file
@ -0,0 +1,47 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object k;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
kInlet 0.1;
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform $kInlet;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type inletOutlet;
|
||||
inletValue uniform $kInlet;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type kqRWallFunction;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
44
etc/templates/inflowOutflow/0/nut
Normal file
44
etc/templates/inflowOutflow/0/nut
Normal file
@ -0,0 +1,44 @@
|
||||
/*--------------------------------*- 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;
|
||||
object nut;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type nutkWallFunction;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
47
etc/templates/inflowOutflow/0/omega
Normal file
47
etc/templates/inflowOutflow/0/omega
Normal file
@ -0,0 +1,47 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object omega;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
omegaInlet 1.0;
|
||||
|
||||
dimensions [0 0 -1 0 0 0 0];
|
||||
|
||||
internalField uniform $omegaInlet;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform $omegaInlet;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type inletOutlet;
|
||||
inletValue uniform $omegaInlet;
|
||||
value uniform $omegaInlet;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type omegaWallFunction;
|
||||
value uniform $omegaInlet;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
42
etc/templates/inflowOutflow/0/p
Normal file
42
etc/templates/inflowOutflow/0/p
Normal file
@ -0,0 +1,42 @@
|
||||
/*--------------------------------*- 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;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
54
etc/templates/inflowOutflow/README
Normal file
54
etc/templates/inflowOutflow/README
Normal file
@ -0,0 +1,54 @@
|
||||
Overview
|
||||
========
|
||||
+ This is a template case with single inlet and outlet
|
||||
+ Setup to run the simpleFoam solver
|
||||
+ The case is designed to be meshed with snappyHexMesh
|
||||
+ snappyHexMesh is setup to use a single trisurface file named CAD.obj
|
||||
+ Copy the CAD.obj file to the constant/triSurface directory
|
||||
+ The CAD.obj should contain an inlet and outlet region to create the relevant
|
||||
patches in the mesh
|
||||
|
||||
Background Mesh
|
||||
===============
|
||||
+ The user should establish the bounds of their CAD.obj file
|
||||
+ The blockMeshDict file contains a backgroundMesh subditionary
|
||||
+ Set xMin, xMax, etc to be beyond the CAD.obj bounds
|
||||
+ Set background mesh density with xCells, yCells, zCells
|
||||
+ Run blockMesh
|
||||
|
||||
Background Mesh (alternative)
|
||||
=============================
|
||||
+ The user can adopt the background mesh patches in the mesh
|
||||
+ For example, the background mesh can provide external patches of an external
|
||||
flow
|
||||
+ An alternative blockMeshDict file is set up for this: blockMeshDict.extPatches
|
||||
+ Simply copy blockMeshDict.extPatches to blockMeshDict and edit inlet, outlet
|
||||
patches accordingly
|
||||
|
||||
Castellated Mesh
|
||||
================
|
||||
+ In the snappyHexMeshDict file, replace <inletPatch> with the name of the inlet
|
||||
region in the CAD.obj file
|
||||
+ Replace <outletPatch> with the name of the outlet region
|
||||
+ run snappyHexMesh to obtain a castellatedMesh
|
||||
+ Review the mesh; modify refinement levels and regenerate the mesh as required
|
||||
(levels are set in refinementSurfaces and refinementRegions)
|
||||
|
||||
Snapped Mesh
|
||||
============
|
||||
+ In snappyHexMeshDict, set castellatedMesh off; snap on;
|
||||
+ Run the snapping phase of snappyHexMesh
|
||||
+ Review the mesh
|
||||
|
||||
Layers
|
||||
======
|
||||
+ To add layers to the mesh along wall boundary patches...
|
||||
+ Switch on addLayers; switch snap off;
|
||||
+ Run snappyHexMesh
|
||||
+ The number of layers can be changed by modifying nSurfaceLayers
|
||||
|
||||
Initialisation
|
||||
==============
|
||||
+ In the field files in the 0 directory, set inlet values
|
||||
+ For example, in 0/U, set the inlet velocity Uinlet
|
||||
+ Set the viscosity in constant/transportProperties
|
||||
23
etc/templates/inflowOutflow/constant/RASProperties
Normal file
23
etc/templates/inflowOutflow/constant/RASProperties
Normal file
@ -0,0 +1,23 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object RASProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
RASModel kOmegaSST;
|
||||
|
||||
turbulence on;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
// ************************************************************************* //
|
||||
68
etc/templates/inflowOutflow/constant/polyMesh/blockMeshDict
Normal file
68
etc/templates/inflowOutflow/constant/polyMesh/blockMeshDict
Normal file
@ -0,0 +1,68 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
backgroundMesh
|
||||
{
|
||||
xMin -1;
|
||||
xMax 1;
|
||||
yMin -1;
|
||||
yMax 1;
|
||||
zMin -1;
|
||||
zMax 1;
|
||||
xCells 20;
|
||||
yCells 20;
|
||||
zCells 20;
|
||||
}
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7)
|
||||
(
|
||||
$:backgroundMesh.xCells
|
||||
$:backgroundMesh.yCells
|
||||
$:backgroundMesh.zCells
|
||||
)
|
||||
simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
boundary
|
||||
(
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,121 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
backgroundMesh
|
||||
{
|
||||
xMin -1;
|
||||
xMax 1;
|
||||
yMin -1;
|
||||
yMax 1;
|
||||
zMin -1;
|
||||
zMax 1;
|
||||
xCells 20;
|
||||
yCells 20;
|
||||
zCells 20;
|
||||
}
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7)
|
||||
(
|
||||
$:backgroundMesh.xCells
|
||||
$:backgroundMesh.yCells
|
||||
$:backgroundMesh.zCells
|
||||
)
|
||||
simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
boundary
|
||||
(
|
||||
left
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(0 3 7 4)
|
||||
);
|
||||
}
|
||||
|
||||
right
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(1 5 6 2)
|
||||
);
|
||||
}
|
||||
|
||||
bottom
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(0 1 2 3)
|
||||
);
|
||||
}
|
||||
|
||||
top
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(4 7 6 5)
|
||||
);
|
||||
}
|
||||
|
||||
back
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(0 4 5 1)
|
||||
);
|
||||
}
|
||||
|
||||
front
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(3 2 6 7)
|
||||
);
|
||||
}
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
21
etc/templates/inflowOutflow/constant/transportProperties
Normal file
21
etc/templates/inflowOutflow/constant/transportProperties
Normal file
@ -0,0 +1,21 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object transportProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
transportModel Newtonian;
|
||||
|
||||
nu nu [ 0 2 -1 0 0 0 0 ] 1.5e-05;
|
||||
|
||||
// ************************************************************************* //
|
||||
19
etc/templates/inflowOutflow/constant/turbulenceProperties
Normal file
19
etc/templates/inflowOutflow/constant/turbulenceProperties
Normal file
@ -0,0 +1,19 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object turbulenceProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
simulationType RASModel;
|
||||
|
||||
// ************************************************************************* //
|
||||
55
etc/templates/inflowOutflow/system/controlDict
Normal file
55
etc/templates/inflowOutflow/system/controlDict
Normal file
@ -0,0 +1,55 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application simpleFoam;
|
||||
|
||||
startFrom latestTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 1000;
|
||||
|
||||
deltaT 1;
|
||||
|
||||
writeControl timeStep;
|
||||
|
||||
writeInterval 50;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 8;
|
||||
|
||||
writeCompression off;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable true;
|
||||
|
||||
// adjustTimeStep yes;
|
||||
|
||||
// maxCo 1;
|
||||
|
||||
functions
|
||||
{
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
67
etc/templates/inflowOutflow/system/fvSchemes
Normal file
67
etc/templates/inflowOutflow/system/fvSchemes
Normal file
@ -0,0 +1,67 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSchemes;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
ddtSchemes
|
||||
{
|
||||
default steadyState;
|
||||
}
|
||||
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
|
||||
limited cellLimited Gauss linear 1;
|
||||
grad(U) $limited;
|
||||
grad(k) $limited;
|
||||
grad(omega) $limited;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default none;
|
||||
|
||||
div(phi,U) bounded Gauss linearUpwind limited;
|
||||
|
||||
turbulence bounded Gauss limitedLinear 1;
|
||||
div(phi,k) $turbulence;
|
||||
div(phi,omega) $turbulence;
|
||||
div(phi,epsilon) $turbulence;
|
||||
|
||||
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
{
|
||||
default corrected;
|
||||
}
|
||||
|
||||
fluxRequired
|
||||
{
|
||||
default no;
|
||||
p ;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
93
etc/templates/inflowOutflow/system/fvSolution
Normal file
93
etc/templates/inflowOutflow/system/fvSolution
Normal file
@ -0,0 +1,93 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSolution;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvers
|
||||
{
|
||||
p
|
||||
{
|
||||
solver GAMG;
|
||||
smoother GaussSeidel;
|
||||
cacheAgglomeration on; // Need to make this default?
|
||||
agglomerator faceAreaPair; // Need to make this default?
|
||||
nCellsInCoarsestLevel 10; // Need to make this default?
|
||||
mergeLevels 1; // Need to make this default
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)"
|
||||
{
|
||||
solver smoothSolver;
|
||||
smoother symGaussSeidel;
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
pFinal
|
||||
{
|
||||
$p;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)Final"
|
||||
{
|
||||
$U;
|
||||
relTol 0;
|
||||
}
|
||||
}
|
||||
|
||||
"(PIMPLE|PISO)"
|
||||
{
|
||||
nOuterCorrectors 1;
|
||||
nCorrectors 2;
|
||||
nNonOrthogonalCorrectors 1;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
|
||||
SIMPLE
|
||||
{
|
||||
residualControl
|
||||
{
|
||||
p 1e-4;
|
||||
U 1e-4;
|
||||
"(k|omega|epsilon)" 1e-4;
|
||||
}
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
|
||||
}
|
||||
|
||||
potentialFlow
|
||||
{
|
||||
nNonOrthogonalCorrectors 10;
|
||||
}
|
||||
|
||||
relaxationFactors
|
||||
{
|
||||
fields
|
||||
{
|
||||
p 0.3;
|
||||
}
|
||||
equations
|
||||
{
|
||||
U 0.7;
|
||||
"(k|omega|epsilon)" 0.7;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
22
etc/templates/inflowOutflow/system/meshQualityDict
Normal file
22
etc/templates/inflowOutflow/system/meshQualityDict
Normal file
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object meshQualityDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/meshQualityDict.cfg"
|
||||
|
||||
//- minFaceWeight (0 -> 0.5)
|
||||
//minFaceWeight 0.02;
|
||||
|
||||
// ************************************************************************* //
|
||||
120
etc/templates/inflowOutflow/system/snappyHexMeshDict
Normal file
120
etc/templates/inflowOutflow/system/snappyHexMeshDict
Normal file
@ -0,0 +1,120 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object snappyHexMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/snappyHexMeshDict.cfg"
|
||||
|
||||
castellatedMesh on;
|
||||
snap off;
|
||||
addLayers off;
|
||||
|
||||
geometry
|
||||
{
|
||||
CAD.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name CAD;
|
||||
regions
|
||||
{
|
||||
<inletPatch> { name inlet; }
|
||||
<outletPatch> { name outlet; }
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
castellatedMeshControls
|
||||
{
|
||||
features
|
||||
(
|
||||
// { file "CAD.eMesh"; level 1; }
|
||||
);
|
||||
|
||||
refinementSurfaces
|
||||
{
|
||||
CAD
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type wall; }
|
||||
|
||||
regions
|
||||
{
|
||||
<inletPatch>
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type patch; }
|
||||
}
|
||||
|
||||
<outletPatch>
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type patch; }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
refinementRegions
|
||||
{
|
||||
CAD
|
||||
{
|
||||
mode inside;
|
||||
levels ((1E15 2));
|
||||
}
|
||||
}
|
||||
|
||||
locationInMesh (1e-5 1e-5 1e-5); // Offset from (0 0 0) to avoid
|
||||
// coinciding with face or edge
|
||||
}
|
||||
|
||||
snapControls
|
||||
{
|
||||
// explicitFeatureSnap true;
|
||||
// implicitFeatureSnap false;
|
||||
}
|
||||
|
||||
addLayersControls
|
||||
{
|
||||
layers
|
||||
{
|
||||
"CAD.*"
|
||||
{
|
||||
nSurfaceLayers 2;
|
||||
}
|
||||
}
|
||||
|
||||
relativeSizes true; // false, usually with firstLayerThickness
|
||||
expansionRatio 1.2;
|
||||
finalLayerThickness 0.5;
|
||||
minThickness 1e-3;
|
||||
// firstLayerThickness 0.01;
|
||||
|
||||
// maxThicknessToMedialRatio 0.6;
|
||||
}
|
||||
|
||||
meshQualityControls
|
||||
{
|
||||
// minTetQuality -1e+30;
|
||||
}
|
||||
|
||||
writeFlags
|
||||
(
|
||||
scalarLevels
|
||||
layerSets
|
||||
layerFields
|
||||
);
|
||||
|
||||
mergeTolerance 1e-6;
|
||||
|
||||
// ************************************************************************* //
|
||||
35
etc/templates/inflowOutflow/system/surfaceFeatureExtractDict
Normal file
35
etc/templates/inflowOutflow/system/surfaceFeatureExtractDict
Normal file
@ -0,0 +1,35 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object surfaceFeatureExtractDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
CAD.obj
|
||||
{
|
||||
extractionMethod extractFromSurface;
|
||||
|
||||
extractFromSurfaceCoeffs
|
||||
{
|
||||
includedAngle 150;
|
||||
}
|
||||
|
||||
subsetFeatures
|
||||
{
|
||||
nonManifoldEdges yes;
|
||||
openEdges yes;
|
||||
}
|
||||
|
||||
writeObj yes;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
52
etc/templates/inflowOutflowRotating/0/U
Normal file
52
etc/templates/inflowOutflowRotating/0/U
Normal file
@ -0,0 +1,52 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volVectorField;
|
||||
object U;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
Uinlet (10 0 0);
|
||||
|
||||
dimensions [0 1 -1 0 0 0 0];
|
||||
|
||||
internalField uniform (0 0 0);
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform $Uinlet;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type pressureInletOutletVelocity;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
|
||||
rotating
|
||||
{
|
||||
type movingWallVelocity;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform (0 0 0);
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
47
etc/templates/inflowOutflowRotating/0/k
Normal file
47
etc/templates/inflowOutflowRotating/0/k
Normal file
@ -0,0 +1,47 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object k;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
kInlet 0.1;
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform $kInlet;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type inletOutlet;
|
||||
inletValue uniform $kInlet;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type kqRWallFunction;
|
||||
value uniform $kInlet;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
44
etc/templates/inflowOutflowRotating/0/nut
Normal file
44
etc/templates/inflowOutflowRotating/0/nut
Normal file
@ -0,0 +1,44 @@
|
||||
/*--------------------------------*- 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;
|
||||
object nut;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -1 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type calculated;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type nutkWallFunction;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
47
etc/templates/inflowOutflowRotating/0/omega
Normal file
47
etc/templates/inflowOutflowRotating/0/omega
Normal file
@ -0,0 +1,47 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class volScalarField;
|
||||
object omega;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
omegaInlet 1.0;
|
||||
|
||||
dimensions [0 0 -1 0 0 0 0];
|
||||
|
||||
internalField uniform $omegaInlet;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform $omegaInlet;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type inletOutlet;
|
||||
inletValue uniform $omegaInlet;
|
||||
value uniform $omegaInlet;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type omegaWallFunction;
|
||||
value uniform $omegaInlet;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
42
etc/templates/inflowOutflowRotating/0/p
Normal file
42
etc/templates/inflowOutflowRotating/0/p
Normal file
@ -0,0 +1,42 @@
|
||||
/*--------------------------------*- 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;
|
||||
object p;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dimensions [0 2 -2 0 0 0 0];
|
||||
|
||||
internalField uniform 0;
|
||||
|
||||
boundaryField
|
||||
{
|
||||
inlet
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
outlet
|
||||
{
|
||||
type fixedValue;
|
||||
value uniform 0;
|
||||
}
|
||||
|
||||
wall
|
||||
{
|
||||
type zeroGradient;
|
||||
}
|
||||
|
||||
#includeEtc "caseDicts/setConstraintTypes"
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
32
etc/templates/inflowOutflowRotating/README
Normal file
32
etc/templates/inflowOutflowRotating/README
Normal file
@ -0,0 +1,32 @@
|
||||
Overview
|
||||
========
|
||||
+ Template case for rotating geometry flow with single inlet and outlet
|
||||
+ Can be used for MRF or AMI simulations
|
||||
+ Setup to run the simpleFoam solver for MRF, pimpleDyMFoam for AMI
|
||||
+ The case is designed to be meshed with snappyHexMesh
|
||||
+ snappyHexMesh is setup to use 3 trisurface files
|
||||
+ fixed.obj: CAD of the stationary geometry
|
||||
+ rotating.obj: CAD of the rotating geometry
|
||||
+ rotatingZone.obj: CAD of surface bounding the rotating region
|
||||
+ Copy the *.obj files to the constant/triSurface directory
|
||||
+ The fixed.obj should contain an inlet and outlet region to create the relevant
|
||||
patches in the mesh
|
||||
|
||||
Meshing
|
||||
=======
|
||||
+ Meshing is setup as in the inflowOutflow template
|
||||
+ See $FOAM_ETC/templates/inflowOutflow/README for details
|
||||
+ For AMI, the AMI interface can be set up by running createBaffles which uses
|
||||
the createBafflesDict file
|
||||
|
||||
Initialisation
|
||||
==============
|
||||
+ In the field files in the 0 directory, set inlet values
|
||||
+ For example, in 0/U, set the inlet velocity Uinlet
|
||||
+ Set the viscosity in constant/transportProperties
|
||||
+ Rotating properties are set in constant/rotatingZoneProperties
|
||||
+ For MRF, this file is included from system/fvOptions
|
||||
+ For AMI, this file is included from constant/dynamicMeshDict
|
||||
+ Ensure settings are appropriate in controlDict, fvSchemes, fvSolution, for
|
||||
relevant simulation; for AMI, in particular, ensure that deltaT, ddtSchemes
|
||||
and relaxationFactors are set for transient simulation
|
||||
23
etc/templates/inflowOutflowRotating/constant/RASProperties
Normal file
23
etc/templates/inflowOutflowRotating/constant/RASProperties
Normal file
@ -0,0 +1,23 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object RASProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
RASModel kOmegaSST;
|
||||
|
||||
turbulence on;
|
||||
|
||||
printCoeffs on;
|
||||
|
||||
// ************************************************************************* //
|
||||
30
etc/templates/inflowOutflowRotating/constant/dynamicMeshDict
Normal file
30
etc/templates/inflowOutflowRotating/constant/dynamicMeshDict
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object dynamicMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
dynamicFvMesh solidBodyMotionFvMesh;
|
||||
|
||||
solidBodyMotionFvMeshCoeffs
|
||||
{
|
||||
cellZone rotatingZone;
|
||||
|
||||
solidBodyMotionFunction rotatingMotion;
|
||||
rotatingMotionCoeffs
|
||||
{
|
||||
#include "rotatingZoneProperties"
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,68 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
backgroundMesh
|
||||
{
|
||||
xMin -1;
|
||||
xMax 1;
|
||||
yMin -1;
|
||||
yMax 1;
|
||||
zMin -1;
|
||||
zMax 1;
|
||||
xCells 20;
|
||||
yCells 20;
|
||||
zCells 20;
|
||||
}
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7)
|
||||
(
|
||||
$:backgroundMesh.xCells
|
||||
$:backgroundMesh.yCells
|
||||
$:backgroundMesh.zCells
|
||||
)
|
||||
simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
boundary
|
||||
(
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,121 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object blockMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
backgroundMesh
|
||||
{
|
||||
xMin -1;
|
||||
xMax 1;
|
||||
yMin -1;
|
||||
yMax 1;
|
||||
zMin -1;
|
||||
zMax 1;
|
||||
xCells 20;
|
||||
yCells 20;
|
||||
zCells 20;
|
||||
}
|
||||
|
||||
convertToMeters 1;
|
||||
|
||||
vertices
|
||||
(
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMin)
|
||||
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMin $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMax $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
($:backgroundMesh.xMin $:backgroundMesh.yMax $:backgroundMesh.zMax)
|
||||
);
|
||||
|
||||
blocks
|
||||
(
|
||||
hex (0 1 2 3 4 5 6 7)
|
||||
(
|
||||
$:backgroundMesh.xCells
|
||||
$:backgroundMesh.yCells
|
||||
$:backgroundMesh.zCells
|
||||
)
|
||||
simpleGrading (1 1 1)
|
||||
);
|
||||
|
||||
edges
|
||||
(
|
||||
);
|
||||
|
||||
boundary
|
||||
(
|
||||
left
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(0 3 7 4)
|
||||
);
|
||||
}
|
||||
|
||||
right
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(1 5 6 2)
|
||||
);
|
||||
}
|
||||
|
||||
bottom
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(0 1 2 3)
|
||||
);
|
||||
}
|
||||
|
||||
top
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(4 7 6 5)
|
||||
);
|
||||
}
|
||||
|
||||
back
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(0 4 5 1)
|
||||
);
|
||||
}
|
||||
|
||||
front
|
||||
{
|
||||
type patch;
|
||||
faces
|
||||
(
|
||||
(3 2 6 7)
|
||||
);
|
||||
}
|
||||
);
|
||||
|
||||
mergePatchPairs
|
||||
(
|
||||
);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object rotatingZoneProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
origin (0 0 0);
|
||||
axis (0 0 1);
|
||||
omega constant <rad/s>;
|
||||
nonRotatingPatches (fixed);
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,21 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object transportProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
transportModel Newtonian;
|
||||
|
||||
nu nu [ 0 2 -1 0 0 0 0 ] 1.5e-05;
|
||||
|
||||
// ************************************************************************* //
|
||||
@ -0,0 +1,19 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object turbulenceProperties;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
simulationType RASModel;
|
||||
|
||||
// ************************************************************************* //
|
||||
55
etc/templates/inflowOutflowRotating/system/controlDict
Normal file
55
etc/templates/inflowOutflowRotating/system/controlDict
Normal file
@ -0,0 +1,55 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object controlDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
application simpleFoam;
|
||||
|
||||
startFrom latestTime;
|
||||
|
||||
startTime 0;
|
||||
|
||||
stopAt endTime;
|
||||
|
||||
endTime 1000;
|
||||
|
||||
deltaT 1;
|
||||
|
||||
writeControl timeStep;
|
||||
|
||||
writeInterval 50;
|
||||
|
||||
purgeWrite 0;
|
||||
|
||||
writeFormat ascii;
|
||||
|
||||
writePrecision 8;
|
||||
|
||||
writeCompression off;
|
||||
|
||||
timeFormat general;
|
||||
|
||||
timePrecision 6;
|
||||
|
||||
runTimeModifiable true;
|
||||
|
||||
// adjustTimeStep yes;
|
||||
|
||||
// maxCo 1;
|
||||
|
||||
functions
|
||||
{
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
46
etc/templates/inflowOutflowRotating/system/createBafflesDict
Normal file
46
etc/templates/inflowOutflowRotating/system/createBafflesDict
Normal file
@ -0,0 +1,46 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object createBafflesDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
internalFacesOnly true;
|
||||
|
||||
baffles
|
||||
{
|
||||
baffleFaces
|
||||
{
|
||||
type faceZone;
|
||||
zoneName rotatingZone;
|
||||
|
||||
patches
|
||||
{
|
||||
master
|
||||
{
|
||||
name AMI1;
|
||||
type cyclicAMI;
|
||||
matchTolerance 0.0001;
|
||||
neighbourPatch AMI2;
|
||||
transform noOrdering;
|
||||
}
|
||||
slave
|
||||
{
|
||||
$master;
|
||||
name AMI2;
|
||||
neighbourPatch AMI1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
30
etc/templates/inflowOutflowRotating/system/fvOptions
Normal file
30
etc/templates/inflowOutflowRotating/system/fvOptions
Normal file
@ -0,0 +1,30 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvOptions;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
MRF1
|
||||
{
|
||||
type MRFSource;
|
||||
selectionMode cellZone;
|
||||
cellZone rotatingZone;
|
||||
active yes;
|
||||
|
||||
MRFSourceCoeffs
|
||||
{
|
||||
#include "${FOAM_CASE}/constant/rotatingZoneProperties"
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
67
etc/templates/inflowOutflowRotating/system/fvSchemes
Normal file
67
etc/templates/inflowOutflowRotating/system/fvSchemes
Normal file
@ -0,0 +1,67 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSchemes;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
ddtSchemes
|
||||
{
|
||||
default steadyState;
|
||||
}
|
||||
|
||||
gradSchemes
|
||||
{
|
||||
default Gauss linear;
|
||||
|
||||
limited cellLimited Gauss linear 1;
|
||||
grad(U) $limited;
|
||||
grad(k) $limited;
|
||||
grad(omega) $limited;
|
||||
}
|
||||
|
||||
divSchemes
|
||||
{
|
||||
default none;
|
||||
|
||||
div(phi,U) bounded Gauss linearUpwind limited;
|
||||
|
||||
turbulence bounded Gauss limitedLinear 1;
|
||||
div(phi,k) $turbulence;
|
||||
div(phi,omega) $turbulence;
|
||||
div(phi,epsilon) $turbulence;
|
||||
|
||||
div((nuEff*dev(T(grad(U))))) Gauss linear;
|
||||
}
|
||||
|
||||
laplacianSchemes
|
||||
{
|
||||
default Gauss linear corrected;
|
||||
}
|
||||
|
||||
interpolationSchemes
|
||||
{
|
||||
default linear;
|
||||
}
|
||||
|
||||
snGradSchemes
|
||||
{
|
||||
default corrected;
|
||||
}
|
||||
|
||||
fluxRequired
|
||||
{
|
||||
default no;
|
||||
p ;
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
93
etc/templates/inflowOutflowRotating/system/fvSolution
Normal file
93
etc/templates/inflowOutflowRotating/system/fvSolution
Normal file
@ -0,0 +1,93 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object fvSolution;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
solvers
|
||||
{
|
||||
p
|
||||
{
|
||||
solver GAMG;
|
||||
smoother GaussSeidel;
|
||||
cacheAgglomeration on; // Need to make this default?
|
||||
agglomerator faceAreaPair; // Need to make this default?
|
||||
nCellsInCoarsestLevel 10; // Need to make this default?
|
||||
mergeLevels 1; // Need to make this default
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)"
|
||||
{
|
||||
solver smoothSolver;
|
||||
smoother symGaussSeidel;
|
||||
tolerance 1e-6;
|
||||
relTol 0.1;
|
||||
}
|
||||
|
||||
pFinal
|
||||
{
|
||||
$p;
|
||||
relTol 0;
|
||||
}
|
||||
|
||||
"(U|k|omega|epsilon)Final"
|
||||
{
|
||||
$U;
|
||||
relTol 0;
|
||||
}
|
||||
}
|
||||
|
||||
"(PIMPLE|PISO)"
|
||||
{
|
||||
nOuterCorrectors 1;
|
||||
nCorrectors 2;
|
||||
nNonOrthogonalCorrectors 1;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
}
|
||||
|
||||
SIMPLE
|
||||
{
|
||||
residualControl
|
||||
{
|
||||
p 1e-4;
|
||||
U 1e-4;
|
||||
"(k|omega|epsilon)" 1e-4;
|
||||
}
|
||||
nNonOrthogonalCorrectors 0;
|
||||
pRefCell 0;
|
||||
pRefValue 0;
|
||||
|
||||
}
|
||||
|
||||
potentialFlow
|
||||
{
|
||||
nNonOrthogonalCorrectors 10;
|
||||
}
|
||||
|
||||
relaxationFactors
|
||||
{
|
||||
fields
|
||||
{
|
||||
p 0.3;
|
||||
}
|
||||
equations
|
||||
{
|
||||
U 0.7;
|
||||
"(k|omega|epsilon)" 0.7;
|
||||
}
|
||||
}
|
||||
|
||||
// ************************************************************************* //
|
||||
22
etc/templates/inflowOutflowRotating/system/meshQualityDict
Normal file
22
etc/templates/inflowOutflowRotating/system/meshQualityDict
Normal file
@ -0,0 +1,22 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object meshQualityDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/meshQualityDict.cfg"
|
||||
|
||||
//- minFaceWeight (0 -> 0.5)
|
||||
//minFaceWeight 0.02;
|
||||
|
||||
// ************************************************************************* //
|
||||
147
etc/templates/inflowOutflowRotating/system/snappyHexMeshDict
Normal file
147
etc/templates/inflowOutflowRotating/system/snappyHexMeshDict
Normal file
@ -0,0 +1,147 @@
|
||||
/*--------------------------------*- C++ -*----------------------------------*\
|
||||
| ========= | |
|
||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||
| \\ / O peration | Version: dev |
|
||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||
| \\/ M anipulation | |
|
||||
\*---------------------------------------------------------------------------*/
|
||||
FoamFile
|
||||
{
|
||||
version 2.0;
|
||||
format ascii;
|
||||
class dictionary;
|
||||
object snappyHexMeshDict;
|
||||
}
|
||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||
|
||||
#includeEtc "caseDicts/mesh/generation/snappyHexMeshDict.cfg"
|
||||
|
||||
castellatedMesh on;
|
||||
snap on;
|
||||
addLayers off;
|
||||
|
||||
geometry
|
||||
{
|
||||
fixed.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name fixed;
|
||||
regions
|
||||
{
|
||||
<inletPatch> { name inlet; }
|
||||
<outletPatch> { name outlet; }
|
||||
}
|
||||
}
|
||||
rotating.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name rotating;
|
||||
}
|
||||
rotatingZone.obj
|
||||
{
|
||||
type triSurfaceMesh;
|
||||
name rotatingZone;
|
||||
}
|
||||
};
|
||||
|
||||
castellatedMeshControls
|
||||
{
|
||||
features
|
||||
(
|
||||
{ file "fixed.eMesh"; level 1; }
|
||||
{ file "rotating.eMesh"; level 1; }
|
||||
{ file "rotatingZone.eMesh"; level 1; }
|
||||
);
|
||||
|
||||
refinementSurfaces
|
||||
{
|
||||
fixed
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type wall; }
|
||||
inGroups (fixed);
|
||||
|
||||
regions
|
||||
{
|
||||
<inletPatch>
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type patch; }
|
||||
}
|
||||
|
||||
<outletPatch>
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type patch; }
|
||||
}
|
||||
}
|
||||
}
|
||||
rotating
|
||||
{
|
||||
level (2 2);
|
||||
patchInfo { type wall; }
|
||||
}
|
||||
rotatingZone
|
||||
{
|
||||
level (2 2);
|
||||
faceZone rotatingZone;
|
||||
cellZone rotatingZone;
|
||||
cellZoneInside inside;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
refinementRegions
|
||||
{
|
||||
/*
|
||||
rotatingZone
|
||||
{
|
||||
mode inside;
|
||||
levels ((1E15 2));
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
locationInMesh (1e-5 1e-5 1e-5); // Offset from (0 0 0) to avoid
|
||||
// coinciding with face or edge
|
||||
}
|
||||
|
||||
snapControls
|
||||
{
|
||||
explicitFeatureSnap true;
|
||||
}
|
||||
|
||||
addLayersControls
|
||||
{
|
||||
layers
|
||||
{
|
||||
"(rotating|fixed)"
|
||||
{
|
||||
nSurfaceLayers 2;
|
||||
}
|
||||
}
|
||||
|
||||
relativeSizes true; // false, usually with firstLayerThickness
|
||||
expansionRatio 1.2;
|
||||
finalLayerThickness 0.5;
|
||||
minThickness 1e-3;
|
||||
// firstLayerThickness 0.01;
|
||||
|
||||
// maxThicknessToMedialRatio 0.6;
|
||||
}
|
||||
|
||||
meshQualityControls
|
||||
{
|
||||
// minTetQuality -1e+30;
|
||||
}
|
||||
|
||||
writeFlags
|
||||
(
|
||||
scalarLevels
|
||||
layerSets
|
||||
layerFields
|
||||
);
|
||||
|
||||
mergeTolerance 1e-6;
|
||||
|
||||
// ************************************************************************* //
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user