/*************************************************************************** track.hh - description ------------------- begin : Tue Mar 7 2000 copyright : (C) 2000 by Liuht email : liuht@particle.phys.ethz.ch ***************************************************************************/ /*************************************************************************** * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * ***************************************************************************/ #ifndef TRACK_HH #define TRACK_HH #include "TObject.h" #include "TObjString.h" /** *@author Liuht */ class Track : public TObject { public: Track(){}; Track(int,int,int,double*,double*,int,int,int,double,double,double,double, const char *, const char *, const char*,const char*, const char*, double*, double*,int); ~Track(); int GetTrackID(){return TrackID;} int GetParticleID(){return ParticleID;} int GetTrackType(); int GetParentID(){return ParentID;} int GetAncientParentID(){return AncientParentID;} int GetPDGEncodeing(){return PDGEncoding;} int Getbounceno(){return bounceno;} double GetPDGCharge(){return PDGCharge;} double* GetPosition(){return position;} void GetPosition(double *) const ;// return position in unit of cm; void GetMomentumDirection(double *)const;// return momentum direction; double* GetMomentum(){return momentum;} void GetMomentum(double *) const;//Get Momentum in unit of GeV double GetKineticEnergy() const ;//return kinetic energy in unit of Gev double GetPDGMass() {return PDGMass;} double GetLvalue(); const char * GetParticleName(){return ParticleName.GetName();}; const char * GetParentProcessName(){return ParentProcessName.GetName();} const char * GetKillProcess(){return KillProcess.GetName();}; double GetTrackLength(){return TrackLength;}; double GetTrackLengthInEarthR(){return TrackLength/(6.3712e9);} double GetFlightTime(){ return TrackLife;}; const char * GetCurrentVolume() {return CurrentVolume.GetName();}; const char * GetOriginVolume(){return OriginVolume.GetName();}; double* GetOriginPosition(){ return OriginPosition;}; double* GetOriginMomentum(){ return OriginMomentum;}; /** */ void getcutoff(double &cutoff, double &thetamags, double &ct); double GetRadius()const ; //return radius in unit of cm void GetPhiTheta(double &phi, double &theta)const ; void GetDirPhiTheta(double &phi, double &theta) const; double GetLongitude()const; double GetLatitude()const; double GetDriftSpeed(); // void operator delete(void *ptr){}; virtual void Print(Option_t *option=""); private: // Private attributes /** */ int TrackID; int ParticleID; int TrackType; /** type 0, primary begin; type 1, primary reenter the atmosphere; type 2, secondary come out of atmosphers; type 3, pass through the shulter sphere; type 4, secondary enter the atmosphere; type 5, secondary was killed after more than 5 bounces; type 6, secondary out of world;(come to the surface of earth) type 7, goto outer space, type 8, killed type 9,stopped isotope type 80,killed by userspecialcut; type 81,killed by inelastic; type 82,killed by conv type 83,killed by decay; type 84,killed by LCapture; type 85,killed by phot type 86,killed by annihil; type 87,killed by LElastic; **/ double position[3]; double momentum[3]; int ParentID; //parent track id int PDGEncoding; int bounceno; double PDGCharge; double PDGMass; double TrackLength; double TrackLife; TObjString ParticleName; TObjString ParentProcessName; TObjString KillProcess; //Process that stopped this track TObjString CurrentVolume; TObjString OriginVolume; double OriginPosition[3]; double OriginMomentum[3]; int AncientParentID; ClassDef(Track,8) }; #endif