BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Ext_track.h
Go to the documentation of this file.
1//
2// File: Ext_track.h
3//
4// Description: Ext_track class.
5//
6// Author: L.L.Wang
7//
8// Creation: 2005.3.7
9// Version: v1
10//
11// $Id: Ext_track.h,v 1.11 2015/07/29 00:28:14 sunss Exp $
12//
13// Revision history
14//
15//
16
17#ifndef _EXT_TRACK_FLAG_
18#define _EXT_TRACK_FLAG_
19
20// class Hep3Vector;
21
22#include <string>
23
24#include "Ext_xp_err.h"
25
26#include "G4Track.hh"
27#include "G4TrackingManager.hh"
28#include "G4VPhysicalVolume.hh"
29#include "G4VUserDetectorConstruction.hh"
30#include "G4VUserPhysicsList.hh"
31
32#include "ExtSteppingAction.h"
33
34/**
35 Track extrapolation class.
36*/
37
38class G4RunManagerKernel;
39
40class Ext_track {
41
42public:
43 // Default constructor.
44 Ext_track();
45 Ext_track( const bool msgFlag, const bool myBFieldOn, const bool GeomOptimization,
46 const int m_detVer, const bool UseMucKal, const int MucWindow );
47
48 // Destructor.
49 ~Ext_track();
50
51 // Public member functins.
52
53 // Initialization of the object. par -- Options.
54 void Initialization( const bool aMsgFlag, const bool Bfield, const bool GeomOptimization,
55 const bool aUseMucKal, const int aMucWindow );
56
57 /** Setup the error skip list as a part of the initialization.
58 errskip\_list -- Name of the error skip file.*/
59 // bool Set_errskip_list( const char* errskip_list );
60
61 /** Print out the contents of the error skip list.*/
62 // void Prn_errskip_list() const;
63
64 // Set the starting point of the track extrapolation.
65 // xv3 -- Starting position(x,y,z)
66 // pv3 -- Starting momentum(px,py,pz)
67 // err -- Starting error matrix(x,y,z,px,py,pz)
68 // particleName - Assumed particle's name
69 //
70 bool Set( const Hep3Vector& xv3, const Hep3Vector& pv3, const HepSymMatrix& err,
71 const std::string& particleName, const double pathInMDC, const double tofInMdc );
72
73 // Perform the actual extrapolation and write the result of the extrapolation to TDS.
74 void TrackExtrapotation();
75
76 /** Termination of the track extrapolation.
77 */
78 // void End();
79
80 /** Accessors for the parameters.
81 */
82
83 /** Modifiers for the parameters.
84 */
85
86 /** Modifiers for the track direction. (0/1)=(outgoing/incoming).
87 */
88 inline void Dir( const int dir );
89
90 inline ExtSteppingAction* GetStepAction() { return extSteppingAction; };
91
92private:
93 // Geometry Initialization
94 bool GeometryInitialization();
95
96 // Physics Initialization
97 bool PhysicsInitialization();
98
99 // CheckRegions
100 void CheckRegions();
101
102 // Check Vertex is Inside the setup
103 bool CheckVertexInsideWorld( const Hep3Vector& pos );
104
105 // Commonly used data in member functions.
106
107 Ext_xp_err m_xp_err;
108
109 bool myMsgFlag;
110 bool myGeomOptimization;
111 bool myBFieldOn;
112 int m_detVer;
113 bool myUseMucKal;
114 int myMucWindow;
115 float m_vect[7];
116 int m_dir;
117
118 // Error calculation skip data.
119
120 // Ext_list m_errskip_list;
121 // bool m_errskip_flag;
122 // int m_errskip_level;
123 // int m_errskip_iname;
124
125 // Bes3DetectorConstruction
126 G4VUserDetectorConstruction* bes3DetectorConstruction;
127 G4VPhysicalVolume* bes3WorldVolume;
128
129 // ExtPhysicsList
130 G4VUserPhysicsList* extPhysicsList;
131
132 // G4Track
133 G4Track* extTrack;
134
135 // ExtSteppingAction
136 ExtSteppingAction* extSteppingAction;
137
138 // Tracking Manager
139 G4TrackingManager* extTrackingManager;
140
141 // RunManagerKernel for geant4.9.0
142 G4RunManagerKernel* extRunManagerKernel;
143};
144
145/*
146 Inline function.
147*/
148
149// Modifiers.
150
151inline void Ext_track::Dir( const int dir ) { m_dir = dir; }
152
153#endif /* _EXT_TRACK_FLAG_ */
void TrackExtrapotation()
void Initialization(const bool aMsgFlag, const bool Bfield, const bool GeomOptimization, const bool aUseMucKal, const int aMucWindow)
ExtSteppingAction * GetStepAction()
Definition Ext_track.h:90
bool Set(const Hep3Vector &xv3, const Hep3Vector &pv3, const HepSymMatrix &err, const std::string &particleName, const double pathInMDC, const double tofInMdc)
void Dir(const int dir)
Definition Ext_track.h:151