3 $RockMaterial="ShotRock"; # current options: "Granite", "Dirt", "ShotRock"
8 $CavernWidth=$DetectorWidth+2*$TotalPadding;
9 $CavernHeight=$DetectorHeight+$TotalPadding;
10 $CavernLength=$DetectorLength+2*$TotalPadding;
13 $GlassFoamPadding=100;
14 $TotalPadding=$ConcretePadding+$GlassFoamPadding;
19 open(GDML) or die("Could not open file $GDML for writing");
22 <?xml version="1.0" encoding="UTF-8" ?>
23 <gdml xmlns:gdml="http://cern.ch/2001/Schemas/GDML"
24 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
25 xsi:noNamespaceSchemaLocation="GDMLSchema/gdml.xsd">
27 <constant name="kInch" value="2.54" />
28 <constant name="kPi" value="3.14159265358979" />
29 <constant name="kSteelThickness" value="0.5*kInch" />
33 <element name="videRef" formula="VACUUM" Z="1"> <atom value="1"/> </element>
34 <element name="bromine" formula="Br" Z="35"> <atom value="79.904"/> </element>
35 <element name="hydrogen" formula="H" Z="1"> <atom value="1.0079"/> </element>
36 <element name="nitrogen" formula="N" Z="7"> <atom value="14.0067"/> </element>
37 <element name="oxygen" formula="O" Z="8"> <atom value="15.999"/> </element>
38 <element name="aluminum" formula="Al" Z="13"> <atom value="26.9815"/> </element>
39 <element name="silicon" formula="Si" Z="14"> <atom value="28.0855"/> </element>
40 <element name="carbon" formula="C" Z="6"> <atom value="12.0107"/> </element>
41 <element name="potassium" formula="K" Z="19"> <atom value="39.0983"/> </element>
42 <element name="chromium" formula="Cr" Z="24"> <atom value="51.9961"/> </element>
43 <element name="iron" formula="Fe" Z="26"> <atom value="55.8450"/> </element>
44 <element name="nickel" formula="Ni" Z="28"> <atom value="58.6934"/> </element>
45 <element name="calcium" formula="Ca" Z="20"> <atom value="40.078"/> </element>
46 <element name="magnesium" formula="Mg" Z="12"> <atom value="24.305"/> </element>
47 <element name="sodium" formula="Na" Z="11"> <atom value="22.99"/> </element>
48 <element name="titanium" formula="Ti" Z="22"> <atom value="47.867"/> </element>
49 <element name="argon" formula="Ar" Z="18"> <atom value="39.9480"/> </element>
51 <material name="Vacuum" formula="Vacuum">
52 <D value="1.e-25" unit="g/cm3"/>
53 <fraction n="1.0" ref="videRef"/>
56 <material name="ALUMINUM_Al" formula="ALUMINUM_Al">
57 <D value="2.6990" unit="g/cm3"/>
58 <fraction n="1.0000" ref="aluminum"/>
61 <material name="SILICON_Si" formula="SILICON_Si">
62 <D value="2.3300" unit="g/cm3"/>
63 <fraction n="1.0000" ref="silicon"/>
66 <material name="epoxy_resin" formula="C38H40O6Br4">
67 <D value="1.1250" unit="g/cm3"/>
68 <composite n="38" ref="carbon"/>
69 <composite n="40" ref="hydrogen"/>
70 <composite n="6" ref="oxygen"/>
71 <composite n="4" ref="bromine"/>
74 <material name="SiO2" formula="SiO2">
75 <D value="2.2" unit="g/cm3"/>
76 <composite n="1" ref="silicon"/>
77 <composite n="2" ref="oxygen"/>
80 <material name="Al2O3" formula="Al2O3">
81 <D value="3.97" unit="g/cm3"/>
82 <composite n="2" ref="aluminum"/>
83 <composite n="3" ref="oxygen"/>
86 <material name="Fe2O3" formula="Fe2O3">
87 <D value="5.24" unit="g/cm3"/>
88 <composite n="2" ref="iron"/>
89 <composite n="3" ref="oxygen"/>
92 <material name="CaO" formula="CaO">
93 <D value="3.35" unit="g/cm3"/>
94 <composite n="1" ref="calcium"/>
95 <composite n="1" ref="oxygen"/>
98 <material name="MgO" formula="MgO">
99 <D value="3.58" unit="g/cm3"/>
100 <composite n="1" ref="magnesium"/>
101 <composite n="1" ref="oxygen"/>
104 <material name="Na2O" formula="Na2O">
105 <D value="2.27" unit="g/cm3"/>
106 <composite n="2" ref="sodium"/>
107 <composite n="1" ref="oxygen"/>
110 <material name="TiO2" formula="TiO2">
111 <D value="4.23" unit="g/cm3"/>
112 <composite n="1" ref="titanium"/>
113 <composite n="2" ref="oxygen"/>
116 <material name="fibrous_glass">
117 <D value="2.74351" unit="g/cm3"/>
118 <fraction n="0.600" ref="SiO2"/>
119 <fraction n="0.118" ref="Al2O3"/>
120 <fraction n="0.001" ref="Fe2O3"/>
121 <fraction n="0.224" ref="CaO"/>
122 <fraction n="0.034" ref="MgO"/>
123 <fraction n="0.010" ref="Na2O"/>
124 <fraction n="0.013" ref="TiO2"/>
127 <material name="FR4">
128 <D value="1.98281" unit="g/cm3"/>
129 <fraction n="0.47" ref="epoxy_resin"/>
130 <fraction n="0.53" ref="fibrous_glass"/>
133 <material name="STEEL_STAINLESS_Fe7Cr2Ni" formula="STEEL_STAINLESS_Fe7Cr2Ni">
134 <D value="7.9300" unit="g/cm3"/>
135 <fraction n="0.0010" ref="carbon"/>
136 <fraction n="0.1800" ref="chromium"/>
137 <fraction n="0.7298" ref="iron"/>
138 <fraction n="0.0900" ref="nickel"/>
141 <material name="LAr" formula="LAr">
142 <D value="1.40" unit="g/cm3"/>
143 <fraction n="1.0000" ref="argon"/>
146 <material formula=" " name="Air">
147 <D value="0.001205" unit="g/cm3"/>
148 <fraction n="0.78084" ref="nitrogen"/>
149 <fraction n="0.209476" ref="oxygen"/>
150 <fraction n="0.00934" ref="argon"/>
153 <material formula=" " name="G10">
154 <D value="1.7" unit="g/cm3"/>
155 <fraction n="0.2805" ref="silicon"/>
156 <fraction n="0.3954" ref="oxygen"/>
157 <fraction n="0.2990" ref="carbon"/>
158 <fraction n="0.0251" ref="hydrogen"/>
161 <material formula=" " name="Granite">
162 <D value="2.7" unit="g/cm3"/>
163 <fraction n="0.438" ref="oxygen"/>
164 <fraction n="0.257" ref="silicon"/>
165 <fraction n="0.222" ref="sodium"/>
166 <fraction n="0.049" ref="aluminum"/>
167 <fraction n="0.019" ref="iron"/>
168 <fraction n="0.015" ref="potassium"/>
171 <material formula=" " name="ShotRock">
172 <D value="2.7*0.6" unit="g/cm3"/>
173 <fraction n="0.438" ref="oxygen"/>
174 <fraction n="0.257" ref="silicon"/>
175 <fraction n="0.222" ref="sodium"/>
176 <fraction n="0.049" ref="aluminum"/>
177 <fraction n="0.019" ref="iron"/>
178 <fraction n="0.015" ref="potassium"/>
181 <material formula=" " name="Dirt">
182 <D value="1.7" unit="g/cm3"/>
183 <fraction n="0.438" ref="oxygen"/>
184 <fraction n="0.257" ref="silicon"/>
185 <fraction n="0.222" ref="sodium"/>
186 <fraction n="0.049" ref="aluminum"/>
187 <fraction n="0.019" ref="iron"/>
188 <fraction n="0.015" ref="potassium"/>
191 <material formula=" " name="Concrete">
192 <D value="2.3" unit="g/cm3"/>
193 <fraction n="0.530" ref="oxygen"/>
194 <fraction n="0.335" ref="silicon"/>
195 <fraction n="0.060" ref="calcium"/>
196 <fraction n="0.015" ref="sodium"/>
197 <fraction n="0.020" ref="iron"/>
198 <fraction n="0.040" ref="aluminum"/>
201 <material formula="H2O" name="Water">
202 <D value="1.0" unit="g/cm3"/>
203 <fraction n="0.1119" ref="hydrogen"/>
204 <fraction n="0.8881" ref="oxygen"/>
207 <material formula="Ti" name="Titanium">
208 <D value="4.506" unit="g/cm3"/>
209 <fraction n="1." ref="titanium"/>
212 <material name="TPB" formula="TPB">
213 <D value="1.40" unit="g/cm3"/>
214 <fraction n="1.0000" ref="argon"/>
217 <material name="Glass">
218 <D value="2.74351" unit="g/cm3"/>
219 <fraction n="0.600" ref="SiO2"/>
220 <fraction n="0.118" ref="Al2O3"/>
221 <fraction n="0.001" ref="Fe2O3"/>
222 <fraction n="0.224" ref="CaO"/>
223 <fraction n="0.034" ref="MgO"/>
224 <fraction n="0.010" ref="Na2O"/>
225 <fraction n="0.013" ref="TiO2"/>
228 <material name="Acrylic">
229 <D value="1.19" unit="g/cm3"/>
230 <fraction n="0.600" ref="carbon"/>
231 <fraction n="0.320" ref="oxygen"/>
232 <fraction n="0.080" ref="hydrogen"/>
237 <box name="World" lunit="cm"
238 x="$CavernWidth+$RockThickness"
239 y="$CavernHeight+$RockThickness"
240 z="$CavernLength+$RockThickness"/>
241 <box name="Rock" lunit="cm"
242 x="$CavernWidth+$RockThickness"
243 y="$CavernHeight+$RockThickness"
244 z="$CavernLength+$RockThickness"/>
245 <box name="RockBottom" lunit="cm"
249 <box name="Cavern" lunit="cm"
251 y="$CavernHeight+2*$RockThickness+100"
253 <subtraction name="RockWithCavern">
255 <second ref="Cavern"/>
257 <box name="Concrete" lunit="cm"
261 <box name="ConcreteBottom" lunit="cm"
265 <box name="ConcreteCavern" lunit="cm"
269 <subtraction name="ConcreteWithCavern">
270 <first ref="Concrete"/>
271 <second ref="ConcreteCavern"/>
273 <box name="SteelBox" lunit="cm"
277 <box name="ArgonInterior" lunit="cm"
278 x="1900-2*150-kSteelThickness"
279 y="1600-kSteelThickness"
280 z="1700-2*150-kSteelThickness"/>
281 <subtraction name="CryostatSteelShell">
282 <first ref="SteelBox"/>
283 <second ref="ArgonInterior"/>
288 <volume name="volArgonInterior">
289 <materialref ref="LAr" />
290 <solidref ref="ArgonInterior" />
292 <volume name="volCryostatSteelShell">
293 <materialref ref="STEEL_STAINLESS_Fe7Cr2Ni" />
294 <solidref ref="CryostatSteelShell" />
296 <volume name="volConcreteWithCavern">
297 <materialref ref="Concrete" />
298 <solidref ref="ConcreteWithCavern" />
300 <volume name="volConcreteBottom">
301 <materialref ref="Concrete" />
302 <solidref ref="ConcreteBottom" />
304 <volume name="volRockWithCavern">
305 <materialref ref="$RockMaterial" />
306 <solidref ref="RockWithCavern" />
308 <volume name="volRockBottom">
309 <materialref ref="$RockMaterial" />
310 <solidref ref="RockBottom" />
312 <volume name="volWorld" >
313 <materialref ref="Air"/>
314 <solidref ref="World"/>
316 <volumeref ref="volCryostatSteelShell"/>
317 <position name="posCryostatSteelShell" unit="cm" x="0" y="250+(1550/2)" z="0"/>
320 <volumeref ref="volArgonInterior"/>
321 <position name="posArgonInterior" unit="cm" x="0" y="250+(1550/2)" z="0"/>
324 <volumeref ref="volConcreteWithCavern"/>
325 <position name="posConcreteWithCavern" unit="cm" x="0" y="150+(1700/2)" z="0"/>
328 <volumeref ref="volConcreteBottom"/>
329 <position name="posConcreteWithCavern" unit="cm" x="0" y="150+(50/2)" z="0"/>
332 <volumeref ref="volRockWithCavern"/>
333 <position name="posRockWithCavern" unit="cm" x="0" y="0" z="0"/>
336 <volumeref ref="volRockBottom"/>
337 <position name="posRockBottom" unit="cm" x="0" y="-850" z="0"/>
340 <volumeref ref="volRockWithCavern"/>
341 <position name="posRockWithCavern" unit="cm" x="0" y="0" z="0"/>
344 <volumeref ref="volRockBottom"/>
345 <position name="posRockBottom" unit="cm" x="0" y="-850" z="0"/>
350 <setup name="Default" version="1.0">
351 <world ref="volWorld" />