9#include <arich/simulation/SensitiveAero.h>
10#include <arich/dataobjects/ARICHAeroHit.h>
15#include <framework/datastore/StoreArray.h>
16#include <framework/datastore/RelationArray.h>
17#include <framework/gearbox/Unit.h>
19#include <Math/Vector3D.h>
31 Simulation::SensitiveDetectorBase(
"ARICH",
Const::ARICH)
52 G4Track* aTrack = aStep->GetTrack();
54 G4StepPoint* PostPosition = aStep->GetPostStepPoint();
55 G4ThreeVector worldPosition = PostPosition->GetPosition();
56 G4ParticleDefinition* particle = aTrack->GetDefinition();
57 G4double PDGCharge = particle->GetPDGCharge();
58 G4ThreeVector momentum = PostPosition->GetMomentum();
61 if (PDGCharge == 0)
return (
true);
65 if ((PostPosition->GetStepStatus() == fGeomBoundary) && (momentum.z() > 0.0)) {
76 int trackID = aTrack->GetTrackID();
77 int PDGEncoding = particle->GetPDGEncoding();
79 ROOT::Math::XYZVector TPosition(worldPosition.x() *
Unit::mm, worldPosition.y() *
Unit::mm, worldPosition.z() *
Unit::mm);
Datastore class that holds information on track parameters at the entrance in aerogel.
This class provides a set of constants for the framework.
Low-level class to create/modify relations between StoreArrays.
@ c_deleteElement
Delete the whole relation element if the original element got re-attributed.
void add(index_type from, index_type to, weight_type weight=1.0)
Add a new element to the relation.
int getArrayIndex() const
Returns this object's array index (in StoreArray), or -1 if not found.
static void registerMCParticleRelation(const std::string &name, RelationArray::EConsolidationAction ignoreAction=RelationArray::c_negativeWeight)
Register an relation involving MCParticles.
bool registerInDataStore(DataStore::EStoreFlags storeFlags=DataStore::c_WriteOut)
Register the object/array in the DataStore.
Accessor to arrays stored in the data store.
T * appendNew()
Construct a new T object at the end of the array.
bool registerRelationTo(const StoreArray< TO > &toArray, DataStore::EDurability durability=DataStore::c_Event, DataStore::EStoreFlags storeFlags=DataStore::c_WriteOut, const std::string &namedRelation="") const
Register a relation to the given StoreArray.
static const double mm
[millimeters]
static const double MeV
[megaelectronvolt]
bool step(G4Step *aStep, G4TouchableHistory *) override
Process each step and calculate variables defined in PXDSimHit.
SensitiveAero()
Constructor.
Abstract base class for different kinds of events.