Fixing tutorials

This commit is contained in:
Henrik Rusche 2014-06-01 19:37:59 +02:00
parent cb4c606882
commit dd542da6e1
12 changed files with 537 additions and 591 deletions

View file

@ -4,7 +4,6 @@
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application="MRFSimpleFoam"
#application="simpleFoam"
#Create the mesh:
m4 < constant/polyMesh/blockMeshDict.m4 > constant/polyMesh/blockMeshDict

View file

@ -431,7 +431,7 @@ boundary
// quad2D(RU3l, RU2l)
// quad2D(RU0r, RU1r)
// quad2D(RU2r, RU3r)
// )
// );
//}
RUBLADE

View file

@ -470,7 +470,7 @@ boundary
// quad2D(RU3l, RU2l)
// quad2D(RU0r, RU1r)
// quad2D(RU2r, RU3r)
// )
// );
//}
RUBLADE

View file

@ -4,13 +4,11 @@
. $WM_PROJECT_DIR/bin/tools/RunFunctions
application="pimpleDyMFoam"
#application="icoDyMFoam"
#Create the mesh:
./makeMesh
#Fix constant/boundary:
changeDictionary
m4 < constant/polyMesh/blockMeshDict.m4 > constant/polyMesh/blockMeshDict
blockMesh
transformPoints -cylToCart "((0 0 0) (0 0 1) (1 0 0))"
# Set 0-directory and create GGI set:
cp -r 0_orig 0

View file

