20 if(particle.
charge() == 0. || magneticFieldZ == 0.){
21 LogDebug(
"FastSim") <<
"create straight trajectory";
25 LogDebug(
"FastSim") <<
"create straight trajectory (huge radius)";
29 LogDebug(
"FastSim") <<
"create helix trajectory";
39 return this->
nextCrossingTimeC(static_cast<const fastsim::ForwardSimplifiedGeometry &>(layer), onLayer);
43 return this->
nextCrossingTimeC(static_cast<const fastsim::BarrelSimplifiedGeometry &>(layer), onLayer);
58 return deltaTimeC > 0. ? deltaTimeC : -1.;
Implementation of a forward detector layer (disk).
Implementation of a generic detector layer (base class for forward/barrel layers).
const math::XYZTLorentzVector & position() const
Return position of the particle.
double nextCrossingTimeC(const SimplifiedGeometry &layer, bool onLayer=false) const
Return delta time (t*c) of the next intersection of trajectory and generic layer. ...
static double constexpr speedOfLight
Speed of light [cm / ns].
virtual bool isForward() const =0
Returns false/true depending if the object is a (non-abstract) barrel/forward layer.
const double getZ() const
Return z-position of the forward layer.
math::XYZTLorentzVector position_
position of the particle that was used to create trajectory
Mathematical representation of a straight trajectory.
Abs< T >::type abs(const T &t)
Trajectory(const fastsim::Particle &particle)
Constructor of base class.
double charge() const
Return charge of the particle.
static std::unique_ptr< Trajectory > createTrajectory(const fastsim::Particle &particle, const double magneticFieldZ)
Calls constructor of derived classes.
const math::XYZTLorentzVector & momentum() const
Return momentum of the particle.
Mathematical representation of a helix.
Definition of a generic FastSim Particle which can be propagated through the detector (formerly Parti...
math::XYZTLorentzVector momentum_
momentum of the particle that was used to create trajectory