ECCE @ EIC Software
Reference for
ECCE @ EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
doiPETRun.hh
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file doiPETRun.hh
1
//
2
// ********************************************************************
3
// * License and Disclaimer *
4
// * *
5
// * The Geant4 software is copyright of the Copyright Holders of *
6
// * the Geant4 Collaboration. It is provided under the terms and *
7
// * conditions of the Geant4 Software License, included in the file *
8
// * LICENSE and available at http://cern.ch/geant4/license . These *
9
// * include a list of copyright holders. *
10
// * *
11
// * Neither the authors of this software system, nor their employing *
12
// * institutes,nor the agencies providing financial support for this *
13
// * work make any representation or warranty, express or implied, *
14
// * regarding this software system or assume any liability for its *
15
// * use. Please see the license in the file LICENSE and URL above *
16
// * for the full disclaimer and the limitation of liability. *
17
// * *
18
// * This code implementation is the result of the scientific and *
19
// * technical work of the GEANT4 collaboration. *
20
// * By using, copying, modifying or distributing the software (or *
21
// * any work based on the software) you agree to acknowledge its *
22
// * use in resulting scientific publications, and indicate your *
23
// * acceptance of all terms of the Geant4 Software license. *
24
// ********************************************************************
25
//
28
//
29
//
30
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
31
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
32
33
#ifndef doiPETRun_h
34
#define doiPETRun_h 1
35
36
#include "
G4Run.hh
"
37
#include "
G4VProcess.hh
"
38
#include "
globals.hh
"
39
40
#include <iostream>
41
#include <fstream>
42
#include <sstream>
43
#include <map>
44
#include <set>
45
class
doiPETDetectorConstruction
;
46
class
G4ParticleDefinition
;
47
class
doiPETRunAction
;
48
49
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
50
class
InteractionInformation
;
51
class
doiPETAnalysis
;
52
class
doiPETRun
:
public
G4Run
53
{
54
public
:
55
doiPETRun
(
/*doiPETDetectorConstruction**/
);
56
~doiPETRun
();
57
58
public
:
59
//
60
void
GetIntractionInfomation
(
InteractionInformation
*);
61
void
FindInteractingCrystal
();
62
void
Clear
();
63
void
OpenRun
(
G4String
);
64
void
GetEventIDRun
(
G4int
);
65
void
CalulateAcquisitionTime
();
66
void
SetAnnihilationTime
(
G4double
);
67
void
SetEventID
(
G4int
);
68
virtual
void
Merge
(
const
G4Run
*);
69
// void EndOfRun();
70
71
private
:
72
73
std::multimap< G4int, InteractionInformation* >
mapBlockInteraction
;
74
std::set<G4int>
setBlockInteraction
;
75
std::ofstream
ofs
;
76
G4int
eventID
;
77
doiPETRunAction
*
fRunAction
;
78
doiPETAnalysis
*
fAnalysis
;
79
G4double
totalEdep
;
80
G4int
blockID
,
crystalID
;
81
82
//
83
G4double
activityNow
;
84
G4double
InitialActivity
;
85
G4double
halfLife
;
86
87
G4double
totalTime
;
88
G4double
prev_totalTime
;
89
G4double
timeInterval
;
90
91
G4ThreeVector
interactionPos
;
92
//
93
G4double
interactionTime
;
94
G4double
timeOfAnnihil
;
95
96
G4int
numberofInteractions
;
97
G4double
edep
;
98
G4double
edepMax
;
99
G4double
edep_AfterCrystalBlurring
;
100
101
};
102
103
104
//The following is to get interaction information
105
class
InteractionInformation
106
{
107
108
public
:
109
InteractionInformation
(){;};
110
~InteractionInformation
(){;};
111
112
//set energy deposition
113
void
SetEdep
(
G4double
e
) {
edep
=
e
;};
114
115
//set block number
116
void
SetBlockNo
(
G4int
n
) {
blockNo
=
n
;};
117
118
//set crystal ID (this is continuous numbering of crystals)
119
void
SetCrystalNo
(
G4int
n
) {
crystalNo
=
n
;};
120
121
//set global time
122
void
SetGlobalTime
(
G4double
t
){
globalTime
=
t
;};
123
124
//set interaction position with respect to the crystal axis (local position)
125
void
SetInteractionPositionInCrystal
(
G4ThreeVector
pos
){
crystalPosition
=
pos
;};
126
127
128
G4double
GetEdep
() {
return
edep
;};
129
G4int
GetBlockNo
() {
return
blockNo
;};
130
G4int
GetCrystalNo
() {
return
crystalNo
;};
131
G4double
GetGlobalTime
() {
return
globalTime
;};
132
133
//Interaction position in the detector
134
G4ThreeVector
GetInteractionPositionInCrystal
(){
return
crystalPosition
;};
135
136
137
private
:
138
G4double
edep
;
139
G4double
globalTime
;
140
G4int
blockNo
;
141
G4int
crystalNo
;
142
G4ThreeVector
crystalPosition
;
143
144
};
145
146
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
147
148
#endif
149
geant4
tree
geant4-10.6-release
examples
advanced
doiPET
include
doiPETRun.hh
Built by
Jin Huang
. updated:
Wed Jun 29 2022 17:24:57
using
1.8.2 with
ECCE GitHub integration