@ -267,144 +267,287 @@ edges // Inappropriate with arc due to coordinate conversion
)
);
patches
boundary
(
patch GVINLET
GVINLET
{
type patch;
faces
(
quad2D(GV3r, GV3l)
)
);
}
overlapGgi GVOUTLET
GVOUTLET
{
type overlapGgi;
shadowPatch RUINLET;
zone GVOUTLETZone;
rotationAxis ( 0 0 1 );
nCopies 5;
faces
(
quad2D(GV0l, GV0r)
)
);
}
cyclicGgi GVCYCLIC1
GVCYCLIC1
{
type cyclicGgi;
shadowPatch GVCYCLIC2;
zone GVCYCLIC1Zone;
bridgeOverlap false;
rotationAxis (0 0 1);
rotationAngle 72;
separationOffset (0 0 0);
faces
(
quad2D(GV1l, GV0l)
quad2D(GV3l, GV2l)
)
);
}
cyclicGgi GVCYCLIC2
GVCYCLIC2
{
type cyclicGgi;
shadowPatch GVCYCLIC1;
zone GVCYCLIC2Zone;
bridgeOverlap false;
rotationAxis (0 0 1);
rotationAngle -72;
separationOffset (0 0 0);
faces
(
quad2D(GV0r, GV1r)
quad2D(GV2r, GV3r)
)
);
}
//cyclic GVCYCLIC
//GVCYCLIC
//{
// type cyclic;
// faces
// (
// quad2D(GV1l, GV0l)
// quad2D(GV3l, GV2l)
// quad2D(GV0r, GV1r)
// quad2D(GV2r, GV3r)
//)
// );
//}
wall GVBLADE
GVBLADE
{
type wall;
faces
(
quad2D(GV2l, GV1l)
quad2D(GV1r, GV2r)
)
);
}
wall GVHUB
GVHUB
{
type wall;
faces
(
backQuad(GV0l, GV0r, GV1r, GV1l)
backQuad(GV1l, GV1r, GV2r, GV2l)
backQuad(GV2l, GV2r, GV3r, GV3l)
)
);
}
wall GVSHROUD
GVSHROUD
{
type wall;
faces
(
frontQuad(GV0l, GV0r, GV1r, GV1l)
frontQuad(GV1l, GV1r, GV2r, GV2l)
frontQuad(GV2l, GV2r, GV3r, GV3l)
)
);
}
overlapGgi RUINLET
RUINLET
{
type overlapGgi;
shadowPatch GVOUTLET;
zone RUINLETZone;
rotationAxis ( 0 0 1 );
nCopies 5;
faces
(
quad2D(RU3r, RU3l)
)
);
}
overlapGgi RUOUTLET
RUOUTLET
{
type overlapGgi;
shadowPatch DTINLET;
zone RUOUTLETZone;
rotationAxis ( 0 0 1 );
nCopies 5;
faces
(
quad2D(RU0l, RU0r)
)
);
}
cyclicGgi RUCYCLIC1
RUCYCLIC1
{
type cyclicGgi;
shadowPatch RUCYCLIC2;
zone RUCYCLIC1Zone;
bridgeOverlap false;
rotationAxis (0 0 1);
rotationAngle 72;
separationOffset (0 0 0);
faces
(
quad2D(RU1l, RU0l)
quad2D(RU3l, RU2l)
)
);
}
cyclicGgi RUCYCLIC2
RUCYCLIC2
{
type cyclicGgi;
shadowPatch RUCYCLIC1;
zone RUCYCLIC2Zone;
bridgeOverlap false;
rotationAxis (0 0 1);
rotationAngle -72;
separationOffset (0 0 0);
faces
(
quad2D(RU0r, RU1r)
quad2D(RU2r, RU3r)
)
);
}
//cyclic RUCYCLIC
//RUCYCLIC
//{
// type cyclic;
// faces
// (
// quad2D(RU1l, RU0l)
// quad2D(RU3l, RU2l)
// quad2D(RU0r, RU1r)
// quad2D(RU2r, RU3r)
//)
// );
//}
wall RUBLADE
RUBLADE
{
type wall;
faces
(
quad2D(RU2l, RU1l)
quad2D(RU1r, RU2r)
)
);
}
wall RUHUB
RUHUB
{
type wall;
faces
(
backQuad(RU0l, RU0r, RU1r, RU1l)
backQuad(RU1l, RU1r, RU2r, RU2l)
backQuad(RU2l, RU2r, RU3r, RU3l)
)
);
}
wall RUSHROUD
RUSHROUD
{
type wall;
faces
(
frontQuad(RU0l, RU0r, RU1r, RU1l)
frontQuad(RU1l, RU1r, RU2r, RU2l)
frontQuad(RU2l, RU2r, RU3r, RU3l)
)
);
}
overlapGgi DTINLET
DTINLET
{
type overlapGgi;
shadowPatch RUOUTLET;
zone DTINLETZone;
rotationAxis ( 0 0 1 );
nCopies 5;
faces
(
quad2D(DT1r, DT1l)
)
);
}
patch DTOUTLET
DTOUTLET
{
type patch;
faces
(
quad2D(DT0l, DT0r)
)
);
}
cyclicGgi DTCYCLIC1
DTCYCLIC1
{
type cyclicGgi;
shadowPatch DTCYCLIC2;
zone DTCYCLIC1Zone;
bridgeOverlap false;
rotationAxis (0 0 1);
rotationAngle 72;
separationOffset (0 0 0);
faces
(
quad2D(DT1l, DT0l)
)
);
}
cyclicGgi DTCYCLIC2
DTCYCLIC2
{
type cyclicGgi;
shadowPatch DTCYCLIC1;
zone DTCYCLIC2Zone;
bridgeOverlap false;
rotationAxis (0 0 1);
rotationAngle -72;
separationOffset (0 0 0);
faces
(
quad2D(DT0r, DT1r)
)
);
}
//cyclic DTCYCLIC
//DTCYCLIC
//{
// type cyclic;
// faces
// (
// quad2D(DT1l, DT0l)
// quad2D(DT0r, DT1r)
//)
// );
//}
wall DTHUB
DTHUB
{
type wall;
faces
(
backQuad(DT0l, DT0r, DT1r, DT1l)
)
);
}
wall DTSHROUD
DTSHROUD
{
type wall;
faces
(
frontQuad(DT0l, DT0r, DT1r, DT1l)
)
);
}
);
// ************************************************************************* //

View file

@ -15,6 +15,5 @@ runApplication setSet -batch setBatchMotion
runApplication setsToZones
\rm -rf constant/polyMesh/sets/
\cp boundary constant/polyMesh/boundary
runApplication $application

View file

