31 mRandomGaus.setRandomPosition(rng);
32 mRandomFlat.setRandomPosition(rng);
39 mVDrift = vdrift > 0 ? vdrift : mGasParam->
DriftV;
45 float driftl = mDetParam->
TPClength - std::abs(posEle.Z());
49 driftl = std::sqrt(driftl);
50 const float sigT = driftl * mGasParam->
DiffT;
51 const float sigL = driftl * mGasParam->
DiffL;
55 GlobalPosition3D posEleDiffusion((mRandomGaus.getNextValue() * sigT) + posEle.X(),
56 (mRandomGaus.getNextValue() * sigT) + posEle.Y(),
57 (mRandomGaus.getNextValue() * sigL) + posEle.Z());
63 if (posEle.Z() / posEleDiffusion.Z() < 0.f) {
65 posEleDiffusion.SetZ(posEle.Z());
71 return posEleDiffusion;
77 float driftl = mDetParam->
TPClength - std::abs(posEle.Z());
81 driftl = std::sqrt(driftl);
84 const float threeSigmaT = 3.f * driftl * mGasParam->
DiffT;
87 return mapper.isOutOfSector(posEle,
sector, threeSigmaT);
Simple interface to the CDB manager.
Definition of the electron transport.
configStandalone Light OpenGL display display_light Apply smoothing to points Enable Z buffer Highlight links Highlight seeds Highlight sector tracks Highlight final tracks Show individual sector
static const ParameterGas & Instance()
void setRandomRingPositions(TRandom &rng)
Move the random rings to new positions drawn from rng.
void updateParameters(float vdrift=0)
Update the OCDB parameters cached in the class. To be called once per event.
bool isCompletelyOutOfSectorCoarseElectronDrift(GlobalPosition3D posEle, const Sector §or) const
ElectronTransport(TRandom *rng=nullptr)
float getDriftTime(float zPos, float signChange=1.f) const
GlobalPosition3D getElectronDrift(GlobalPosition3D posEle, float &driftTime)
static Mapper & instance(const std::string mappingDir="")
Global TPC definitions and constants.
math_utils::Point3D< float > GlobalPosition3D
float TPClength
Length of the TPC [cm].
float DiffL
Longitudinal diffusion [sqrt(cm)].
float DiffT
Transverse diffusion [sqrt(cm)].
float DriftV
Drift velocity [cm/us].