5 |
C |
C |
6 |
INCLUDE 'INTEST.TXT' |
INCLUDE 'INTEST.TXT' |
7 |
C |
C |
8 |
REAL PIANO(22), VARFIT(2) |
REAL PIANO(NPLAV), VARFIT(2) |
9 |
REAL SHIFT |
REAL SHIFT |
10 |
REAL TG(2), BAR(2,NPLA) |
REAL TG(2), BAR(2,NPLAV) |
11 |
REAL DISTX, DISTY, Y(NPLA), YY(NPLA) |
REAL DISTX, DISTY, Y(NPLAV), YY(NPLAV) |
12 |
REAL RIG, RMASS |
REAL RIG, RMASS |
13 |
REAL CHECK, ENER, CX, CY |
REAL CHECK, ENER, CX, CY |
14 |
REAL EINF, ESUP,ENPLANEX,ENPLANEY,TENPLAX,TENPLAY |
REAL EINF, ESUP,ENPLANEX,ENPLANEY,TENPLAX,TENPLAY |
16 |
c |
c |
17 |
INTEGER gtr |
INTEGER gtr |
18 |
INTEGER j, m, nn, i |
INTEGER j, m, nn, i |
19 |
INTEGER IBAR(2,NPLA), NPFIT(2) |
INTEGER IBAR(2,NPLAV), NPFIT(2) |
20 |
INTEGER Iquest(100), IWPL(2),CHTRACK |
INTEGER Iquest(100), IWPL(2),CHTRACK |
21 |
c |
c |
22 |
COMMON / TAGLIOEN / EINF, ESUP, ENER(2) |
COMMON / TAGLIOEN / EINF, ESUP, ENER(2) |
53 |
C |
C |
54 |
C Z position of Y planes, Y1 = 0., Y2 = -8.09, Y3 = -18.18, ... |
C Z position of Y planes, Y1 = 0., Y2 = -8.09, Y3 = -18.18, ... |
55 |
C |
C |
56 |
|
c print *,'NPLA IS ',NPLA |
57 |
PIANO(1) = 0. |
PIANO(1) = 0. |
58 |
DO I = 2, 22 |
DO I = 2, NPLA |
59 |
IF ( MOD(I,2).EQ.0 ) THEN |
IF ( MOD(I,2).EQ.0 ) THEN |
60 |
PIANO(I) = PIANO(I-1) - 8.09 |
PIANO(I) = PIANO(I-1) - 8.09 |
61 |
ELSE |
ELSE |
64 |
ENDDO |
ENDDO |
65 |
C |
C |
66 |
CALL VZERO(DEXY,2*LENSEV) |
CALL VZERO(DEXY,2*LENSEV) |
67 |
CALL VZERO(BAR,2*NPLA) |
CALL VZERO(BAR,2*NPLAV) |
68 |
CALL VZERO(IBAR,2*NPLA) |
CALL VZERO(IBAR,2*NPLAV) |
69 |
CALL VZERO(CBAR,2*NPLA) |
CALL VZERO(CBAR,2*NPLAV) |
70 |
CALL VZERO(CIBAR,2*NPLA) |
CALL VZERO(CIBAR,2*NPLAV) |
71 |
CALL VZERO(QQ,4) |
CALL VZERO(QQ,4) |
72 |
CALL VZERO(Y,NPLA) |
CALL VZERO(Y,NPLAV) |
73 |
CALL VZERO(YY,NPLA) |
CALL VZERO(YY,NPLAV) |
74 |
VARFIT(1) = 0. |
VARFIT(1) = 0. |
75 |
VARFIT(2) = 0. |
VARFIT(2) = 0. |
76 |
NPFIT(1) = 0. |
NPFIT(1) = 0. |
101 |
C |
C |
102 |
C CALCULATE QTOT, NSTRIP, QQ, NX22, QX22, QMAX AND PLANEMAX |
C CALCULATE QTOT, NSTRIP, QQ, NX22, QX22, QMAX AND PLANEMAX |
103 |
C |
C |
104 |
DO I = 1,22 |
DO I = 1,NPLA |
105 |
ENPLANEY = 0. |
ENPLANEY = 0. |
106 |
ENPLANEX = 0. |
ENPLANEX = 0. |
107 |
DO J = 1,96 |
DO J = 1,96 |
108 |
|
c if ( ESTRIP(1,I,J).gt.0) |
109 |
|
c & print *,' I ',I,' J ',J,' ES1 ',ESTRIP(1,I,J) |
110 |
|
c if ( ESTRIP(2,I,J).gt.0) |
111 |
|
c & print *,' I ',I,' J ',J,' ES2 ',ESTRIP(2,I,J) |
112 |
IF ( MOD(I,2).NE.0 ) THEN |
IF ( MOD(I,2).NE.0 ) THEN |
113 |
IF ( ESTRIP(2,I,J).GT.EMIN ) THEN |
IF ( ESTRIP(2,I,J).GT.EMIN ) THEN |
114 |
DEXY(2,I,J) = ESTRIP(2,I,J) |
DEXY(2,I,J) = ESTRIP(2,I,J) |
152 |
ENPLANEX = ENPLANEX + DEXY(1,I,J) |
ENPLANEX = ENPLANEX + DEXY(1,I,J) |
153 |
NSTRIP = NSTRIP + 1. |
NSTRIP = NSTRIP + 1. |
154 |
QTOT = QTOT + DEXY(1,I,J) |
QTOT = QTOT + DEXY(1,I,J) |
155 |
IF (I.EQ.22) THEN |
IF (I.EQ.NPLA) THEN |
156 |
NX22 = NX22 + 1. |
NX22 = NX22 + 1. |
157 |
QX22 = QX22 + DEXY(1,I,J) |
QX22 = QX22 + DEXY(1,I,J) |
158 |
ENDIF |
ENDIF |
177 |
C FIT THE TRACK INSIDE THE CALORIMETER |
C FIT THE TRACK INSIDE THE CALORIMETER |
178 |
C |
C |
179 |
if (GOOD2.EQ.1.OR.TRIGTY.GE.2) then |
if (GOOD2.EQ.1.OR.TRIGTY.GE.2) then |
180 |
|
c print *,' CALL CLUSTER ' |
181 |
CALL CLUSTER |
CALL CLUSTER |
182 |
|
c print *,' CALL DIRECTION ' |
183 |
CALL DIRECTION(TG) |
CALL DIRECTION(TG) |
184 |
NPCFIT(1) = NPFIT(1) |
NPCFIT(1) = NPFIT(1) |
185 |
NPCFIT(2) = NPFIT(2) |
NPCFIT(2) = NPFIT(2) |
201 |
C NN = 0 |
C NN = 0 |
202 |
C IF (M.EQ.2) NN = 1 |
C IF (M.EQ.2) NN = 1 |
203 |
IF (MOD(I,2).EQ.NN) THEN |
IF (MOD(I,2).EQ.NN) THEN |
204 |
SHIFT = +0.5 |
IF (REVERSE.EQ.0) THEN |
205 |
|
SHIFT = +0.5 |
206 |
|
ELSE |
207 |
|
SHIFT = -0.5 |
208 |
|
ENDIF |
209 |
ELSE |
ELSE |
210 |
SHIFT = -0.5 |
IF (REVERSE.EQ.0) THEN |
211 |
|
SHIFT = -0.5 |
212 |
|
ELSE |
213 |
|
SHIFT = +0.5 |
214 |
|
ENDIF |
215 |
ENDIF |
ENDIF |
216 |
C |
C |
217 |
IF (M.EQ.1) THEN |
IF (M.EQ.1) THEN |