@ -1,324 +0,0 @@
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | foam-extend: Open Source CFD |
| \\ / O peration | Version: 3.1 |
| \\ / A nd | Web: http://www.extend-project.de |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
object blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
convertToMeters 0.01;
vertices
(
// FRONT PLANE
// First cylinder
// Inner circle
( -0.70710677 -0.70710677 -0.05)
( 0.70710677 -0.70710677 -0.05)
( 0.70710677 0.70710677 -0.05)
( -0.70710677 0.70710677 -0.05)
// Outer circle
( -1.0606601 -1.0606601 -0.05)
( 1.0606601 -1.0606601 -0.05)
( 1.0606601 1.0606601 -0.05)
( -1.0606601 1.0606601 -0.05)
// Square
( -2 -2 -0.05)
( 2 -2 -0.05)
( 2 2 -0.05)
( -2 2 -0.05)
// Outer square
( -2 -5 -0.05)
( 2 -5 -0.05)
( 2 5 -0.05)
( -2 5 -0.05)
// Second cylinder
// Inner circle
( 3.29289322 -0.70710677 -0.05)
( 4.70710677 -0.70710677 -0.05)
( 4.70710677 0.70710677 -0.05)
( 3.29289322 0.70710677 -0.05)
// Outer circle
( 2.9393399 -1.0606601 -0.05)
( 5.0606601 -1.0606601 -0.05)
( 5.0606601 1.0606601 -0.05)
( 2.9393399 1.0606601 -0.05)
// Square
( 2 -2 -0.05)
( 6 -2 -0.05)
( 6 2 -0.05)
( 2 2 -0.05)
// Outer square
( 2 -5 -0.05)
( 6 -5 -0.05)
( 6 5 -0.05)
( 2 5 -0.05)
// Lead square
( -10 -5 -0.05)
( -2 -5 -0.05)
( -10 5 -0.05)
( -2 5 -0.05)
// Tail square
( 6 -5 -0.05)
( 14 -5 -0.05)
( 6 5 -0.05)
( 14 5 -0.05)
// BACK PLANE
// First cylinder
// Inner circle
( -0.70710677 -0.70710677 0.05)
( 0.70710677 -0.70710677 0.05)
( 0.70710677 0.70710677 0.05)
( -0.70710677 0.70710677 0.05)
// Outer circle
( -1.0606601 -1.0606601 0.05)
( 1.0606601 -1.0606601 0.05)
( 1.0606601 1.0606601 0.05)
( -1.0606601 1.0606601 0.05)
// Square
( -2 -2 0.05)
( 2 -2 0.05)
( 2 2 0.05)
( -2 2 0.05)
// Outer square
( -2 -5 0.05)
( 2 -5 0.05)
( 2 5 0.05)
( -2 5 0.05)
// Second cylinder
// Inner circle
( 3.29289322 -0.70710677 0.05)
( 4.70710677 -0.70710677 0.05)
( 4.70710677 0.70710677 0.05)
( 3.29289322 0.70710677 0.05)
// Outer circle
( 2.9393399 -1.0606601 0.05)
( 5.0606601 -1.0606601 0.05)
( 5.0606601 1.0606601 0.05)
( 2.9393399 1.0606601 0.05)
// Square
( 2 -2 0.05)
( 6 -2 0.05)
( 6 2 0.05)
( 2 2 0.05)
// Outer square
( 2 -5 0.05)
( 6 -5 0.05)
( 6 5 0.05)
( 2 5 0.05)
// Lead square
( -10 -5 0.05)
( -2 -5 0.05)
( -10 5 0.05)
( -2 5 0.05)
// Tail square
( 6 -5 0.05)
( 14 -5 0.05)
( 6 5 0.05)
( 14 5 0.05)
);
blocks
(
// First cylinder
hex (0 4 5 1 40 44 45 41) cyl1 (7 10 1) simpleGrading (1 1 1)
hex (1 5 6 2 41 45 46 42) cyl1 (7 10 1) simpleGrading (1 1 1)
hex (2 6 7 3 42 46 47 43) cyl1 (7 10 1) simpleGrading (1 1 1)
hex (3 7 4 0 43 47 44 40) cyl1 (7 10 1) simpleGrading (1 1 1)
// Square around cylinder
hex (4 8 9 5 44 48 49 45) cyl1 (5 10 1) simpleGrading (1 1 1)
hex (5 9 10 6 45 49 50 46) cyl1 (5 10 1) simpleGrading (1 1 1)
hex (6 10 11 7 46 50 51 47) cyl1 (5 10 1) simpleGrading (1 1 1)
hex (7 11 8 4 47 51 48 44) cyl1 (5 10 1) simpleGrading (1 1 1)
// Top and bottom
hex (12 13 9 8 52 53 49 48) c1Bot (10 10 1) simpleGrading (1 1 1)
hex (11 10 14 15 51 50 54 55) c1Top (10 10 1) simpleGrading (1 1 1)
// Second cylinder
hex (16 20 21 17 56 60 61 57) cyl2 (7 10 1) simpleGrading (1 1 1)
hex (17 21 22 18 57 61 62 58) cyl2 (7 10 1) simpleGrading (1 1 1)
hex (18 22 23 19 58 62 63 59) cyl2 (7 10 1) simpleGrading (1 1 1)
hex (19 23 20 16 59 63 60 56) cyl2 (7 10 1) simpleGrading (1 1 1)
// Square around cylinder
hex (20 24 25 21 60 64 65 61) cyl2 (5 10 1) simpleGrading (1 1 1)
hex (21 25 26 22 61 65 66 62) cyl2 (5 10 1) simpleGrading (1 1 1)
hex (22 26 27 23 62 66 67 63) cyl2 (5 10 1) simpleGrading (1 1 1)
hex (23 27 24 20 63 67 64 60) cyl2 (5 10 1) simpleGrading (1 1 1)
// Top and bottom
hex (28 29 25 24 68 69 65 64) c2Bot (10 10 1) simpleGrading (1 1 1)
hex (27 26 30 31 67 66 70 71) c2Top (10 10 1) simpleGrading (1 1 1)
// Lead square
hex (32 33 35 34 72 73 75 74) (20 20 1) simpleGrading (1 1 1)
// Tail square
hex (36 37 39 38 76 77 79 78) (20 20 1) simpleGrading (1 1 1)
);
edges
(
// First cylinder, inner
arc 0 1 ( 0 -1 -0.05)
arc 1 2 ( 1 0 -0.05)
arc 2 3 ( 0 1 -0.05)
arc 3 0 ( -1 0 -0.05)
// First cylinder, outer
arc 4 5 ( 0 -1.5 -0.05)
arc 5 6 ( 1.5 0 -0.05)
arc 6 7 ( 0 1.5 -0.05)
arc 7 4 ( -1.5 0 -0.05)
// First cylinder, inner
arc 40 41 ( 0 -1 0.05)
arc 41 42 ( 1 0 0.05)
arc 42 43 ( 0 1 0.05)
arc 43 40 ( -1 0 0.05)
// First cylinder, outer
arc 44 45 ( 0 -1.5 0.05)
arc 45 46 ( 1.5 0 0.05)
arc 46 47 ( 0 1.5 0.05)
arc 47 44 ( -1.5 0 0.05)
// Second cylinder, inner
arc 16 17 ( 4 -1 -0.05)
arc 17 18 ( 5 0 -0.05)
arc 18 19 ( 4 1 -0.05)
arc 19 16 ( 3 0 -0.05)
// Second cylinder, outer
arc 20 21 ( 4 -1.5 -0.05)
arc 21 22 ( 5.5 0 -0.05)
arc 22 23 ( 4 1.5 -0.05)
arc 23 20 ( 2.5 0 -0.05)
// Second cylinder, inner
arc 56 57 ( 4 -1 0.05)
arc 57 58 ( 5 0 0.05)
arc 58 59 ( 4 1 0.05)
arc 59 56 ( 3 0 0.05)
// Second cylinder, outer
arc 60 61 ( 4 -1.5 0.05)
arc 61 62 ( 5.5 0 0.05)
arc 62 63 ( 4 1.5 0.05)
arc 63 60 ( 2.5 0 0.05)
);
patches
(
patch inlet
(
(32 72 74 34)
)
patch outlet
(
(37 39 79 77)
)
wall bottom
(
(32 33 73 72)
(12 13 53 52)
(28 29 69 68)
(36 37 77 76)
)
wall top
(
(34 74 75 35)
(15 55 54 14)
(31 71 70 30)
(38 78 79 39)
)
wall firstCyl
(
(0 40 41 1)
(1 41 42 2)
(2 42 43 3)
(3 43 40 0)
)
wall secondCyl
(
(16 56 57 17)
(17 57 58 18)
(18 58 59 19)
(19 59 56 16)
)
ggi frontIn
(
(33 35 75 73)
)
ggi frontOut
(
(12 52 48 8)
(8 48 51 11)
(11 51 55 15)
)
ggi middleIn
(
(13 9 49 53)
(9 10 50 49)
(10 14 54 50)
)
ggi middleOut
(
(28 68 64 24)
(24 64 67 27)
(27 67 71 31)
)
ggi backIn
(
(29 25 65 69)
(25 26 66 65)
(26 30 70 66)
)
ggi backOut
(
(36 76 78 38)
)
);
// ************************************************************************* //

