41
42
43
45 USE elbufdef_mod
46
47
48
49#include "implicit_f.inc"
50
51
52
53#include "parit_c.inc"
54#include "scr02_c.inc"
55#include "scr18_c.inc"
56
57
58
59 TYPE(NLOCAL_STR_), INTENT(INOUT), TARGET :: NLOC_DMG
60 my_real,
DIMENSION(NEL),
INTENT(IN) :: var_reg
61 INTEGER, INTENT(IN) :: NEL
62 my_real,
DIMENSION(NEL),
INTENT(IN) :: off
63 my_real,
DIMENSION(NEL),
INTENT(IN) :: vol
64 INTEGER, DIMENSION(NEL) :: NC1
65 INTEGER, DIMENSION(NEL) :: NC2
66 INTEGER, DIMENSION(NEL) :: NC3
67 INTEGER, DIMENSION(NEL) :: NC4
68 INTEGER, DIMENSION(NEL) :: NC5
69 INTEGER, DIMENSION(NEL) :: NC6
70 INTEGER, DIMENSION(NEL) :: NC7
71 INTEGER, DIMENSION(NEL) :: NC8
72 my_real,
DIMENSION(NEL),
INTENT(IN) :: px1
73 my_real,
DIMENSION(NEL),
INTENT(IN) :: px2
74 my_real,
DIMENSION(NEL),
INTENT(IN) :: px3
75 my_real,
DIMENSION(NEL),
INTENT(IN) :: px4
76 my_real,
DIMENSION(NEL),
INTENT(IN) :: py1
77 my_real,
DIMENSION(NEL),
INTENT(IN) :: py2
78 my_real,
DIMENSION(NEL),
INTENT(IN) :: py3
79 my_real,
DIMENSION(NEL),
INTENT(IN) :: py4
80 my_real,
DIMENSION(NEL),
INTENT(IN) :: pz1
81 my_real,
DIMENSION(NEL),
INTENT(IN) :: pz2
82 my_real,
DIMENSION(NEL),
INTENT(IN) :: pz3
83 my_real,
DIMENSION(NEL),
INTENT(IN) :: pz4
84 INTEGER, INTENT(IN) :: IMAT
85 INTEGER, INTENT(IN) :: ITASK
87 my_real,
DIMENSION(NEL),
INTENT(IN) :: vol0
88 INTEGER, INTENT(IN) :: NFT
89
90
91
92 INTEGER I,II,K,N1,N2,N3,N4,N5,N6,N7,N8,L_NLOC
93 INTEGER, DIMENSION(:), ALLOCATABLE ::
94 . POS1,POS2,POS3,POS4,POS5,POS6,POS7,POS8
96 . l2,ntn_unl,ntn_vnl,xi,ntvar,a,
97 . b1,b2,b3,b4,b5,b6,b7,b8,zeta,sspnl,dtnl,le_max,
98 . maxstif,ntn
99 my_real,
DIMENSION(:) ,
ALLOCATABLE ::
100 . btb11,btb12,btb13,btb14,btb22,btb23,btb24,
101 . btb33,btb34,btb44,sti1,sti2,sti3,sti4,sti5,
102 . sti6,sti7,sti8,f1,f2,f3,f4,f5,f6,f7,f8,lc
103 my_real,
POINTER,
DIMENSION(:) ::
104 . vnl,fnl,unl,stifnl,mass,mass0,vnl0
105
107
108
109
110
111
112 nothing = zero
113 vnl => nothing
114 fnl => nothing
115 unl => nothing
116 stifnl => nothing
117 mass => nothing
118 mass0 => nothing
119 vnl0 => nothing
120
121
122 l2 = nloc_dmg%LEN(imat)**2
123 xi = nloc_dmg%DAMP(imat)
124 l_nloc = nloc_dmg%L_NLOC
125 zeta = nloc_dmg%DENS(imat)
126 sspnl = nloc_dmg%SSPNL(imat)
127 le_max = nloc_dmg%LE_MAX(imat)
128
129
130 ALLOCATE(btb11(nel),btb12(nel),btb13(nel),btb14(nel),btb22(nel),
131 . btb23(nel),btb24(nel),btb33(nel),btb34(nel),btb44(nel),pos1(nel),
132 . pos2(nel),pos3(nel),pos4(nel),pos5(nel),pos6(nel),pos7(nel),pos8(nel),
133 . f1(nel),f2(nel),f3(nel),f4(nel),f5(nel),f6(nel),f7(nel),f8(nel),lc(nel))
134
135
136 ntn = eight*eight
137
138
139 lc(1:nel) = zero
140
141 IF (nodadt > 0) THEN
142
143 ALLOCATE(sti1(nel),sti2(nel),sti3(nel),sti4(nel),sti5(nel),sti6(nel),
144 . sti7(nel),sti8(nel))
145
146 mass => nloc_dmg%MASS(1:l_nloc)
147
148 mass0 => nloc_dmg%MASS0(1:l_nloc)
149 ENDIF
150
151 vnl => nloc_dmg%VNL(1:l_nloc)
152
153 vnl0 => nloc_dmg%VNL_OLD(1:l_nloc)
154
155 unl => nloc_dmg%UNL(1:l_nloc)
156
157
158
159
160
161 DO i=1,nel
162
163
164 n1 = nloc_dmg%IDXI(nc1(i))
165 n2 = nloc_dmg%IDXI(nc2(i))
166 n3 = nloc_dmg%IDXI(nc3(i))
167 n4 = nloc_dmg%IDXI(nc4(i))
168 n5 = nloc_dmg%IDXI(nc5(i))
169 n6 = nloc_dmg%IDXI(nc6(i))
170 n7 = nloc_dmg%IDXI(nc7(i))
171 n8 = nloc_dmg%IDXI(nc8(i))
172
173
174 pos1(i) = nloc_dmg%POSI(n1)
175 pos2(i) = nloc_dmg%POSI(n2)
176 pos3(i) = nloc_dmg%POSI(n3)
177 pos4(i) = nloc_dmg%POSI(n4)
178 pos5(i) = nloc_dmg%POSI(n5)
179 pos6(i) = nloc_dmg%POSI(n6)
180 pos7(i) = nloc_dmg%POSI(n7)
181 pos8(i) = nloc_dmg%POSI(n8)
182
183
184 btb11(i) = px1(i)**2 + py1(i)**2 + pz1(i)**2
185 btb12(i) = px1(i)*px2(i) + py1(i)*py2(i) + pz1(i)*pz2(i)
186 btb13(i) = px1(i)*px3(i) + py1(i)*py3(i) + pz1(i)*pz3(i)
187 btb14(i) = px1(i)*px4(i) + py1(i)*py4(i) + pz1(i)*pz4(i)
188 btb22(i) = px2(i)**2 + py2(i)**2 + pz2(i)**2
189 btb23(i) = px2(i)*px3(i) + py2(i)*py3(i) + pz2(i)*pz3(i)
190 btb24(i) = px2(i)*px4(i) + py2(i)*py4(i) + pz2(i)*pz4(i)
191 btb33(i) = px3(i)**2 + py3(i)**2 + pz3(i)**2
192 btb34(i) = px3(i)*px4(i) + py3(i)*py4(i) + pz3(i)*pz4(i)
193 btb44(i) = px4(i)**2 + py4(i)**2 + pz4(i)**2
194
195 ENDDO
196
197
198
199
200
201 DO i = 1, nel
202
203
204 IF (off(i) /= zero) THEN
205
206
207 ntn_unl = (unl(pos1(i)) + unl(pos2(i)) + unl(pos3(i)) + unl(pos4(i))
208 . + unl(pos5(i)) + unl(pos6(i)) + unl(pos7(i)) + unl(pos8(i))) / ntn
209
210
211 ntn_vnl = (vnl(pos1(i)) + vnl(pos2(i)) + vnl(pos3(i)) + vnl(pos4(i))
212 . + vnl(pos5(i)) + vnl(pos6(i)) + vnl(pos7(i)) + vnl(pos8(i))) / ntn
213 IF (nodadt > 0) THEN
214 ntn_vnl =
min(sqrt(mass(pos1(i))/mass0(pos1(i))),
215 . sqrt(mass(pos2(i))/mass0(pos2(i))),
216 . sqrt(mass(pos3(i))/mass0(pos3(i))),
217 . sqrt(mass(pos4(i))/mass0(pos4(i))),
218 . sqrt(mass(pos5(i))/mass0(pos5(i))),
219 . sqrt(mass(pos6(i))/mass0(pos6(i))),
220 . sqrt(mass(pos7(i))/mass0(pos7(i))),
221 . sqrt(mass(pos8(i))/mass0(pos8(i))))*ntn_vnl
222 ENDIF
223
224
225 b1 = l2 * vol(i) * ( btb11(i)*unl(pos1(i)) + btb12(i)*unl(pos2(i))
226 . + btb13(i)*unl(pos3(i)) + btb14(i)*unl(pos4(i)) - btb13(i)*unl(pos5(i))
227 . - btb14(i)*unl(pos6(i)) - btb11(i)*unl(pos7(i)) - btb12(i)*unl(pos8(i)))
228
229 b2 = l2 * vol(i) * ( btb12(i)*unl(pos1(i)) + btb22(i)*unl(pos2(i))
230 . + btb23(i)*unl(pos3(i)) + btb24(i)*unl(pos4(i)) - btb23(i)*unl(pos5(i))
231 . - btb24(i)*unl(pos6(i)) - btb12(i)*unl(pos7(i)) - btb22(i)*unl(pos8(i)))
232
233 b3 = l2 * vol(i) * ( btb13(i)*unl(pos1(i)) + btb23(i)*unl(pos2(i))
234 . + btb33(i)*unl(pos3(i)) + btb34(i)*unl(pos4(i)) - btb33(i)*unl(pos5(i))
235 . - btb34(i)*unl(pos6(i)) - btb13(i)*unl(pos7(i)) - btb23(i)*unl(pos8(i)))
236
237 b4 = l2 * vol(i) * ( btb14(i)*unl(pos1(i)) + btb24(i)*unl(pos2(i))
238 . + btb34(i)*unl(pos3(i)) + btb44(i)*unl(pos4(i)) - btb34(i)*unl(pos5(i))
239 . - btb44(i)*unl(pos6(i)) - btb14(i)*unl(pos7(i)) - btb24(i)*unl(pos8(i)))
240
241 b5 = l2 * vol(i) * ( -btb13(i)*unl(pos1(i)) - btb23(i)*unl(pos2(i))
242 . - btb33(i)*unl(pos3(i)) - btb34(i)*unl(pos4(i)) + btb33(i)*unl(pos5(i))
243 . + btb34(i)*unl(pos6(i)) + btb13(i)*unl(pos7(i)) + btb23(i)*unl(pos8(i)))
244
245 b6 = l2 * vol(i) * ( -btb14(i)*unl(pos1(i)) - btb24(i)*unl(pos2(i))
246 . - btb34(i)*unl(pos3(i)) - btb44(i)*unl(pos4(i)) + btb34(i)*unl(pos5(i))
247 . + btb44(i)*unl(pos6(i)) + btb14(i)*unl(pos7(i)) + btb24(i)*unl(pos8(i)))
248
249 b7 = l2 * vol(i) * ( -btb11(i)*unl(pos1(i)) - btb12(i)*unl(pos2(i))
250 . - btb13(i)*unl(pos3(i)) - btb14(i)*unl(pos4(i)) + btb13(i)*unl(pos5(i))
251 . + btb14(i)*unl(pos6(i)) + btb11(i)*unl(pos7(i)) + btb12(i)*unl(pos8(i)))
252
253 b8 = l2 * vol(i) * ( -btb12(i)*unl(pos1(i)) - btb22(i)*unl(pos2(i))
254 . - btb23(i)*unl(pos3(i)) - btb24(i)*unl(pos4(i)) + btb23(i)*unl(pos5(i))
255 . + btb24(i)*unl(pos6(i)) + btb12(i)*unl(pos7(i)) + btb22(i)*unl(pos8(i)))
256
257
258 ntn_unl = ntn_unl * vol(i)
259 ntn_vnl = ntn_vnl * xi * vol(i)
260
261
262 ntvar = var_reg(i)*one_over_8* vol(i)
263
264
265 a = ntn_unl + ntn_vnl - ntvar
266 f1(i) = a + b1
267 f2(i) = a + b2
268 f3(i) = a + b3
269 f4(i) = a + b4
270 f5(i) = a + b5
271 f6(i) = a + b6
272 f7(i) = a + b7
273 f8(i) = a + b8
274
275
276 IF (nodadt > 0) THEN
277 sti1(i) = (abs(l2*btb11(i) + one/ntn) + abs(l2*btb12(i) + one/ntn) + abs
278 . abs(l2*btb14(i) + one/ntn) + abs(-l2*btb13(i) + one/ntn) + abs(-l2*btb14(i) + one/ntn) +
279 . abs(-l2*btb11(i) + one/ntn) + abs(-l2*btb12(i) + one/ntn))*vol(i)
280 sti2(i) = (abs(l2*btb12(i) + one/ntn) + abs(l2*btb22(i) + one/ntn) + abs(l2*btb23(i) + one/ntn) +
281 . abs(l2*btb24(i) + one/ntn) + abs(-l2*btb23(i) + one/ntn) + abs(-l2*btb24(i) + one/ntn) +
282 . abs(-l2*btb12(i) + one/ntn) + abs(-l2*btb22(i) + one/ntn))*vol(i)
283 sti3(i) = (abs(l2*btb13(i) + one/ntn) + abs(l2*btb23(i) + one/ntn) + abs(l2*btb33(i
284 . abs(l2*btb34(i) + one/ntn) + abs(-l2*btb33(i) + one/ntn) + abs(-l2*btb34(i) + one/ntn) +
285 . abs(-l2*btb13(i) + one/ntn) + abs(-l2*btb23(i) + one/ntn))*vol(i)
286 sti4(i) = (abs(l2*btb14(i) + one/ntn) + abs(l2*btb24(i) + one/ntn) + abs(l2*btb34(i) + one/ntn) +
287 . abs(l2*btb44(i) + one/ntn) + abs(-l2*btb34(i) + one/ntn) + abs(-l2*btb44(i) + one/ntn) +
288 . abs(-l2*btb14(i) + one/ntn) + abs(-l2*btb24(i) + one/ntn))*vol(i)
289 sti5(i) = (abs(-l2*btb13(i) + one/ntn) + abs(-l2*btb23(i) + one/ntn) + abs(-l2*btb33(i) + one/ntn) +
290 . abs(-l2*btb34(i) + one/ntn) + abs(l2*btb33(i) + one/ntn) + abs(l2*btb34(i) + one/ntn) +
291 . abs(l2*btb13(i) + one/ntn) + abs(l2*btb23(i) + one/ntn))*vol(i)
292 sti6(i) = (abs(-l2*btb14(i) + one/ntn) + abs(-l2*btb24(i) + one/ntn) + abs(-l2*btb34(i) + one/ntn) +
293 . abs(-l2*btb44(i) + one/ntn) + abs(l2*btb34(i) + one/ntn) + abs(l2*btb44(i) + one/ntn) +
294 . abs(l2*btb14(i) + one/ntn) + abs(l2*btb24(i) + one/ntn))*vol(i)
295 sti7(i) = (abs(-l2*btb11(i) + one/ntn) + abs(-l2*btb12(i) + one/ntn) + abs(-l2*btb13(i) + one/ntn) +
296 . abs(-l2*btb14(i) + one/ntn) + abs(l2*btb13(i) + one/ntn) + abs(l2*btb14(i) + one/ntn) +
297 . abs(l2*btb11(i) + one/ntn) + abs(l2*btb12(i) + one/ntn))*vol(i)
298 sti8(i) = (abs(-l2*btb12(i) + one/ntn) + abs(-l2*btb22(i) + one/ntn) + abs(-l2*btb23(i) + one/ntn) +
299 . abs(-l2*btb24(i) + one/ntn) + abs(l2*btb23(i) + one/ntn) + abs(l2*btb24(i) + one/ntn) +
300 . abs(l2*btb12(i) + one/ntn) + abs(l2*btb22(i) + one
301 ENDIF
302
303
304 ELSE
305
306
307 lc(i) = vol0(i)**third
308
309 IF (nodadt > 0) THEN
310
311
312 f1(i) = sqrt(mass(pos1(i))/mass0(pos1(i)))*zeta*sspnl*half*
313 . (vnl(pos1(i))+vnl0(pos1(i)))*(three/four)*(lc(i)**2)
314 f2(i) = sqrt(mass(pos2(i))/mass0(pos2(i)))*zeta*sspnl*half*
315 . (vnl(pos2(i))+vnl0(pos2(i)))*(three/four)*(lc(i)**2)
316 f3(i) = sqrt(mass(pos3(i))/mass0(pos3(i)))*zeta*sspnl*half*
317 . (vnl(pos3(i))+vnl0(pos3(i)))*(three/four)*(lc(i)**2)
318 f4(i) = sqrt(mass(pos4(i))/mass0(pos4(i)))*zeta*sspnl*half*
319 . (vnl(pos4(i))+vnl0(pos4(i)))*(three/four)*(lc(i)**2)
320 f5(i) = sqrt(mass(pos5(i))/mass0(pos5(i)))*zeta*sspnl*half*
321 . (vnl(pos5(i))+vnl0(pos5(i)))*(three/four)*(lc(i)**2)
322 f6(i) = sqrt(mass(pos6(i))/mass0(pos6(i)))*zeta*sspnl*half*
323 . (vnl(pos6(i))+vnl0(pos6(i)))*(three/four)*(lc(i)**2)
324 f7(i) = sqrt(mass(pos7(i))/mass0(pos7(i)))*zeta*sspnl*half*
325 . (vnl(pos7(i))+vnl0(pos7(i)))*(three/four)*(lc(i)**2)
326 f8(i) = sqrt(mass(pos8(i))/mass0(pos8(i)))*zeta*sspnl*half*
327 . (vnl(pos8(i))+vnl0(pos8(i)))*(three/four)*(lc(i)**2)
328
329 sti1(i) = em20
330 sti2(i) = em20
331 sti3(i) = em20
332 sti4(i) = em20
333 sti5(i) = em20
334 sti6(i) = em20
335 sti7(i) = em20
336 sti8(i) = em20
337 ELSE
338
339 f1(i) = zeta*sspnl*half*(vnl(pos1(i))+vnl0(pos1(i)))*(three/four)*(lc(i)**2)
340 f2(i) = zeta*sspnl*half*(vnl(pos2(i))+vnl0(pos2(i)))*(three/four)*(lc(i)**2)
341 f3(i) = zeta*sspnl*half*(vnl(pos3(i))+vnl0(pos3(i)))*(three/four)*(lc(i)**2)
342 f4(i) = zeta*sspnl*half*(vnl(pos4(i))+vnl0(pos4(i)))*(three/four)*(lc(i)**2)
343 f5(i) = zeta*sspnl*half*(vnl(pos5(i))+vnl0(pos5(i)))*(three/four)*(lc(i)**2)
344 f6(i) = zeta*sspnl*half*(vnl(pos6(i))+vnl0(pos6(i)))*(three/four)*(lc(i)**2)
345 f7(i) = zeta*sspnl*half*(vnl(pos7(i))+vnl0(pos7(i)))*(three/four)*(lc(i)**2)
346 f8(i) = zeta*sspnl*half*(vnl(pos8(i))+vnl0(pos8(i)))*(three/four)*(lc(i)**2)
347 ENDIF
348 ENDIF
349 ENDDO
350
351
352
353
354 IF (iparit == 0) THEN
355 fnl => nloc_dmg%FNL(1:l_nloc,itask+1)
356 IF (nodadt > 0) stifnl => nloc_dmg%STIFNL(1:l_nloc,itask+1)
357
358 DO i=1,nel
359
360 fnl(pos1(i)) = fnl(pos1(i)) - f1(i)
361 fnl(pos2(i)) = fnl(pos2(i)) - f2(i)
362 fnl(pos3(i)) = fnl(pos3(i)) - f3(i)
363 fnl(pos4(i)) = fnl(pos4(i)) - f4(i)
364 fnl(pos5(i)) = fnl(pos5(i)) - f5(i)
365 fnl(pos6(i)) = fnl(pos6(i)) - f6(i)
366 fnl(pos7(i)) = fnl(pos7(i)) - f7(i)
367 fnl(pos8(i)) = fnl(pos8(i)) - f8(i)
368 IF (nodadt > 0) THEN
369
370 maxstif =
max(sti1(i),sti2(i),sti3(i),sti4(i),sti5(i),sti6(i),sti7(i),sti8(i))
371
372 stifnl(pos1(i)) = stifnl(pos1(i)) + maxstif
373 stifnl(pos2(i)) = stifnl(pos2(i)) + maxstif
374 stifnl(pos3(i)) = stifnl(pos3(i)) + maxstif
375 stifnl(pos4(i)) = stifnl(pos4(i)) + maxstif
376 stifnl(pos5(i)) = stifnl(pos5(i)) + maxstif
377 stifnl(pos6(i)) = stifnl(pos6(i)) + maxstif
378 stifnl(pos7(i)) = stifnl(pos7(i)) + maxstif
379 stifnl(pos8(i)) = stifnl(pos8(i)) + maxstif
380 ENDIF
381 ENDDO
382
383
384 ELSE
385
386
387 DO i=1,nel
388 ii = i + nft
389
390
391 IF (nodadt > 0) THEN
392 maxstif =
max(sti1(i),sti2(i),sti3(i),sti4(i),sti5(i),sti6(i),sti7(i),sti8(i))
393 ENDIF
394
395 k = nloc_dmg%IADS(1,ii)
396 nloc_dmg%FSKY(k,1) = -f1(i)
397 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
398
399 k = nloc_dmg%IADS(2,ii)
400 nloc_dmg%FSKY(k,1) = -f2(i)
401 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
402
403 k = nloc_dmg%IADS(3,ii)
404 nloc_dmg%FSKY(k,1) = -f3(i)
405 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
406
407 k = nloc_dmg%IADS(4,ii)
408 nloc_dmg%FSKY(k,1) = -f4(i)
409 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
410
411 k = nloc_dmg%IADS(5,ii)
412 nloc_dmg%FSKY(k,1) = -f5(i)
413 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
414
415 k = nloc_dmg%IADS(6,ii)
416 nloc_dmg%FSKY(k,1) = -f6(i)
417 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
418
419 k = nloc_dmg%IADS(7,ii)
420 nloc_dmg%FSKY(k,1) = -f7(i)
421 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
422
423 k = nloc_dmg%IADS(8,ii)
424 nloc_dmg%FSKY(k,1) = -f8(i)
425 IF (nodadt > 0) nloc_dmg%STSKY(k,1) = maxstif
426
427 ENDDO
428 ENDIF
429
430
431
432 !-----------------------------------------------------------------------
433 IF (nodadt == 0) THEN
434 DO i = 1,nel
435
436 IF (off(i)/=zero) THEN
437
438 dtnl = (two*(
min(vol(i)**third,le_max))*sqrt(three*zeta))/
439 . sqrt(twelve*l2 + (
min(vol(i)**third,le_max))**2)
440
441 dt2t =
min(dt2t,dtfac1(1)*cdamp*dtnl)
442 ENDIF
443 ENDDO
444 ENDIF
445
446
447 IF (ALLOCATED(btb11)) DEALLOCATE(btb11)
448 IF (ALLOCATED(btb12)) DEALLOCATE(btb12)
449 IF (ALLOCATED(btb13)) DEALLOCATE(btb13)
450 IF (ALLOCATED(btb14)) DEALLOCATE(btb14)
451 IF (ALLOCATED(btb22)) DEALLOCATE(btb22)
452 IF (ALLOCATED(btb23)) DEALLOCATE(btb23)
453 IF (ALLOCATED(btb24)) DEALLOCATE(btb24)
454 IF (ALLOCATED(btb33)) DEALLOCATE(btb33)
455 IF (ALLOCATED(btb34)) DEALLOCATE(btb34)
456 IF (ALLOCATED(btb44)) DEALLOCATE(btb44)
457 IF (ALLOCATED(pos1)) DEALLOCATE(pos1)
458 IF (ALLOCATED(pos2)) DEALLOCATE(pos2)
459 IF (ALLOCATED(pos3)) DEALLOCATE(pos3)
460 IF (ALLOCATED(pos4)) DEALLOCATE(pos4)
461 IF (ALLOCATED(pos5)) DEALLOCATE(pos5)
462 IF (ALLOCATED(pos6)) DEALLOCATE(pos6)
463 IF (ALLOCATED(pos7)) DEALLOCATE(pos7)
464 IF (ALLOCATED(pos8)) DEALLOCATE(pos8)
465 IF (ALLOCATED(f1)) DEALLOCATE(f1)
466 IF (ALLOCATED(f2)) DEALLOCATE(f2)
467 IF (ALLOCATED(f3)) DEALLOCATE(f3)
468 IF (ALLOCATED(f4)) DEALLOCATE(f4)
469 IF (ALLOCATED(f5)) DEALLOCATE(f5)
470 IF (ALLOCATED(f6)) DEALLOCATE(f6)
471 IF (ALLOCATED(f7)) DEALLOCATE(f7)
472 IF (ALLOCATED(f8)) DEALLOCATE(f8)
473 IF (ALLOCATED(sti1)) DEALLOCATE(sti1)
474 IF (ALLOCATED(sti2)) DEALLOCATE(sti2)
475 IF (ALLOCATED(sti3)) DEALLOCATE(sti3)
476 IF (ALLOCATED(sti4)) DEALLOCATE(sti4)
477 IF (ALLOCATED(sti5)) DEALLOCATE(sti5)
478 IF (ALLOCATED(sti6)) DEALLOCATE(sti6)
479 IF (ALLOCATED(sti7)) DEALLOCATE(sti7)
480 IF (ALLOCATED(sti8)) DEALLOCATE(sti8)
481 IF (ALLOCATED(lc)) DEALLOCATE(lc)
482