1 |
mocchiut |
1.1 |
C---------------------------------------------------------------------- |
2 |
|
|
SUBROUTINE CLUSTER2 |
3 |
|
|
C---------------------------------------------------------------------- |
4 |
|
|
C- |
5 |
|
|
C- Purpose and Methods : IT WORKS AS CLUSTER BUT USING TWO PARTS OF THE |
6 |
|
|
C- CALORIMETER (LAYERS 1 - 4 AND LAYERS 5 - 8) INSTEAD OF THE 8 |
7 |
|
|
C- LAYERS . |
8 |
|
|
C- |
9 |
|
|
C- Created 25-FEB-1995 MIRKO BOEZIO |
10 |
|
|
C- Modified 30-MAR-1995 MIRKO BOEZIO . CORRECTED AN ERROR IN THE |
11 |
|
|
C- DEFINITION OF THE TWO PARTS , OTHERWISE IT WAS LAYERS 1 - 5 AND |
12 |
|
|
C- LAYERS 6 - 8 . |
13 |
|
|
C- |
14 |
|
|
C---------------------------------------------------------------------- |
15 |
|
|
INCLUDE 'INTEST.TXT' |
16 |
mocchiut |
1.4 |
REAL QQQ(NCHA), ENE, BAR |
17 |
|
|
INTEGER IERR1 |
18 |
mocchiut |
1.1 |
|
19 |
mocchiut |
1.3 |
COMMON / SHIFT / SHIFT |
20 |
|
|
SAVE / SHIFT / |
21 |
mocchiut |
1.4 |
DATA ENE / 0. / |
22 |
|
|
DATA BAR / 0. / |
23 |
|
|
DATA IERR1 / 0 / |
24 |
|
|
C |
25 |
|
|
ENE = 0. |
26 |
|
|
BAR = 0. |
27 |
|
|
IERR1 = 0 |
28 |
mocchiut |
1.1 |
C |
29 |
|
|
DO J = 1,2 |
30 |
|
|
DO N = 1,2 |
31 |
|
|
DO M = 1,NCHA |
32 |
|
|
CLUS2(N,J,M) = 0. |
33 |
|
|
ENDDO |
34 |
|
|
NCL2(N,J) = 0 |
35 |
|
|
ENDDO |
36 |
|
|
ENDDO |
37 |
|
|
C |
38 |
|
|
LPIANO = NPLA / 2 |
39 |
|
|
C |
40 |
|
|
DO N = 1,2 |
41 |
|
|
DO J = 1,2 |
42 |
|
|
DO M = 1,NCHA |
43 |
|
|
QQQ(M) = 0. |
44 |
|
|
DO L = 1,NPLA |
45 |
|
|
EN = DEXY(N,L,M) |
46 |
|
|
IF (EN.GT.EMIN.AND.J.EQ.1.AND.L.LE.LPIANO) THEN |
47 |
|
|
QQQ(M) = QQQ(M) + EN |
48 |
|
|
ENDIF |
49 |
|
|
IF (EN.GT.EMIN.AND.J.EQ.2.AND.L.GT.LPIANO) THEN |
50 |
|
|
QQQ(M) = QQQ(M) + EN |
51 |
|
|
ENDIF |
52 |
|
|
ENDDO |
53 |
|
|
ENDDO |
54 |
|
|
C |
55 |
mocchiut |
1.5 |
IGIRO = 0 |
56 |
mocchiut |
1.1 |
C |
57 |
|
|
50 CONTINUE |
58 |
|
|
MAX = LVMAX(QQQ,NCHA) |
59 |
|
|
IF (QQQ(MAX).LT.EMIN) GO TO 100 |
60 |
|
|
MSTR = MAX |
61 |
|
|
55 CONTINUE |
62 |
|
|
MSTR = MSTR + 1 |
63 |
|
|
IF (MSTR.GT.NCHA) GO TO 56 |
64 |
|
|
IF (QQQ(MSTR).GT.EMIN) GO TO 55 |
65 |
|
|
56 CONTINUE |
66 |
|
|
IB = MSTR - 1 |
67 |
|
|
C |
68 |
|
|
MSTR = MAX |
69 |
|
|
65 CONTINUE |
70 |
|
|
MSTR = MSTR - 1 |
71 |
|
|
IF (MSTR.LT.1) GO TO 66 |
72 |
|
|
IF (QQQ(MSTR).GT.EMIN) GO TO 65 |
73 |
|
|
66 CONTINUE |
74 |
|
|
IA = MSTR + 1 |
75 |
|
|
C |
76 |
mocchiut |
1.2 |
NN = 0 |
77 |
|
|
IF (MOD(J,2).EQ.NN) THEN |
78 |
|
|
IF (REVERSE.EQ.0) THEN |
79 |
mocchiut |
1.3 |
SHIFT = -0.5 |
80 |
|
|
ELSE |
81 |
mocchiut |
1.2 |
SHIFT = +0.5 |
82 |
|
|
ENDIF |
83 |
|
|
ELSE |
84 |
|
|
IF (REVERSE.EQ.0) THEN |
85 |
mocchiut |
1.3 |
SHIFT = +0.5 |
86 |
|
|
ELSE |
87 |
mocchiut |
1.2 |
SHIFT = -0.5 |
88 |
|
|
ENDIF |
89 |
|
|
ENDIF |
90 |
|
|
C |
91 |
mocchiut |
1.1 |
CALL BARIC(QQQ,IA,IB,BAR,ENE,IERR1) |
92 |
|
|
IGIRO = IGIRO + 1 |
93 |
mocchiut |
1.4 |
IGI = IGIRO + NCHA / 2 |
94 |
mocchiut |
1.1 |
CLUS2(N,J,IGIRO) = BAR |
95 |
|
|
CLUS2(N,J,IGI) = ENE |
96 |
|
|
C |
97 |
|
|
DO LL = IA,IB |
98 |
|
|
QQQ(LL) = 0. |
99 |
|
|
ENDDO |
100 |
|
|
GO TO 50 |
101 |
|
|
C |
102 |
|
|
100 CONTINUE |
103 |
|
|
NCL2(N,J) = IGIRO |
104 |
|
|
ENDDO |
105 |
|
|
ENDDO |
106 |
|
|
C |
107 |
|
|
RETURN |
108 |
|
|
END |
109 |
|
|
|