00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef ATLFAST_TRACK_H
00029 #define ATLFAST_TRACK_H
00030
00031
00032
00033 #include "CLHEP/Vector/ThreeVector.h"
00034 #include "HepMC/GenParticle.h"
00035 #include "CLHEP/Matrix/Matrix.h"
00036
00037
00038 #include "AtlfastEvent/TrackTrajectory.h"
00039 #include "AtlfastEvent/AssociationManager.h"
00040
00041
00042 #include "GaudiKernel/ContainedObject.h"
00043 #include "GaudiKernel/MsgStream.h"
00044
00045
00046
00047 static const CLID CLID_ATLFAST_Track=2306 ;
00048
00049 using ::HepMatrix;
00050
00051 namespace Atlfast {
00052
00053
00060 class Track :
00061 virtual public ContainedObject,
00062 public AssociationManager
00063 {
00064
00065 private:
00066
00068 TrackTrajectory m_trajectory;
00070 TrackTrajectory m_truthTrajectory;
00073 const HepMC::GenParticle* m_truth ;
00075 HepMatrix m_smearMatrix;
00077 int m_pdg_id;
00078
00079 public:
00080
00081
00082
00083
00084 Track( const TrackTrajectory& trajectory,
00085 const HepMC::GenParticle* progenitor )
00086 : ContainedObject(),
00087 AssociationManager(),
00088 m_trajectory(trajectory),
00089 m_truthTrajectory(trajectory),
00090 m_truth( progenitor ),
00091 m_smearMatrix(HepMatrix(5,5,0.)),
00092 m_pdg_id(progenitor->pdg_id())
00093 { }
00094
00095 Track( const TrackTrajectory& truthTrajectory,
00096 const TrackTrajectory& smearTrajectory,
00097 const HepMC::GenParticle* progenitor,
00098 const HepMatrix& matrix )
00099 : ContainedObject(),
00100 AssociationManager(),
00101 m_trajectory(smearTrajectory),
00102 m_truthTrajectory(truthTrajectory),
00103 m_truth( progenitor ),
00104 m_smearMatrix(matrix),
00105 m_pdg_id(progenitor->pdg_id())
00106 { }
00107
00108 Track( const TrackTrajectory& truthTrajectory,
00109 const TrackTrajectory& smearTrajectory,
00110 const HepMatrix& matrix, int pdg )
00111 : ContainedObject(),
00112 AssociationManager(),
00113 m_trajectory(smearTrajectory),
00114 m_truthTrajectory(truthTrajectory),
00115 m_truth( NULL ),
00116 m_smearMatrix(matrix),
00117 m_pdg_id(pdg)
00118 { }
00119
00120
00121 Track( const Track& other ) : ContainedObject( ),
00122 AssociationManager(other),
00123 m_trajectory(other.m_trajectory),
00124 m_truthTrajectory(other.m_truthTrajectory),
00125 m_truth( other.m_truth ),
00126 m_smearMatrix(other.m_smearMatrix),
00127 m_pdg_id(other.m_pdg_id)
00128 { }
00129
00130
00131
00132 Track()
00133 : ContainedObject(),
00134 AssociationManager(),
00135 m_truth(NULL)
00136 { }
00137
00138 ~Track() {}
00139
00141 virtual TrackTrajectory trajectory() const {return m_trajectory;}
00143 virtual int pdg_id() const {return m_pdg_id;}
00145 const HepMC::GenParticle* truth() const { return m_truth ; }
00147 const HepMatrix smearMatrix() const {return m_smearMatrix;}
00149 void setMatrix(const HepMatrix& matrix) {m_smearMatrix = matrix;}
00151 const TrackTrajectory truthTrajectory() const {return m_truthTrajectory;}
00152
00153
00154 static const CLID& classID() { return CLID_ATLFAST_Track; }
00155 virtual const CLID& clID() const { return CLID_ATLFAST_Track; }
00156
00157 };
00158
00159
00160
00161
00162
00163 MsgStream& operator << ( MsgStream& s, const Track& t ) ;
00164 MsgStream& operator << ( MsgStream& s, const Track* t ) ;
00165
00166
00167 }
00168
00169
00170 #endif