mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: Improving twoRotorTutorial set up
This commit is contained in:
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: v1806 |
|
| \\ / O peration | Version: plus |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.com |
|
| \\ / A nd | Web: www.OpenFOAM.com |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -16,7 +16,7 @@ FoamFile
|
|||||||
|
|
||||||
dimensions [0 1 -1 0 0 0 0];
|
dimensions [0 1 -1 0 0 0 0];
|
||||||
|
|
||||||
internalField uniform (0.1 0 0);
|
internalField uniform (0 0 0);
|
||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
@ -24,7 +24,6 @@ boundaryField
|
|||||||
|
|
||||||
walls
|
walls
|
||||||
{
|
{
|
||||||
//type slip;
|
|
||||||
type uniformFixedValue;
|
type uniformFixedValue;
|
||||||
uniformValue (0 0 0);
|
uniformValue (0 0 0);
|
||||||
}
|
}
|
||||||
@ -37,20 +36,14 @@ boundaryField
|
|||||||
|
|
||||||
outlet
|
outlet
|
||||||
{
|
{
|
||||||
type pressureInletOutletVelocity;
|
type uniformFixedValue;
|
||||||
value uniform (0 0 0);
|
uniformValue (0 0 0);
|
||||||
}
|
}
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type uniformFixedValue;
|
||||||
value $internalField;
|
uniformValue (0 0 0);
|
||||||
}
|
}
|
||||||
//
|
|
||||||
// right1
|
|
||||||
// {
|
|
||||||
// type zeroGradient; //calculated;
|
|
||||||
// value $internalField;
|
|
||||||
// }
|
|
||||||
|
|
||||||
overset
|
overset
|
||||||
{
|
{
|
||||||
|
|||||||
@ -0,0 +1,39 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: plus |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.com |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
object epsilon;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
|
||||||
|
dimensions [ 0 2 -3 0 0 0 0 ];
|
||||||
|
|
||||||
|
internalField uniform 0.1;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
#includeEtc "caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
|
overset
|
||||||
|
{
|
||||||
|
type overset;
|
||||||
|
}
|
||||||
|
|
||||||
|
"(walls|hole|inlet|outlet)"
|
||||||
|
{
|
||||||
|
type epsilonWallFunction;
|
||||||
|
value $internalField;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -0,0 +1,37 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: plus |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.com |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
object k;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
dimensions [ 0 2 -2 0 0 0 0 ];
|
||||||
|
|
||||||
|
internalField uniform 0.01;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
#includeEtc "caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
|
overset
|
||||||
|
{
|
||||||
|
type overset;
|
||||||
|
}
|
||||||
|
|
||||||
|
"(walls|hole|inlet|outlet)"
|
||||||
|
{
|
||||||
|
type kqRWallFunction;
|
||||||
|
value $internalField;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -0,0 +1,37 @@
|
|||||||
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
|
| ========= | |
|
||||||
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
|
| \\ / O peration | Version: plus |
|
||||||
|
| \\ / A nd | Web: www.OpenFOAM.com |
|
||||||
|
| \\/ M anipulation | |
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
FoamFile
|
||||||
|
{
|
||||||
|
version 2.0;
|
||||||
|
format ascii;
|
||||||
|
class volScalarField;
|
||||||
|
object nut;
|
||||||
|
}
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
dimensions [ 0 2 -1 0 0 0 0 ];
|
||||||
|
|
||||||
|
internalField uniform 0;
|
||||||
|
|
||||||
|
boundaryField
|
||||||
|
{
|
||||||
|
#includeEtc "caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
|
overset
|
||||||
|
{
|
||||||
|
type overset;
|
||||||
|
}
|
||||||
|
|
||||||
|
"(walls|hole|inlet|outlet)"
|
||||||
|
{
|
||||||
|
type nutkWallFunction;
|
||||||
|
value $internalField;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: v1806 |
|
| \\ / O peration | Version: plus |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.com |
|
| \\ / A nd | Web: www.OpenFOAM.com |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -22,27 +22,10 @@ boundaryField
|
|||||||
{
|
{
|
||||||
#includeEtc "caseDicts/setConstraintTypes"
|
#includeEtc "caseDicts/setConstraintTypes"
|
||||||
|
|
||||||
"(walls|hole)"
|
"(walls|hole|outlet|inlet)"
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet
|
|
||||||
{
|
|
||||||
type fixedValue;
|
|
||||||
value uniform 0;
|
|
||||||
}
|
|
||||||
inlet
|
|
||||||
{
|
|
||||||
type zeroGradient;
|
|
||||||
}
|
|
||||||
//
|
|
||||||
// right1
|
|
||||||
// {
|
|
||||||
// type fixedValue; //calculated;
|
|
||||||
// value $internalField;
|
|
||||||
// }
|
|
||||||
|
|
||||||
overset
|
overset
|
||||||
{
|
{
|
||||||
type overset;
|
type overset;
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
/*--------------------------------*- C++ -*----------------------------------*\
|
||||||
| ========= | |
|
| ========= | |
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
||||||
| \\ / O peration | Version: v1806 |
|
| \\ / O peration | Version: plus |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.com |
|
| \\ / A nd | Web: www.OpenFOAM.com |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|||||||
@ -5,10 +5,10 @@ cd ${0%/*} || exit 1 # Run from this directory
|
|||||||
./Allrun.pre
|
./Allrun.pre
|
||||||
|
|
||||||
# Serial
|
# Serial
|
||||||
#runApplication $(getApplication)
|
runApplication $(getApplication)
|
||||||
|
|
||||||
# Parallel
|
# Parallel
|
||||||
runApplication decomposePar -cellDist
|
#runApplication decomposePar -cellDist
|
||||||
runParallel $(getApplication)
|
#runParallel $(getApplication)
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
|
|||||||
@ -14,6 +14,15 @@ FoamFile
|
|||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
simulationType laminar;
|
simulationType RAS;
|
||||||
|
|
||||||
|
RAS
|
||||||
|
{
|
||||||
|
RASModel kEpsilon;
|
||||||
|
|
||||||
|
turbulence on;
|
||||||
|
|
||||||
|
printCoeffs on;
|
||||||
|
}
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|||||||
@ -50,11 +50,11 @@ vertices
|
|||||||
|
|
||||||
blocks
|
blocks
|
||||||
(
|
(
|
||||||
hex (0 1 2 3 4 5 6 7) (73 37 1) simpleGrading (1 1 1)
|
hex (0 1 2 3 4 5 6 7) (140 70 1) simpleGrading (1 1 1)
|
||||||
|
|
||||||
hex (8 9 10 11 12 13 14 15) movingZone1 (28 12 1) simpleGrading (1 1 1)
|
hex (8 9 10 11 12 13 14 15) movingZone1 (60 24 1) simpleGrading (1 1 1)
|
||||||
|
|
||||||
hex (16 17 18 19 20 21 22 23) movingZone2 (12 28 1) simpleGrading (1 1 1)
|
hex (16 17 18 19 20 21 22 23) movingZone2 (24 60 1) simpleGrading (1 1 1)
|
||||||
);
|
);
|
||||||
|
|
||||||
edges
|
edges
|
||||||
@ -99,7 +99,7 @@ boundary
|
|||||||
|
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type patch;
|
type wall;
|
||||||
faces
|
faces
|
||||||
(
|
(
|
||||||
(0 4 7 3)
|
(0 4 7 3)
|
||||||
@ -108,7 +108,7 @@ boundary
|
|||||||
|
|
||||||
outlet
|
outlet
|
||||||
{
|
{
|
||||||
type patch;
|
type wall;
|
||||||
faces
|
faces
|
||||||
(
|
(
|
||||||
(2 6 5 1)
|
(2 6 5 1)
|
||||||
|
|||||||
@ -16,6 +16,12 @@ FoamFile
|
|||||||
|
|
||||||
libs ("liboverset.so");
|
libs ("liboverset.so");
|
||||||
|
|
||||||
|
DebugSwitches
|
||||||
|
{
|
||||||
|
overset 0;
|
||||||
|
dynamicOversetFvMesh 0;
|
||||||
|
}
|
||||||
|
|
||||||
application overPimpleDyMFoam;
|
application overPimpleDyMFoam;
|
||||||
|
|
||||||
startFrom startTime;
|
startFrom startTime;
|
||||||
@ -24,9 +30,9 @@ startTime 0;
|
|||||||
|
|
||||||
stopAt endTime;
|
stopAt endTime;
|
||||||
|
|
||||||
endTime 0.6;
|
endTime 0.08;
|
||||||
|
|
||||||
deltaT 0.00025;
|
deltaT 2e-5;
|
||||||
|
|
||||||
writeControl adjustableRunTime;
|
writeControl adjustableRunTime;
|
||||||
|
|
||||||
@ -46,7 +52,7 @@ timePrecision 6;
|
|||||||
|
|
||||||
runTimeModifiable true;
|
runTimeModifiable true;
|
||||||
|
|
||||||
adjustTimeStep yes;
|
adjustTimeStep no;
|
||||||
|
|
||||||
maxCo 1;
|
maxCo 1;
|
||||||
|
|
||||||
@ -54,6 +60,30 @@ maxCo 1;
|
|||||||
functions
|
functions
|
||||||
{
|
{
|
||||||
// #include "catalyst"
|
// #include "catalyst"
|
||||||
|
probes
|
||||||
|
{
|
||||||
|
type probes;
|
||||||
|
libs ("libsampling.so");
|
||||||
|
|
||||||
|
// Name of the directory for probe data
|
||||||
|
name probes;
|
||||||
|
|
||||||
|
// Write at same frequency as fields
|
||||||
|
writeControl timeStep;
|
||||||
|
writeInterval 1;
|
||||||
|
|
||||||
|
// Fields to be probed
|
||||||
|
fields (p U);
|
||||||
|
|
||||||
|
// Optional: interpolation scheme to use (default is cell)
|
||||||
|
interpolationScheme cell;
|
||||||
|
|
||||||
|
probeLocations
|
||||||
|
(
|
||||||
|
(0.015 0.005 0.005) // at inlet
|
||||||
|
);
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -22,18 +22,16 @@ ddtSchemes
|
|||||||
gradSchemes
|
gradSchemes
|
||||||
{
|
{
|
||||||
default Gauss linear;
|
default Gauss linear;
|
||||||
grad(T) Gauss linear;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
divSchemes
|
divSchemes
|
||||||
{
|
{
|
||||||
default none;
|
default none;
|
||||||
div(phi,U) Gauss limitedLinearV 1;
|
div(phi,U) Gauss upwind;
|
||||||
div(phi,k) Gauss limitedLinear 1;
|
|
||||||
div(phi,epsilon) Gauss limitedLinear 1;
|
div(phi,epsilon) Gauss upwind;
|
||||||
div(phi,R) Gauss limitedLinear 1;
|
div(phi,k) Gauss upwind;
|
||||||
div(R) Gauss linear;
|
|
||||||
div(phi,nuTilda) Gauss limitedLinear 1;
|
|
||||||
div((nuEff*dev2(T(grad(U))))) Gauss linear;
|
div((nuEff*dev2(T(grad(U))))) Gauss linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -55,7 +53,7 @@ snGradSchemes
|
|||||||
|
|
||||||
oversetInterpolation
|
oversetInterpolation
|
||||||
{
|
{
|
||||||
method inverseDistance;
|
method cellVolumeWeight;
|
||||||
}
|
}
|
||||||
|
|
||||||
fluxRequired
|
fluxRequired
|
||||||
@ -65,4 +63,10 @@ fluxRequired
|
|||||||
p ;
|
p ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
oversetInterpolationSuppressed
|
||||||
|
{
|
||||||
|
grad(p);
|
||||||
|
surfaceIntegrate(phiHbyA);
|
||||||
|
}
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|||||||
@ -30,13 +30,14 @@ solvers
|
|||||||
{
|
{
|
||||||
solver PBiCGStab;
|
solver PBiCGStab;
|
||||||
preconditioner DILU;
|
preconditioner DILU;
|
||||||
tolerance 1e-6;
|
tolerance 1e-9;
|
||||||
relTol 0;
|
relTol 0.01;
|
||||||
}
|
}
|
||||||
|
|
||||||
pFinal
|
pFinal
|
||||||
{
|
{
|
||||||
$p;
|
$p;
|
||||||
|
relTol 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
pcorr
|
pcorr
|
||||||
@ -70,13 +71,13 @@ solvers
|
|||||||
|
|
||||||
PIMPLE
|
PIMPLE
|
||||||
{
|
{
|
||||||
momentumPredictor no;
|
momentumPredictor true;
|
||||||
correctPhi no;
|
correctPhi no;
|
||||||
nOuterCorrectors 1;
|
nOuterCorrectors 1;
|
||||||
nCorrectors 2;
|
nCorrectors 5;
|
||||||
nNonOrthogonalCorrectors 0;
|
nNonOrthogonalCorrectors 0;
|
||||||
|
|
||||||
ddtCorr false;
|
ddtCorr true;
|
||||||
|
|
||||||
pRefPoint (0.0001 0.0001 0.001);
|
pRefPoint (0.0001 0.0001 0.001);
|
||||||
pRefValue 0.0;
|
pRefValue 0.0;
|
||||||
|
|||||||
Reference in New Issue
Block a user