-
Notifications
You must be signed in to change notification settings - Fork 30
/
nozzle2D_example.geo
89 lines (76 loc) · 2.12 KB
/
nozzle2D_example.geo
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
// 2D mesh of a half nozzle
// rE _
// rS _ |\__ _ _ _ _ _
// | \__ ___/|
// | \__ ___/ |
// rC _ | _ _ _ \ / |
// 0 _ |__________|_________|
//
// <---------><-------->
// lConv lDiv
// Geometry details
// rE _ 4
// |\__
// | \__
// rS _ | _ _ \__ (3)_ _ _ _ _ _ _ 6
// | \__ (7)____/|
// |(4) \__ ____/ |
// | \__ ____/ |
// rC _ | _ _ _ _ _ _ \3/ |
// | |(6)
// | "1" (2)| "2" |
// | |
// 0 _ |___________________|________________|
// 1 (1) 2 (5) 5
// <-------------------><------------->
// lConv lDiv
//----------------- DATA -----------------
// Geo parameters
rE = 0.3;
rC = 0.1;
rS = 0.3;
lConv = 5.;
lDiv = 5.;
// Number of cells x-dir.
nbxLConv = 100;
nbxLDiv = 100;
// Number of cells y-dir.
nby = 1;
// Boundary condition numbers
bcAxis = 1;
bcWall = 2;
bcInlet = 3;
bcOutlet = 4;
surfFluid = 10;
//----------------- GEO -----------------
// Geometry convergent
Point(1) = {0, 0, 0};
Point(2) = {lConv, 0, 0};
Point(3) = {lConv, rC, 0};
Point(4) = {0, rE, 0};
Line(1) = {1,2};
Line(2) = {2,3};
Line(3) = {3,4};
Line(4) = {4,1};
Line Loop(1) = {1,2,3,4};
Plane Surface(1) = {1};
// Geometry divergent
Point(5) = {lConv+lDiv, 0, 0};
Point(6) = {lConv+lDiv, rS, 0};
Line(5) = {2,5};
Line(6) = {5,6};
Line(7) = {6,3};
Line Loop(2) = {5,6,7,-2};
Plane Surface(2) = {2};
// Structured mesh
Transfinite Line {1,3} = nbxLConv;
Transfinite Line {5,7} = nbxLDiv;
Transfinite Line {2,4,6} = nby;
Transfinite Surface "*";
Recombine Surface "*";
// Boundary conditions and fluid domain
Physical Line(bcAxis) = {1,5};
Physical Line(bcWall) = {3,7};
Physical Line(bcInlet) = {4};
Physical Line(bcOutlet) = {6};
Physical Surface(surfFluid) = {1,2};