142 |
call DOTRACK(NPLA,ZIN,XOUT,YOUT,AL_P,IFAIL) |
call DOTRACK(NPLA,ZIN,XOUT,YOUT,AL_P,IFAIL) |
143 |
if(IFAIL.ne.0)then |
if(IFAIL.ne.0)then |
144 |
GOOD2 = 0 |
GOOD2 = 0 |
145 |
print *,' CALORIMETER - WARNING F77: tracking failed ' |
c print *,' CALORIMETER - WARNING F77: tracking failed ' |
146 |
goto 969 |
goto 969 |
147 |
endif |
endif |
148 |
TX = TAN(ASIN(AL_P(3))) * COS(AL_P(4)) |
TX = TAN(ASIN(AL_P(3))) * COS(AL_P(4)) |
159 |
C CHECK IF XOUT OR YOUT ARE NaN |
C CHECK IF XOUT OR YOUT ARE NaN |
160 |
C |
C |
161 |
IF (XOUT(I).NE.XOUT(I).OR.YOUT(I).NE.YOUT(I)) THEN |
IF (XOUT(I).NE.XOUT(I).OR.YOUT(I).NE.YOUT(I)) THEN |
162 |
print *, |
c print *, |
163 |
& ' CALORIMETER - WARNING F77: tracking error (NaN values)' |
c & ' CALORIMETER - WARNING F77: tracking error (NaN values)' |
164 |
GOOD2 = 0 |
GOOD2 = 0 |
165 |
GOTO 969 |
GOTO 969 |
166 |
ENDIF |
ENDIF |
167 |
C |
C |
168 |
CX = XOUT(I)*10. + XALIG |
CX = XOUT(I)*10. + XALIG |
169 |
CY = -YOUT(I)*10. + YALIG |
CY = YOUT(I)*10. + YALIG |
170 |
C |
C |
171 |
IF (I.EQ.1) THEN |
IF (I.EQ.1) THEN |
172 |
TIMPX = CX |
TIMPX = CX |
180 |
ELSE |
ELSE |
181 |
YY(I) = CY |
YY(I) = CY |
182 |
BAR(M,I) = YY(I) |
BAR(M,I) = YY(I) |
183 |
TBAR(M,I) = (YALIG - YY(I))/10. |
TBAR(M,I) = (-YALIG + YY(I))/10. |
184 |
IF (I.EQ.22) MY=ABS(Y(1)-Y(22))/ABS(ZIN(1)-ZIN(22)) |
IF (I.EQ.22) MY=ABS(Y(1)-Y(22))/ABS(ZIN(1)-ZIN(22)) |
185 |
ENDIF |
ENDIF |
186 |
CALL LASTRISCIA(BAR(M,I),IBAR(M,I)) |
CALL LASTRISCIA(BAR(M,I),IBAR(M,I)) |
306 |
C |
C |
307 |
IF (CHTRACK.EQ.44) THEN |
IF (CHTRACK.EQ.44) THEN |
308 |
GOOD2 = 0 |
GOOD2 = 0 |
309 |
PRINT *,' CALORIMETER - WARNING F77: track outside calorimeter' |
c PRINT *,' CALORIMETER - WARNING F77: track outside calorimeter' |
310 |
GOTO 50 |
GOTO 50 |
311 |
ELSE |
ELSE |
312 |
IF ( IWPL(1).LE.IWPL(2) ) THEN |
IF ( IWPL(1).LE.IWPL(2) ) THEN |
559 |
DO J = NPLA-4,NPLA |
DO J = NPLA-4,NPLA |
560 |
NNX = IBAR(1,J) |
NNX = IBAR(1,J) |
561 |
IF (NNX.NE.-1) THEN |
IF (NNX.NE.-1) THEN |
562 |
IF (NNX.LT.9) NNX = 9 |
IF (NNX.LT.5) NNX = 5 |
563 |
IF (NNX.GT.88) NNX = 88 |
IF (NNX.GT.92) NNX = 92 |
564 |
INFX = NNX - 8 |
c IF (NNX.LT.9) NNX = 9 |
565 |
ISUPX = NNX + 8 |
c IF (NNX.GT.88) NNX = 88 |
566 |
|
INFX = NNX - 4 |
567 |
|
ISUPX = NNX + 4 |
568 |
|
c INFX = NNX - 8 |
569 |
|
c ISUPX = NNX + 8 |
570 |
DO I = INFX,ISUPX |
DO I = INFX,ISUPX |
571 |
IF (DEXY(1,J,I).GE.EMIN) THEN |
IF (DEXY(1,J,I).GE.EMIN) THEN |
572 |
NLAST = NLAST + 1 |
NLAST = NLAST + 1 |
577 |
C |
C |
578 |
NNY = IBAR(2,J) |
NNY = IBAR(2,J) |
579 |
IF (NNY.NE.-1) THEN |
IF (NNY.NE.-1) THEN |
580 |
IF (NNY.LT.9) NNY = 9 |
IF (NNY.LT.5) NNY = 5 |
581 |
IF (NNY.GT.88) NNY = 88 |
IF (NNY.GT.92) NNY = 92 |
582 |
INFY = NNY - 8 |
c IF (NNY.LT.9) NNY = 9 |
583 |
ISUPY = NNY + 8 |
c IF (NNY.GT.88) NNY = 88 |
584 |
|
INFY = NNY - 4 |
585 |
|
ISUPY = NNY + 4 |
586 |
|
c INFY = NNY - 8 |
587 |
|
c ISUPY = NNY + 8 |
588 |
DO I=INFY,ISUPY |
DO I=INFY,ISUPY |
589 |
IF (DEXY(2,J,I).GE.EMIN) THEN |
IF (DEXY(2,J,I).GE.EMIN) THEN |
590 |
NLAST = NLAST + 1 |
NLAST = NLAST + 1 |