mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: Added baffles and fan cyclic
This commit is contained in:
@ -20,27 +20,36 @@ internalField uniform (0 0 0);
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
type pressureInletOutletVelocity;
|
type pressureInletOutletVelocity;
|
||||||
value uniform (0 0 0);
|
value uniform (0 0 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet1
|
outlet1
|
||||||
{
|
{
|
||||||
type inletOutlet;
|
type inletOutlet;
|
||||||
inletValue uniform (0 0 0);
|
inletValue uniform (0 0 0);
|
||||||
value uniform (0 0 0);
|
value uniform (0 0 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet2
|
outlet2
|
||||||
{
|
{
|
||||||
type inletOutlet;
|
type inletOutlet;
|
||||||
inletValue uniform (0 0 0);
|
inletValue uniform (0 0 0);
|
||||||
value uniform (0 0 0);
|
value uniform (0 0 0);
|
||||||
}
|
}
|
||||||
|
baffles
|
||||||
defaultFaces
|
{
|
||||||
|
type fixedValue;
|
||||||
|
value uniform ( 0 0 0 );
|
||||||
|
}
|
||||||
|
fan
|
||||||
|
{
|
||||||
|
type cyclic;
|
||||||
|
value uniform ( 0 0 0 );
|
||||||
|
}
|
||||||
|
defaultFaces
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type fixedValue;
|
||||||
value uniform (0 0 0);
|
value uniform (0 0 0);
|
||||||
|
|||||||
@ -27,23 +27,33 @@ boundaryField
|
|||||||
mixingLength 0.01; // 1cm - half channel height
|
mixingLength 0.01; // 1cm - half channel height
|
||||||
value uniform 1;
|
value uniform 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet1
|
outlet1
|
||||||
{
|
{
|
||||||
type inletOutlet;
|
type inletOutlet;
|
||||||
inletValue uniform 1;
|
inletValue uniform 1;
|
||||||
|
value uniform 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet2
|
outlet2
|
||||||
{
|
{
|
||||||
type inletOutlet;
|
type inletOutlet;
|
||||||
inletValue uniform 1;
|
inletValue uniform 1;
|
||||||
|
value uniform 1;
|
||||||
|
}
|
||||||
|
baffles
|
||||||
|
{
|
||||||
|
type epsilonWallFunction;
|
||||||
|
value uniform 1;
|
||||||
|
}
|
||||||
|
fan
|
||||||
|
{
|
||||||
|
type cyclic;
|
||||||
|
value uniform 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
defaultFaces
|
defaultFaces
|
||||||
{
|
{
|
||||||
type epsilonWallFunction;
|
type epsilonWallFunction;
|
||||||
value uniform 0;
|
value uniform 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -27,23 +27,34 @@ boundaryField
|
|||||||
intensity 0.05; // 5% turbulent intensity
|
intensity 0.05; // 5% turbulent intensity
|
||||||
value uniform 1;
|
value uniform 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet1
|
outlet1
|
||||||
{
|
{
|
||||||
type inletOutlet;
|
type inletOutlet;
|
||||||
inletValue uniform 1;
|
inletValue uniform 1;
|
||||||
|
value uniform 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet2
|
outlet2
|
||||||
{
|
{
|
||||||
type inletOutlet;
|
type inletOutlet;
|
||||||
inletValue uniform 1;
|
inletValue uniform 1;
|
||||||
|
value uniform 1;
|
||||||
|
}
|
||||||
|
baffles
|
||||||
|
{
|
||||||
|
type kqRWallFunction;
|
||||||
|
value uniform 1;
|
||||||
|
}
|
||||||
|
fan
|
||||||
|
{
|
||||||
|
type cyclic;
|
||||||
|
value uniform 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
defaultFaces
|
defaultFaces
|
||||||
{
|
{
|
||||||
type kqRWallFunction;
|
type kqRWallFunction;
|
||||||
value uniform 0;
|
value uniform 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -34,7 +34,15 @@ boundaryField
|
|||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
}
|
}
|
||||||
|
baffles
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
fan
|
||||||
|
{
|
||||||
|
type cyclic;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
defaultFaces
|
defaultFaces
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
|
|||||||
@ -38,7 +38,16 @@ boundaryField
|
|||||||
type calculated;
|
type calculated;
|
||||||
value uniform 0;
|
value uniform 0;
|
||||||
}
|
}
|
||||||
|
baffles
|
||||||
|
{
|
||||||
|
type nutkWallFunction;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
|
fan
|
||||||
|
{
|
||||||
|
type cyclic;
|
||||||
|
value uniform 0;
|
||||||
|
}
|
||||||
defaultFaces
|
defaultFaces
|
||||||
{
|
{
|
||||||
type nutkWallFunction;
|
type nutkWallFunction;
|
||||||
|
|||||||
@ -20,7 +20,7 @@ internalField uniform 100000;
|
|||||||
|
|
||||||
boundaryField
|
boundaryField
|
||||||
{
|
{
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
//type totalPressure;
|
//type totalPressure;
|
||||||
//p0 uniform 100040;
|
//p0 uniform 100040;
|
||||||
@ -38,18 +38,28 @@ boundaryField
|
|||||||
value uniform 100040;
|
value uniform 100040;
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet1
|
outlet1
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type fixedValue;
|
||||||
value uniform 100010;
|
value uniform 100010;
|
||||||
}
|
}
|
||||||
|
|
||||||
outlet2
|
outlet2
|
||||||
{
|
{
|
||||||
type fixedValue;
|
type fixedValue;
|
||||||
value uniform 100000;
|
value uniform 100000;
|
||||||
}
|
}
|
||||||
|
baffles
|
||||||
|
{
|
||||||
|
type zeroGradient;
|
||||||
|
}
|
||||||
|
fan
|
||||||
|
{
|
||||||
|
type fan;
|
||||||
|
patchType cyclic;
|
||||||
|
f 2 ( 50 -0.1 );
|
||||||
|
value uniform 100000;
|
||||||
|
}
|
||||||
defaultFaces
|
defaultFaces
|
||||||
{
|
{
|
||||||
type zeroGradient;
|
type zeroGradient;
|
||||||
|
|||||||
27
tutorials/incompressible/pimpleFoam/t-junction/Allrun
Executable file
27
tutorials/incompressible/pimpleFoam/t-junction/Allrun
Executable file
@ -0,0 +1,27 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Source tutorial run functions
|
||||||
|
. $WM_PROJECT_DIR/bin/tools/RunFunctions
|
||||||
|
|
||||||
|
# Get application name
|
||||||
|
application=`getApplication`
|
||||||
|
|
||||||
|
runApplication blockMesh
|
||||||
|
|
||||||
|
|
||||||
|
# Creating patches 'out of nothing' so willl get undefined value which
|
||||||
|
# might cause floating point error
|
||||||
|
unset FOAM_SIGFPE
|
||||||
|
unset FOAM_SETNAN
|
||||||
|
|
||||||
|
# Add cyclic baffles for fan
|
||||||
|
runApplication setSet -batch selectCyclics.setSet
|
||||||
|
runApplication createBaffles cyclicFaces fan -overwrite
|
||||||
|
|
||||||
|
# Add wall baffles
|
||||||
|
rm log.setSet
|
||||||
|
runApplication setSet -batch selectBaffles.setSet
|
||||||
|
rm log.createBaffles
|
||||||
|
runApplication createBaffles baffleFaces baffles -overwrite
|
||||||
|
|
||||||
|
runApplication $application
|
||||||
@ -1,2 +1,3 @@
|
|||||||
15/8/8 Simple T-junction. Inlet on left, one outlet at bottom, one at top.
|
300-04-16 T-junction with baffles and fan.
|
||||||
|
Inlet on left, one outlet at bottom, one at top.
|
||||||
To test multiple outlets.
|
To test multiple outlets.
|
||||||
|
|||||||
@ -100,6 +100,16 @@ patches
|
|||||||
(
|
(
|
||||||
(8 18 19 9)
|
(8 18 19 9)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
wall baffles
|
||||||
|
()
|
||||||
|
|
||||||
|
cyclic fan
|
||||||
|
()
|
||||||
|
|
||||||
|
wall defaultFaces
|
||||||
|
()
|
||||||
|
|
||||||
);
|
);
|
||||||
|
|
||||||
mergePatchPairs
|
mergePatchPairs
|
||||||
|
|||||||
@ -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: 1.6 |
|
| \\ / O peration | Version: dev |
|
||||||
| \\ / A nd | Web: www.OpenFOAM.org |
|
| \\ / A nd | Web: www.OpenFOAM.org |
|
||||||
| \\/ M anipulation | |
|
| \\/ M anipulation | |
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
@ -15,7 +15,7 @@ FoamFile
|
|||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
4
|
6
|
||||||
(
|
(
|
||||||
inlet
|
inlet
|
||||||
{
|
{
|
||||||
@ -35,6 +35,19 @@ FoamFile
|
|||||||
nFaces 25;
|
nFaces 25;
|
||||||
startFace 10100;
|
startFace 10100;
|
||||||
}
|
}
|
||||||
|
baffles
|
||||||
|
{
|
||||||
|
type wall;
|
||||||
|
nFaces 0;
|
||||||
|
startFace 10125;
|
||||||
|
}
|
||||||
|
fan
|
||||||
|
{
|
||||||
|
type cyclic;
|
||||||
|
nFaces 0;
|
||||||
|
startFace 10125;
|
||||||
|
featureCos 0.9;
|
||||||
|
}
|
||||||
defaultFaces
|
defaultFaces
|
||||||
{
|
{
|
||||||
type wall;
|
type wall;
|
||||||
|
|||||||
@ -0,0 +1,4 @@
|
|||||||
|
faceSet baffleFaces new boxToFace (0.099 -10 -10)(0.101 10 10)
|
||||||
|
# Remove the centre faces that become fan
|
||||||
|
faceSet baffleFaces delete boxToFace (0.099 -0.006 0.004)(0.101 0.006 0.016)
|
||||||
|
faceZoneSet baffleFaces new setToFaceZone baffleFaces
|
||||||
@ -0,0 +1,3 @@
|
|||||||
|
faceSet cyclicFaces new boxToFace (0.099 -0.006 0.004)(0.101 0.006 0.016)
|
||||||
|
cellSet cyclicFacesSlaveCells new boxToCell (-10 -10 -10)(0.1 10 10)
|
||||||
|
faceZoneSet cyclicFaces new setsToFaceZone cyclicFaces cyclicFacesSlaveCells
|
||||||
@ -15,6 +15,8 @@ FoamFile
|
|||||||
}
|
}
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
libs ("libOpenFOAM.so" "libincompressibleTurbulenceModel.so" "libincompressibleRASModels.so");
|
||||||
|
|
||||||
application pimpleFoam;
|
application pimpleFoam;
|
||||||
|
|
||||||
startFrom startTime;
|
startFrom startTime;
|
||||||
@ -37,7 +39,7 @@ writeFormat ascii;
|
|||||||
|
|
||||||
writePrecision 6;
|
writePrecision 6;
|
||||||
|
|
||||||
writeCompression off;
|
writeCompression uncompressed;
|
||||||
|
|
||||||
timeFormat general;
|
timeFormat general;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user