StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StFtpcTrackEvaluator.cc
1 // $Id: StFtpcTrackEvaluator.cc,v 1.22 2007/01/15 08:23:02 jcs Exp $
2 // $Log: StFtpcTrackEvaluator.cc,v $
3 // Revision 1.22 2007/01/15 08:23:02 jcs
4 // replace printf, cout and gMesMgr with Logger commands
5 //
6 // Revision 1.21 2004/02/12 19:37:10 oldi
7 // *** empty log message ***
8 //
9 // Revision 1.20 2004/01/28 01:41:32 jeromel
10 // *** empty log message ***
11 //
12 // Revision 1.19 2003/09/16 15:27:02 jcs
13 // removed inline as it would leave a few undefined reference
14 //
15 // Revision 1.18 2003/01/16 18:04:33 oldi
16 // Bugs eliminated. Now it compiles on Solaris again.
17 // Split residuals for global and primary fit.
18 //
19 // Revision 1.17 2002/11/06 13:46:24 oldi
20 // Code clean ups.
21 //
22 // Revision 1.16 2002/10/24 16:37:46 oldi
23 // dca (impact parameter) is calculated using StHelix::distance(vertexPos), now.
24 // Therefore it is the smallest three dimensional distance of the helix to the
25 // primary vertex.
26 // dca for primary tracks is filled correctly, now. (Even though this value
27 // shouldn't be of great use.)
28 // Code clean-ups.
29 //
30 // Revision 1.15 2002/10/11 15:45:22 oldi
31 // Get FTPC geometry and dimensions from database.
32 // No field fit activated: Returns momentum = 0 but fits a helix.
33 // Bug in TrackMaker fixed (events with z_vertex > outer_ftpc_radius were cut).
34 // QA histograms corrected (0 was supressed).
35 // Code cleanup (several lines of code changed due to *params -> Instance()).
36 // cout -> gMessMgr.
37 //
38 // Revision 1.14 2002/04/05 16:50:51 oldi
39 // Cleanup of MomentumFit (StFtpcMomentumFit is now part of StFtpcTrack).
40 // Each Track inherits from StHelix, now.
41 // Therefore it is possible to calculate, now:
42 // - residuals
43 // - vertex estimations obtained by back extrapolations of FTPC tracks
44 // Chi2 was fixed.
45 // Many additional minor (and major) changes.
46 //
47 // Revision 1.13 2002/03/05 16:53:10 jcs
48 // force data type definitions to avoid compiler warnings (this is a correct
49 // but inelegant fix which must be changed)
50 //
51 // Revision 1.12 2001/07/12 08:34:27 oldi
52 // Many new things were developed eg. histograms for time consumption and
53 // momentum resolution.
54 // File handling was debugged.
55 // New constructor to evaluate tracks of good evaluated clusters of a
56 // previous run.
57 //
58 // Revision 1.11 2001/05/02 13:40:07 oldi
59 // Small change to be able to update the output file again.
60 //
61 // Revision 1.10 2001/04/27 10:25:21 oldi
62 // Protection against crash due to lack of fast simulator hit information.
63 // The evaluator gives (up to now) only valueable information when tracking was
64 // performed with the fast simulator. But now it is possile to evaluate slow
65 // simulated events as well (as far as the necessary information is available).
66 // ShowTracks() has still a problem due the change of ROOT version.
67 //
68 // Revision 1.9 2001/04/25 17:55:10 perev
69 // HPcorrs
70 //
71 // Revision 1.8 2001/03/06 18:06:36 oldi
72 // Because StFtpcClusterMaker and StFtpcConfMapper have changed two things had
73 // to be changed here: coeff[4] -> coeff[6], ffs_gepoint -> ffs_fgepoint.
74 //
75 // Revision 1.7 2001/01/25 15:22:10 oldi
76 // Review of the complete code.
77 // Fix of several bugs which caused memory leaks:
78 // - Tracks were not allocated properly.
79 // - Tracks (especially split tracks) were not deleted properly.
80 // - TClonesArray seems to have a problem (it could be that I used it in a
81 // wrong way). I changed all occurences to TObjArray which makes the
82 // program slightly slower but much more save (in terms of memory usage).
83 // Speed up of HandleSplitTracks() which is now 12.5 times faster than before.
84 // Cleanup.
85 //
86 // Revision 1.6 2000/11/10 18:38:24 oldi
87 // Short tracks are treated now.
88 //
89 // Revision 1.5 2000/07/18 21:22:16 oldi
90 // Changes due to be able to find laser tracks.
91 // Cleanup: - new functions in StFtpcConfMapper, StFtpcTrack, and StFtpcPoint
92 // to bundle often called functions
93 // - short functions inlined
94 // - formulas of StFormulary made static
95 // - avoid streaming of objects of unknown size
96 // (removes the bunch of CINT warnings during compile time)
97 // - two or three minor bugs cured
98 //
99 // Revision 1.4 2000/06/13 14:36:19 oldi
100 // Changed cout to gMessMgr->Message() (only for non-interactive part).
101 //
102 // Revision 1.3 2000/06/07 11:09:50 oldi
103 // Changed 0 pointers to NULL pointers.
104 // In SetupHistos(): avoided exit(-1) if write permission is wrong.
105 // Added new functionality (improvement of output histos).
106 // Cleanup.
107 //
108 // Revision 1.2 2000/05/11 15:14:51 oldi
109 // Changed class names *Hit.* due to already existing class StFtpcHit.cxx in StEvent
110 //
111 // Revision 1.1 2000/05/10 13:39:25 oldi
112 // Initial version of StFtpcTrackMaker
113 //
114 
115 //----------Author: Markus D. Oldenburg
116 //----------Last Modified: 17.10.2000
117 //----------Copyright: &copy MDO Production 2000
118 
119 #include "StFtpcTrackEvaluator.hh"
120 #include "StFtpcConfMapper.hh"
121 #include "StFtpcPoint.hh"
122 #include "StFtpcConfMapPoint.hh"
123 #include "StFtpcTrack.hh"
124 #include "StFormulary.hh"
125 #include "StFtpcDisplay.hh"
126 
127 #include "St_DataSetIter.h"
128 
129 #include "TFile.h"
130 #include "TH1.h"
131 #include "TH2.h"
132 #include "TAxis.h"
133 
134 #include "MIntArray.h"
135 
136 #include "StMessMgr.h"
137 
139 // //
140 // StFtpcTrackEvaluator class - evaluates found tracks by comparison to the input //
141 // GEANT clusters and tracks. //
142 // //
143 // As input this class gets the pointers to the ObjArrays of found hits and //
144 // tracks and the pointers of the input (to the tracker) geant hits and tracks. //
145 // The class should tell then which tracks are found and where are the remaining //
146 // problems. //
147 // //
149 
150 ClassImp(StFtpcTrackEvaluator)
151 
152 
154 {
155  // Default constructor.
156  // Sets the pointers.
157 
158  mFilename = 0;
159  mWritePermission = 0;
160  mFile = 0;
161 
162  mNumGeantHits = 0;
163  mNumFoundHits = 0;
164  mNumGeantTracks = 0;
165  mNumFoundTracks = 0;
166 
167  mClusterArr = 0;
168  mUncleanTracksArr = 0;
169  mSplitTracksArr = 0;
170  mSplitGoodTracksArr = 0;
171  mGoodFastSimHitsArr = 0;
172 
173  mNumFoundVertexTracks = 0;
174  mNumFoundNonVertexTracks = 0;
175 
176  mNumLookLikeGoodTracks = 0;
177  mNumElectronTracks = 0;
178  mNumNonVertexTracks = 0;
179  mNumGoodGTracks = 0;
180  mNumGoodFTracks = 0;
181  mGoodRatio = 0;
182  mContamination = 0;
183  mContaWoSplit = 0;
184  mNumSplitTracks = 0;
185  mNumSplitGoodTracks = 0;
186  mNumSplitLoliGoodTracks = 0;
187  mNumUncleanTracks = 0;
188  mNumUncleanGoodTracks = 0;
189  mNumLongTracks = 0;
190  mNumLongTrackClusters = 0;
191  mNumShortTracks = 0;
192  mNumTooShortTracks = 0;
193  mNumShortTrackClusters = 0;
194 
195  mVertex = 0;
196 
197  mGeantHits = 0;
198  mFoundHits = 0;
199  mFastSimHits = 0;
200  mGeantTracks = 0;
201  mFoundTracks = 0;
202 
203  mObjArraysCreated = (Bool_t)kFALSE;
204 
205  mFtpcTrackNum = 0;
206 
207  mSplitTracks = 0;
208  mSplitGoodTracks = 0;
209  mSplitLoliGoodTracks = 0;
210  mUncleanTracks = 0;
211  mUncleanGoodTracks = 0;
212  mLongTracks = 0;
213  mLongTrackClusters = 0;
214  mShortTracks = 0;
215  mShortTrackClusters = 0;
216  mMaxClusters = 0;
217 
218  mGoodGeantPoints = 0;
219  mGoodFoundPoints = 0;
220 
221  mNumGoodGeantPoints = 0;
222  mNumGoodFoundPoints = 0;
223  mGoodPointRatio = 0;
224 
225  mFHitsOnTrack = 0;
226  mGHitsOnTrack = 0;
227  mNumParents = 0;
228 
229  mNumWrongHitsAll = 0;
230  mNumWrongHits = 0;
231 
232  mPtot = 0;
233  mPt = 0;
234  mPx = 0;
235  mPy = 0;
236  mPz = 0;
237 
238  mPtotDiff = 0;
239  mPtDiff = 0;
240  mPxDiff = 0;
241  mPyDiff = 0;
242  mPzDiff = 0;
243 
244  mPtotAcc = 0;
245  mPtAcc = 0;
246  mPxAcc = 0;
247  mPyAcc = 0;
248  mPzAcc = 0;
249 
250  mPRelErr = 0;
251  mPRelErrqok = 0;
252  mPRelDiff = 0;
253 
254  mEtaNghits = 0;
255  mEtaNfhits = 0;
256 
257  mPtEtaF = 0;
258  mPtEtaFMes = 0;
259  mPtEtaGood = 0;
260  mPtEtaBad = 0;
261  mPtEtaUnclean = 0;
262  mPtEtaMesUnclean = 0;
263  mPtEtaUncleanGood = 0;
264  mPtEtaMesUncleanGood = 0;
265 
266  mPtEtaSplit = 0;
267  mPtEtaSplitGood = 0;
268  mPtEtaSplitLoliGood = 0;
269 
270  mPtEtaGoodG = 0;
271  mPtEtaGoodF = 0;
272  mPtEtaGoodRatio = 0;
273  mPtEtaBadG = 0;
274  mPtEtaBadF = 0;
275  mPtEtaBadRatio = 0;
276 
277  mPtEtaFVtx = 0;
278  mPtEtaLookLikeGood = 0;
279  mPtEtaContamination = 0;
280  mPtEtaContaWoSplits = 0;
281 
282  mPtEta10PointTracks = 0;
283  mPtEtaWrongCharge = 0;
284  mPtEtaWrongPosCharge = 0;
285 
286  mGLengthDistTrackAng = 0;
287  mGCircleDistTrackAng = 0;
288  mFLengthDistTrackAng = 0;
289  mFCircleDistTrackAng = 0;
290 
291  mGTracklAngAll = 0;
292  mGTrackAngAll = 0;
293  mGCircleDistAll = 0;
294  mGLengthDistAll = 0;
295 
296  mDcaFMainVertex = 0;
297  mDcaFNonVertex = 0;
298  mDcaGMainVertex = 0;
299  mDcaGNonVertex = 0;
300 
301  mGTrackAng = 0;
302  mGCircleDist = 0;
303  mGLengthDist = 0;
304 
305  mGCircleLength = 0;
306 
307  mFTracklAngAll = 0;
308  mFTrackAngAll = 0;
309  mFCircleDistAll = 0;
310  mFLengthDistAll = 0;
311 
312  mFTrackAng = 0;
313  mFCircleDist = 0;
314  mFLengthDist = 0;
315 
316  mFCircleLength = 0;
317 
318  mPRatioDist = 0;
319  mPRatioDistSplit = 0;
320 
321  mParentTrack = 0;
322  mParentTracks = 0;
323  mNumParentTracks = 0;
324 
325  mUnclean = 0;
326 
327  mSetupTime = 0;
328  mTrackingTime = 0;
329  mExtensionTime = 0;
330  mSplitTime = 0;
331  mFitTime = 0;
332  mTotalTime = 0;
333 }
334 
335 
336 StFtpcTrackEvaluator::StFtpcTrackEvaluator(St_DataSet *geant, St_DataSet *ftpc_data, StFtpcTracker *tracker, Char_t *filename, Char_t *write_permission)
337 {
338  // Usual used constructor if conformal mapping tracker output available.
339 
340  LOG_INFO << "Track evaluating started..." << endm;
341 
342  mVertex = tracker->GetVertex();
343 
344  mFoundHits = tracker->GetClusters();
345  mFoundTracks = tracker->GetTracks();
346  mObjArraysCreated = (Bool_t)kFALSE;
347 
348  SetupFile(filename, write_permission);
349  SetupHistos();
350  Setup(geant, ftpc_data);
351 
352  St_ffs_gepoint *ffs_gepoint = (St_ffs_gepoint *)ftpc_data->Find("ffs_fgepoint");
353 
354  if (!ffs_gepoint) {
355  // event processed with slow simulator
356  LOG_INFO << "This event was processed with the slow simulator!" << endm;
357  LOG_INFO << "Most information will be missing due to lack of geant hit information." << endm;
358  }
359 
360  InfoAll();
361  FillHitsOnTrack();
362 
363  if (ffs_gepoint) {
364  // fast simulator was present
365  FillParentHistos();
366  FillMomentumHistos();
367  }
368 
369  FillEventHistos();
370  FillTimeHistos(tracker);
371  FillCutHistos();
372  DivideHistos();
373  WriteHistos();
374 }
375 
376 
377 StFtpcTrackEvaluator::~StFtpcTrackEvaluator()
378 {
379  // Destructor.
380  // Deletes ObjArrays and Histograms.
381 
382  DeleteHistos();
383 
384  delete mClusterArr;
385  delete mUncleanTracksArr;
386  delete mSplitTracksArr;
387  delete mSplitGoodTracksArr;
388  delete mGoodFastSimHitsArr;
389 
390  mFile->Close();
391  delete mFile;
392  delete[] mFilename;
393  delete[] mWritePermission;
394 
395  if (mGeantHits) {
396  mGeantHits->Delete();
397  delete mGeantHits;
398  }
399 
400  if (mGeantTracks) {
401  mGeantTracks->Delete();
402  delete mGeantTracks;
403  }
404 
405  if (mFastSimHits) {
406  mFastSimHits->Delete();
407  delete mFastSimHits;
408  }
409 
410  delete mFtpcTrackNum;
411 
412  delete mParentTrack;
413  delete mParentTracks;
414  delete mNumParentTracks;
415  delete mParent;
416 
417  delete[] mUnclean;
418 
419  if (mObjArraysCreated) {
420  mFoundHits->Delete();
421  mFoundTracks->Delete();
422  delete mFoundHits;
423  delete mFoundTracks;
424  }
425 }
426 
427 
428 void StFtpcTrackEvaluator::DeleteHistos()
429 {
430  // Deletes the histograms
431 
432  delete mNumGeantHits;
433  delete mNumFoundHits;
434  delete mNumGeantTracks;
435  delete mNumFoundTracks;
436 
437  delete mNumFoundVertexTracks;
438  delete mNumFoundNonVertexTracks;
439 
440  delete mNumLookLikeGoodTracks;
441  delete mNumElectronTracks;
442  delete mNumNonVertexTracks;
443  delete mNumGoodGTracks;
444  delete mNumGoodFTracks;
445  delete mGoodRatio;
446  delete mContamination;
447  delete mContaWoSplit;
448  delete mNumSplitTracks;
449  delete mNumSplitGoodTracks;
450  delete mNumSplitLoliGoodTracks;
451  delete mNumUncleanTracks;
452  delete mNumUncleanGoodTracks;
453  delete mNumLongTracks;
454  delete mNumLongTrackClusters;
455  delete mNumShortTracks;
456  delete mNumTooShortTracks;
457  delete mNumShortTrackClusters;
458 
459  delete mNumGoodGeantPoints;
460  delete mNumGoodFoundPoints;
461  delete mGoodPointRatio;
462 
463  delete mFHitsOnTrack;
464  delete mGHitsOnTrack;
465 
466  delete mNumParents;
467  delete mNumWrongHitsAll;
468  delete mNumWrongHits;
469 
470  delete mPtot;
471  delete mPt;
472  delete mPx;
473  delete mPy;
474  delete mPz;
475 
476  delete mPtotDiff;
477  delete mPtDiff;
478  delete mPxDiff;
479  delete mPyDiff;
480  delete mPzDiff;
481 
482  delete mPtotAcc;
483  delete mPtAcc;
484  delete mPxAcc;
485  delete mPyAcc;
486  delete mPzAcc;
487 
488  delete mPRelErr;
489  delete mPRelErrqok;
490  delete mPRelDiff;
491 
492  delete mEtaNghits;
493  delete mEtaNfhits;
494 
495  delete mPtEtaF;
496  delete mPtEtaFMes;
497  delete mPtEtaGood;
498  delete mPtEtaBad;
499  delete mPtEtaUnclean;
500  delete mPtEtaMesUnclean;
501  delete mPtEtaUncleanGood;
502  delete mPtEtaMesUncleanGood;
503 
504  delete mPtEtaSplit;
505  delete mPtEtaSplitGood;
506  delete mPtEtaSplitLoliGood;
507 
508  delete mPtEtaGoodG;
509  delete mPtEtaGoodF;
510  delete mPtEtaGoodRatio;
511  delete mPtEtaBadG;
512  delete mPtEtaBadF;
513  delete mPtEtaBadRatio;
514 
515  delete mPtEtaFVtx;
516  delete mPtEtaLookLikeGood;
517  delete mPtEtaContamination;
518  delete mPtEtaContaWoSplits;
519 
520  delete mPtEta10PointTracks;
521  delete mPtEtaWrongCharge;
522  delete mPtEtaWrongPosCharge;
523 
524  delete mGLengthDistTrackAng;
525  delete mGCircleDistTrackAng;
526  delete mFLengthDistTrackAng;
527  delete mFCircleDistTrackAng;
528 
529  delete mDcaFMainVertex;
530  delete mDcaFNonVertex;
531  delete mDcaGMainVertex;
532  delete mDcaGNonVertex;
533 
534  delete mGTracklAngAll;
535  delete mGTrackAngAll;
536  delete mGCircleDistAll;
537  delete mGLengthDistAll;
538 
539  delete mGTrackAng;
540  delete mGCircleDist;
541  delete mGLengthDist;
542 
543  delete mGCircleLength;
544 
545  delete mFTracklAngAll;
546  delete mFTrackAngAll;
547  delete mFCircleDistAll;
548  delete mFLengthDistAll;
549 
550  delete mFTrackAng;
551  delete mFCircleDist;
552  delete mFLengthDist;
553 
554  delete mFCircleLength;
555 
556  delete mPRatioDist;
557  delete mPRatioDistSplit;
558 
559  delete mSetupTime;
560  delete mTrackingTime;
561  delete mExtensionTime;
562  delete mSplitTime;
563  delete mFitTime;
564  delete mTotalTime;
565 
566  return;
567 }
568 
569 
570 void StFtpcTrackEvaluator::SetupFile(Char_t *filename, Char_t *write_permission)
571 {
572  // Opens the data file.
573 
574  mFilename = new Char_t[50];
575  mWritePermission = new Char_t[10];
576 
577  if (filename) {
578  sprintf(mFilename, "%s", filename);
579  }
580 
581  else {
582  sprintf(mFilename, "ftpc_evaluator.root");
583  }
584 
585  if (write_permission) {
586  sprintf(mWritePermission, "%s", write_permission);
587  }
588 
589  else {
590  sprintf(mWritePermission, "RECREATE");
591  }
592 
593  if (strcmp(mWritePermission, "UPDATE") == 0) {
594 
595  mFile = new TFile(mFilename, "READ");
596 
597  if (!mFile->IsOpen()) {
598  // File not there
599  LOG_WARN << "but that's o.k. - I'll create it immediately!" << endm;
600  delete mFile;
601  mFile = new TFile(mFilename, "RECREATE");
602  CreateHistos();
603  WriteHistos();
604  DeleteHistos();
605  }
606 
607  else {
608  // File is there
609  mFile->Close();
610  delete mFile;
611  mFile = new TFile(mFilename, "UPDATE");
612  }
613  }
614 
615  else {
616  // mWritePermission != "UPDATE"
617  mFile = new TFile(mFilename, "UPDATE");
618  }
619 
620  return;
621 }
622 
623 
624 void StFtpcTrackEvaluator::Setup(St_DataSet *geant, St_DataSet *ftpc_data)
625 {
626  // Does all the setup which is common to all constructors.
627 
628  mClusterArr = new MIntArray();
629 
630  mUncleanTracksArr = new MIntArray();
631  mSplitTracksArr = new MIntArray();
632  mSplitGoodTracksArr = new MIntArray();
633  mGoodFastSimHitsArr = new MIntArray();
634 
635  mFtpcTrackNum = new MIntArray();
636 
637  mParentTrack = new MIntArray();
638  mParentTracks = new MIntArray();
639  mNumParentTracks = new MIntArray();
640  mParent = new MIntArray();
641 
642  mUnclean = new Bool_t[mFoundTracks->GetEntriesFast()];
643 
644  mFoundVertexTracks = 0;
645  mFoundNonVertexTracks = 0;
646 
647  mLookLikeGoodTracks = 0;
648  mElectronTracks = 0;
649  mNonVertexTracks = 0;
650  mGoodGTracks = 0;
651  mGoodFTracks = 0;
652  mSplitTracks = 0;
653  mSplitGoodTracks = 0;
654  mSplitLoliGoodTracks = 0;
655  mUncleanTracks = 0;
656  mUncleanGoodTracks = 0;
657  mLongTracks = 0;
658  mLongTrackClusters = 0;
659  mShortTracks = 0;
660  mShortTrackClusters = 0;
661  mTooShortTracks = 0;
662  mMaxClusters = 0;
663 
664  mGoodGeantPoints = 0;
665  mGoodFoundPoints = 0;
666 
667  if (geant) {
668  // GEANT Table found
669 
670  St_DataSetIter geantI(geant);
671 
672  GeantHitInit((St_g2t_ftp_hit *)geantI("g2t_ftp_hit"));
673  GeantTrackInit((St_g2t_track *)geantI("g2t_track"), (St_g2t_ftp_hit *)geantI("g2t_ftp_hit"));
674 
675  St_ffs_gepoint *ffs_gepoint = (St_ffs_gepoint *)ftpc_data->Find("ffs_fgepoint");
676 
677  if (ffs_gepoint) {
678  // event processed with fast simulator
679  FastSimHitInit(ffs_gepoint);
680  ParentTrackInit();
681  CalcSplitTracks();
682  }
683  }
684 
685  return;
686 }
687 
688 
689 void StFtpcTrackEvaluator::SetupHistos()
690 {
691  // Sets up the histograms.
692 
693  if (strcmp(mWritePermission, "RECREATE") !=0 && strcmp(mWritePermission, "UPDATE") != 0) {
694  LOG_WARN << "Wrong write permission! Has to be RECREATE or UPDATE. Set to RECREATE." << endm;
695  mWritePermission = (Char_t*)"RECREATE";
696  }
697 
698  if (strcmp(mWritePermission, "RECREATE") == 0) {
699  CreateHistos();
700  }
701 
702  else if (strcmp(mWritePermission, "UPDATE") == 0) {
703 
704  mNumGeantHits = (TH1F *)mFile->Get("num_ghits");
705  mNumFoundHits = (TH1F *)mFile->Get("num_fhits");
706  mNumGeantTracks = (TH1F *)mFile->Get("num_gtracks");
707  mNumFoundTracks = (TH1F *)mFile->Get("num_ftracks");
708 
709  mNumFoundVertexTracks = (TH1F *)mFile->Get("num_fvtx");
710  mNumFoundNonVertexTracks = (TH1F *)mFile->Get("num_fnonvtx");
711 
712  mNumLookLikeGoodTracks = (TH1F *)mFile->Get("num_loligood");
713  mNumElectronTracks = (TH1F *)mFile->Get("num_electron");
714  mNumNonVertexTracks = (TH1F *)mFile->Get("num_nvtx");
715  mNumGoodGTracks = (TH1F *)mFile->Get("num_goodg");
716  mNumGoodFTracks = (TH1F *)mFile->Get("num_goodf");
717  mNumSplitTracks = (TH1F *)mFile->Get("num_split");
718  mNumSplitGoodTracks = (TH1F *)mFile->Get("num_split_good");
719  mNumSplitLoliGoodTracks = (TH1F *)mFile->Get("num_split_loligood");
720  mNumUncleanTracks = (TH1F *)mFile->Get("num_unclean");
721  mNumUncleanGoodTracks = (TH1F *)mFile->Get("num_unclean_good");
722  mNumLongTracks = (TH1F *)mFile->Get("num_long");
723  mNumLongTrackClusters = (TH1F *)mFile->Get("num_longclus");
724  mNumShortTracks = (TH1F *)mFile->Get("num_short");
725  mNumTooShortTracks = (TH1F *)mFile->Get("num_tooshort");
726  mNumShortTrackClusters = (TH1F *)mFile->Get("num_shortclus");
727 
728  mNumGoodGeantPoints = (TH1F *)mFile->Get("good_pointsg");
729  mNumGoodFoundPoints = (TH1F *)mFile->Get("good_pointsf");
730  mGoodPointRatio = (TH1F *)mFile->Get("good_point_ratio");
731 
732  mGHitsOnTrack = (TH1F *)mFile->Get("geant_hits");
733  mFHitsOnTrack = (TH1F *)mFile->Get("found_hits");
734 
735  mNumParents = (TH1F *)mFile->Get("num_parents");
736  mNumWrongHits = (TH2F *)mFile->Get("wrong_hits");
737  mNumWrongHitsAll = (TH1F *)mFile->Get("wrong_hits_all");
738 
739  mGoodRatio = (TH1F *)mFile->Get("good_ratio");
740  mContamination = (TH1F *)mFile->Get("contamination");
741  mContaWoSplit = (TH1F *)mFile->Get("conta_wo_split");
742 
743  mPtot = (TH2F *)mFile->Get("ptot");
744  mPt = (TH2F *)mFile->Get("pt");
745  mPx = (TH2F *)mFile->Get("px");
746  mPy = (TH2F *)mFile->Get("py");
747  mPz = (TH2F *)mFile->Get("pz");
748 
749  mPtotDiff = (TH1F *)mFile->Get("ptot_diff");
750  mPtDiff = (TH1F *)mFile->Get("pt_diff");
751  mPxDiff = (TH1F *)mFile->Get("px_diff");
752  mPyDiff = (TH1F *)mFile->Get("py_diff");
753  mPzDiff = (TH1F *)mFile->Get("pz_diff");
754 
755  mPtotAcc = (TH1F *)mFile->Get("ptot_acc");
756  mPtAcc = (TH1F *)mFile->Get("pt_acc");
757  mPxAcc = (TH1F *)mFile->Get("px_acc");
758  mPyAcc = (TH1F *)mFile->Get("py_acc");
759  mPzAcc = (TH1F *)mFile->Get("pz_acc");
760 
761  mPRelErr = (TH3F *)mFile->Get("p_rel_err");
762  mPRelErrqok = (TH3F *)mFile->Get("p_rel_err_q_ok");
763  mPRelDiff = (TH3F *)mFile->Get("p_rel_diff");
764 
765  mEtaNfhits = (TH2F *)mFile->Get("eta_fhits");
766  mEtaNghits = (TH2F *)mFile->Get("eta_ghits");
767 
768  mPtEtaF = (TH2F *)mFile->Get("pt_etaf");
769  mPtEtaFMes = (TH2F *)mFile->Get("pt_etaf_mes");
770  mPtEtaGood = (TH2F *)mFile->Get("pt_eta_good");
771  mPtEtaBad = (TH2F *)mFile->Get("pt_eta_bad");
772  mPtEtaUnclean = (TH2F *)mFile->Get("pt_eta_unclean");
773  mPtEtaMesUnclean = (TH2F *)mFile->Get("pt_eta_mes_unclean");
774  mPtEtaUncleanGood = (TH2F *)mFile->Get("pt_eta_unclean_good");
775  mPtEtaMesUncleanGood = (TH2F *)mFile->Get("pt_eta_mes_unclean_good");
776 
777  mPtEtaSplit = (TH2F *)mFile->Get("pt_eta_split");
778  mPtEtaSplitGood = (TH2F *)mFile->Get("pt_eta_split_good");
779  mPtEtaSplitLoliGood = (TH2F *)mFile->Get("pt_eta_split_loligood");
780 
781  mPtEtaGoodG = (TH2F *)mFile->Get("pt_eta_goodg");
782  mPtEtaGoodF = (TH2F *)mFile->Get("pt_eta_goodf");
783  mPtEtaGoodRatio = (TH2F *)mFile->Get("pt_eta_good_ratio");
784  mPtEtaBadG = (TH2F *)mFile->Get("pt_eta_badg");
785  mPtEtaBadF = (TH2F *)mFile->Get("pt_eta_badf");
786  mPtEtaBadRatio = (TH2F *)mFile->Get("pt_eta_bad_ratio");
787 
788  mPtEtaFVtx = (TH2F *)mFile->Get("pt_eta_vtxf");
789  mPtEtaLookLikeGood = (TH2F *)mFile->Get("pt_eta_loligood");
790  mPtEtaContamination = (TH2F *)mFile->Get("pt_eta_contam");
791  mPtEtaContaWoSplits = (TH2F *)mFile->Get("pt_eta_contam_wo_splits");
792 
793  mPtEta10PointTracks = (TH2F *)mFile->Get("pt_eta_10point_tracks");
794  mPtEtaWrongCharge = (TH2F *)mFile->Get("pt_eta_wrong_charge");
795  mPtEtaWrongPosCharge = (TH2F *)mFile->Get("pt_eta_wrong_positive_charge");
796 
797  mDcaFMainVertex = (TH1F *)mFile->Get("dca_mainf");
798  mDcaFNonVertex = (TH1F *)mFile->Get("dca_nonf");
799  mDcaGMainVertex = (TH1F *)mFile->Get("dca_maing");
800  mDcaGNonVertex = (TH1F *)mFile->Get("dca_nong");
801 
802  mGLengthDistTrackAng = (TH2F *)mFile->Get("glength_ang");
803  mGCircleDistTrackAng = (TH2F *)mFile->Get("gcircle_ang");
804  mFLengthDistTrackAng = (TH2F *)mFile->Get("flength_ang");
805  mFCircleDistTrackAng = (TH2F *)mFile->Get("fcircle_ang");
806 
807  mGTracklAngAll = (TH1F *)mFile->Get("gtrackl_angle_all");
808  mGTrackAngAll = (TH1F *)mFile->Get("gtrack_angle_all");
809  mGCircleDistAll = (TH1F *)mFile->Get("gcircle_dist_all");
810  mGLengthDistAll = (TH1F *)mFile->Get("glength_dist_all");
811 
812  mGTrackAng = (TH2F *)mFile->Get("gtrack_angle");
813  mGCircleDist = (TH2F *)mFile->Get("gcircle_dist");
814  mGLengthDist = (TH2F *)mFile->Get("glength_dist");
815 
816  mGCircleLength = (TH2F *)mFile->Get("gcircle_length");
817 
818  mFTracklAngAll = (TH1F *)mFile->Get("ftrackl_angle_all");
819  mFTrackAngAll = (TH1F *)mFile->Get("ftrack_angle_all");
820  mFCircleDistAll = (TH1F *)mFile->Get("fcircle_dist_all");
821  mFLengthDistAll = (TH1F *)mFile->Get("flength_dist_all");
822 
823  mFTrackAng = (TH2F *)mFile->Get("ftrack_angle");
824  mFCircleDist = (TH2F *)mFile->Get("fcircle_dist");
825  mFLengthDist = (TH2F *)mFile->Get("flength_dist");
826 
827  mFCircleLength = (TH2F *)mFile->Get("fcircle_length");
828 
829  mPRatioDist = (TH2F *)mFile->Get("pratio_dist");
830  mPRatioDistSplit = (TH2F *)mFile->Get("pratio_dist_split");
831 
832  mSetupTime = (TH1F*)mFile->Get("setup_time");
833  mTrackingTime = (TH1F*)mFile->Get("tracking_time");
834  mExtensionTime = (TH1F*)mFile->Get("extension_time");
835  mSplitTime = (TH1F*)mFile->Get("split_time");
836  mFitTime = (TH1F*)mFile->Get("fit_time");
837  mTotalTime = (TH1F*)mFile->Get("total_time");
838  }
839 
840  return;
841 }
842 
843 
844 void StFtpcTrackEvaluator::CreateHistos()
845 {
846  // Create histograms.
847 
848  mNumGeantHits = new TH1F("num_ghits", "Simulated clusters", 100, 0., 40000.);
849  mNumFoundHits = new TH1F("num_fhits", "Found clusters", 100, 0., 40000.);
850  mNumGeantTracks = new TH1F("num_gtracks", "Simulated tracks", 100, 0., 5000.);
851  mNumFoundTracks = new TH1F("num_ftracks", "Found tracks", 100, 0., 2500.);
852 
853  mNumFoundVertexTracks = new TH1F("num_fvtx", "Found main vertex tracks", 100, 0., 2500.);
854  mNumFoundNonVertexTracks = new TH1F("num_fnonvtx", "Found non main vertex tracks", 100, 0., 2500.);
855 
856  mNumLookLikeGoodTracks = new TH1F("num_loligood", "Tracks which look like good tracks", 100, 0., 500.);
857  mNumElectronTracks = new TH1F("num_electron", "Electrons", 100, 0., 500.);
858  mNumNonVertexTracks = new TH1F("num_nvtx", "Non main vertex tracks", 100, 0., 1000.);
859  mNumGoodGTracks = new TH1F("num_goodg", "Good geant tracks", 100, 0., 1000.);
860  mNumGoodFTracks = new TH1F("num_goodf", "Good found tracks", 100, 0., 1000.);
861  mGoodRatio = new TH1F("good_ratio", "Ratio of good found tracks to good geant tracks", 100, 0., 2.);
862  mContamination = new TH1F("contamination", "Ratio of loli good tracks to good main vertex tracks", 100, 0., 2.);
863  mContaWoSplit = new TH1F("conta_wo_split", "Ratio of loli good minus split tracks to good main vertex tracks", 100, 0., 2.);
864  mNumSplitTracks = new TH1F("num_split", "Split tracks", 100, 0., 300.);
865  mNumSplitGoodTracks = new TH1F("num_split_good", "Split good tracks", 100, 0., 300.);
866  mNumSplitLoliGoodTracks = new TH1F("num_split_loligood", "Split look-like good tracks", 100, 0., 300.);
867  mNumUncleanTracks = new TH1F("num_unclean", "Unclean tracks", 100, 0., 300.);
868  mNumUncleanGoodTracks = new TH1F("num_unclean_good", "Unclean good tracks", 100, 0., 300.);
869  mNumLongTracks = new TH1F("num_long", "Simulated tracks with more than 10 clusters", 100, 0., 300.);
870  mNumShortTracks = new TH1F("num_short", "Simulated tracks with less than 5 clusters", 100, 0., 5000.);
871  mNumTooShortTracks = new TH1F("num_tooshort", "Tracks which should be longer", 100, 0., 1000.);
872 
873  mNumShortTrackClusters = new TH1F("num_shortclus", "Clusters on tracks with less than 5 clusters", 100, 0., 12000.);
874  mNumLongTrackClusters = new TH1F("num_longclus", "Clusters on tracks with more than 10 clusters", 100, 0., 1600.);
875 
876  mNumGoodGeantPoints = new TH1F("good_pointsg", "Number of points on good geant tracks", 100, 0., 40000.);
877  mNumGoodFoundPoints = new TH1F("good_pointsf", "Number of points on good found tracks", 100, 0., 40000.);
878  mGoodPointRatio = new TH1F("good_point_ratio", "Ratio of good points", 100, 0., 1.);
879 
880  mFHitsOnTrack = new TH1F("found_hits", "Found clusters", StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), 0.5, StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + 0.5);
881  mGHitsOnTrack = new TH1F("geant_hits", "Geant clusters", 50, 0.5, 50.5);
882 
883  mNumParents = new TH1F("num_parents", "Parent tracks", StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), 0.5, StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + 0.5);
884  mNumWrongHits = new TH2F("wrong_hits", "Wrong clusters on tracks", StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), -0.5, 9.5, StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), 0.5, StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + 0.5);
885  mNumWrongHitsAll = new TH1F("wrong_hits_all", "Wrong clusters on tracks", StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), -0.5, 9.5);
886 
887  mPtot = new TH2F("ptot", "Total momentum", 60, 0., 30., 60, 0., 30.);
888  mPt = new TH2F("pt", "Transverse momentum", 50, 0., 2.5, 50, 0., 2.5);
889  mPx = new TH2F("px", "Momentum in x direction", 60, -1.5, 1.5, 60, -1.5, 1.5);
890  mPy = new TH2F("py", "Momentum in y direction", 60, -1.5, 1.5, 60, -1.5, 1.5);
891  mPz = new TH2F("pz", "Momentum in z direction", 100, -25., 25., 100, -25., 25.);
892 
893  mPtotDiff = new TH1F("ptot_diff", "Rel. difference in p_tot", 200, -1., 1.);
894  mPtDiff = new TH1F("pt_diff", "Rel. difference in p_t", 200, -1., 1.);
895  mPxDiff = new TH1F("px_diff", "Rel. difference in p_x", 200, -1., 1.);
896  mPyDiff = new TH1F("py_diff", "Rel. difference in p_y", 200, -1., 1.);
897  mPzDiff = new TH1F("pz_diff", "Rel. difference in p_z", 200, -1., 1.);
898 
899  mPtotAcc = new TH1F("ptot_acc", "Rel. accuracy in p_tot", 200, 0., 5.);
900  mPtAcc = new TH1F("pt_acc", "Rel. accuracy in p_t", 200, 0., 5.);
901  mPxAcc = new TH1F("px_acc", "Rel. accuracy in p_x", 200, 0., 5.);
902  mPyAcc = new TH1F("py_acc", "Rel. accuracy in p_y", 200, 0., 5.);
903  mPzAcc = new TH1F("pz_acc", "Rel. accuracy in p_z", 200, 0., 5.);
904 
905  mPRelErr = new TH3F("p_rel_err", "Rel. error of p_tot", 48, 2., 4.4, 25, 0., 5., 50, -1., 1.);
906  mPRelErrqok = new TH3F("p_rel_err_q_ok", "Rel. error of p_tot (charge ok)", 48, 2., 4.4, 25, 0., 5., 50, -1., 1.);
907  mPRelDiff = new TH3F("p_rel_diff", "Rel. differnce of p_tot", 48, 2., 4.4, 25, 0., 5., 50, -1., 1.);
908 
909  mEtaNghits = new TH2F("eta_ghits", "Geant tracks", StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), 0.5, StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + 0.5, 96, 2.0, 4.4);
910  mEtaNfhits = new TH2F("eta_fhits", "Found tracks", StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), 0.5, StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + 0.5, 96, 2.0, 4.4);
911 
912  mPtEtaF = new TH2F("pt_etaf", "Found tracks", 96, 2.0, 4.4, 50, 0., 5.);
913  mPtEtaFMes = new TH2F("pt_etaf_mes", "Found tracks", 96, 2.0, 4.4, 50, 0., 5.);
914  mPtEtaGood = new TH2F("pt_eta_good", "Ratio of good tracks", 96, 2.0, 4.4, 50, 0., 5.);
915  mPtEtaBad = new TH2F("pt_eta_bad", "Ratio of bad tracks", 96, 2.0, 4.4, 50, 0., 5.);
916  mPtEtaUnclean = new TH2F("pt_eta_unclean", "Unclean tracks", 96, 2.0, 4.4, 50, 0., 5.);
917  mPtEtaMesUnclean = new TH2F("pt_eta_mes_unclean", "Unclean tracks", 96, 2.0, 4.4, 50, 0., 5.);
918  mPtEtaUncleanGood = new TH2F("pt_eta_unclean_good", "Unclean good tracks", 96, 2.0, 4.4, 50, 0., 5.);
919  mPtEtaMesUncleanGood = new TH2F("pt_eta_mes_unclean_good", "Unclean good tracks", 96, 2.0, 4.4, 50, 0., 5.);
920 
921  mPtEtaSplit = new TH2F("pt_eta_split", "Split tracks", 96, 2.0, 4.4, 50, 0., 5.);
922  mPtEtaSplitGood = new TH2F("pt_eta_split_good", "Split good tracks", 96, 2.0, 4.4, 50, 0., 5.);
923  mPtEtaSplitLoliGood = new TH2F("pt_eta_split_loligood", "Split look-like good tracks", 96, 2.0, 4.4, 50, 0., 5.);
924 
925  mPtEtaGoodG = new TH2F("pt_eta_goodg", "Good geant tracks", 96, 2.0, 4.4, 50, 0., 5.);
926  mPtEtaGoodF = new TH2F("pt_eta_goodf", "Good found tracks", 96, 2.0, 4.4, 50, 0., 5.);
927  mPtEtaGoodRatio = new TH2F("pt_eta_good_ratio", "Ratio of good found tracks", 96, 2.0, 4.4, 50, 0., 5.);
928  mPtEtaBadG = new TH2F("pt_eta_badg", "Bad geant tracks", 96, 2.0, 4.4, 50, 0., 5.);
929  mPtEtaBadF = new TH2F("pt_eta_badf", "Bad found tracks", 96, 2.0, 4.4, 50, 0., 5.);
930  mPtEtaBadRatio = new TH2F("pt_eta_bad_ratio", "Ratio of bad found tracks", 96, 2.0, 4.4, 50, 0., 5.);
931 
932  mPtEtaFVtx = new TH2F("pt_eta_vtxf", "Found tracks with main vertex tag", 96, 2.0, 4.4, 50, 0., 5.);
933  mPtEtaLookLikeGood = new TH2F("pt_eta_loligood", "Found tracks looking good but are not", 96, 2.0, 4.4, 50, 0., 5.);
934  mPtEtaContamination = new TH2F("pt_eta_contam", "Contamination", 96, 2.0, 4.4, 50, 0., 5.);
935  mPtEtaContaWoSplits = new TH2F("pt_eta_contam_wo_splits", "Contamination without splits", 96, 2.0, 4.4, 50, 0., 5.);
936 
937  mPtEta10PointTracks = new TH2F("pt_eta_10point_tracks", "tracks with 10 points", 96, 2.0, 4.4, 50, 0., 5.);
938  mPtEtaWrongCharge = new TH2F("pt_eta_wrong_charge", "tracks with wrong charge", 96, 2.0, 4.4, 50, 0., 5.);
939  mPtEtaWrongPosCharge = new TH2F("pt_eta_wrong_positive_charge", "tracks with wrong positiv charge", 96, 2.0, 4.4, 50, 0., 5.);
940 
941  mDcaFMainVertex = new TH1F("dca_mainf", "Found main vertex tracks", 100, 0., 10.);
942  mDcaFNonVertex = new TH1F("dca_nonf", "Found non vertex tracks", 100, 0., 10.);
943  mDcaGMainVertex = new TH1F("dca_maing", "Geant main vertex tracks", 100, 0., 10.);
944  mDcaGNonVertex = new TH1F("dca_nong", "Geant non vertex tracks", 100, 0., 10.);
945 
946  mGLengthDistTrackAng = new TH2F("glength_ang", "Geant tracks", 100, 0., 0.1, 100, 0., 50.);
947  mGCircleDistTrackAng = new TH2F("gcircle_ang", "Geant tracks", 100, 0., 0.1, 100, 0., 0.01);
948  mFLengthDistTrackAng = new TH2F("flength_ang", "Found tracks", 100, 0., 0.1, 100, 0., 50.);
949  mFCircleDistTrackAng = new TH2F("fcircle_ang", "Found tracks", 100, 0., 0.1, 100, 0., 0.01);
950 
951  mGTracklAngAll = new TH1F("gtrackl_angle_all", "Geant tracks", 100, 0., 0.1);
952  mGTrackAngAll = new TH1F("gtrack_angle_all", "Geant tracks", 100, 0., 0.5);
953  mGCircleDistAll = new TH1F("gcircle_dist_all", "Geant tracks", 100, 0., 0.015);
954  mGLengthDistAll = new TH1F("glength_dist_all", "Geant tracks", 100, 0., 200);
955 
956  mGTrackAng = new TH2F("gtrack_angle", "Geant tracks", 100, 0., 0.5, 8, 2.5, 10.5);
957  mGCircleDist = new TH2F("gcircle_dist", "Geant tracks", 100, 0., 0.015, 7, 3.5, 10.5);
958  mGLengthDist = new TH2F("glength_dist", "Geant tracks", 100, 0., 200, 7, 3.5, 10.5);
959 
960  mGCircleLength = new TH2F("gcircle_length", "Geant tracks", 100, 0., 40., 100, 0., 0.015);
961 
962  mFTracklAngAll = new TH1F("ftrackl_angle_all", "Found tracks", 100, 0., 0.1);
963  mFTrackAngAll = new TH1F("ftrack_angle_all", "Found tracks", 100, 0., 0.5);
964  mFCircleDistAll = new TH1F("fcircle_dist_all", "Found tracks", 100, 0., 0.015);
965  mFLengthDistAll = new TH1F("flength_dist_all", "Found tracks", 100, 0., 200);
966 
967  mFTrackAng = new TH2F("ftrack_angle", "Found tracks", 100, 0., 0.5, 8, 2.5, 10.5);
968  mFCircleDist = new TH2F("fcircle_dist", "Found tracks", 100, 0., 0.015, 7, 3.5, 10.5);
969  mFLengthDist = new TH2F("flength_dist", "Found tracks", 100, 0., 200, 7, 3.5, 10.5);
970 
971  mFCircleLength = new TH2F("fcircle_length", "Found tracks", 100, 0., 40., 100, 0., 0.015);
972 
973  mPRatioDist = new TH2F("pratio_dist", "Found track pairs", 100, 0., 2., 37, 0.25, 1.0);
974  mPRatioDistSplit = new TH2F("pratio_dist_split", "Split track pairs", 100, 0., 2., 37, 0.25, 1.0);
975 
976  mSetupTime = new TH1F("setup_time", "Setup time", 1000, 0., 2.);
977  mTrackingTime = new TH1F("tracking_time", "Tracking time", 1000, 0., 2.);
978  mExtensionTime = new TH1F("extension_time", "Extension time", 1000, 0., 2.);
979  mSplitTime = new TH1F("split_time", "Splits time", 1000, 0., 2.);
980  mFitTime = new TH1F("fit_time", "Fit time", 1000, 0., 2.);
981  mTotalTime = new TH1F("total_time", "Total time", 1000, 0., 2.);
982 
983  ((TAxis *)mNumGeantHits->GetXaxis())->SetTitle("'F# of clusters");
984  ((TAxis *)mNumGeantHits->GetYaxis())->SetTitle("'F# of events");
985  ((TAxis *)mNumFoundHits->GetXaxis())->SetTitle("'F# of clusters");
986  ((TAxis *)mNumFoundHits->GetYaxis())->SetTitle("'F# of events");
987  ((TAxis *)mNumGeantTracks->GetXaxis())->SetTitle("'F# of tracks");
988  ((TAxis *)mNumGeantTracks->GetYaxis())->SetTitle("'F# of events");
989  ((TAxis *)mNumFoundTracks->GetXaxis())->SetTitle("'F# of tracks");
990  ((TAxis *)mNumFoundTracks->GetYaxis())->SetTitle("'F# of events");
991 
992  ((TAxis *)mNumFoundVertexTracks->GetXaxis())->SetTitle("'F# of tracks");
993  ((TAxis *)mNumFoundVertexTracks->GetYaxis())->SetTitle("'F# of events");
994  ((TAxis *)mNumFoundNonVertexTracks->GetXaxis())->SetTitle("'F# of tracks");
995  ((TAxis *)mNumFoundNonVertexTracks->GetYaxis())->SetTitle("'F# of events");
996 
997  ((TAxis *)mNumLookLikeGoodTracks->GetXaxis())->SetTitle("'F# of tracks");
998  ((TAxis *)mNumLookLikeGoodTracks->GetYaxis())->SetTitle("'F# of events");
999 
1000  ((TAxis *)mNumElectronTracks->GetXaxis())->SetTitle("'F# of tracks");
1001  ((TAxis *)mNumElectronTracks->GetYaxis())->SetTitle("'F# of events");
1002  ((TAxis *)mNumNonVertexTracks->GetXaxis())->SetTitle("'F# of tracks");
1003  ((TAxis *)mNumNonVertexTracks->GetYaxis())->SetTitle("'F# of events");
1004  ((TAxis *)mNumGoodGTracks->GetXaxis())->SetTitle("'F# of tracks");
1005  ((TAxis *)mNumGoodGTracks->GetYaxis())->SetTitle("'F# of events");
1006  ((TAxis *)mNumGoodFTracks->GetXaxis())->SetTitle("'F# of tracks");
1007  ((TAxis *)mNumGoodFTracks->GetYaxis())->SetTitle("'F# of events");
1008  ((TAxis *)mGoodRatio->GetXaxis())->SetTitle("ratio");
1009  ((TAxis *)mGoodRatio->GetYaxis())->SetTitle("'F# of events");
1010  ((TAxis *)mContamination->GetXaxis())->SetTitle("ratio");
1011  ((TAxis *)mContamination->GetYaxis())->SetTitle("'F# of events");
1012  ((TAxis *)mContaWoSplit->GetXaxis())->SetTitle("ratio");
1013  ((TAxis *)mContaWoSplit->GetYaxis())->SetTitle("'F# of events");
1014 
1015  ((TAxis *)mNumSplitTracks->GetXaxis())->SetTitle("'F# of tracks");
1016  ((TAxis *)mNumSplitTracks->GetYaxis())->SetTitle("'F# of events");
1017  ((TAxis *)mNumSplitGoodTracks->GetXaxis())->SetTitle("'F# of tracks");
1018  ((TAxis *)mNumSplitGoodTracks->GetYaxis())->SetTitle("'F# of events");
1019  ((TAxis *)mNumSplitLoliGoodTracks->GetXaxis())->SetTitle("'F# of tracks");
1020  ((TAxis *)mNumSplitLoliGoodTracks->GetYaxis())->SetTitle("'F# of events");
1021  ((TAxis *)mNumUncleanTracks->GetXaxis())->SetTitle("'F# of tracks");
1022  ((TAxis *)mNumUncleanTracks->GetYaxis())->SetTitle("'F# of events");
1023  ((TAxis *)mNumUncleanGoodTracks->GetXaxis())->SetTitle("'F# of tracks");
1024  ((TAxis *)mNumUncleanGoodTracks->GetYaxis())->SetTitle("'F# of events");
1025  ((TAxis *)mNumLongTracks->GetXaxis())->SetTitle("'F# of tracks");
1026  ((TAxis *)mNumLongTracks->GetYaxis())->SetTitle("'F# of events");
1027  ((TAxis *)mNumLongTrackClusters->GetXaxis())->SetTitle("'F# of clusters");
1028  ((TAxis *)mNumLongTrackClusters->GetYaxis())->SetTitle("'F# of events");
1029  ((TAxis *)mNumShortTracks->GetXaxis())->SetTitle("'F# of tracks");
1030  ((TAxis *)mNumShortTracks->GetYaxis())->SetTitle("'F# of events");
1031  ((TAxis *)mNumTooShortTracks->GetXaxis())->SetTitle("'F# of tracks");
1032  ((TAxis *)mNumTooShortTracks->GetYaxis())->SetTitle("'F# of events");
1033  ((TAxis *)mNumShortTrackClusters->GetXaxis())->SetTitle("'F# of clusters");
1034  ((TAxis *)mNumShortTrackClusters->GetYaxis())->SetTitle("'F# of events");
1035 
1036  ((TAxis *)mFHitsOnTrack->GetXaxis())->SetTitle("'F# of clusters on track");
1037  ((TAxis *)mFHitsOnTrack->GetYaxis())->SetTitle("'F# of found tracks");
1038  ((TAxis *)mGHitsOnTrack->GetXaxis())->SetTitle("'F# of clusters on track");
1039  ((TAxis *)mGHitsOnTrack->GetYaxis())->SetTitle("'F# of found tracks");
1040 
1041  ((TAxis *)mNumGoodGeantPoints->GetXaxis())->SetTitle("'F# of clusters");
1042  ((TAxis *)mNumGoodGeantPoints->GetYaxis())->SetTitle("'F# of events");
1043  ((TAxis *)mNumGoodFoundPoints->GetXaxis())->SetTitle("'F# of clusters");
1044  ((TAxis *)mNumGoodFoundPoints->GetYaxis())->SetTitle("'F# of events");
1045  ((TAxis *)mGoodPointRatio->GetXaxis())->SetTitle("Ratio");
1046  ((TAxis *)mGoodPointRatio->GetYaxis())->SetTitle("'F# of events");
1047 
1048  ((TAxis *)mNumParents->GetXaxis())->SetTitle("'F# of parent tracks");
1049  ((TAxis *)mNumParents->GetYaxis())->SetTitle("'F# of found tracks");
1050  ((TAxis *)mNumWrongHits->GetXaxis())->SetTitle("'F# of wrong clusters on track");
1051  ((TAxis *)mNumWrongHits->GetXaxis())->SetTitle("'F# of found clusters on track");
1052  ((TAxis *)mNumWrongHits->GetZaxis())->SetTitle("'F# of found tracks");
1053  ((TAxis *)mNumWrongHitsAll->GetXaxis())->SetTitle("'F# of wrong clusters on track");
1054  ((TAxis *)mNumWrongHitsAll->GetYaxis())->SetTitle("'F# of found tracks");
1055 
1056  ((TAxis *)mPtot->GetXaxis())->SetTitle("momentum of geant track");
1057  ((TAxis *)mPtot->GetYaxis())->SetTitle("momentum of found track");
1058  ((TAxis *)mPtot->GetZaxis())->SetTitle("'F# of found tracks");
1059  ((TAxis *)mPt->GetXaxis())->SetTitle("momentum of geant track");
1060  ((TAxis *)mPt->GetYaxis())->SetTitle("momentum of found track");
1061  ((TAxis *)mPt->GetZaxis())->SetTitle("'F# of found tracks");
1062  ((TAxis *)mPx->GetXaxis())->SetTitle("momentum of geant track");
1063  ((TAxis *)mPx->GetYaxis())->SetTitle("momentum of found track");
1064  ((TAxis *)mPx->GetZaxis())->SetTitle("'F# of found tracks");
1065  ((TAxis *)mPy->GetXaxis())->SetTitle("momentum of geant track");
1066  ((TAxis *)mPy->GetYaxis())->SetTitle("momentum of found track");
1067  ((TAxis *)mPy->GetZaxis())->SetTitle("'F# of found tracks");
1068  ((TAxis *)mPz->GetXaxis())->SetTitle("momentum of geant track");
1069  ((TAxis *)mPz->GetYaxis())->SetTitle("momentum of found track");
1070  ((TAxis *)mPz->GetZaxis())->SetTitle("'F# of found tracks");
1071 
1072  ((TAxis *)mPtotDiff->GetXaxis())->SetTitle("rel. difference");
1073  ((TAxis *)mPtotDiff->GetYaxis())->SetTitle("'F# of found tracks");
1074  ((TAxis *)mPtDiff->GetXaxis())->SetTitle("rel. difference");
1075  ((TAxis *)mPtDiff->GetYaxis())->SetTitle("'F# of found tracks");
1076  ((TAxis *)mPxDiff->GetXaxis())->SetTitle("rel. difference");
1077  ((TAxis *)mPxDiff->GetYaxis())->SetTitle("'F# of found tracks");
1078  ((TAxis *)mPyDiff->GetXaxis())->SetTitle("rel. difference");
1079  ((TAxis *)mPyDiff->GetYaxis())->SetTitle("'F# of found tracks");
1080  ((TAxis *)mPzDiff->GetXaxis())->SetTitle("rel. difference");
1081  ((TAxis *)mPzDiff->GetYaxis())->SetTitle("'F# of found tracks");
1082 
1083  ((TAxis *)mPtotAcc->GetXaxis())->SetTitle("rel. accuracy");
1084  ((TAxis *)mPtotAcc->GetYaxis())->SetTitle("'F# of found tracks");
1085  ((TAxis *)mPtAcc->GetXaxis())->SetTitle("rel. accuracy");
1086  ((TAxis *)mPtAcc->GetYaxis())->SetTitle("'F# of found tracks");
1087  ((TAxis *)mPxAcc->GetXaxis())->SetTitle("rel. accuracy");
1088  ((TAxis *)mPxAcc->GetYaxis())->SetTitle("'F# of found tracks");
1089  ((TAxis *)mPyAcc->GetXaxis())->SetTitle("rel. accuracy");
1090  ((TAxis *)mPyAcc->GetYaxis())->SetTitle("'F# of found tracks");
1091  ((TAxis *)mPzAcc->GetXaxis())->SetTitle("rel. accuracy");
1092  ((TAxis *)mPzAcc->GetYaxis())->SetTitle("'F# of found tracks");
1093 
1094  ((TAxis *)mDcaFMainVertex->GetXaxis())->SetTitle("dca [cm]");
1095  ((TAxis *)mDcaFMainVertex->GetYaxis())->SetTitle("'F# of tracks");
1096  ((TAxis *)mDcaFNonVertex->GetXaxis())->SetTitle("dca [cm]");
1097  ((TAxis *)mDcaFNonVertex->GetYaxis())->SetTitle("'F# of tracks");
1098  ((TAxis *)mDcaGMainVertex->GetXaxis())->SetTitle("dca [cm]");
1099  ((TAxis *)mDcaGMainVertex->GetYaxis())->SetTitle("'F# of tracks");
1100  ((TAxis *)mDcaGNonVertex->GetXaxis())->SetTitle("dca [cm]");
1101  ((TAxis *)mDcaGNonVertex->GetYaxis())->SetTitle("'F# of tracks");
1102 
1103  ((TAxis *)mGTracklAngAll->GetXaxis())->SetTitle("angle of tracklet");
1104  ((TAxis *)mGTracklAngAll->GetYaxis())->SetTitle("'F# of tracklets");
1105  ((TAxis *)mGTrackAngAll->GetXaxis())->SetTitle("angle of track endings");
1106  ((TAxis *)mGTrackAngAll->GetYaxis())->SetTitle("'F# of track endings");
1107  ((TAxis *)mGCircleDistAll->GetXaxis())->SetTitle("circle distance to track");
1108  ((TAxis *)mGCircleDistAll->GetYaxis())->SetTitle("'F# of track endings");
1109  ((TAxis *)mGLengthDistAll->GetXaxis())->SetTitle("length distance to track");
1110  ((TAxis *)mGLengthDistAll->GetYaxis())->SetTitle("'F# of track endings");
1111 
1112  ((TAxis *)mGTrackAng->GetXaxis())->SetTitle("angle of track endings");
1113  ((TAxis *)mGTrackAng->GetYaxis())->SetTitle("'F# of last point");
1114  ((TAxis *)mGTrackAng->GetZaxis())->SetTitle("'F# of track endings");
1115  ((TAxis *)mGCircleDist->GetXaxis())->SetTitle("circle distance to track");
1116  ((TAxis *)mGCircleDist->GetYaxis())->SetTitle("'F# of last point");
1117  ((TAxis *)mGCircleDist->GetZaxis())->SetTitle("'F# of track endings");
1118  ((TAxis *)mGLengthDist->GetXaxis())->SetTitle("length distance to track");
1119  ((TAxis *)mGLengthDist->GetYaxis())->SetTitle("'F# of last point");
1120  ((TAxis *)mGLengthDist->GetZaxis())->SetTitle("'F# of track endings");
1121 
1122  ((TAxis *)mGCircleLength->GetXaxis())->SetTitle("length distance");
1123  ((TAxis *)mGCircleLength->GetYaxis())->SetTitle("circle distance");
1124  ((TAxis *)mGCircleLength->GetZaxis())->SetTitle("'F# of track endings");
1125 
1126  ((TAxis *)mFTracklAngAll->GetXaxis())->SetTitle("angle of tracklet");
1127  ((TAxis *)mFTracklAngAll->GetYaxis())->SetTitle("'F# of tracklets");
1128  ((TAxis *)mFTrackAngAll->GetXaxis())->SetTitle("angle of track endings");
1129  ((TAxis *)mFTrackAngAll->GetYaxis())->SetTitle("'F# of track endings");
1130  ((TAxis *)mFCircleDistAll->GetXaxis())->SetTitle("circle distance to track");
1131  ((TAxis *)mFCircleDistAll->GetYaxis())->SetTitle("'F# of track endings");
1132  ((TAxis *)mFLengthDistAll->GetXaxis())->SetTitle("length distance to track");
1133  ((TAxis *)mFLengthDistAll->GetYaxis())->SetTitle("'F# of track endings");
1134 
1135  ((TAxis *)mFTrackAng->GetXaxis())->SetTitle("angle of track endings");
1136  ((TAxis *)mFTrackAng->GetYaxis())->SetTitle("'F# of last point");
1137  ((TAxis *)mFTrackAng->GetZaxis())->SetTitle("'F# of track endings");
1138  ((TAxis *)mFCircleDist->GetXaxis())->SetTitle("circle distance to track");
1139  ((TAxis *)mFCircleDist->GetYaxis())->SetTitle("'F# of last point");
1140  ((TAxis *)mFCircleDist->GetZaxis())->SetTitle("'F# of track endings");
1141  ((TAxis *)mFLengthDist->GetXaxis())->SetTitle("length distance to track");
1142  ((TAxis *)mFLengthDist->GetYaxis())->SetTitle("'F# of last point");
1143  ((TAxis *)mFLengthDist->GetZaxis())->SetTitle("'F# of track endings");
1144 
1145  ((TAxis *)mFCircleLength->GetXaxis())->SetTitle("length distance");
1146  ((TAxis *)mFCircleLength->GetYaxis())->SetTitle("circle distance");
1147  ((TAxis *)mFCircleLength->GetZaxis())->SetTitle("'F# of track endings");
1148 
1149  ((TAxis *)mPRatioDist->GetXaxis())->SetTitle("distance [cm]");
1150  ((TAxis *)mPRatioDist->GetYaxis())->SetTitle("(p1 + p2) / (p1max + p2max)");
1151  ((TAxis *)mPRatioDist->GetZaxis())->SetTitle("'F# of pairs");
1152  ((TAxis *)mPRatioDistSplit->GetXaxis())->SetTitle("distance [GeV]");
1153  ((TAxis *)mPRatioDistSplit->GetYaxis())->SetTitle("(p1 + p2) / (p1max + p2max)");
1154  ((TAxis *)mPRatioDistSplit->GetZaxis())->SetTitle("'F# of pairs");
1155 
1156  ((TAxis *)mEtaNghits->GetXaxis())->SetTitle("'F# of geant clusters");
1157  ((TAxis *)mEtaNghits->GetYaxis())->SetTitle("`h#");
1158  ((TAxis *)mEtaNfhits->GetXaxis())->SetTitle("'F# of found clusters");
1159  ((TAxis *)mEtaNfhits->GetYaxis())->SetTitle("`h#");
1160 
1161  ((TAxis *)mPtEtaF->GetXaxis())->SetTitle("`h# (of parent)");
1162  ((TAxis *)mPtEtaF->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1163  ((TAxis *)mPtEtaF->GetZaxis())->SetTitle("'F# of tracks");
1164 
1165  ((TAxis *)mPtEtaFMes->GetXaxis())->SetTitle("`h# (measured)");
1166  ((TAxis *)mPtEtaFMes->GetYaxis())->SetTitle("p?'c#! [GeV] (measured)");
1167  ((TAxis *)mPtEtaFMes->GetZaxis())->SetTitle("'F# of tracks");
1168 
1169  ((TAxis *)mPtEtaGood->GetXaxis())->SetTitle("`h# (of parent)");
1170  ((TAxis *)mPtEtaGood->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1171  ((TAxis *)mPtEtaGood->GetZaxis())->SetTitle("'F# of tracks");
1172  ((TAxis *)mPtEtaBad->GetXaxis())->SetTitle("`h# (of parent)");
1173  ((TAxis *)mPtEtaBad->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1174  ((TAxis *)mPtEtaBad->GetZaxis())->SetTitle("'F# of tracks");
1175  ((TAxis *)mPtEtaUnclean->GetXaxis())->SetTitle("`h# (of parent)");
1176  ((TAxis *)mPtEtaUnclean->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1177  ((TAxis *)mPtEtaUnclean->GetZaxis())->SetTitle("'F# of tracks");
1178  ((TAxis *)mPtEtaMesUnclean->GetXaxis())->SetTitle("`h# (of parent)");
1179  ((TAxis *)mPtEtaMesUnclean->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1180  ((TAxis *)mPtEtaMesUnclean->GetZaxis())->SetTitle("'F# of tracks");
1181  ((TAxis *)mPtEtaUncleanGood->GetXaxis())->SetTitle("`h# (of parent)");
1182  ((TAxis *)mPtEtaUncleanGood->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1183  ((TAxis *)mPtEtaUncleanGood->GetZaxis())->SetTitle("'F# of tracks");
1184  ((TAxis *)mPtEtaMesUncleanGood->GetXaxis())->SetTitle("`h# (of parent)");
1185  ((TAxis *)mPtEtaMesUncleanGood->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1186  ((TAxis *)mPtEtaMesUncleanGood->GetZaxis())->SetTitle("'F# of tracks");
1187 
1188  ((TAxis *)mPtEtaSplit->GetXaxis())->SetTitle("`h# (of parent)");
1189  ((TAxis *)mPtEtaSplit->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1190  ((TAxis *)mPtEtaSplit->GetZaxis())->SetTitle("'F# of tracks");
1191  ((TAxis *)mPtEtaSplitGood->GetXaxis())->SetTitle("`h# (of parent)");
1192  ((TAxis *)mPtEtaSplitGood->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1193  ((TAxis *)mPtEtaSplitGood->GetZaxis())->SetTitle("'F# of tracks");
1194  ((TAxis *)mPtEtaSplitLoliGood->GetXaxis())->SetTitle("`h# (of parent)");
1195  ((TAxis *)mPtEtaSplitLoliGood->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1196  ((TAxis *)mPtEtaSplitLoliGood->GetZaxis())->SetTitle("'F# of tracks");
1197 
1198  ((TAxis *)mPtEtaFVtx->GetXaxis())->SetTitle("`h# (of parent)");
1199  ((TAxis *)mPtEtaFVtx->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1200  ((TAxis *)mPtEtaFVtx->GetZaxis())->SetTitle("'F# of tracks");
1201  ((TAxis *)mPtEtaLookLikeGood->GetXaxis())->SetTitle("`h# (of parent)");
1202  ((TAxis *)mPtEtaLookLikeGood->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1203  ((TAxis *)mPtEtaLookLikeGood->GetZaxis())->SetTitle("'F# of tracks");
1204  ((TAxis *)mPtEtaContamination->GetXaxis())->SetTitle("`h# (of parent)");
1205  ((TAxis *)mPtEtaContamination->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1206  ((TAxis *)mPtEtaContamination->GetZaxis())->SetTitle("'F# of tracks");
1207  ((TAxis *)mPtEtaContaWoSplits->GetXaxis())->SetTitle("`h# (of parent)");
1208  ((TAxis *)mPtEtaContaWoSplits->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1209  ((TAxis *)mPtEtaContaWoSplits->GetZaxis())->SetTitle("'F# of tracks");
1210 
1211  ((TAxis *)mPtEta10PointTracks->GetXaxis())->SetTitle("`h# (of parent)");
1212  ((TAxis *)mPtEta10PointTracks->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1213  ((TAxis *)mPtEta10PointTracks->GetZaxis())->SetTitle("'F# of tracks");
1214  ((TAxis *)mPtEtaWrongCharge->GetXaxis())->SetTitle("`h# (of parent)");
1215  ((TAxis *)mPtEtaWrongCharge->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1216  ((TAxis *)mPtEtaWrongCharge->GetZaxis())->SetTitle("'F# of tracks");
1217  ((TAxis *)mPtEtaWrongPosCharge->GetXaxis())->SetTitle("`h# (of parent)");
1218  ((TAxis *)mPtEtaWrongPosCharge->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1219  ((TAxis *)mPtEtaWrongPosCharge->GetZaxis())->SetTitle("'F# of tracks");
1220 
1221  ((TAxis *)mPtEtaGoodG->GetXaxis())->SetTitle("`h# (of parent)");
1222  ((TAxis *)mPtEtaGoodG->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1223  ((TAxis *)mPtEtaGoodG->GetZaxis())->SetTitle("'F# of tracks");
1224  ((TAxis *)mPtEtaGoodF->GetXaxis())->SetTitle("`h# (of parent)");
1225  ((TAxis *)mPtEtaGoodF->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1226  ((TAxis *)mPtEtaGoodF->GetZaxis())->SetTitle("'F# of tracks");
1227  ((TAxis *)mPtEtaGoodRatio->GetXaxis())->SetTitle("`h# (of parent)");
1228  ((TAxis *)mPtEtaGoodRatio->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1229  ((TAxis *)mPtEtaGoodRatio->GetZaxis())->SetTitle("ratio");
1230  ((TAxis *)mPtEtaBadG->GetXaxis())->SetTitle("`h# (of parent)");
1231  ((TAxis *)mPtEtaBadG->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1232  ((TAxis *)mPtEtaBadG->GetZaxis())->SetTitle("'F# of tracks");
1233  ((TAxis *)mPtEtaBadF->GetXaxis())->SetTitle("`h# (of parent)");
1234  ((TAxis *)mPtEtaBadF->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1235  ((TAxis *)mPtEtaBadF->GetZaxis())->SetTitle("'F# of tracks");
1236  ((TAxis *)mPtEtaBadRatio->GetXaxis())->SetTitle("`h# (of parent)");
1237  ((TAxis *)mPtEtaBadRatio->GetYaxis())->SetTitle("p?'c#! [GeV] (of parent)");
1238  ((TAxis *)mPtEtaBadRatio->GetZaxis())->SetTitle("ratio");
1239 
1240  ((TAxis *)mGLengthDistTrackAng->GetXaxis())->SetTitle("angle of track endings");
1241  ((TAxis *)mGLengthDistTrackAng->GetYaxis())->SetTitle("length dist. of last point");
1242  ((TAxis *)mGLengthDistTrackAng->GetZaxis())->SetTitle("'F# of track endings");
1243  ((TAxis *)mFLengthDistTrackAng->GetXaxis())->SetTitle("angle of track endings");
1244  ((TAxis *)mFLengthDistTrackAng->GetYaxis())->SetTitle("length dist. of last point");
1245  ((TAxis *)mFLengthDistTrackAng->GetZaxis())->SetTitle("'F# of track endings");
1246  ((TAxis *)mGCircleDistTrackAng->GetXaxis())->SetTitle("angle of track endings");
1247  ((TAxis *)mGCircleDistTrackAng->GetYaxis())->SetTitle("circle dist. of last point");
1248  ((TAxis *)mGCircleDistTrackAng->GetZaxis())->SetTitle("'F# of track endings");
1249  ((TAxis *)mFCircleDistTrackAng->GetXaxis())->SetTitle("angle of track endings");
1250  ((TAxis *)mFCircleDistTrackAng->GetYaxis())->SetTitle("circle dist. of last point");
1251  ((TAxis *)mFCircleDistTrackAng->GetZaxis())->SetTitle("'F# of track endings");
1252  ((TAxis *)mSetupTime->GetXaxis())->SetTitle("Zeit [s]");
1253  ((TAxis *)mSetupTime->GetYaxis())->SetTitle("Ereignisse");
1254  ((TAxis *)mTrackingTime->GetXaxis())->SetTitle("Zeit [s]");
1255  ((TAxis *)mTrackingTime->GetYaxis())->SetTitle("Ereignisse");
1256  ((TAxis *)mExtensionTime->GetXaxis())->SetTitle("Zeit [s]");
1257  ((TAxis *)mExtensionTime->GetYaxis())->SetTitle("Ereignisse");
1258  ((TAxis *)mSplitTime->GetXaxis())->SetTitle("Zeit [s]");
1259  ((TAxis *)mSplitTime->GetYaxis())->SetTitle("Ereignisse");
1260  ((TAxis *)mFitTime->GetXaxis())->SetTitle("Zeit [s]");
1261  ((TAxis *)mFitTime->GetYaxis())->SetTitle("Ereignisse");
1262  ((TAxis *)mTotalTime->GetXaxis())->SetTitle("Zeit [s]");
1263  ((TAxis *)mTotalTime->GetYaxis())->SetTitle("Ereignisse");
1264 
1265  return;
1266 }
1267 
1268 
1269 void StFtpcTrackEvaluator::GeantHitInit(St_g2t_ftp_hit *g2t_ftp_hit)
1270 {
1271  // Initializes Geant hits.
1272 
1273  if(g2t_ftp_hit) {
1274 
1275  Int_t NumGeantHits = g2t_ftp_hit->GetNRows(); // number of generated clusters
1276  g2t_ftp_hit_st *point_st = g2t_ftp_hit->GetTable(); // pointer to generated clusters
1277 
1278  mGeantHits = new TObjArray(NumGeantHits); // create TObjArray
1279 
1280  // Loop ovver all generated clusters
1281  {for (Int_t i = 0; i < NumGeantHits; i++, point_st++) {
1282  mGeantHits->AddAt(new StFtpcConfMapPoint(), i); // create StFtpcConfMapPoint
1283  ((StFtpcConfMapPoint *)mGeantHits->At(i))->SetHitNumber(i);
1284  ((StFtpcConfMapPoint *)mGeantHits->At(i))->SetNextHitNumber(point_st->next_tr_hit_p-1);
1285  ((StFtpcConfMapPoint *)mGeantHits->At(i))->SetX(point_st->x[0]);
1286  ((StFtpcConfMapPoint *)mGeantHits->At(i))->SetY(point_st->x[1]);
1287  ((StFtpcConfMapPoint *)mGeantHits->At(i))->SetZ(point_st->x[2]);
1288  ((StFtpcConfMapPoint *)mGeantHits->At(i))->Setup(mVertex);
1289  }}
1290  }
1291 }
1292 
1293 
1294 void StFtpcTrackEvaluator::GeantTrackInit(St_g2t_track *g2t_track, St_g2t_ftp_hit *g2t_ftp_hit)
1295 {
1296  // Initializes Geant tracks. Therefore the Geant hits are needed as well.
1297  if (g2t_track) {
1298 
1299  Int_t NumGeantTracks = g2t_track->GetNRows(); // number of generated tracks
1300  g2t_track_st *track_st = g2t_track->GetTable(); // pointer to generated tracks
1301  mGeantTracks = new TObjArray(NumGeantTracks); // create TObjArray
1302 
1303  Int_t NumFtpcGeantTracks = 0;
1304  Int_t ftpc_hits = 0;
1305 
1306  mFtpcTrackNum->SetFill(NumGeantTracks, -1);
1307 
1308  // Loop over all generated tracks
1309  {for (Int_t i = 0; i < NumGeantTracks; i++, track_st++) {
1310  ftpc_hits = track_st->n_ftp_hit;
1311 
1312  if (ftpc_hits) { // track has hits in Ftpc
1313 
1314  mGHitsOnTrack->Fill(ftpc_hits);
1315  mGeantTracks->AddAt(new StFtpcTrack(NumFtpcGeantTracks), NumFtpcGeantTracks); // create StFtpcTrack
1316  StFtpcTrack *t = (StFtpcTrack*)mGeantTracks->At(NumFtpcGeantTracks);
1317  TObjArray *points = t->GetHits();
1318 
1319  // set momentum
1320  t->SetPx(track_st->p[0]);
1321  t->SetPy(track_st->p[1]);
1322  t->SetPz(track_st->p[2]);
1323 
1324  // set charge and pid
1325  t->SetCharge((Int_t)track_st->charge);
1326  t->SetPid(track_st->ge_pid);
1327  // if (t->GetPid() <= 3) {
1328  // mElectronTracks++;
1329  // }
1330 
1331  // set main vertex
1332  if (track_st->start_vertex_p == 1) {
1333  t->ComesFromMainVertex((Bool_t) kTRUE);
1334  }
1335 
1336  else {
1337  // mNonVertexTracks++;
1338  t->ComesFromMainVertex((Bool_t) kFALSE);
1339  }
1340 
1341  MIntArray *hitnumber = t->GetHitNumbers();
1342  hitnumber->Set(ftpc_hits);
1343  ((StFtpcConfMapPoint *)mGeantHits->At(track_st->hit_ftp_p - 1))->SetTrackNumber(NumFtpcGeantTracks);
1344  mFtpcTrackNum->AddAt(NumFtpcGeantTracks, i);
1345  points->Expand(ftpc_hits);
1346  points->AddAt(mGeantHits->At(track_st->hit_ftp_p - 1), 0);
1347  hitnumber->AddAt(track_st->hit_ftp_p - 1, 0);
1348 
1349  // Loop over all hits in Ftpc
1350  {for(Int_t j = 1; j < ftpc_hits; j++) {
1351  Int_t number = ((StFtpcConfMapPoint *)mGeantHits->At(hitnumber->At(j-1)))->GetNextHitNumber();
1352  ((StFtpcConfMapPoint *)mGeantHits->At(number))->SetTrackNumber(NumFtpcGeantTracks);
1353  points->AddAt(mGeantHits->At(number), j);
1354  hitnumber->AddAt(number, j);
1355  }}
1356 
1357  t->CalculateNMax();
1358  NumFtpcGeantTracks++;
1359 
1360  if (ftpc_hits>StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide()) {
1361  mLongTracks++;
1362  mLongTrackClusters += ftpc_hits;
1363 
1364  if (ftpc_hits > mMaxClusters) {
1365  mMaxClusters = ftpc_hits;
1366  }
1367  }
1368 
1369  if (ftpc_hits<5) {
1370  mShortTracks++;
1371  mShortTrackClusters += ftpc_hits;
1372  }
1373 
1374  else {
1375 
1376  if (IsGoodTrack(t)) {
1377 
1378  if (ftpc_hits == StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide()) {
1379  mPtEta10PointTracks->Fill(TMath::Abs(t->GetEta()), t->GetPt());
1380  }
1381 
1382  mGoodGTracks++;
1383  mGoodGeantPoints += ftpc_hits;
1384  }
1385  }
1386  }
1387  }}
1388  }
1389 }
1390 
1391 
1392 void StFtpcTrackEvaluator::FastSimHitInit(St_ffs_gepoint *ffs_hit)
1393 {
1394  // Initializes fast simulated hits.
1395  if(ffs_hit) {
1396 
1397  Int_t NumFastSimHits = ffs_hit->GetNRows(); // number of generated clusters
1398  mClusterArr->SetFill(NumFastSimHits, 0);
1399  mGoodFastSimHitsArr->SetFill(NumFastSimHits, -1); // goodness of points set to 'undefined'
1400  ffs_gepoint_st *point_st = ffs_hit->GetTable(); // pointer to fast simulated clusters
1401  mFastSimHits = new TObjArray(NumFastSimHits); // create TObjArray
1402 
1403  // Loop ovver all generated clusters
1404  {for (Int_t i = 0; i < NumFastSimHits; i++, point_st++) {
1405  mFastSimHits->AddAt(new StFtpcPoint(), i); // create StFtpcPoint
1406  StFtpcPoint *p = (StFtpcPoint*)mFastSimHits->At(i);
1407  p->SetHitNumber(i);
1408  p->SetTrackNumber(mFtpcTrackNum->At(point_st->ge_track_p - 1));
1409 
1410  // evaluate goodness of points, fill array with results
1411  if (IsGoodTrack((StFtpcTrack*)mGeantTracks->At(p->GetTrackNumber()))) {
1412  mGoodFastSimHitsArr->AddAt(1, i);
1413  }
1414 
1415  else {
1416  mGoodFastSimHitsArr->AddAt(0, i);
1417  }
1418  }}
1419  }
1420 }
1421 
1422 
1423 void StFtpcTrackEvaluator::ParentTrackInit()
1424 {
1425  // Initializes the parents of all tracks.
1426 
1427  mParent->Set(mFoundTracks->GetEntriesFast());
1428  mNumParentTracks->SetFill(mFoundTracks->GetEntriesFast()*StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(), -1);
1429 
1430  Int_t actual_track = -1;
1431 
1432  // loop over tracks
1433  for (Int_t t_counter = 0; t_counter < mFoundTracks->GetEntriesFast(); t_counter++) {
1434  StFtpcTrack *track = (StFtpcTrack*)mFoundTracks->At(t_counter);
1435  TObjArray *hits = (TObjArray*) track->GetHits();
1436  mUnclean[t_counter] = (Bool_t)kFALSE;
1437 
1438  if (track->ComesFromMainVertex()) {
1439  mFoundVertexTracks++;
1440  }
1441 
1442  else {
1443  mFoundNonVertexTracks++;
1444  }
1445 
1446  Int_t max_hits = hits->GetEntriesFast();
1447 
1448  for (Int_t h_counter = 0; h_counter < StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(); h_counter++) {
1449 
1450  if (h_counter < max_hits) {
1451  StFtpcPoint *hit = (StFtpcPoint *)hits->At(h_counter);
1452  mParentTrack->AddLast(((StFtpcPoint*)mFastSimHits->At(hit->GetHitNumber()))->GetTrackNumber());
1453  mParentTracks->AddLast(mParentTrack->AtLast());
1454  }
1455 
1456  else {
1457  mParentTrack->AddLast(-1);
1458  mParentTracks->AddLast(-1);
1459  }
1460  }
1461 
1462  for (Int_t cluster1 = 0; cluster1 < max_hits; cluster1++) {
1463 
1464  if (mParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster1) != -1) {
1465  mNumParentTracks->AddAt(1, t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster1);
1466 
1467  for (Int_t cluster2 = cluster1+1; cluster2 < max_hits; cluster2++) {
1468 
1469  if (mParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster2) != -1) {
1470 
1471  if (mParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster1) == mParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster2)) {
1472  mParentTracks->AddAt(-1, t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster2);
1473  mNumParentTracks->AddAt(mNumParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster1) + 1, t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster1);
1474  }
1475 
1476  else { // different parent tracks found
1477  if (actual_track != t_counter) {
1478  mUncleanTracksArr->AddLast(t_counter);
1479  mUncleanTracks++;
1480  mUnclean[t_counter] = (Bool_t)kTRUE;
1481  mPtEtaMesUnclean->Fill(TMath::Abs(((StFtpcTrack *)mFoundTracks->At(t_counter))->GetEta()), ((StFtpcTrack *)mFoundTracks->At(t_counter))->GetPt());
1482  actual_track = t_counter;
1483  }
1484  }
1485  }
1486  }
1487  }
1488  }
1489 
1490  // Evaluate the most likely parent for this track.
1491  Int_t max = 0;
1492 
1493  for (Int_t cluster = 0; cluster < StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(); cluster++) {
1494 
1495  if (mNumParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster) >= max) {
1496  max = mNumParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster);
1497  mParent->AddAt(mParentTrack->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + cluster), t_counter);
1498  }
1499  }
1500 
1501  EvaluateGoodness(t_counter);
1502  }
1503 
1504  return;
1505 }
1506 
1507 
1508 void StFtpcTrackEvaluator::EvaluateGoodness(Int_t t_counter)
1509 {
1510  // Evaluates if the parent track of the found track no. t_counter is a good track or not.
1511 
1512  StFtpcTrack *track = (StFtpcTrack *)mFoundTracks->At(t_counter);
1513  StFtpcTrack *parent = (StFtpcTrack *)mGeantTracks->At(mParent->At(t_counter));
1514  mPtEtaF->Fill(TMath::Abs(parent->GetPseudoRapidity()), parent->GetPt());
1515  mPtEtaFMes->Fill(TMath::Abs(track->GetPseudoRapidity()), track->GetPt());
1516 
1517  TObjArray *points = track->GetHits();
1518 
1519  Int_t wrong_hits_on_this_track = 0;
1520 
1521  {for (Int_t i=0; i<points->GetEntriesFast(); i++) {
1522  StFtpcPoint *p = (StFtpcPoint *)points->At(i);
1523 
1524  if (mParentTrack->At(t_counter*StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide()+i) == mParent->At(t_counter)) {
1525  mClusterArr->AddAt(1, p->GetHitNumber());
1526 
1527  if (i == points->GetEntriesFast()-1) {
1528  // last point on track was picked up wrong
1529 
1530  StFtpcConfMapper c;
1531 
1532  Double_t chi2_1[6];
1533  Double_t chi2_2[6];
1534 
1535  c.StraightLineFit(track, chi2_1, i);
1536  c.StraightLineFit(track, chi2_2, i-1);
1537 
1538  //LOG_INFO << " " << chi2_1[4] << " " << chi2_2[4] << " " << chi2_1[4] - chi2_2[4] << endm;
1539  //LOG_INFO << " " << chi2_1[5] << " " << chi2_2[5] << " " << chi2_1[5] - chi2_2[5] << endm << endm;
1540  }
1541  }
1542 
1543  else {
1544  mClusterArr->AddAt(-1, p->GetHitNumber());
1545  wrong_hits_on_this_track++;
1546 
1547  if (i == points->GetEntriesFast()-1) {
1548  // last point on track was picked up wrong
1549 
1550  StFtpcConfMapper c;
1551 
1552  Double_t chi2_1[6];
1553  Double_t chi2_2[6];
1554 
1555  c.StraightLineFit(track, chi2_1, i);
1556  c.StraightLineFit(track, chi2_2, i-1);
1557 
1558  //LOG_INFO << "u" << chi2_1[4] << " " << chi2_2[4] << " " << chi2_1[4] - chi2_2[4] << endm;
1559  //LOG_INFO << "u" << chi2_1[5] << " " << chi2_2[5] << " " << chi2_1[5] - chi2_2[5] << endm << endm;
1560  }
1561 
1562  }
1563  }}
1564 
1565  if (IsUncleanTrack(t_counter)) {
1566  mPtEtaUnclean->Fill(TMath::Abs(((StFtpcTrack *)mGeantTracks->At(mParent->At(t_counter)))->GetEta()), ((StFtpcTrack *)mGeantTracks->At(mParent->At(t_counter)))->GetPt());
1567 
1568  if (IsGoodTrack(parent) && track->ComesFromMainVertex()) {
1569  mGoodFoundPoints += (track->GetNumberOfPoints() - wrong_hits_on_this_track);
1570  mPtEtaUncleanGood->Fill(TMath::Abs(((StFtpcTrack *)mGeantTracks->At(mParent->At(t_counter)))->GetEta()), ((StFtpcTrack *)mGeantTracks->At(mParent->At(t_counter)))->GetPt());
1571  mPtEtaMesUncleanGood->Fill(TMath::Abs(track->GetEta()), track->GetPt());
1572  mUncleanGoodTracks++;
1573  }
1574  }
1575 
1576  if (IsGoodTrack(parent) && IsCleanTrack(t_counter) && track->ComesFromMainVertex()) {
1577  mGoodFTracks++;
1578  mGoodFoundPoints += track->GetNumberOfPoints();
1579  mPtEtaGoodF->Fill(TMath::Abs(parent->GetPseudoRapidity()), parent->GetPt());
1580  }
1581 
1582  else {
1583  mPtEtaBadF->Fill(TMath::Abs(parent->GetPseudoRapidity()), parent->GetPt());
1584 
1585  if (parent->GetPid() <= 3) {
1586  mElectronTracks++;
1587  }
1588 
1589  if(!(parent->ComesFromMainVertex())) {
1590  mNonVertexTracks++;
1591  }
1592  }
1593 
1594  if (track->ComesFromMainVertex()) {
1595  mPtEtaFVtx->Fill(TMath::Abs(parent->GetPseudoRapidity()), parent->GetPt());
1596 
1597  if ((IsUncleanTrack(t_counter) || (IsCleanTrack(t_counter) && (!IsGoodTrack(parent))))) {
1598  mPtEtaLookLikeGood->Fill(TMath::Abs(parent->GetPseudoRapidity()), parent->GetPt());
1599  mLookLikeGoodTracks++;
1600  }
1601  }
1602 
1603  return;
1604 }
1605 
1606 
1607 void StFtpcTrackEvaluator::DivideHistos()
1608 {
1609  // Divides Histograms to get the efficiency.
1610  // These hostograms contain always the last event only!
1611 
1612  mPtEtaGood->Divide(mPtEtaGoodF, mPtEtaF);
1613  mPtEtaBad->Divide(mPtEtaBadF, mPtEtaF);
1614  mPtEtaGoodRatio->Divide(mPtEtaGoodF, mPtEtaGoodG);
1615  mPtEtaBadRatio->Divide(mPtEtaBadF, mPtEtaBadG);
1616  mPtEtaContamination->Divide(mPtEtaLookLikeGood, mPtEtaFVtx);
1617  // Splits have to be substracted, still. They are available in PtEta up to now but mPtEtaLookLikeGood would be overwritten.
1618  // mPtEtaContaWoSplits->Divide(mPtEtaLookLikeGood->Add(mPtEtaSplitLoliGood, -1), mPtEtaFVtx);
1619 
1620  return;
1621 }
1622 
1623 
1624 void StFtpcTrackEvaluator::FillGCutHistos()
1625 {
1626  // Evaluates the cuts by looking into the distibution od the cut-variables in GEANT tracks.
1627 
1628  StFtpcConfMapper t;
1629  Double_t coeff[6];
1630 
1631  for (Int_t t_counter = 0; t_counter < mGeantTracks->GetEntriesFast(); t_counter++) {
1632  StFtpcTrack *track = (StFtpcTrack*) mGeantTracks->At(t_counter);
1633  TObjArray *hits = (TObjArray*) track->GetHits();
1634 
1635  if (IsGoodMainVertexTrack(track)) {
1636  mDcaGMainVertex->Fill(track->CalcDca(mVertex, 0));
1637  }
1638 
1639  if (IsGoodNonVertexTrack(track)) {
1640  mDcaGNonVertex->Fill(track->CalcDca(mVertex, 0));
1641  }
1642 
1643  if (IsGoodTrack(track)) {
1644 
1645  mEtaNghits->Fill(hits->GetEntriesFast(), TMath::Abs(track->GetPseudoRapidity()));
1646  mPtEtaGoodG->Fill(TMath::Abs(track->GetPseudoRapidity()), track->GetPt());
1647 
1648  for (Int_t h_counter = 2; h_counter < hits->GetEntriesFast() && h_counter < StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(); h_counter++) {
1649 
1650  StFtpcConfMapPoint *hit = (StFtpcConfMapPoint *)hits->At(h_counter);
1651 
1652  if (h_counter == 2) {
1653  mGTracklAngAll->Fill(t.StFtpcConfMapper::TrackletAngle(track, h_counter+1));
1654  mGTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter+1), (Float_t)h_counter+1);
1655  }
1656 
1657  else {
1658  mGTrackAngAll->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter+1));
1659  mGTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter+1), (Float_t)h_counter+1);
1660 
1661  t.StraightLineFit(track, coeff, h_counter-1);
1662  hit->SetDist(t.CalcDistance(hit, coeff+0), t.CalcDistance(hit, coeff+2));
1663 
1664  mGLengthDistTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter+1), (Float_t)hit->GetLengthDist());
1665  mGCircleDistTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter+1), (Float_t)hit->GetCircleDist());
1666 
1667  mGCircleDistAll->Fill(hit->GetCircleDist());
1668  mGLengthDistAll->Fill(hit->GetLengthDist());
1669  mGCircleDist->Fill((Float_t)hit->GetCircleDist(),(Float_t)h_counter+1);
1670  mGLengthDist->Fill((Float_t)hit->GetLengthDist(), (Float_t)h_counter+1);
1671  mGCircleLength->Fill((Float_t)hit->GetLengthDist(), (Float_t)hit->GetCircleDist());
1672  }
1673  }
1674  }
1675 
1676  else {
1677  mPtEtaBadG->Fill(TMath::Abs(track->GetPseudoRapidity()), track->GetPt());
1678  }
1679  }
1680 
1681  return;
1682 }
1683 
1684 
1685 void StFtpcTrackEvaluator::FillFCutHistos()
1686 {
1687  // Fills cut histograms for found tracks.
1688 
1689  StFtpcConfMapper t;
1690  Double_t coeff[6];
1691 
1692  for (Int_t t_counter = 0; t_counter < mFoundTracks->GetEntriesFast(); t_counter++) {
1693  StFtpcTrack *track = (StFtpcTrack*) mFoundTracks->At(t_counter);
1694  TObjArray *hits = (TObjArray*) track->GetHits();
1695 
1696  // evaluate if the track could be longer
1697  if (track->GetNumberOfPoints() < track->GetNMax()) {
1698  mTooShortTracks++;
1699  }
1700 
1701  if (hits->GetEntriesFast() >= 3) {
1702 
1703  mEtaNfhits->Fill(hits->GetEntriesFast(), TMath::Abs(track->GetPseudoRapidity()));
1704 
1705  for (Int_t h_counter = 3; h_counter < hits->GetEntriesFast(); h_counter++) {
1706 
1707  StFtpcConfMapPoint *hit = (StFtpcConfMapPoint *)hits->At(h_counter);
1708 
1709  if (h_counter == 3) {
1710  mFTracklAngAll->Fill(t.StFtpcConfMapper::TrackletAngle(track, h_counter));
1711  mFTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter), (Float_t)h_counter);
1712  }
1713 
1714  else {
1715  mFTrackAngAll->Fill(t.StFtpcConfMapper::TrackletAngle(track, h_counter));
1716  mFTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter), (Float_t)h_counter);
1717 
1718  t.StraightLineFit(track, coeff, h_counter-1);
1719  hit->SetDist(t.CalcDistance(hit, coeff+0), t.CalcDistance(hit, coeff+2));
1720 
1721  mFLengthDistTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter+1), (Float_t)hit->GetLengthDist());
1722  mFCircleDistTrackAng->Fill((Float_t)t.StFtpcConfMapper::TrackletAngle(track, h_counter+1), (Float_t)hit->GetCircleDist());
1723 
1724  mFCircleDistAll->Fill(hit->GetCircleDist());
1725  mFLengthDistAll->Fill(hit->GetLengthDist());
1726  mFCircleDist->Fill((Float_t)hit->GetCircleDist(), (Float_t)h_counter);
1727  mFLengthDist->Fill((Float_t)hit->GetLengthDist(), (Float_t)h_counter);
1728  mFCircleLength->Fill((Float_t)hit->GetLengthDist(), (Float_t)hit->GetCircleDist());
1729  }
1730  }
1731  }
1732  }
1733 
1734  return;
1735 }
1736 
1737 
1738 void StFtpcTrackEvaluator::Loop()
1739 {
1740  // Usual used loop to loop over tracks and clusters.
1741  // This is just an example to make it easier to develop new routines.
1742 
1743  for (Int_t t_counter = 0; t_counter < mFoundTracks->GetEntriesFast(); t_counter++) {
1744  StFtpcTrack *track = (StFtpcTrack*) mFoundTracks->At(t_counter);
1745  TObjArray *fhits = (TObjArray*) track->GetHits();
1746 
1747  for (Int_t h_counter = 0; h_counter < fhits->GetEntriesFast(); h_counter++) {
1748 
1749 
1750  //StFtpcPoint *hit = (StFtpcPoint *) fhits->At(h_counter);
1751 
1752  }
1753  }
1754 }
1755 
1756 
1757 void StFtpcTrackEvaluator::WriteHistos()
1758 {
1759  // Writes histograms to file.
1760 
1761  mFile->cd();
1762  mFile->Delete("*;1");
1763 
1764  mNumGeantHits->Write();
1765  mNumFoundHits->Write();
1766  mNumGeantTracks->Write();
1767  mNumFoundTracks->Write();
1768 
1769  mNumFoundVertexTracks->Write();
1770  mNumFoundNonVertexTracks->Write();
1771 
1772  mNumLookLikeGoodTracks->Write();
1773  mNumElectronTracks->Write();
1774  mNumNonVertexTracks->Write();
1775  mNumGoodGTracks->Write();
1776  mNumGoodFTracks->Write();
1777  mGoodRatio->Write();
1778  mContamination->Write();
1779  mContaWoSplit->Write();
1780  mNumSplitTracks->Write();
1781  mNumSplitGoodTracks->Write();
1782  mNumSplitLoliGoodTracks->Write();
1783  mNumUncleanTracks->Write();
1784  mNumUncleanGoodTracks->Write();
1785  mNumLongTracks->Write();
1786  mNumLongTrackClusters->Write();
1787  mNumShortTracks->Write();
1788  mNumShortTrackClusters->Write();
1789  mNumTooShortTracks->Write();
1790 
1791  mGHitsOnTrack->Write();
1792  mFHitsOnTrack->Write();
1793 
1794  mNumGoodGeantPoints->Write();
1795  mNumGoodFoundPoints->Write();
1796  mGoodPointRatio->Write();
1797 
1798  mNumParents->Write();
1799  mNumWrongHits->Write();
1800  mNumWrongHitsAll->Write();
1801 
1802  mPtot->Write();
1803  mPt->Write();
1804  mPx->Write();
1805  mPy->Write();
1806  mPz->Write();
1807 
1808  mPtotDiff->Write();
1809  mPtDiff->Write();
1810  mPxDiff->Write();
1811  mPyDiff->Write();
1812  mPzDiff->Write();
1813 
1814  mPtotAcc->Write();
1815  mPtAcc->Write();
1816  mPxAcc->Write();
1817  mPyAcc->Write();
1818  mPzAcc->Write();
1819 
1820  mPRelErr->Write();
1821  mPRelErrqok->Write();
1822  mPRelDiff->Write();
1823 
1824  mEtaNghits->Write();
1825  mEtaNfhits->Write();
1826 
1827  mPtEtaF->Write();
1828  mPtEtaFMes->Write();
1829  mPtEtaGood->Write();
1830  mPtEtaBad->Write();
1831  mPtEtaUnclean->Write();
1832  mPtEtaMesUnclean->Write();
1833  mPtEtaUncleanGood->Write();
1834  mPtEtaMesUncleanGood->Write();
1835 
1836  mPtEtaSplit->Write();
1837  mPtEtaSplitGood->Write();
1838  mPtEtaSplitLoliGood->Write();
1839 
1840  mPtEtaGoodG->Write();
1841  mPtEtaGoodF->Write();
1842  mPtEtaGoodRatio->Write();
1843  mPtEtaBadG->Write();
1844  mPtEtaBadF->Write();
1845  mPtEtaBadRatio->Write();
1846 
1847  mPtEtaFVtx->Write();
1848  mPtEtaLookLikeGood->Write();
1849  mPtEtaContamination->Write();
1850  mPtEtaContaWoSplits->Write();
1851 
1852  mPtEta10PointTracks->Write();
1853  mPtEtaWrongCharge->Write();
1854  mPtEtaWrongPosCharge->Write();
1855 
1856  mDcaFMainVertex->Write();
1857  mDcaFNonVertex->Write();
1858  mDcaGMainVertex->Write();
1859  mDcaGNonVertex->Write();
1860 
1861  mGLengthDistTrackAng->Write();
1862  mGCircleDistTrackAng->Write();
1863  mFLengthDistTrackAng->Write();
1864  mFCircleDistTrackAng->Write();
1865 
1866  mGTracklAngAll->Write();
1867  mGTrackAngAll->Write();
1868  mGCircleDistAll->Write();
1869  mGLengthDistAll->Write();
1870 
1871  mGTrackAng->Write();
1872  mGCircleDist->Write();
1873  mGLengthDist->Write();
1874 
1875  mGCircleLength->Write();
1876 
1877  mFTracklAngAll->Write();
1878  mFTrackAngAll->Write();
1879  mFCircleDistAll->Write();
1880  mFLengthDistAll->Write();
1881 
1882  mFTrackAng->Write();
1883  mFCircleDist->Write();
1884  mFLengthDist->Write();
1885 
1886  mFCircleLength->Write();
1887 
1888  mPRatioDist->Write();
1889  mPRatioDistSplit->Write();
1890 
1891  mSetupTime->Write();
1892  mTrackingTime->Write();
1893  mExtensionTime->Write();
1894  mSplitTime->Write();
1895  mFitTime->Write();
1896  mTotalTime->Write();
1897 
1898  return;
1899 }
1900 
1901 
1902 void StFtpcTrackEvaluator::FillMomentumHistos()
1903 {
1904  // Fill the relative momentum of the found track in comparison to the geant track in histograms.
1905 
1906  StFtpcTrack *ftrack;
1907  StFtpcTrack *gtrack;
1908 
1909  for (Int_t t_counter = 0; t_counter<mFoundTracks->GetEntriesFast(); t_counter++) {
1910 
1911  ftrack = (StFtpcTrack *)mFoundTracks->At(t_counter);
1912  gtrack = (StFtpcTrack *)mGeantTracks->At(mParent->At(t_counter));
1913 
1914  mPtot->Fill((Float_t)gtrack->GetP(), (Float_t)ftrack->GetP());
1915  mPt->Fill((Float_t)gtrack->GetPt(), (Float_t)ftrack->GetPt());
1916  mPx->Fill((Float_t)gtrack->GetPx(), (Float_t)ftrack->GetPx());
1917  mPy->Fill((Float_t)gtrack->GetPy(), (Float_t)ftrack->GetPy());
1918  mPz->Fill((Float_t)gtrack->GetPz(), (Float_t)ftrack->GetPz());
1919 
1920  mPtotDiff->Fill((Float_t)StFormulary::RelDiff(ftrack->GetP(), (Float_t)gtrack->GetP()));
1921  mPtDiff->Fill((Float_t)StFormulary::RelDiff(ftrack->GetPt(), (Float_t)gtrack->GetPt()));
1922  mPxDiff->Fill((Float_t)StFormulary::RelDiff(ftrack->GetPx(), (Float_t)gtrack->GetPx()));
1923  mPyDiff->Fill((Float_t)StFormulary::RelDiff(ftrack->GetPy(), (Float_t)gtrack->GetPy()));
1924  mPzDiff->Fill((Float_t)StFormulary::RelDiff(ftrack->GetPz(), (Float_t)gtrack->GetPz()));
1925 
1926  mPtotAcc->Fill(ftrack->GetP()/gtrack->GetP());
1927  mPtAcc->Fill(ftrack->GetPt()/gtrack->GetPt());
1928  mPxAcc->Fill(ftrack->GetPx()/gtrack->GetPx());
1929  mPyAcc->Fill(ftrack->GetPy()/gtrack->GetPy());
1930  mPzAcc->Fill(ftrack->GetPz()/gtrack->GetPz());
1931 
1932  mPRelErr->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt(), (ftrack->GetP() - gtrack->GetP())/gtrack->GetP());
1933  mPRelDiff->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt(), StFormulary::RelDiff(ftrack->GetP(), gtrack->GetP()));
1934 
1935  if (ftrack->GetCharge() != gtrack->GetCharge()) {
1936  mPtEtaWrongCharge->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt());
1937 
1938  if(ftrack->GetCharge() > 0.) {
1939  mPtEtaWrongPosCharge->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt());
1940  }
1941  }
1942 
1943  else {
1944  mPRelErrqok->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt(), (ftrack->GetP() - gtrack->GetP())/gtrack->GetP());
1945  }
1946  }
1947 
1948  return;
1949 }
1950 
1951 
1952 void StFtpcTrackEvaluator::FillMomentumHistos(Int_t t_counter)
1953 {
1954  // Fill the relative momentum of the found track in comparison to the geant track in histograms.
1955 
1956  StFtpcTrack *ftrack = (StFtpcTrack *)mFoundTracks->At(t_counter);
1957  StFtpcTrack *gtrack = (StFtpcTrack *)mGeantTracks->At(mParent->At(t_counter));
1958 
1959  mPtot->Fill(gtrack->GetP(), ftrack->GetP());
1960  mPt->Fill(gtrack->GetPt(), ftrack->GetPt());
1961  mPx->Fill(gtrack->GetPx(), ftrack->GetPx());
1962  mPy->Fill(gtrack->GetPy(), ftrack->GetPy());
1963  mPz->Fill(gtrack->GetPz(), ftrack->GetPz());
1964 
1965  mPtotDiff->Fill(StFormulary::RelDiff(ftrack->GetP(), gtrack->GetP()));
1966  mPtDiff->Fill(StFormulary::RelDiff(ftrack->GetPt(), gtrack->GetPt()));
1967  mPxDiff->Fill(StFormulary::RelDiff(ftrack->GetPx(), gtrack->GetPx()));
1968  mPyDiff->Fill(StFormulary::RelDiff(ftrack->GetPy(), gtrack->GetPy()));
1969  mPzDiff->Fill(StFormulary::RelDiff(ftrack->GetPz(), gtrack->GetPz()));
1970 
1971  mPtotAcc->Fill(ftrack->GetP()/gtrack->GetP());
1972  mPtAcc->Fill(ftrack->GetPt()/gtrack->GetPt());
1973  mPxAcc->Fill(ftrack->GetPx()/gtrack->GetPx());
1974  mPyAcc->Fill(ftrack->GetPy()/gtrack->GetPy());
1975  mPzAcc->Fill(ftrack->GetPz()/gtrack->GetPz());
1976 
1977  mPRelErr->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt(), (ftrack->GetP() - gtrack->GetP())/gtrack->GetP());
1978  mPRelDiff->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt(), StFormulary::RelDiff(ftrack->GetP(), gtrack->GetP()));
1979 
1980  if (ftrack->GetCharge() != gtrack->GetCharge()) {
1981  mPtEtaWrongCharge->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt());
1982 
1983  if(ftrack->GetCharge() > 0.) {
1984  mPtEtaWrongPosCharge->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt());
1985  }
1986  }
1987 
1988  else {
1989  mPRelErrqok->Fill(TMath::Abs(gtrack->GetEta()), gtrack->GetPt(), (ftrack->GetP() - gtrack->GetP())/gtrack->GetP());
1990  }
1991 
1992  return;
1993 }
1994 
1995 
1996 void StFtpcTrackEvaluator::FillParentHistos()
1997 {
1998  // Fill the number of parents per track in histogram.
1999 
2000  for (Int_t t_counter = 0; t_counter < mFoundTracks->GetEntriesFast(); t_counter++) {
2001  // Loop over tracks
2002  Int_t num_histo = ((StFtpcTrack *)mFoundTracks->At(t_counter))->GetNumberOfPoints();
2003 
2004  Int_t num_parents = 0;
2005  Int_t num_hits = 0;
2006  for (Int_t h_counter = 0; h_counter < StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(); h_counter++) {
2007  // Loop over clusters
2008 
2009  if (mNumParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + h_counter) != -1) {
2010  num_parents++;
2011 
2012  if (mParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + h_counter) != mParent->At(t_counter)) {
2013  num_hits += mNumParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + h_counter);
2014  }
2015  }
2016  }
2017 
2018  mNumParents->Fill(num_parents);
2019  mNumWrongHits->Fill((Float_t)num_hits, (Float_t)num_histo);
2020  mNumWrongHitsAll->Fill(num_hits);
2021  }
2022 }
2023 
2024 
2025 void StFtpcTrackEvaluator::FillParentHistos(Int_t t_counter)
2026 {
2027  // Fill the number of parents per track in histogram.
2028 
2029  Int_t num_histo = ((StFtpcTrack *)mFoundTracks->At(t_counter))->GetNumberOfPoints();
2030 
2031  Int_t num_parents = 0;
2032  Int_t num_hits = 0;
2033  for (Int_t h_counter = 0; h_counter < StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide(); h_counter++) {
2034  // Loop over clusters
2035 
2036  if (mNumParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + h_counter) != -1) {
2037  num_parents++;
2038 
2039  if (mParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + h_counter) != mParent->At(t_counter)) {
2040  num_hits += mNumParentTracks->At(t_counter * StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide() + h_counter);
2041  }
2042  }
2043  }
2044 
2045  mNumParents->Fill(num_parents);
2046  mNumWrongHits->Fill((Float_t)num_hits, (Float_t)num_histo);
2047  mNumWrongHitsAll->Fill(num_hits);
2048 }
2049 
2050 
2051 void StFtpcTrackEvaluator::FillHitsOnTrack(TObjArray *trackarray, Char_t c)
2052 {
2053  // Fills histogram with the number of points on tracks.
2054  // If c is set to 'g' it fills the 'geant histo', otherwise the 'found histo'.
2055 
2056  TH1F *histo;
2057 
2058  if (c=='g') {
2059  histo = mGHitsOnTrack;
2060  }
2061 
2062  else {
2063  histo = mFHitsOnTrack;
2064  }
2065 
2066  {for (Int_t i = 0; i < trackarray->GetEntriesFast(); i++) {
2067  histo->Fill(((StFtpcTrack*)trackarray->At(i))->GetNumberOfPoints());
2068  }}
2069 
2070  return;
2071 }
2072 
2073 
2074 void StFtpcTrackEvaluator::CalcSplitTracks()
2075 {
2076  // Calculates the number of split tracks and returns it.
2077 
2078  Double_t ratio;
2079  Double_t dist;
2080 
2081  Double_t r1;
2082  Double_t r2;
2083  Double_t R1;
2084  Double_t R2;
2085  Double_t phi1;
2086  Double_t phi2;
2087  Double_t Phi1;
2088  Double_t Phi2;
2089 
2090  for (Int_t track1 = 0; track1 < mFoundTracks->GetEntriesFast(); track1++) {
2091 
2092  for (Int_t track2 = track1+1; track2 < mFoundTracks->GetEntriesFast(); track2++) {
2093 
2094  StFtpcTrack *t1 = (StFtpcTrack *)mFoundTracks->At(track1);
2095  StFtpcTrack *t2 = (StFtpcTrack *)mFoundTracks->At(track2);
2096 
2097  r1 = t1->GetRLast();
2098  r2 = t2->GetRLast();
2099  phi1 = t1->GetAlphaLast();
2100  phi2 = t2->GetAlphaLast();
2101  R1 = t1->GetRFirst();
2102  R2 = t2->GetRFirst();
2103  Phi1 = t1->GetAlphaFirst();
2104  Phi2 = t2->GetAlphaFirst();
2105 
2106  dist = (TMath::Sqrt(r2*r2+r1*r1-2*r1*r2*(TMath::Cos(phi1)*TMath::Cos(phi2)+TMath::Sin(phi1)*TMath::Sin(phi2))) +
2107  TMath::Sqrt(R2*R2+R1*R1-2*R1*R2*(TMath::Cos(Phi1)*TMath::Cos(Phi2)+TMath::Sin(Phi1)*TMath::Sin(Phi2)))) / 2.;
2108  ratio = (Double_t)(t1->GetNumberOfPoints() + t2->GetNumberOfPoints()) / (Double_t)(t1->GetNMax() + t2->GetNMax());
2109 
2110  if (!(t1->GetRowsWithPoints() & t2->GetRowsWithPoints()) && (t1->GetHemisphere() == t2->GetHemisphere())) {
2111  mPRatioDist->Fill(dist, ratio);
2112  }
2113 
2114  if (mParent->At(track1) == mParent->At(track2)) {
2115 
2116  StFtpcTrack *track = (StFtpcTrack *)mGeantTracks->At(mParent->At(track1));
2117 
2118  mSplitTracksArr->AddLast(track1);
2119  mSplitTracksArr->AddLast(track2);
2120  mSplitTracks++;
2121 
2122  mPtEtaSplit->Fill(TMath::Abs(track->GetEta()), track->GetPt());
2123 
2124  if (ratio) mPRatioDistSplit->Fill(dist, ratio);
2125 
2126  if ((IsUncleanTrack(track1) || (IsCleanTrack(track1) && (!IsGoodTrack(track))))) {
2127  mPtEtaSplitLoliGood->Fill(TMath::Abs(track->GetPseudoRapidity()), track->GetPt());
2128  mSplitLoliGoodTracks++;
2129  }
2130 
2131  if (IsGoodTrack(track) && ((StFtpcTrack*)mFoundTracks->At(track1))->ComesFromMainVertex()) {
2132  mSplitGoodTracksArr->AddLast(track1);
2133  mSplitGoodTracks++;
2134 
2135  mPtEtaSplitGood->Fill(TMath::Abs(track->GetEta()), track->GetPt());
2136  }
2137  }
2138  }
2139  }
2140 
2141  return;
2142 }
2143 
2144 
2145 void StFtpcTrackEvaluator::FillTimeHistos(StFtpcTracker *tracker)
2146 {
2147  // Fills histograms of time consumption.
2148 
2149  mSetupTime->Fill(tracker->GetTime((Char_t*)"init"));
2150  mTrackingTime->Fill(tracker->GetTime((Char_t*)"main_vertex"));
2151  mExtensionTime->Fill(tracker->GetTime((Char_t*)"extend"));
2152  mSplitTime->Fill(tracker->GetTime((Char_t*)"splits"));
2153  mFitTime->Fill(tracker->GetTime((Char_t*)"fit"));
2154  mTotalTime->Fill(tracker->GetTime());
2155 
2156  return;
2157 }
2158 
2159 
2160 void StFtpcTrackEvaluator::FillEventHistos()
2161 {
2162  // Fill the histograms which are filled only once per event.
2163 
2164 
2165  mNumGeantHits->Fill(GetNumGeantHits());
2166  mNumGeantTracks->Fill(GetNumGeantTracks());
2167  mNumFoundHits->Fill(GetNumFoundHits());
2168  mNumFoundTracks->Fill(GetNumFoundTracks());
2169 
2170  mNumFoundVertexTracks->Fill(GetNumFoundVertexTracks());
2171  mNumFoundNonVertexTracks->Fill(GetNumFoundNonVertexTracks());
2172 
2173  mNumLookLikeGoodTracks->Fill(GetNumLookLikeGoodTracks());
2174  mNumElectronTracks->Fill(GetNumElectronTracks());
2175  mNumNonVertexTracks->Fill(GetNumNonVertexTracks());
2176  mNumGoodGTracks->Fill(GetNumGoodGeantTracks());
2177  mNumGoodFTracks->Fill(GetNumGoodFoundTracks());
2178  mGoodRatio->Fill(((Float_t)GetNumGoodFoundTracks()-(Float_t)GetNumSplitGoodTracks())/(Float_t)GetNumGoodGeantTracks());
2179  mContamination->Fill((Float_t)GetNumLookLikeGoodTracks()/(Float_t)GetNumFoundVertexTracks());
2180  mContaWoSplit->Fill((Float_t)(GetNumLookLikeGoodTracks()-GetNumSplitLookLikeGoodTracks())/(Float_t)GetNumFoundVertexTracks());
2181  mNumSplitTracks->Fill(GetNumSplitTracks());
2182  mNumSplitGoodTracks->Fill(GetNumSplitGoodTracks());
2183  mNumSplitLoliGoodTracks->Fill(GetNumSplitLookLikeGoodTracks());
2184  mNumUncleanTracks->Fill(GetNumUncleanTracks());
2185  mNumUncleanGoodTracks->Fill(GetNumUncleanGoodTracks());
2186  mNumLongTracks->Fill(GetNumLongTracks());
2187  mNumLongTrackClusters->Fill(GetNumLongTrackClusters());
2188  mNumShortTracks->Fill(GetNumShortTracks());
2189  mNumShortTrackClusters->Fill(GetNumShortTrackClusters());
2190  mNumTooShortTracks->Fill(GetNumTooShortTracks());
2191  mNumGoodGeantPoints->Fill(GetNumGoodGeantPoints());
2192  mNumGoodFoundPoints->Fill(GetNumGoodFoundPoints());
2193  mGoodPointRatio->Fill((Float_t)GetNumGoodFoundPoints()/(Float_t)GetNumGoodGeantPoints());
2194 
2195  return;
2196 }
2197 
2198 void StFtpcTrackEvaluator::GetGoodHits(TObjArray *good_clusters)
2199 {
2200  // Fills hits of good simulated tarcks in given TObjArray.
2201 
2202  good_clusters->Clear();
2203 
2204  {for (Int_t i = 0; i < mGeantHits->GetEntriesFast(); i++) {
2205 
2206  StFtpcConfMapPoint *hit = (StFtpcConfMapPoint*)mGeantHits->At(i);
2207 
2208  {for (Int_t j = 0; j < mFtpcTrackNum->GetSize(); j++) {
2209 
2210  if (mFtpcTrackNum->At(j) == hit->GetTrackNumber() && IsGoodTrack((StFtpcTrack*)mGeantTracks->At(j))) {
2211  LOG_INFO << i << " " << j << " " << mFtpcTrackNum->At(j) << " " << hit->GetTrackNumber() << " " << ((StFtpcTrack*)mGeantTracks->At(j))->GetEta() << endm;
2212  good_clusters->AddLast(hit);
2213  }
2214  }}
2215  }}
2216 
2217  return;
2218 }
2219 
2220 
2221 void StFtpcTrackEvaluator::GeantInfo()
2222 {
2223  // Shows information abaout GEANT output.
2224 
2225  LOG_INFO << "Geant hits : " << GetNumGeantHits() << endm;
2226  LOG_INFO << "Geant tracks : " << GetNumGeantTracks() << endm;
2227  LOG_INFO << "Short tracks : " << GetNumShortTracks() << endm;
2228  LOG_INFO << "Long tracks : " << GetNumLongTracks() << endm;
2229  LOG_INFO << "Good tracks : " << GetNumGoodGeantTracks() << endm;
2230 
2231  return;
2232 }
2233 
2234 
2235 void StFtpcTrackEvaluator::ClusterInfo()
2236 {
2237  // Shows information abaout GEANT clusters.
2238 
2239  LOG_INFO << "Short track clusters : " << GetNumShortTrackClusters() << endm;
2240  LOG_INFO << "Long track clusters : " << GetNumLongTrackClusters() << endm;
2241  LOG_INFO << "Max. track clusters : " << GetMaxClusters() << endm;
2242  LOG_INFO << "# of hits on good found tracks: " << GetNumGoodFoundPoints() << endm;
2243  LOG_INFO << "# of hits on good geant tracks: " << GetNumGoodGeantPoints() << endm;
2244  LOG_INFO << "Ratio of good found clusters : " << (Float_t)GetNumGoodFoundPoints()/(Float_t)GetNumGoodGeantPoints() << endm;
2245 
2246  return;
2247 }
2248 
2249 
2250 void StFtpcTrackEvaluator::ProblemsInfo()
2251 {
2252  // Shows information about problems.
2253 
2254  LOG_INFO << "Unclean tracks : " << GetNumUncleanTracks() << endm;
2255  LOG_INFO << "Unclean good tracks : " << GetNumUncleanGoodTracks() << endm;
2256  LOG_INFO << "Split tracks : " << GetNumSplitTracks() << endm;
2257  LOG_INFO << "Split good tracks : " << GetNumSplitGoodTracks() << endm;
2258  LOG_INFO << "Split look like good tracks : " << GetNumSplitLookLikeGoodTracks() << endm;
2259 
2260  return;
2261 }
2262 
2263 
2264 void StFtpcTrackEvaluator::TrackerInfo()
2265 {
2266  // Shows information about tracker output.
2267 
2268  LOG_INFO << "Found hits : " << GetNumFoundHits() << endm;
2269  LOG_INFO << "Found tracks (vtx/non vtx) : " << GetNumFoundTracks() << " (" << GetNumFoundVertexTracks() << "/" << GetNumFoundNonVertexTracks() << ")" << endm;
2270  LOG_INFO << "Found good tracks : " << GetNumGoodFoundTracks() << endm;
2271  LOG_INFO << "Bad found tracks looking good : " << GetNumLookLikeGoodTracks() << endm;
2272  LOG_INFO << "Found electron tracks : " << GetNumElectronTracks() << endm;
2273  LOG_INFO << "Found non main vertex tracks : " << GetNumNonVertexTracks() << endm;
2274  LOG_INFO << "Found too short tracks : " << GetNumTooShortTracks() << endm;
2275 
2276  LOG_INFO << "Ratio of good geant tracks : " << ((Float_t)GetNumGoodFoundTracks()-(Float_t)GetNumSplitGoodTracks())/(Float_t)GetNumGoodGeantTracks() << endm;
2277  LOG_INFO << "Contamination : " << (Float_t)GetNumLookLikeGoodTracks()/(Float_t)GetNumFoundVertexTracks() << endm;
2278  LOG_INFO << "Contamination without splits : " << ((Float_t)GetNumLookLikeGoodTracks()-(Float_t)GetNumSplitLookLikeGoodTracks())/(Float_t)GetNumFoundVertexTracks() << endm;
2279 
2280  return;
2281 }
2282 
2283 
2284 void StFtpcTrackEvaluator::InfoAll()
2285 {
2286  // Shows all information.
2287 
2288  TrackerInfo();
2289  LOG_INFO << endm;
2290  GeantInfo();
2291  LOG_INFO << endm;
2292  ClusterInfo();
2293  LOG_INFO << endm;
2294  ProblemsInfo();
2295 
2296  return;
2297 }
2298 
2299 void StFtpcTrackEvaluator::FillCutHistos()
2300 {
2301  // Fills histograms for cuts. This is done for Geant tracks and found tracks.
2302 
2303  FillGCutHistos();
2304  FillFCutHistos();
2305 
2306  return;
2307 }
2308 
2309 
2310 void StFtpcTrackEvaluator::FillHitsOnTrack()
2311 {
2312  // Fill hits on all tracks in histograms.
2313 
2314  FillHitsOnTrack(mGeantTracks, 'g');
2315  FillHitsOnTrack(mFoundTracks, 'f');
2316 
2317  return;
2318 }
2319 
2320 
2321 void StFtpcTrackEvaluator::FillFoundHitsOnTrack()
2322 {
2323  // Fill hits on found tracks in histograms.
2324 
2325  FillHitsOnTrack(mFoundTracks, 'f');
2326 
2327  return;
2328 }
2329 
2330 
2331 Bool_t StFtpcTrackEvaluator::IsGoodTrack(StFtpcTrack* track)
2332 {
2333  // Returns true if the given track fulfills all requirements to be a "good" track.
2334 
2335  if (track->GetPid() > 3 && track->ComesFromMainVertex() && track->GetNumberOfPoints() >= 5 && track->GetNumberOfPoints() <= StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide()) {
2336  return (Bool_t)kTRUE;
2337  }
2338 
2339  else {
2340  return (Bool_t)kFALSE;
2341  }
2342 }
2343 
2344 
2345 Bool_t StFtpcTrackEvaluator::IsGoodMainVertexTrack(StFtpcTrack* track)
2346 {
2347  // Returns true if the given track fulfills all requirements to be a "good" track.
2348 
2349  if (track->GetPid() > 3 && track->ComesFromMainVertex() && track->GetNumberOfPoints() >= 5 && track->GetNumberOfPoints() <= StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide()) {
2350  return (Bool_t)kTRUE;
2351  }
2352 
2353  else {
2354  return (Bool_t)kFALSE;
2355  }
2356 }
2357 
2358 
2359 Bool_t StFtpcTrackEvaluator::IsGoodNonVertexTrack(StFtpcTrack* track)
2360 {
2361  // Returns true if the given track fulfills all requirements to be a "good" track.
2362 
2363  if (track->GetPid() > 3 && !(track->ComesFromMainVertex()) && track->GetNumberOfPoints() >= 5 && track->GetNumberOfPoints() <= StFtpcTrackingParams::Instance()->NumberOfPadRowsPerSide()) {
2364  return (Bool_t)kTRUE;
2365  }
2366 
2367  else {
2368  return (Bool_t)kFALSE;
2369  }
2370 }
2371 
2372 
2373 void StFtpcTrackEvaluator::ShowTracks()
2374 {
2375  // Displays the geant and/or found tracks.
2376 
2377  StFtpcDisplay display(GetFoundHits(), GetFoundTracks(), GetGeantHits(), GetGeantTracks());
2378  display.ShowEvalTracks(mSplitTracksArr, mUncleanTracksArr, mClusterArr);
2379 
2380  return;
2381 }
Char_t * mWritePermission
Name of the data file.
TFile * mFile
Write permission of the data file.
virtual TDataSet * Find(const char *path) const
Definition: TDataSet.cxx:362