CMS 3D CMS Logo

PPSDiamondSD.h
Go to the documentation of this file.
1 //Author: Seyed Mohsen Etesami
3 // setesami@cern.ch
4 // 2016 Nov
6 
7 #ifndef PPS_PPSDiamondSD_h
8 #define PPS_PPSDiamondSD_h
9 
15 
20 
21 #include <string>
22 
23 class G4Step;
24 class G4HCofThisEvent;
25 class TrackingSlaveSD;
26 class SimTrackManager;
27 
29  public Observer<const BeginOfEvent*>,
30  public Observer<const EndOfEvent*> {
31 public:
33  const edm::EventSetup&,
35  edm::ParameterSet const&,
36  const SimTrackManager*);
37  ~PPSDiamondSD() override;
38  void printHitInfo();
39 
40  void Initialize(G4HCofThisEvent* HCE) override;
41  void EndOfEvent(G4HCofThisEvent* eventHC) override;
42  void clear() override;
43  void clearTrack(G4Track* Track);
44  void DrawAll() override;
45  void PrintAll() override;
46  void fillHits(edm::PSimHitContainer&, const std::string&) override;
47 
48 private:
49  static constexpr unsigned int maxDiamondHits_ = 15000;
50 
51  void clearHits() override;
52  bool ProcessHits(G4Step* step, G4TouchableHistory* tHistory) override;
53  uint32_t setDetUnitId(const G4Step* step) override;
54  void update(const BeginOfEvent*) override;
55  void update(const ::EndOfEvent*) override;
57 
58  std::unique_ptr<TrackingSlaveSD> slave_;
59  std::unique_ptr<PPSVDetectorOrganization> numberingScheme_;
60 
63 
64  G4ThreeVector setToLocal(const G4ThreeVector& globalPoint);
65  void stepInfo(const G4Step* aStep);
66  G4bool hitExists();
67  void importInfoToHit(); //added pps
68  void updateHit();
70  void resetForNewPrimary();
71  void summarize();
72  bool isPrimary(const G4Track* track);
73 
74  G4ThreeVector entrancePoint_;
76  G4String name_;
77  G4int hcID_;
80  G4Track* theTrack_;
81  G4VPhysicalVolume* currentPV_;
82  unsigned int unitID_;
84  G4double tSlice_;
85 
86  G4StepPoint* preStepPoint_;
87  G4StepPoint* postStepPoint_;
88  G4ThreeVector hitPoint_;
89  G4ThreeVector exitPoint_;
90  G4ThreeVector theLocalEntryPoint_;
91  G4ThreeVector theLocalExitPoint_;
92  double Pabs_;
93  double thePx_, thePy_, thePz_;
94  double Tof_;
95  double Eloss_;
97  double ThetaAtEntry_;
98  double PhiAtEntry_;
99  int ParentId_;
100  double Vx_, Vy_, Vz_;
103  int eventno_;
104 };
105 
106 #endif // PPS_PPSDiamondSD_h
PPSDiamondSD::storeHit
void storeHit(PPSDiamondG4Hit *)
Definition: PPSDiamondSD.cc:192
PPSDiamondSD
Definition: PPSDiamondSD.h:28
SimTrackManager
Definition: SimTrackManager.h:35
PPSDiamondSD::incidentEnergy_
double incidentEnergy_
Definition: PPSDiamondSD.h:75
PPSDiamondSD::theTrack_
G4Track * theTrack_
Definition: PPSDiamondSD.h:80
PPSDiamondG4HitCollection
G4THitsCollection< PPSDiamondG4Hit > PPSDiamondG4HitCollection
Definition: PPSDiamondG4HitCollection.h:12
Observer
Definition: Observer.h:23
step
step
Definition: StallMonitor.cc:94
PPSDiamondSD::stepInfo
void stepInfo(const G4Step *aStep)
Definition: PPSDiamondSD.cc:140
SensitiveTkDetector
Definition: SensitiveTkDetector.h:8
PPSDiamondSD::maxDiamondHits_
static constexpr unsigned int maxDiamondHits_
Definition: PPSDiamondSD.h:49
PPSDiamondSD::ParentId_
int ParentId_
Definition: PPSDiamondSD.h:99
PPSDiamondSD::hcID_
G4int hcID_
Definition: PPSDiamondSD.h:77
PPSDiamondSD::fillHits
void fillHits(edm::PSimHitContainer &, const std::string &) override
Definition: PPSDiamondSD.cc:272
PPSDiamondSD::Eloss_
double Eloss_
Definition: PPSDiamondSD.h:95
PPSDiamondSD::clearTrack
void clearTrack(G4Track *Track)
Definition: PPSDiamondSD.cc:291
PPSDiamondSD::clear
void clear() override
Definition: PPSDiamondSD.cc:263
PPSDiamondSD::PhiAtEntry_
double PhiAtEntry_
Definition: PPSDiamondSD.h:98
EndOfEvent.h
PPSDiamondG4HitCollection.h
PPSDiamondSD::thePz_
double thePz_
Definition: PPSDiamondSD.h:93
PPSDiamondSD::thePy_
double thePy_
Definition: PPSDiamondSD.h:93
PPSDiamondSD::Globaltimehit_
double Globaltimehit_
Definition: PPSDiamondSD.h:101
PPSDiamondSD::theLocalExitPoint_
G4ThreeVector theLocalExitPoint_
Definition: PPSDiamondSD.h:91
PPSDiamondSD::theMPDebug_
int theMPDebug_
Definition: PPSDiamondSD.h:62
PPSDiamondSD::DrawAll
void DrawAll() override
Definition: PPSDiamondSD.cc:265
Observer.h
SensitiveTkDetector.h
PPSDiamondSD::theLocalEntryPoint_
G4ThreeVector theLocalEntryPoint_
Definition: PPSDiamondSD.h:90
PPSDiamondSD::printHitInfo
void printHitInfo()
Definition: PPSDiamondSD.cc:79
PPSDiamondSD::resetForNewPrimary
void resetForNewPrimary()
PPSDiamondSD::ProcessHits
bool ProcessHits(G4Step *step, G4TouchableHistory *tHistory) override
Definition: PPSDiamondSD.cc:117
PPSDiamondSD::currentHit_
PPSDiamondG4Hit * currentHit_
Definition: PPSDiamondSD.h:79
PPSDiamondSD::eventno_
int eventno_
Definition: PPSDiamondSD.h:103
PPSDiamondSD::EndOfEvent
void EndOfEvent(G4HCofThisEvent *eventHC) override
Definition: PPSDiamondSD.cc:240
PPSDiamondSD::setToLocal
G4ThreeVector setToLocal(const G4ThreeVector &globalPoint)
Definition: PPSDiamondSD.cc:232
PPSDiamondSD::tSliceID_
G4int tSliceID_
Definition: PPSDiamondSD.h:83
PPSDiamondSD::exitPoint_
G4ThreeVector exitPoint_
Definition: PPSDiamondSD.h:89
PPSDiamondSD::setNumberingScheme
void setNumberingScheme(PPSVDetectorOrganization *scheme)
Definition: PPSDiamondSD.cc:276
PPSDiamondSD::Vz_
double Vz_
Definition: PPSDiamondSD.h:100
PPSDiamondSD::numberingScheme_
std::unique_ptr< PPSVDetectorOrganization > numberingScheme_
Definition: PPSDiamondSD.h:59
PPSDiamondG4Hit.h
PPSVDetectorOrganization.h
PPSDiamondSD::primaryID_
G4int primaryID_
Definition: PPSDiamondSD.h:83
PPSVDetectorOrganization
Definition: PPSVDetectorOrganization.h:10
SensitiveDetectorCatalog
Definition: SensitiveDetectorCatalog.h:10
PPSDiamondSD::preStepPoint_
G4StepPoint * preStepPoint_
Definition: PPSDiamondSD.h:86
PPSDiamondSD::theHC_
PPSDiamondG4HitCollection * theHC_
Definition: PPSDiamondSD.h:78
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
PPSDiamondSD::unitID_
unsigned int unitID_
Definition: PPSDiamondSD.h:82
PPSDiamondSD::Tof_
double Tof_
Definition: PPSDiamondSD.h:94
edm::ParameterSet
Definition: ParameterSet.h:36
PPSDiamondSD::Vx_
double Vx_
Definition: PPSDiamondSD.h:100
PPSDiamondSD::PrintAll
void PrintAll() override
Definition: PPSDiamondSD.cc:267
PPSDiamondG4Hit
Definition: PPSDiamondG4Hit.h:13
PPSDiamondSD::update
void update(const BeginOfEvent *) override
This routine will be called when the appropriate signal arrives.
Definition: PPSDiamondSD.cc:282
PPSDiamondSD::isPrimary
bool isPrimary(const G4Track *track)
Definition: PPSDiamondSD.cc:295
PPSDiamondSD::Pabs_
double Pabs_
Definition: PPSDiamondSD.h:92
BeginOfEvent.h
PPSDiamondSD::currentPV_
G4VPhysicalVolume * currentPV_
Definition: PPSDiamondSD.h:81
PPSDiamondSD::Vy_
double Vy_
Definition: PPSDiamondSD.h:100
PPSDiamondNumberingScheme.h
PPSDiamondSD::entrancePoint_
G4ThreeVector entrancePoint_
Definition: PPSDiamondSD.h:74
TrackingSlaveSD
Definition: TrackingSlaveSD.h:11
PPSDiamondSD::verbosity_
int verbosity_
Definition: PPSDiamondSD.h:61
BeginOfEvent
Definition: BeginOfEvent.h:6
PPSDiamondOrganization.h
edm::EventSetup
Definition: EventSetup.h:57
PPSDiamondSD::PPSDiamondSD
PPSDiamondSD(const std::string &, const edm::EventSetup &, const SensitiveDetectorCatalog &, edm::ParameterSet const &, const SimTrackManager *)
Definition: PPSDiamondSD.cc:28
PPSDiamondSD::ParticleType_
short ParticleType_
Definition: PPSDiamondSD.h:96
PPSDiamondSD::name_
G4String name_
Definition: PPSDiamondSD.h:76
generator_cfi.scheme
scheme
Definition: generator_cfi.py:22
PPSDiamondSD::~PPSDiamondSD
~PPSDiamondSD() override
Definition: PPSDiamondSD.cc:67
PPSDiamondSD::hitPoint_
G4ThreeVector hitPoint_
Definition: PPSDiamondSD.h:88
PPSDiamondSD::theglobaltimehit_
double theglobaltimehit_
Definition: PPSDiamondSD.h:102
PPSDiamondSD::thePx_
double thePx_
Definition: PPSDiamondSD.h:93
PPSDiamondSD::slave_
std::unique_ptr< TrackingSlaveSD > slave_
Definition: PPSDiamondSD.h:58
PPSDiamondSD::summarize
void summarize()
Definition: PPSDiamondSD.cc:261
HLT_2018_cff.track
track
Definition: HLT_2018_cff.py:10352
edm::PSimHitContainer
std::vector< PSimHit > PSimHitContainer
Definition: PSimHitContainer.h:11
PPSDiamondSD::postStepPoint_
G4StepPoint * postStepPoint_
Definition: PPSDiamondSD.h:87
PPSDiamondSD::Initialize
void Initialize(G4HCofThisEvent *HCE) override
Definition: PPSDiamondSD.cc:69
PPSDiamondSD::ThetaAtEntry_
double ThetaAtEntry_
Definition: PPSDiamondSD.h:97
PPSDiamondSD::setDetUnitId
uint32_t setDetUnitId(const G4Step *step) override
Definition: PPSDiamondSD.cc:188
PPSDiamondSD::updateHit
void updateHit()
PPSDiamondSD::hitExists
G4bool hitExists()
PPSDiamondSD::tSlice_
G4double tSlice_
Definition: PPSDiamondSD.h:84
PPSDiamondSD::importInfoToHit
void importInfoToHit()
Definition: PPSDiamondSD.cc:203
PPSDiamondSD::clearHits
void clearHits() override
Definition: PPSDiamondSD.cc:293