Files
OpenFOAM-12/tutorials/fluid/engine2Valve2D/system/blockMeshDict.valveOpen
2024-07-06 16:02:47 +01:00

197 lines
3.5 KiB
C++

/*--------------------------------*- C++ -*----------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Version: 12
\\/ M anipulation |
\*---------------------------------------------------------------------------*/
FoamFile
{
format ascii;
class dictionary;
object blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
convertToMeters 1;
// 6.--------.9 .
// | | |
// | | |
// 7. _ _ _ _10 .
// /| | |
// 0 _ _ 1/ | | |
// | | |8 _ _ _11 |
// | | / |
// 2 _ _ 3 /_ _ _ _ _ _12
// | | |
// 4 _ _ 5 _ _ _ _ _ _ |13
valveLift -2;
pistonPos -4;
nValve 8;
nPiston 8;
nXLeft 8;
x0 -6;
x1 -4;
x2 -3;
x3 -1;
x4 0;
y0 $valveLift;
y1 $pistonPos;
y2 1;
y3 8;
y4 #calc "$valveLift+1";
z0 0.0;
z1 0.5;
vertices
(
($x0 0.0 $z0) //0
($x1 0.0 $z0) //1
($x0 $y0 $z0) //2
($x1 $y0 $z0) //3
($x0 $y1 $z0) //4
($x1 $y1 $z0) //5
($x2 $y3 $z0) //6
($x2 $y2 $z0) //7
($x2 $y4 $z0) //8
($x3 $y3 $z0) //9
($x3 $y2 $z0) //10
($x3 $y4 $z0) //11
($x4 $y0 $z0) //12
($x4 $y1 $z0) //13
// + 14
($x0 0.0 $z1) //0
($x1 0.0 $z1) //1
($x0 $y0 $z1) //2
($x1 $y0 $z1) //3
($x0 $y1 $z1) //4
($x1 $y1 $z1) //5
($x2 $y3 $z1) //6
($x2 $y2 $z1) //7
($x2 $y4 $z1) //8
($x3 $y3 $z1) //9
($x3 $y2 $z1) //10
($x3 $y4 $z1) //11
($x4 $y0 $z1) //12
($x4 $y1 $z1) //13
);
blocks
(
hex (0 2 3 1 14 16 17 15) ($nValve $nXLeft 1) simpleGrading (1 1 1)
hex (2 4 5 3 16 18 19 17) ($nPiston $nXLeft 1) simpleGrading (1 1 1)
hex (1 3 8 7 15 17 22 21) ($nValve 4 1) simpleGrading (1 1 1)
hex (7 8 11 10 21 22 25 24) ($nValve 8 1) simpleGrading (1 1 1)
hex (6 7 10 9 20 21 24 23) (24 8 1) simpleGrading (1 1 1)
hex (3 5 13 12 17 19 27 26) ($nPiston 15 1) simpleGrading (1 1 1)
);
defaultPatch
{
name frontAndBack;
type empty;
}
boundary
(
piston
{
type wall;
faces
(
(4 5 18 19)
(5 13 19 27)
);
}
liner
{
type wall;
faces
(
(4 2 18 16)
(2 0 16 14)
);
}
cylinderHead
{
type wall;
faces
(
(0 1 15 14)
(1 7 21 15)
(7 6 20 21)
);
}
inlet
{
type patch;
faces
(
(6 9 23 20)
);
}
valveHead
{
type wall;
faces
(
(8 11 25 22)
(3 8 22 17)
(12 3 17 26)
);
}
valveStem
{
type wall;
faces
(
(9 10 24 23)
(10 11 25 24)
);
}
symmetry
{
type patch;
faces
(
(13 27 26 12)
);
}
frontAndBack
{
type empty;
faces
(
(2 3 1 0)
(4 5 3 2)
(1 3 8 7)
(8 11 10 7)
(7 10 9 6)
(5 13 12 3)
(16 17 15 14)
(18 19 17 16)
(15 17 22 21)
(22 25 24 21)
(21 24 23 20)
(19 27 26 17)
);
}
);
// ************************************************************************* //