/[PAMELA software]/gpamela/gpnd/gpndv.F
ViewVC logotype

Contents of /gpamela/gpnd/gpndv.F

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.3 - (show annotations) (download)
Thu Oct 12 11:11:21 2006 UTC (18 years, 1 month ago) by pam-ba
Branch: MAIN
Changes since 1.2: +184 -27 lines
ND geometry updated.

1 SUBROUTINE GPNDV
2 ************************************************************************
3 * *
4 * Volumes definition for the neutron detector *
5 * Called by: GPGEOM *
6 * Author: Francesco Cafagna, 05-sep-05 *
7 * *
8 ************************************************************************
9 #include "gpgeo.inc"
10 #include "gpmed.inc"
11 #include "gpkey.inc"
12 *
13 INTEGER IROT,IVOLU,N,NMED
14 REAL X,Y,Z
15
16 *
17 * Define the NDBO volume
18 *
19 NMED= MN2
20 CALL GSVOLU('NDBO','BOX ',NMED,NDBO, 3,IVOLU)
21 *
22 * Define the NDBX volume
23 *
24 NMED= MAL
25 CALL GSVOLU('NDBX','BOX ',NMED,NDBX, 3,IVOLU)
26 *
27 * Define the NDCD volume
28 *
29 NMED= MN2
30 CALL GSVOLU('NDCD','BOX ',NMED,NDCD, 3,IVOLU)
31 *
32 * Define the NDBI volume
33 *
34 NMED= MN2
35 CALL GSVOLU('NDBI','BOX ',NMED,NDBI, 3,IVOLU)
36 *
37 * Define the NDTU volume
38 *
39 NMED= MIRON
40 NMED= MSCIN
41 CALL GSVOLU('NDTU','TUBE',NMED,NDTU, 3,IVOLU)
42 *
43 * Define the NDTI volume
44 *
45 NMED= MHEND
46 NMED= MSCIN
47 CALL GSVOLU('NDTI','TUBE',NMED,NDTI, 3,IVOLU)
48 *
49 * Define the NDPB volume
50 *
51 NMED= MC2H4
52 NMED= MN2
53 CALL GSVOLU('NDPB','BOX ',NMED,NDPB, 3,IVOLU)
54 *
55 * Define the NDCO volume
56 *
57 NMED= MAL
58 CALL GSVOLU('NDCO','BOX ',NMED,NDCO, 3,IVOLU)
59 *
60 * Define the NDBS volume
61 *
62 NMED= MAL
63 CALL GSVOLU('NDBS','BOX ',NMED,NDBS, 3,IVOLU)
64 *
65 * Define the NDSS volume
66 *
67 NMED= MN2
68 CALL GSVOLU('NDSS','BOX ',NMED,NDSS, 3,IVOLU)
69 *
70 * Define the NDCI volume
71 *
72 NMED= MN2
73 CALL GSVOLU('NDCI','BOX ',NMED,NDCI, 3,IVOLU)
74 *
75 * Define the NDCM volume
76 *
77 NMED= MN2
78 CALL GSVOLU('NDCM','BOX ',NMED,NDCM, 3,IVOLU)
79 *
80 * Define the NDCE volume
81 *
82 NMED= MN2
83 CALL GSVOLU('NDCE','BOX ',NMED,NDCE, 3,IVOLU)
84 *
85 * Define the NDSI volume
86 *
87 NMED= MN2
88 CALL GSVOLU('NDSI','BOX ',NMED,NDSI, 3,IVOLU)
89 *
90 * Define the NDSM volume
91 *
92 NMED= MN2
93 CALL GSVOLU('NDSM','BOX ',NMED,NDSM, 3,IVOLU)
94 *
95 * Define the NDSE volume
96 *
97 NMED= MN2
98 CALL GSVOLU('NDSE','BOX ',NMED,NDSE, 3,IVOLU)
99 *
100 * Positioning volumes NDTI inside NDTU.
101 *
102 N = 1
103 X = 0.
104 Y = 0.
105 Z = 0.
106 CALL GSPOS('NDTI',N,'NDTU',X,Y,Z,0,'ONLY')
107 *
108 * Positioning volume NDTU inside the mother NDPB
109 *
110 N = 0
111 Y = 0.
112 C #
113 C # Start to put tube on top of a cmd and 3 pholyetilene planes
114 C #
115 DO I=1,2
116 C #
117 cC # Place a tube layer at a 4 mm distance each
118 C # Place a tube layer at a 5 mm distance each
119 C #
120 c X = -NDBI(2) + 0.2 + 1.1
121 X = -NDBI(1) + 0.3 + NDTU(2)
122 C Z = -NDBI(3) + 2.*NDCD(3) + 3.*(2.*NDPB(3)) + NDTU(2)
123 C + + (I-1)*4*NDPB(3)
124 Z = -NDBI(3)+3.*(2.*NDPB(3))+NDTU(2)
125 + + (I-1)*2*NDPB(3)+(I-1)*2*NDTU(2)
126 DO II=1,18
127 N= N + 1
128 C CALL GSPOS('NDTU',N,'NDBI',X,Y,Z,2,'MANY')
129 CALL GSPOS('NDTU',N,'NDBI',X,Y,Z,2,'ONLY')
130 C X = X + 2.2
131 X=X+2*NDTU(2)+GNDTU
132 ENDDO
133 ENDDO
134 *
135 * Positioning volume NDPB inside the mother NDBI
136 *
137 N = 0
138 X = 0.
139 Y = 0.
140 C #
141 C # Stack 3 planes then leave the tube gap between the last two
142 C #
143 DO I=1,3
144 N= N + 1
145 c Z = -NDBI(3) + 2.*NDCD(3) + (I-1)*2.*NDPB(3) + NDPB(3)
146 Z=-NDBI(3)+(I-1)*2.*NDPB(3)+NDPB(3)
147 C CALL GSPOS('NDPB',N,'NDBI',X,Y,Z,0,'MANY')
148 CALL GSPOS('NDPB',N,'NDBI',X,Y,Z,0,'ONLY')
149 ENDDO
150 DO I=1,2
151 C Z = -NDBI(3) + 2.*NDCD(3) + 4.*2.*NDPB(3) + NDPB(3)
152 C + + (I-1)*4.*NDPB(3)
153 Z = -NDBI(3) + 3.*2.*NDPB(3) + NDPB(3)
154 + + (I-1)*2.*NDPB(3)+I*2*NDTU(2)
155 N= N + 1
156 C CALL GSPOS('NDPB',N,'NDBI',X,Y,Z,0,'MANY')
157 CALL GSPOS('NDPB',N,'NDBI',X,Y,Z,0,'ONLY')
158 ENDDO
159 C #
160 C # Now put the internal volume inside the cadmium box
161 C # *
162 N = 1
163 X = 0.
164 Y = 0.
165 Z=-NDCD(3)+NDBI(3)+TNDCD
166 CALL GSPOS('NDBI',N,'NDCD',X,Y,Z,0,'ONLY')
167 C #
168 C # Positioning the NDCD inside NDBX
169 C #
170 N=1
171 X = 0
172 Y = 0
173 Z=-NDBX(3)+NDCD(3)+TNDBX
174 CALL GSPOS('NDCD',N,'NDBX',X,Y,Z,0,'ONLY')
175 C #
176 C # Positioning the NDBX inside NDBO
177 C #
178 N=1
179 X = 0
180 Y = 0
181 Z=-NDBO(3)+NDBX(3)
182 CALL GSPOS('NDBX',N,'NDBO',X,Y,Z,0,'ONLY')
183 C #
184 C # Positioning the NDCM inside NDCO
185 C #
186 N=0
187 X = 0
188 Z=NDCO(3)-NDCM(3)
189 DO I=-1,1,2
190 N=N+1
191 Y = I*(NDCI(2)+1.4+NDCM(2))
192 CALL GSPOS('NDCM',N,'NDCO',X,Y,Z,0,'ONLY')
193 ENDDO
194 C #
195 C # Positioning the NDCI inside NDCO
196 C #
197 N=1
198 X = 0
199 Y = 0
200 Z=NDCO(3)-NDCI(3)
201 CALL GSPOS('NDCI',N,'NDCO',X,Y,Z,0,'ONLY')
202 C #
203 C # Positioning the NDCE inside NDCO
204 C #
205 N=0
206 X = 0
207 Z=NDCO(3)-NDCE(3)
208 DO I=-1,1,2
209 N=N+1
210 Y = I*(NDCI(2)+1.4+2*NDCM(2)+1.4+NDCE(2))
211 CALL GSPOS('NDCE',N,'NDCO',X,Y,Z,0,'ONLY')
212 ENDDO
213 C #
214 C # Positioning the NDSM inside NDCO
215 C #
216 N=0
217 Z=NDCO(3)-NDSM(3)
218 DO I=-1,1,2
219 Y = I*(NDCO(2)-9.6-NDSM(2))
220 DO j=-1,1,2
221 N=N+1
222 X=J*(NDCO(1)-2.9-NDSM(1))
223 CALL GSPOS('NDSM',N,'NDCO',X,Y,Z,0,'ONLY')
224 ENDDO
225 ENDDO
226 C #
227 C # Positioning the NDSI inside NDCO
228 C #
229 N=0
230 Z=NDCO(3)-NDSI(3)
231 Y=0.
232 DO j=-1,1,2
233 N=N+1
234 X=J*(NDCO(1)-2.9-NDSI(1))
235 CALL GSPOS('NDSI',N,'NDCO',X,Y,Z,0,'ONLY')
236 ENDDO
237 C #
238 C # Positioning the NDSE inside NDCO
239 C #
240 N=0
241 Z=NDCO(3)-NDSE(3)
242 DO I=-1,1,2
243 Y = I*(NDCI(2)+1.4+2*NDCM(2)+1.4+NDSE(2))
244 DO j=-1,1,2
245 N=N+1
246 X=J*(NDCE(1)+1.6+NDSE(1))
247 CALL GSPOS('NDSE',N,'NDCO',X,Y,Z,0,'ONLY')
248 ENDDO
249 ENDDO
250 C #
251 C # Positioning the NDCO inside NDBO
252 C #
253 N=1
254 X = 0
255 Y = 0
256 Z=NDBO(3)-NDCO(3)
257 CALL GSPOS('NDCO',N,'NDBO',X,Y,Z,0,'ONLY')
258 C #
259 C # Positioning the NDBS inside NDBO
260 C #
261 N=0
262 DO I=-1,1,2
263 N=N+1
264 X = 0.
265 Y = I*NDBO(2)-I*NDBS(2)
266 Z=-NDBO(3)+NDBS(3)
267 CALL GSPOS('NDBS',N,'NDBO',X,Y,Z,0,'ONLY')
268 ENDDO
269 N=1
270 X = 0.
271 Y = 0.
272 Z=0.
273 CALL GSPOS('NDSS',N,'NDBS',X,Y,Z,0,'ONLY')
274 RETURN
275 END

  ViewVC Help
Powered by ViewVC 1.1.23