BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
GeneratorModule/include/GeneratorModule/Gen_HEPEVT.h
Go to the documentation of this file.
1#ifndef GENERATORMODULES_GEN_HEPEVT_H
2#define GENERATORMODULES_GEN_HEPEVT_H
3
4#include <map>
5#include <vector>
6
7#include "CLIDSvc/CLASS_DEF.h"
8// #include "StoreGate/tools/ClassID_traits.h"
9#include "CLHEP/Vector/LorentzVector.h"
10
12public:
13 Gen_HEPEVT( void );
14
15 // Get Methods
16 int nevhep( void ) const;
17 int nhep( void ) const;
18 int isthep( int ihep );
19 int idhep( int ihep );
20 int first_parent( int ihep );
21 int last_parent( int ihep );
22 int first_child( int ihep );
23 int last_child( int ihep );
24 double px( int ihep );
25 double py( int ihep );
26 double pz( int ihep );
27 double e( int ihep );
28 double m( int ihep );
29 double x( int ihep );
30 double y( int ihep );
31 double z( int ihep );
32 double t( int ihep );
33
34 // Set Methods
35 void nevhep( int value );
36 void nhep( int value );
37 void isthep( int& ihep, int value );
38 void idhep( int& ihep, int value );
39 void mothers( int& ihep, int value1, int value2 );
40 void daughters( int& ihep, int value1, int value2 );
41 void momentum( int& ihep, double px, double py, double pz, double e, double m );
42 void position( int& ihep, double x, double y, double z, double t );
43
44private:
45 /**********************************************************/
46 /* D E S C R I P T I O N : */
47 /*--------------------------------------------------------*/
48 /* NEVHEP - event number (or some special meaning*/
49 /* (see documentation for details) */
50 /* NHEP - actual number of entries in current */
51 /* event. */
52 /* ISTHEP[IHEP] - status code for IHEP'th entry - see */
53 /* documentation for details */
54 /* IDHEP [IHEP] - IHEP'th particle identifier according*/
55 /* to PDG. */
56 /* JMOHEP[IHEP][0] - pointer to position of 1st mother */
57 /* JMOHEP[IHEP][1] - pointer to position of 2nd mother */
58 /* JDAHEP[IHEP][0] - pointer to position of 1st daughter */
59 /* JDAHEP[IHEP][1] - pointer to position of 2nd daughter */
60 /* PHEP [IHEP][0] - X momentum [Gev/c] */
61 /* PHEP [IHEP][1] - Y momentum [Gev/c] */
62 /* PHEP [IHEP][2] - Z momentum [Gev/c] */
63 /* PHEP [IHEP][3] - Energy [Gev] */
64 /* PHEP [IHEP][4] - Mass[Gev/c^2] */
65 /* VHEP [IHEP][0] - X vertex [mm] */
66 /* VHEP [IHEP][1] - Y vertex [mm] */
67 /* VHEP [IHEP][2] - Z vertex [mm] */
68 /* VHEP [IHEP][3] - production time [mm/c] */
69 /*========================================================*/
70
71 int m_NEVHEP;
72 int m_NHEP;
73 std::map<int, int> m_ISTHEP;
74 std::map<int, int> m_IDHEP;
75 std::map<int, std::pair<int, int>> m_JMOHEP;
76 std::map<int, std::pair<int, int>> m_JDAHEP;
77 std::map<int, double> m_PHEP0;
78 std::map<int, double> m_PHEP1;
79 std::map<int, double> m_PHEP2;
80 std::map<int, double> m_PHEP3;
81 std::map<int, double> m_PHEP4;
82 std::map<int, double> m_VHEP0;
83 std::map<int, double> m_VHEP1;
84 std::map<int, double> m_VHEP2;
85 std::map<int, double> m_VHEP3;
86};
87
88inline Gen_HEPEVT::Gen_HEPEVT( void ) : m_NEVHEP( 0 ), m_NHEP( 0 ) {}
89
90//
91// Get Methods
92//
93inline int Gen_HEPEVT::nevhep( void ) const { return m_NEVHEP; }
94
95inline int Gen_HEPEVT::nhep( void ) const { return m_NHEP; }
96
97inline int Gen_HEPEVT::isthep( int ihep ) { return m_ISTHEP[ihep]; }
98
99inline int Gen_HEPEVT::idhep( int ihep ) { return m_IDHEP[ihep]; }
100
101inline int Gen_HEPEVT::first_parent( int ihep ) { return m_JMOHEP[ihep].first; }
102
103inline int Gen_HEPEVT::last_parent( int ihep ) { return m_JMOHEP[ihep].second; }
104
105inline int Gen_HEPEVT::first_child( int ihep ) { return m_JDAHEP[ihep].first; }
106
107inline int Gen_HEPEVT::last_child( int ihep ) { return m_JDAHEP[ihep].second; }
108
109inline double Gen_HEPEVT::px( int ihep ) { return m_PHEP0[ihep]; }
110
111inline double Gen_HEPEVT::py( int ihep ) { return m_PHEP1[ihep]; }
112
113inline double Gen_HEPEVT::pz( int ihep ) { return m_PHEP2[ihep]; }
114
115inline double Gen_HEPEVT::e( int ihep ) { return m_PHEP3[ihep]; }
116
117inline double Gen_HEPEVT::m( int ihep ) { return m_PHEP4[ihep]; }
118
119inline double Gen_HEPEVT::x( int ihep ) { return m_VHEP0[ihep]; }
120
121inline double Gen_HEPEVT::y( int ihep ) { return m_VHEP1[ihep]; }
122
123inline double Gen_HEPEVT::z( int ihep ) { return m_VHEP2[ihep]; }
124
125inline double Gen_HEPEVT::t( int ihep ) { return m_VHEP3[ihep]; }
126
127//
128// Set Methods
129//
130inline void Gen_HEPEVT::nevhep( int value ) { m_NEVHEP = value; }
131
132inline void Gen_HEPEVT::nhep( int value ) { m_NHEP = value; }
133
134inline void Gen_HEPEVT::isthep( int& ihep, int value ) { m_ISTHEP[ihep] = value; }
135
136inline void Gen_HEPEVT::idhep( int& ihep, int value ) { m_IDHEP[ihep] = value; }
137
138inline void Gen_HEPEVT::mothers( int& ihep, int value1, int value2 ) {
139 m_JMOHEP[ihep] = std::make_pair( value1, value2 );
140}
141
142inline void Gen_HEPEVT::daughters( int& ihep, int value1, int value2 ) {
143 m_JDAHEP[ihep] = std::make_pair( value1, value2 );
144}
145
146inline void Gen_HEPEVT::momentum( int& ihep, double px, double py, double pz, double e,
147 double m ) {
148 m_PHEP0[ihep] = px;
149 m_PHEP1[ihep] = py;
150 m_PHEP2[ihep] = pz;
151 m_PHEP3[ihep] = e;
152 m_PHEP4[ihep] = m;
153}
154
155inline void Gen_HEPEVT::position( int& ihep, double x, double y, double z, double t ) {
156 m_VHEP0[ihep] = x;
157 m_VHEP1[ihep] = y;
158 m_VHEP2[ihep] = z;
159 m_VHEP3[ihep] = t;
160}
161
162CLASS_DEF( Gen_HEPEVT, 2221, 1 )
163
164#endif // GENERATORMODULES_GEN_HEPEVT_H
**********INTEGER nmxhep !maximum number of particles DOUBLE PRECISION vhep INTEGER idhep
**********INTEGER nmxhep !maximum number of particles DOUBLE PRECISION vhep INTEGER isthep
**********INTEGER nmxhep !maximum number of particles DOUBLE PRECISION vhep INTEGER jdahep COMMON hepevt $ !serial number $ !number of particles $ !status code $ !particle ident KF $ !parent particles $ !childreen particles $ !four momentum
CLASS_DEF(std::vector< std::string >, 10123, 1)
Double_t x[10]
void mothers(int &ihep, int value1, int value2)
void position(int &ihep, double x, double y, double z, double t)
void daughters(int &ihep, int value1, int value2)
void momentum(int &ihep, double px, double py, double pz, double e, double m)
int t()
Definition t.c:1