/[PAMELA software]/DarthVader/TrackerLevel2/src/F77/analysisflight.f
ViewVC logotype

Contents of /DarthVader/TrackerLevel2/src/F77/analysisflight.f

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.11 - (show annotations) (download)
Mon Feb 19 16:28:39 2007 UTC (17 years, 11 months ago) by pam-fi
Branch: MAIN
Changes since 1.10: +1 -0 lines
added TRACKMOD parameter

1 *************************************************************************
2 * Program analysis.f
3 *
4 * - reads cluster information (LEVEL1, reduction.f output ntuple)
5 * - perform track identification and fit
6 * - create LEVEL2 ntuple
7 *
8 *************************************************************************
9 subroutine analysisflight(fin)
10
11 include 'commontracker.f'
12 include 'level1.f'
13 include 'common_momanhough.f'
14 include 'common_mech.f'
15 include 'common_xyzPAM.f'
16 include 'common_mini_2.f'
17 include 'calib.f'
18 include 'level2.f'
19
20 * input flag
21 *
22 * 0 - PFA = ETA
23 * 1 - PFA = COG4
24 integer fin
25
26 * flag to chose PFA
27 character*10 PFA
28 common/FINALPFA/PFA
29
30 c parameter (inf=1.e8) !just a huge number...
31
32 * external functions
33 external npl
34 external acoordsi,coordsi,nld,coord,dcoord
35
36 ************************************************************
37 ************************************************************
38 ************************************************************
39 *
40 * track analysis
41 *
42 ************************************************************
43 ************************************************************
44 ************************************************************
45 PFA='ETA'
46 TRACKMODE = 0
47 if(fin.eq.0)PFA='ETA'
48 if(fin.eq.2)PFA='ETA2'
49 if(fin.eq.3)PFA='ETA3'
50 if(fin.eq.4)PFA='ETA4'
51 if(fin.eq.10)PFA='COG'
52 if(fin.eq.11)PFA='COG1'
53 if(fin.eq.12)PFA='COG2'
54 if(fin.eq.13)PFA='COG3'
55 if(fin.eq.14)PFA='COG4'
56
57 c$$$ PFA='ETA'
58 c$$$ DEBUG=.true.
59
60 if(DEBUG)PRINT*,'P.F.A. --> ',fin,PFA
61
62 if(DEBUG)then
63 print*,'----------------------------------'
64 c print*,'START... ',good1,nclstr1,nclstrmax_level2
65 endif
66
67 *------------------------------------------------------
68 call init_level2
69 call init_hough
70 *------------------------------------------------------
71
72 *------------------------------------------------------
73 * cut on maximum number of clusters
74 *------------------------------------------------------
75 c$$$ if(nclstr1.gt.nclstrmax_level2)then
76 c$$$ goto 8800 !fill nt-uple and go to next event
77 c$$$ endif
78
79 do i=1,nclstr1
80 cl_used(i)=0 !init mask of clusters associated to a track
81 enddo
82
83 if(DEBUG)then
84 print*,'----------------------------------'
85 print*,iev,' ** ',nev2
86 endif
87
88 * ///////////////////////////////////////////////
89 * \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
90
91 iflag=0
92 call track_finding(iflag)
93 if(iflag.eq.1)then !bad event
94 goto 880 !fill ntp and go to next event
95 endif
96
97 call fill_hough
98
99 iflag=0
100 call track_fitting(iflag)
101 if(iflag.eq.1)then !bad event
102 goto 880 !fill ntp and go to next event
103 endif
104
105
106
107 880 continue
108
109 * **********************************************************
110 * stores info about clusters not associated with any track
111 * **********************************************************
112
113 call fill_level2_siglets
114
115 if(DEBUG)then
116
117 print*,''
118 print*,'DONE!'
119 print*,''
120 print*,'* summary *'
121 print*,'tracks ',ntrk
122 print*,'cl used ',(cl_used(i),i=1,nclstr1)
123 print*,''
124 print*,''
125 endif
126
127 ngood = 0
128 do iv = 1,nviews
129 ngood = ngood + good1(iv)
130 enddo
131 c$$$ if(ngood.ne.0)print*,'* WARNING * Event '
132 c$$$ $ ,':LEVEL2 event status: '
133 c$$$ $ ,(good2(i),i=1,nviews)
134
135 8800 continue
136
137
138 * ///////////////////////////////////////////////
139 * \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
140
141 100 continue
142
143 return
144 end
145
146
147 ************************************************************
148
149

  ViewVC Help
Powered by ViewVC 1.1.23