Skip to content

Commit 84d6874

Browse files
committed
Checking in variants of bolted-joint geometry from John.
1 parent 5fa1588 commit 84d6874

File tree

2 files changed

+261
-0
lines changed

2 files changed

+261
-0
lines changed
Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,135 @@
1+
## create base
2+
#{offset = 0.005}
3+
brick x 5 y 0.5 z 5
4+
move volume 1 y 0.25 include_merged
5+
6+
## create plhange base
7+
create cylinder height 0.25 radius 2.2
8+
rotate volume 2 angle 90 about x include_merged
9+
move volume 2 y {0.125 + 0.5 + offset} include_merged
10+
11+
## create plhange
12+
brick x 2 y 2.25 z 2
13+
brick x 1.5 y 2.0 z 1.5
14+
move volume 4 y -0.125
15+
subtract volume 4 from volume 3
16+
tweak curve 15, 17, 19, 21, 39, 41, 43, 45 fillet radius 0.5
17+
move volume 3 y {1.125 + 0.5 + offset} include_merged
18+
subtract volume 3 from volume 2 keep
19+
split body 5
20+
delete volume 2
21+
delete volume 5
22+
23+
## Round base edges
24+
tweak curve 1 3 5 7 fillet radius 0.5
25+
26+
## Create hole for first bolt
27+
create cylinder height {0.75 + offset} radius {0.164 + 0.002}
28+
rotate volume 7 angle 90 about x include_merged
29+
move volume 7 location 1.25 {(0.75 + offset)/2.0} 1.25 include_merged
30+
31+
## Create other bolt holes
32+
volume 7 copy move z -2.5 # volume 8
33+
volume 7 copy move x -2.5 # volume 9
34+
volume 7 copy move x -2.5 z -2.5 # volume 10
35+
volume 7 copy move x -3. z -1.25 # volume 11
36+
volume 7 copy move x 0.5 z -1.25 # volume 12
37+
subtract volume 7 8 9 10 11 12 from volume 6
38+
39+
## Create shaft of first bolt
40+
# if change number of bolts, e.g. to 4 volume 13 must become 11
41+
create cylinder height {0.75 + offset} radius {0.164 + 0.002}
42+
rotate volume 13 angle 90 about x include_merged
43+
move volume 13 location 1.25 {(0.75 + offset)/2.0} 1.25 include_merged
44+
45+
## Create head of bolt and unite
46+
# if change number of bolts, e.g. to 4 volume 14 must become 12
47+
create cylinder height 0.164 radius 0.25
48+
rotate volume 14 angle 90 about x include_merged
49+
move volume 14 location 1.25 {0.164/2.0+0.5+0.25+offset} 1.25 include_merged
50+
unite volume 13 14 # volume 13
51+
52+
## Copy bolts to a bolt pattern
53+
# if change number of bolts, e.g. to 4 volume 13 must become 11
54+
volume 13 copy move z -2.5 # volume 15
55+
volume 13 copy move x -2.5 # volume 16
56+
volume 13 copy move x -2.5 z -2.5 # volume 17
57+
volume 13 copy move x -3. z -1.25 # volume 18
58+
volume 13 copy move x 0.5 z -1.25 # volume 19
59+
60+
## Subtract and keep bolts in plate
61+
subtract volume 13 15 16 17 18 19 from volume 1 keep
62+
delete volume 1 # renames base plate to volume 20 (with 6 bolts)
63+
64+
# Be very specific about imprinting and merging
65+
imprint volume 13 15 16 17 18 19 20
66+
merge volume 13 15 16 17 18 19 20
67+
68+
# Make sure we do not merge the shafts in body 6 with the bolts
69+
imprint volume 13 15 16 17 18 19 6
70+
surface 79 80 81 82 83 84 merge off # bolt surfaces of volume 6
71+
merge volume 13 15 16 17 18 19 6
72+
73+
# imprinting caused a small surfaces (of gap width) in each shaft
74+
# composite surfaces to remedy the issue
75+
composite create surface 147 148
76+
composite create surface 149 150
77+
composite create surface 151 152
78+
composite create surface 153 154
79+
composite create surface 155 156
80+
composite create surface 157 158
81+
82+
# still need to imprint and merge component
83+
imprint volume 3 6
84+
merge volume 3 6
85+
86+
# set scheme for tetmeshing
87+
volume all scheme tetmesh proximity layers off
88+
trimesher surface gradation 1.2
89+
trimesher volume gradation 1.2
90+
set tetmesher optimize level 6 overconstrained off sliver off
91+
set tetmesher interior points on
92+
set tetmesher boundary recovery off
93+
94+
#{coarse_size = 0.25}
95+
#{medium_size = 0.125}
96+
97+
# mesh attachement
98+
volume 3 6 size {coarse_size}
99+
surface 79 80 81 82 83 84 size {medium_size}
100+
mesh volume 3 6
101+
102+
# mesh plate
103+
volume 16 size {coarse_size}
104+
surface 119 120 121 122 123 124 size {medium_size}
105+
mesh volume 20
106+
107+
# mesh bolts
108+
volume 13 15 16 17 18 19 size {medium_size}
109+
mesh volume 13 15 16 17 18 19
110+
111+
# assign blocks
112+
block 1 volume 3 6
113+
block 2 volume 20
114+
block 3 volume 13 15 16 17 18 19
115+
block 1 name "component"
116+
block 2 name "plate"
117+
block 3 name "bolts"
118+
block all element type tetra4
119+
120+
# assign nodesets
121+
nodeset 1 surface 125 127 128 129 130 131 132 134
122+
nodeset 1 name "base_plate"
123+
nodeset 2 surface 14 # top of shaft
124+
nodeset 2 name "loading"
125+
126+
# assign sidesets
127+
sideset 1 surface 125 127 128 129 130 131 132 134
128+
sideset 1 name "base_plate_ss"
129+
sideset 2 surface 14 # top of shaft
130+
sideset 2 name "loading_ss"
131+
132+
body all scale 0.0254 0.0254 0.0254
133+
134+
#export to genesis
135+
export mesh "joint_circular_coarse.g" overwrite
Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
# create plate and attachment
2+
#{offset = 0.005}
3+
4+
undo off
5+
brick x 5 y 0.5 z 5
6+
move volume 1 y 0.25 include_merged
7+
brick x 3.5 y 0.25 z 3.5
8+
move volume 2 y {0.125 + 0.5 + offset} include_merged
9+
10+
brick x 2 y 2.25 z 2
11+
brick x 1.5 y 2.0 z 1.5
12+
move volume 4 y -0.125
13+
subtract volume 4 from volume 3
14+
15+
tweak curve 49 53 55 51 25 29 31 27 fillet radius 0.5
16+
move volume 3 y {1.125 + 0.5 + offset} include_merged
17+
18+
subtract volume 3 from volume 2 keep
19+
split body 5
20+
delete volume 2
21+
delete volume 6
22+
23+
tweak curve 119 117 121 123 fillet radius 0.5
24+
tweak curve 1 3 5 7 fillet radius 0.5
25+
26+
# create holes for bolts
27+
create cylinder height {0.75 + offset} radius {0.082 + 0.002}
28+
rotate volume 7 angle 90 about x include_merged
29+
move volume 7 location 1.25 {(0.75 + offset)/2.0} 1.25 include_merged
30+
volume 7 copy move z -2.5
31+
volume 7 copy move x -2.5
32+
volume 7 copy move x -2.5 z -2.5
33+
subtract volume 7 8 9 10 from volume 5
34+
35+
# create shaft of bolt
36+
# because mesh is continuous, can't have a small gap with 0.002 sized elements
37+
# consequently, we remove the gap by increasing the diameter of the screw
38+
create cylinder height {0.75 + offset} radius {0.082 + 0.002}
39+
rotate volume 11 angle 90 about x include_merged
40+
move volume 11 location 1.25 {(0.75 + offset)/2.0} 1.25 include_merged
41+
42+
# create head of bolt and unite
43+
create cylinder height 0.164 radius 0.125
44+
rotate volume 12 angle 90 about x include_merged
45+
move volume 12 location 1.25 {0.164/2.0+0.5+0.25+offset} 1.25 include_merged
46+
unite volume 11 12
47+
48+
# copy bolts to a bolt pattern
49+
volume 11 copy move z -2.5
50+
volume 11 copy move x -2.5
51+
volume 11 copy move x -2.5 z -2.5
52+
53+
# subtract and keep bolts in plate
54+
subtract volume 11 13 14 15 from volume 1 keep
55+
delete volume 1
56+
57+
# be very specific about imprinting and merging
58+
imprint volume 11 13 14 15 16
59+
merge volume 11 13 14 15 16
60+
61+
# make sure we do not merge the shafts in body 5 with the bolts
62+
imprint volume 11 13 14 15 5
63+
surface 85 83 84 86 merge off
64+
merge volume 11 13 14 15 5
65+
66+
# imprinting caused a small surfaces (of gap width) in each shaft
67+
# composite surfaces to remedy the issue
68+
composite create surface 133 134
69+
composite create surface 137 138
70+
composite create surface 139 140
71+
composite create surface 135 136
72+
73+
# still need to imprint and merge component
74+
imprint volume 3 5
75+
merge volume 3 5
76+
77+
# set scheme for tetmeshing
78+
volume all scheme tetmesh proximity layers off
79+
trimesher surface gradation 1.2
80+
trimesher volume gradation 1.2
81+
set tetmesher optimize level 6 overconstrained off sliver off
82+
set tetmesher interior points on
83+
set tetmesher boundary recovery off
84+
85+
#{coarse_size = 0.125}
86+
#{medium_size = 0.0625}
87+
88+
# mesh attachement
89+
volume 3 5 size {coarse_size}
90+
surface 85 83 84 86 size {medium_size}
91+
mesh volume 3 5
92+
93+
# mesh plate
94+
volume 16 size {coarse_size}
95+
surface 112 111 113 114 size {medium_size}
96+
mesh volume 16
97+
98+
# mesh bolts
99+
volume 11 13 14 15 size {medium_size}
100+
mesh volume 11 13 14 15
101+
102+
# assign blocks
103+
block 1 volume 3 5
104+
block 2 volume 16
105+
block 3 volume 11 13 14 15
106+
block 1 name "component"
107+
block 2 name "plate"
108+
block 3 name "bolts"
109+
block all element type tetra4
110+
111+
# assign nodesets
112+
nodeset 1 surface 117 115 122 119 120 121 124 118
113+
nodeset 1 name "base_plate"
114+
nodeset 2 surface 17
115+
nodeset 2 name "loading"
116+
117+
# assign sidesets (needed for Dirichlet/Neumann BCs in MrHyDE)
118+
sideset 1 surface 117 115 122 119 120 121 124 118
119+
sideset 1 name "base_plate_ss"
120+
sideset 2 surface 17
121+
sideset 2 name "loading_ss"
122+
123+
body all scale 0.0254 0.0254 0.0254
124+
125+
#export to genesis
126+
export mesh "joint_small_bolts_medium.g" overwrite

0 commit comments

Comments
 (0)