View file

@ -238,87 +238,153 @@ edges
arc 63 60 ( 2.5 0 0.05)
);
patches
boundary
(
patch inlet
inlet
{
type patch;
faces
(
(32 72 74 34)
)
);
}
patch outlet
outlet
{
type patch;
faces
(
(37 39 79 77)
)
);
}
wall bottom
bottom
{
type wall;
faces
(
(32 33 73 72)
(12 13 53 52)
(28 29 69 68)
(36 37 77 76)
)
);
}
wall top
top
{
type wall;
faces
(
(34 74 75 35)
(15 55 54 14)
(31 71 70 30)
(38 78 79 39)
)
);
}
wall firstCyl
firstCyl
{
type wall;
faces
(
(0 40 41 1)
(1 41 42 2)
(2 42 43 3)
(3 43 40 0)
)
);
}
wall secondCyl
secondCyl
{
type wall;
faces
(
(16 56 57 17)
(17 57 58 18)
(18 58 59 19)
(19 59 56 16)
)
);
}
ggi frontIn
frontIn
{
type ggi;
shadowPatch frontOut;
zone frontInZone;
bridgeOverlap true;
faces
(
(33 35 75 73)
)
);
}
ggi frontOut
frontOut
{
type ggi;
shadowPatch frontIn;
zone frontOutZone;
bridgeOverlap true;
faces
(
(12 52 48 8)
(8 48 51 11)
(11 51 55 15)
)
);
}
ggi middleIn
middleIn
{
type ggi;
shadowPatch middleOut;
zone middleInZone;
bridgeOverlap true;
faces
(
(13 9 49 53)
(9 10 50 49)
(10 14 54 50)
)
);
}
ggi middleOut
middleOut
{
type ggi;
shadowPatch middleIn;
zone middleOutZone;
bridgeOverlap true;
faces
(
(28 68 64 24)
(24 64 67 27)
(27 67 71 31)
)
);
}
ggi backIn
backIn
{
type ggi;
shadowPatch backOut;
zone backInZone;
bridgeOverlap true;
faces
(
(29 25 65 69)
(25 26 66 65)
(26 30 70 66)
)
);
}
ggi backOut
backOut
{
type ggi;
shadowPatch backIn;
zone backOutZone;
bridgeOverlap true;
faces
(
(36 76 78 38)
)
);
}
);
// ************************************************************************* //

