55 fPositionRecord(0),fParticleDefinition(0)
61 if(fParticleName==
"unknown")
70 fParticleName +=
" : ";
81 else if(fTrackStatus == 2)
96 for(i=0;i<fPositionRecord->size();i++){
97 delete (*fPositionRecord)[i];
99 fPositionRecord->clear();
101 delete fPositionRecord;
107 os <<
G4endl <<
"TrackID =" << fTrackID
108 <<
" : ParentID=" << fParentID <<
" : TrackStatus=" << fTrackStatus <<
G4endl;
109 os <<
"Particle name : " << fParticleName <<
" PDG code : " << fPDGEncoding
110 <<
" Charge : " << fPDGCharge <<
G4endl;
111 os <<
"Original momentum : " <<
113 os <<
"Vertex : " <<
G4BestUnit(fVertexPosition,
"Length")
115 os <<
" Current trajectory has " << fPositionRecord->size()
118 for(
size_t i=0 ; i < fPositionRecord->size() ; i++){
121 os <<
"Point[" << i <<
"]"
134 for (
size_t i = 0; i < fPositionRecord->size() ; i++) {
138 pPolyline.push_back( pos );
167 if(pVVisManager) pVVisManager->
Draw(pPolyline);
174 std::map<G4String,G4AttDef>* store
179 (*store)[id] =
G4AttDef(
id,
"Track ID",
"Bookkeeping",
"",
"G4int");
182 (*store)[pid] =
G4AttDef(pid,
"Parent ID",
"Bookkeeping",
"",
"G4int");
185 (*store)[
status] =
G4AttDef(status,
"Track Status",
"Bookkeeping",
"",
"G4int");
188 (*store)[
pn] =
G4AttDef(pn,
"Particle Name",
"Bookkeeping",
"",
"G4String");
191 (*store)[ch] =
G4AttDef(ch,
"Charge",
"Physics",
"e+",
"G4double");
194 (*store)[pdg] =
G4AttDef(pdg,
"PDG Encoding",
"Bookkeeping",
"",
"G4int");
197 (*store)[imom] =
G4AttDef(imom,
"Momentum of track at start of trajectory",
198 "Physics",
"G4BestUnit",
"G4ThreeVector");
202 G4AttDef(imag,
"Magnitude of momentum of track at start of trajectory",
203 "Physics",
"G4BestUnit",
"G4double");
206 (*store)[vtxPos] =
G4AttDef(vtxPos,
"Vertex position",
207 "Physics",
"G4BestUnit",
"G4ThreeVector");
210 (*store)[ntp] =
G4AttDef(ntp,
"No. of points",
"Bookkeeping",
"",
"G4int");
219 std::vector<G4AttValue>* values =
new std::vector<G4AttValue>;
230 values->push_back(
G4AttValue(
"PN",fParticleName,
""));
256 fPositionRecord->push_back(
263 if(!secondTrajectory)
return;
269 for(
int i=1;i<ent;i++)
271 fPositionRecord->push_back((*(seco->fPositionRecord))[i]);
273 delete (*seco->fPositionRecord)[0];
274 seco->fPositionRecord->clear();
virtual void Draw(const G4Circle &, const G4Transform3D &objectTransformation=G4Transform3D())=0
G4ParticleDefinition * GetDefinition() const
static G4Electron * ElectronDefinition()
G4int GetParentID() const
static G4MuonPlus * MuonPlusDefinition()
virtual const std::map< G4String, G4AttDef > * GetAttDefs() const
virtual ~RE01Trajectory()
const G4DynamicParticle * GetDynamicParticle() const
static G4VVisManager * GetConcreteInstance()
virtual void AppendStep(const G4Step *aStep)
const G4ThreeVector & GetPosition() const
G4ThreadLocal G4Allocator< RE01Trajectory > * myTrajectoryAllocator
virtual void ShowTrajectory(std::ostream &os=G4cout) const
static G4String ConvertToString(G4bool boolVal)
RE01Trajectory(const G4Track *aTrack)
G4int GetPDGEncoding() const
#define G4BestUnit(a, b)
#define G4_USE_G4BESTUNIT_FOR_VERBOSE 1
const G4ThreeVector GetPosition() const
const G4String & GetParticleName() const
G4ParticleDefinition * GetG4code() const
G4VUserTrackInformation * GetUserInformation() const
virtual void DrawTrajectory() const
const G4ThreeVector & GetPosition() const
const G4String & GetParticleType() const
G4double GetGlobalTime() const
G4PrimaryParticle * GetPrimaryParticle() const
void SetVisAttributes(const G4VisAttributes *)
static G4Positron * PositronDefinition()
G4ThreeVector GetMomentum() const
G4StepPoint * GetPostStepPoint() const
virtual std::vector< G4AttValue > * CreateAttValues() const
std::vector< G4VTrajectoryPoint * > RE01TrajectoryPointContainer
G4double GetCharge() const
static G4MuonMinus * MuonMinusDefinition()
virtual void MergeTrajectory(G4VTrajectory *secondTrajectory)
G4double GetPDGCharge() const
virtual int GetPointEntries() const
std::map< G4String, G4AttDef > * GetInstance(G4String storeKey, G4bool &isNew)
Definition of the RE01Trajectory class.
static G4Gamma * GammaDefinition()