//----------------------------------------------------------------------------- // 15 Dec 2000 P.Murat: the simpliest possible version of the extrapolator //----------------------------------------------------------------------------- #ifndef Stntuple_alg_TSimpleExtrapolator_hh #define Stntuple_alg_TSimpleExtrapolator_hh #include "TExtrapolator.hh" class TVector3; class TSimpleExtrapolator: public TExtrapolator { //----------------------------------------------------------------------------- // data members //----------------------------------------------------------------------------- protected: // charge of the particle to be // extrapolated Int_t fCharge; // GEANT code of the extrapolated // particle Int_t fParticleCode; TTrajectoryPoint* fPoint; // to be used soon Double_t fBField[3]; // starting point of the extrapolation // x,y,z, nx,ny,nz,total momentum Double_t fVect[7]; // output of the extrapolation // x,y,z,nx,ny,nz,total momentum Double_t fVout[7]; // extrapolation path Double_t fPath; Double_t fMinPtCes; // min Pt to be traced to CES Double_t fMinPtCmu; // min Pt to be traced to CMU Double_t fMinPt; // min Pt to be traced to plug Double_t fMaxEta; // max |eta| of a track to be traced //----------------------------------------------------------------------------- // functions //----------------------------------------------------------------------------- public: TSimpleExtrapolator(); ~TSimpleExtrapolator(); Int_t Init(Double_t* xyz, Double_t* mom, Int_t charge, Int_t mode); //----------------------------------------------------------------------------- // accessors //----------------------------------------------------------------------------- Double_t GetMinPtCes () { return fMinPtCes; } Double_t GetMinPtCmu () { return fMinPtCmu; } Double_t GetMinPt () { return fMinPt; } Double_t GetMaxEta () { return fMaxEta; } //----------------------------------------------------------------------------- // methods returning results of the extrapolation, have to be called AFTER // extrapolation is done //----------------------------------------------------------------------------- void GetFinalResults (Double_t* xyz, Double_t* mom, Double_t& tot); void GetFinalPosition (Double_t* xyz); void GetFinalDirection (Double_t* dir); void GetTrajectoryPoint(TTrajectoryPoint* Point); Int_t GetBField (Double_t* xyz , Double_t* BField); Int_t GetBField (TVector3* xyz , Double_t* BField); Int_t GetBField (TTrajectoryPoint* Point, Double_t* BField); // returns just 1 number - total // momentum void GetFinalMomentum (Double_t& mom); //----------------------------------------------------------------------------- // modifiers //----------------------------------------------------------------------------- void SetMinPtCes (Double_t Pt ) { fMinPtCes = Pt; } void SetMinPtCmu (Double_t Pt ) { fMinPtCmu = Pt; } void SetMinPt (Double_t Pt ) { fMinPt = Pt; } void SetMaxEta (Double_t Eta) { fMaxEta = Eta; } //----------------------------------------------------------------------------- // for the routines below TTrajectoryPoint is an array, which first point ([0]) // is a starting point for extrapolation // ------------------------------------ // 1. swim to CMU //----------------------------------------------------------------------------- int SwimToCmu(int Charge, int N, const Double_t* Radius, TTrajectoryPoint* Point); //----------------------------------------------------------------------------- // 2. swim to CES: returns indices of the wedge and coordinates of the hit in // the local coordinate system of the wedge, which has Z axis // pointing to the west for the west wedges... //----------------------------------------------------------------------------- int SwimToCes(TTrajectoryPoint* Point , int Charge, int& Side , int& Wedge , Double_t& XWedge, Double_t& ZWedge); //----------------------------------------------------------------------------- // 3. swim to PES: Point[0] is the starting point, // Point[1] is intersection with PES // Wedge, U and V are left undefined, contributions are welcome //----------------------------------------------------------------------------- int SwimToPes(TTrajectoryPoint* Point, int Charge, Int_t& Side , Int_t& Wedge , Double_t& U , Double_t& V); void GetIEtaIPhi(Int_t Side, Int_t Wedge, Double_t ZLocal, Int_t& IEta, Int_t& IPhi); Double_t GetNormDeltaEta(Int_t Side, Int_t Wedge, Double_t ZCes); //----------------------------------------------------------------------------- // 3. overloaded methods of TExtrapolator //----------------------------------------------------------------------------- virtual int SwimToZ (int Charge, int N , const Double_t* Z , TTrajectoryPoint* Point ); ClassDef(TSimpleExtrapolator,0) }; #endif