View file

@ -19,10 +19,10 @@ FoamFile
constructFrom patch;
sourceCase "../wingMotion_snappyHexMesh";
sourcePatch front;
sourcePatch symFront;
// If construct from patch: patch to use for back (can be same as sourcePatch)
exposedPatchName back;
exposedPatchName symBack;
// Flip surface normals before usage.
flipNormals false;

View file

@ -68,7 +68,7 @@ patchInfo
}
{
name back;
name symBack;
dictionary
{
type empty;
@ -78,7 +78,7 @@ patchInfo
}
{
name front;
name symFront;
dictionary
{
type empty;

View file

@ -15,6 +15,5 @@ runApplication setSet -batch setBatchMotion
runApplication setsToZones
\rm -rf constant/polyMesh/sets/
\cp boundary constant/polyMesh/boundary
runApplication $application

View file

@ -238,87 +238,153 @@ edges
arc 63 60 ( 2.5 0 0.05)
);
patches
boundary
(
patch inlet
inlet
{
type patch;
faces
(
(32 72 74 34)
)
);
}
patch outlet
outlet
{
type patch;
faces
(
(37 39 79 77)
)
);
}
wall bottom
bottom
{
type wall;
faces
(
(32 33 73 72)
(12 13 53 52)
(28 29 69 68)
(36 37 77 76)
)
);
}
wall top
top
{
type wall;
faces
(
(34 74 75 35)
(15 55 54 14)
(31 71 70 30)
(38 78 79 39)
)
);
}
wall firstCyl
firstCyl
{
type wall;
faces
(
(0 40 41 1)
(1 41 42 2)
(2 42 43 3)
(3 43 40 0)
)
);
}
wall secondCyl
secondCyl
{
type wall;
faces
(
(16 56 57 17)
(17 57 58 18)
(18 58 59 19)
(19 59 56 16)
)
);
}
ggi frontIn
frontIn
{
type ggi;
shadowPatch frontOut;
zone frontInZone;
bridgeOverlap true;
faces
(
(33 35 75 73)
)
);
}
ggi frontOut
frontOut
{
type ggi;
shadowPatch frontIn;
zone frontOutZone;
bridgeOverlap true;
faces
(
(12 52 48 8)
(8 48 51 11)
(11 51 55 15)
)
);
}
ggi middleIn
middleIn
{
type ggi;
shadowPatch middleOut;
zone middleInZone;
bridgeOverlap true;
faces
(
(13 9 49 53)
(9 10 50 49)
(10 14 54 50)
)
);
}
ggi middleOut
middleOut
{
type ggi;
shadowPatch middleIn;
zone middleOutZone;
bridgeOverlap true;
faces
(
(28 68 64 24)
(24 64 67 27)
(27 67 71 31)
)
);
}
ggi backIn
backIn
{
type ggi;
shadowPatch backOut;
zone backInZone;
bridgeOverlap true;
faces
(
(29 25 65 69)
(25 26 66 65)
(26 30 70 66)
)
);
}
ggi backOut
backOut
{
type ggi;
shadowPatch backIn;
zone backOutZone;
bridgeOverlap true;
faces
(
(36 76 78 38)
)
);
}
);
// ************************************************************************* //