/[PAMELA software]/gpamela/gpspe/gpdspe.F
ViewVC logotype

Diff of /gpamela/gpspe/gpdspe.F

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3.1 by cafagna, Thu Jul 11 16:02:13 2002 UTC revision 3.3 by pam-ba, Mon Dec 5 12:15:21 2005 UTC
# Line 1  Line 1 
1  *  *
2  * $Id$  * $Id: gpdspe.F,v 3.2 2005/07/25 11:53:21 cafagna Exp $
3    *
4    * $Log: gpdspe.F,v $
5    * Revision 3.2  2005/07/25 11:53:21  cafagna
6    * Several updates. See history for details
7    *
8    * Revision 3.1.1.1  2002/07/11 16:02:13  cafagna
9    * First GPAMELA release on CVS
10  *  *
 * $Log$  
11  *  *
12  *CMZ :  2.01/00 05/04/2000  14.35.18  by  Marialuigia Ambriola  *CMZ :  2.01/00 05/04/2000  14.35.18  by  Marialuigia Ambriola
13  *CMZ :  2.00/00 03/03/2000  15.39.06  by  Francesco Cafagna  *CMZ :  2.00/00 03/03/2000  15.39.06  by  Francesco Cafagna
# Line 20  Line 26 
26  ************************************************************************  ************************************************************************
27  #include "gcunit.inc"  #include "gcunit.inc"
28  #include "gpphit.inc"  #include "gpphit.inc"
29        PARAMETER (NH=NHSPE,NHM=NHMSPE,NVOL=4)        PARAMETER (RADDEG=57.295779)
30          PARAMETER (NH=NHSPE,NHM=NHMSPE,NVOL=3)
31  #include "gppdigi.inc"  #include "gppdigi.inc"
32  c +SEQ,GPDSPE.  c +SEQ,GPDSPE.
33  #include "gprhit.inc"  #include "gprhit.inc"
# Line 36  c +SEQ,GPDSPE. Line 43  c +SEQ,GPDSPE.
43        INTEGER NTRA,IDIG,LTRA,NPLANE,LKDN,NTDIGI,JJ        INTEGER NTRA,IDIG,LTRA,NPLANE,LKDN,NTDIGI,JJ
44        INTEGER KDIGI(4),NUMBVD(NVOL)        INTEGER KDIGI(4),NUMBVD(NVOL)
45        REAL XI,YI,XO,YO,PATH,DE,GPGAUS        REAL XI,YI,XO,YO,PATH,DE,GPGAUS
46          REAL VPOS(3),BMAGNET(3),ANGLEX,ANGLEY,XMULT,YMULT,DXPOS,DYPOS
47  *  *
48        DATA NTRA,LTRA/1,1/        DATA NTRA,LTRA/1,1/
49  *  *
# Line 107  c +SEQ,GPDSPE. Line 115  c +SEQ,GPDSPE.
115        NTHSPE = NHITS        NTHSPE = NHITS
116        DO I=1,NHITS        DO I=1,NHITS
117           ITRPB(I)   = NUMBV(1,I)           ITRPB(I)   = NUMBV(1,I)
118           ITRSL(I)   = NUMBV(3,I)           ITRSL(I)   = NUMBV(2,I)
119           ITSPA(I)   = NUMBV(4,I)           ITSPA(I)   = NUMBV(3,I)
120  #if defined(GPAMELA_INTER)  #if defined(GPAMELA_INTER)
121           XAVSPE(I) = VHITS(1,I)           XAVSPE(I) = VHITS(1,I)
122           YAVSPE(I) = VHITS(2,I)           YAVSPE(I) = VHITS(2,I)
# Line 135  c +SEQ,GPDSPE. Line 143  c +SEQ,GPDSPE.
143           PATHSPE(I) = VHITS(8,I)           PATHSPE(I) = VHITS(8,I)
144           IPARSPE(I) = VHITS(9,I)           IPARSPE(I) = VHITS(9,I)
145           P0SPE (I) = VHITS(10,I)           P0SPE (I) = VHITS(10,I)
146    C
147    C ADD RESOLUTION SIMULATION TO XAVSPE
148    C        
149             ANGLEX=0.
150             ANGLEY=0.
151             IF(ZOUTSPE(I).NE.ZINSPE(I)) THEN
152                ANGLEX=RADDEG*ATAN( ABS(XOUTSPE(I)-XINSPE(I) )/
153         +              ABS(ZOUTSPE(I)-ZINSPE(I) ) )
154                ANGLEY=RADDEG*ATAN( ABS(YOUTSPE(I)-YINSPE(I) )/
155         +              ABS(ZOUTSPE(I)-ZINSPE(I) ) )          
156             ENDIF
157             VPOS(1)=XAVSPE(I)
158             VPOS(2)=YAVSPE(I)
159             VPOS(3)=ZAVSPE(I)      
160             CALL GUFLD(VPOS,BMAGNET)
161    
162             CALL GPRSPE(ANGLEX,ANGLEY,BMAGNET,XMULT,YMULT,DXPOS,DYPOS)
163    
164             XAVSPE(I) = XAVSPE(I) + DXPOS
165             YAVSPE(I) = YAVSPE(I) + DYPOS
166    
167    C
168    C ADD RESOLUTION OF THE SHIFT INDUCED BY THE MAG. FIELD
169    C
170    
171             IF(ITRPB(I).LT.6) THEN
172                XAVSPE(I) = XAVSPE(I) - 2.64e-4/4.5*BMAGNET(2)
173             ELSE IF(ITRPB(I).EQ.6) THEN
174                XAVSPE(I) = XAVSPE(I) + 2.64e-4/4.5*BMAGNET(2)
175             ENDIF
176    
177        ENDDO        ENDDO
178  *  *
179  * Loop on the hits retrived to fill the CWN common and the DIGI bank  * Loop on the hits retrived to fill the CWN common and the DIGI bank

Legend:
Removed from v.3.1  
changed lines
  Added in v.3.3

  ViewVC Help
Powered by ViewVC 1.1.23