CbmRoot
Loading...
Searching...
No Matches
CbmMCEvent.h
Go to the documentation of this file.
1
/* Copyright (C) 2009-2020 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2
SPDX-License-Identifier: GPL-3.0-only
3
Authors: Volker Friese [committer] */
4
5
#
13
#ifndef CBMMCEVENT_H
14
#define CBMMCEVENT_H 1
15
16
#include <Rtypes.h>
17
#include <RtypesCore.h>
18
#include <TNamed.h>
19
#include <TVector3.h>
20
21
#include <cstdint>
22
23
24
class
CbmMCEvent
:
public
TNamed {
25
26
public
:
28
CbmMCEvent
();
29
30
41
CbmMCEvent
(uint32_t runId, int32_t iEvent,
double
x
,
double
y
,
double
z,
double
t,
double
b,
double
phi,
42
int32_t nPrim);
43
44
46
CbmMCEvent
(uint32_t runId);
47
48
50
virtual
~CbmMCEvent
();
51
52
54
uint32_t
GetRunID
()
const
{
return
fRunId
; }
// run identifier
55
int32_t
GetEventID
()
const
{
return
fEventId
; }
// event identifier
56
double
GetX
()
const
{
return
fX
; }
// vertex x [cm]
57
double
GetY
()
const
{
return
fY
; }
// vertex y [cm]
58
double
GetZ
()
const
{
return
fZ
; }
// vertex z [cm]
59
double
GetT
()
const
{
return
fT
; }
// event time [ns]
60
double
GetB
()
const
{
return
fB
; }
// impact parameter [fm]
61
double
GetPhi
()
const
{
return
fPhi
; }
// event plane angle [rad]
62
int32_t
GetNPrim
()
const
{
return
fNPrim
; }
// number of input tracks
63
bool
IsSet
()
const
{
return
fIsSet
; }
// Flag
64
void
GetVertex
(TVector3& vertex) { vertex.SetXYZ(
fX
,
fY
,
fZ
); }
65
66
68
void
SetEventID
(int32_t eventId) {
fEventId
= eventId; }
69
void
SetTime
(
double
t) {
fT
= t; }
70
void
SetB
(
double
b) {
fB
= b; }
71
void
SetPhi
(
double
phi) {
fPhi
= phi; }
72
void
SetNPrim
(int32_t nPrim) {
fNPrim
= nPrim; }
73
void
MarkSet
(
bool
isSet) {
fIsSet
= isSet; }
74
void
SetVertex
(
double
x
,
double
y
,
double
z);
75
void
SetVertex
(
const
TVector3& vertex);
76
77
79
void
Reset
();
80
81
82
private
:
83
uint32_t
fRunId
;
// Run identifier
84
uint32_t
fEventId
;
// Event identifier
85
Double32_t
fX
;
// Primary vertex x [cm]
86
Double32_t
fY
;
// Primary vertex y [cm]
87
Double32_t
fZ
;
// Primary vertex z [cm]
88
Double32_t
fT
;
// Event time [s]
89
Double32_t
fB
;
// Impact parameter [fm] (if relevant)
90
Double32_t
fPhi
;
// Event plane angle [rad] (if relevant)
91
int32_t
fNPrim
;
// Number of input tracks
92
bool
fIsSet
;
// Flag whether variables are filled
93
94
95
ClassDef
(
CbmMCEvent
, 1);
96
};
97
98
99
inline
void
CbmMCEvent::SetVertex
(
double
x
,
double
y
,
double
z)
100
{
101
fX
=
x
;
102
fY
=
y
;
103
fZ
= z;
104
}
105
106
107
inline
void
CbmMCEvent::SetVertex
(
const
TVector3& vertex)
108
{
109
fX
= vertex.X();
110
fY
= vertex.Y();
111
fZ
= vertex.Z();
112
}
113
114
115
#endif
y
Double_t y
Definition
CbmMvdSensorDigiToHitTask.cxx:64
x
Double_t x
Definition
CbmMvdSensorDigiToHitTask.cxx:64
CbmMCEvent
Definition
CbmMCEvent.h:24
CbmMCEvent::fEventId
uint32_t fEventId
Definition
CbmMCEvent.h:84
CbmMCEvent::CbmMCEvent
CbmMCEvent()
Definition
CbmMCEvent.cxx:17
CbmMCEvent::fNPrim
int32_t fNPrim
Definition
CbmMCEvent.h:91
CbmMCEvent::GetB
double GetB() const
Definition
CbmMCEvent.h:60
CbmMCEvent::SetB
void SetB(double b)
Definition
CbmMCEvent.h:70
CbmMCEvent::GetY
double GetY() const
Definition
CbmMCEvent.h:57
CbmMCEvent::SetEventID
void SetEventID(int32_t eventId)
Definition
CbmMCEvent.h:68
CbmMCEvent::ClassDef
ClassDef(CbmMCEvent, 1)
CbmMCEvent::SetPhi
void SetPhi(double phi)
Definition
CbmMCEvent.h:71
CbmMCEvent::GetZ
double GetZ() const
Definition
CbmMCEvent.h:58
CbmMCEvent::IsSet
bool IsSet() const
Definition
CbmMCEvent.h:63
CbmMCEvent::fZ
Double32_t fZ
Definition
CbmMCEvent.h:87
CbmMCEvent::fT
Double32_t fT
Definition
CbmMCEvent.h:88
CbmMCEvent::GetVertex
void GetVertex(TVector3 &vertex)
Definition
CbmMCEvent.h:64
CbmMCEvent::SetVertex
void SetVertex(double x, double y, double z)
Definition
CbmMCEvent.h:99
CbmMCEvent::~CbmMCEvent
virtual ~CbmMCEvent()
Definition
CbmMCEvent.cxx:75
CbmMCEvent::Reset
void Reset()
Definition
CbmMCEvent.cxx:80
CbmMCEvent::fB
Double32_t fB
Definition
CbmMCEvent.h:89
CbmMCEvent::GetNPrim
int32_t GetNPrim() const
Definition
CbmMCEvent.h:62
CbmMCEvent::fPhi
Double32_t fPhi
Definition
CbmMCEvent.h:90
CbmMCEvent::MarkSet
void MarkSet(bool isSet)
Definition
CbmMCEvent.h:73
CbmMCEvent::fIsSet
bool fIsSet
Definition
CbmMCEvent.h:92
CbmMCEvent::GetPhi
double GetPhi() const
Definition
CbmMCEvent.h:61
CbmMCEvent::SetTime
void SetTime(double t)
Definition
CbmMCEvent.h:69
CbmMCEvent::GetEventID
int32_t GetEventID() const
Definition
CbmMCEvent.h:55
CbmMCEvent::fX
Double32_t fX
Definition
CbmMCEvent.h:85
CbmMCEvent::fRunId
uint32_t fRunId
Definition
CbmMCEvent.h:83
CbmMCEvent::GetX
double GetX() const
Definition
CbmMCEvent.h:56
CbmMCEvent::SetNPrim
void SetNPrim(int32_t nPrim)
Definition
CbmMCEvent.h:72
CbmMCEvent::GetRunID
uint32_t GetRunID() const
Definition
CbmMCEvent.h:54
CbmMCEvent::fY
Double32_t fY
Definition
CbmMCEvent.h:86
CbmMCEvent::GetT
double GetT() const
Definition
CbmMCEvent.h:59
core
data
CbmMCEvent.h
Generated on Sun Dec 22 2024 23:04:08 for CbmRoot by
1.12.0