00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef FTFTRACK
00011 #define FTFTRACK
00012 #include "Stl3Util/ftf/FtfGeneral.h"
00013 #include "Stl3Util/ftf/FtfBaseTrack.h"
00014 #include "Stl3Util/ftf/FtfHit.h"
00015 #include "Stl3Util/ftf/FtfPara.h"
00016
00017 int const USE_SEGMENT= 1 ;
00018 int const USE_FOLLOW = 2 ;
00019 int const GO_DOWN =-1 ;
00020 int const GO_UP = 1 ;
00021
00022 class FtfTrack : public FtfBaseTrack {
00023
00024 public:
00025 friend class FtfFinder ;
00026
00027 void add ( FtfHit *thisHit, int way ) ;
00028 void add ( FtfTrack *thisTrack ) ;
00029 int buildTrack ( FtfHit *firstHit, FtfContainer *volume ) ;
00030 void dEdx ( ) ;
00031 void deleteCandidate ( ) ;
00032 void fill ( ) ;
00033 void fillPrimary ( double &xc, double &yc, double &rc,
00034 double xPar, double yPar ) ;
00035 void fillSecondary ( double &xc, double &yc, double xPar, double yPar ) ;
00036 int follow ( FtfContainer *volume, int way, int rowToStop ) ;
00037 int followHitSelection ( FtfHit *baseHit, FtfHit *candidateHit ) ;
00038 FtfTrack* getNextTrack ( ) { return (FtfTrack *)nxatrk ; } ;
00039 int mergePrimary ( FtfContainer *trackArea ) ;
00040 void reset ( ) ;
00041 FtfHit *seekNextHit ( FtfContainer *volume, FtfHit *baseHit,
00042 int nradiusSteps, int whichFunction ) ;
00043 int segment ( FtfContainer *volume, int way ) ;
00044 int segmentHitSelection ( FtfHit *baseHit, FtfHit *candidateHit ) ;
00045 void *nxatrk ;
00046
00047 #ifdef DEBUG
00048 void debugAsk ( ) ;
00049 void debugDeleteCandidate ( ) ;
00050 void debugFill ( ) ;
00051 void debugFollowCandidate ( FtfHit *candidate_hit ) ;
00052 void debugFollowSuccess ( double dxy, double dsz, double lchi2_xy,
00053 double lchi2_sz, double chi2_min,
00054 FtfHit *candidate_hit ) ;
00055 void debugInVolume ( FtfHit *base_hit, FtfHit *current_hit ) ;
00056 void debugNew ( ) ;
00057 #endif
00058
00059 float lastXyAngle ;
00060 typedef double vfit ;
00061
00062 vfit xRefHit ;
00063 vfit yRefHit ;
00064 vfit xLastHit ;
00065 vfit yLastHit ;
00066
00067 vfit s11Xy ;
00068 vfit s12Xy ;
00069 vfit s22Xy ;
00070 vfit g1Xy ;
00071 vfit g2Xy ;
00072 vfit s11Sz ;
00073 vfit s12Sz ;
00074 vfit s22Sz ;
00075 vfit g1Sz ;
00076 vfit g2Sz ;
00077
00078 vfit ddXy, a1Xy, a2Xy ;
00079 vfit ddSz, a1Sz, a2Sz ;
00080
00081 inline virtual void nextHit (){ currentHit = ((FtfBaseHit *)currentHit)->nextTrackHit ; } ;
00082
00083 } ;
00084 #endif
00085