#ifndef PNDTRKLEGENDRETRANSFORM2_H #define PNDTRKLEGENDRETRANSFORM2_H #include "PndTrkParameters.h" #include "TObject.h" #include #include class PndTrkLegendreTransform2 : public TObject { public: PndTrkLegendreTransform2(); PndTrkLegendreTransform2(double rmin, double rmax); ~PndTrkLegendreTransform2(); void SetUpLegendreHisto(); void ResetLegendreHisto(); void Fill(int hitid, int thetastep, int radstep, int detstep); void FillLegendreHisto(int detid, int hitid, double x, double y, double radius); std::vector< std::pair< int, int> > ExtractLegendreMaximum(int imax, double &theta_max, double &r_max); Int_t GetNofMaxima(); void SearchSecondaryTracks() { fRMin = -1; fRMax = 1; fThetaStepping = (fThetaMax - fThetaMin)/NOFTHETASTEPS; fRadStepping = (fRMax - fRMin)/NOFRADSTEPS; fThreshold = 20; } void ExtractLineParameters(double theta, double r, double &slope, double &intercept); void ExtractLegendreSingleLineParameters(int imax, double &slope, double &intercept); /* void DeleteZoneAroundXYLegendre(double x, double y); */ void ResetLegendre(); void Draw(); private: Double_t fThetaMin, fThetaMax, fThetaStepping, fRMin, fRMax, fRadStepping; Int_t fhLegendre[NOFTHETASTEPS][NOFRADSTEPS][NOFDETIDSTEPS][NOFHITIDSTEPS]; Int_t fhVotes[NOFTHETASTEPS][NOFRADSTEPS][NOFDETIDSTEPS]; Int_t fhTotVotes[NOFTHETASTEPS][NOFRADSTEPS]; Int_t fhGoodTracks[NOFPOSSIBLETRACKS][2]; Int_t fThreshold, fNofGoodTracks; std::map < std::pair < int, int > , std::vector < std::pair < int, int > > > fLegendrePlane; ClassDef(PndTrkLegendreTransform2, 1) }; #endif