#include <BeamHaloPropagator.h>
Public Member Functions | |
BeamHaloPropagator (Propagator *aEndCapTkProp, Propagator *aCrossTkProp, const MagneticField *field, PropagationDirection dir=alongMomentum) | |
Defines which propagator is used inside endcap and in barrel. | |
BeamHaloPropagator (const Propagator &aEndCapTkProp, const Propagator &aCrossTkProp, const MagneticField *field, PropagationDirection dir=alongMomentum) | |
Defines which propagator is used inside endcap and in barrel. | |
BeamHaloPropagator (const BeamHaloPropagator &) | |
Copy constructor. | |
virtual BeamHaloPropagator * | clone () const |
Virtual constructor (using copy c'tor) | |
bool | crossingTk (const FreeTrajectoryState &fts, const Plane &plane) const |
true if the plane and the fts z position have different sign | |
Propagator * | getCrossTkPropagator () const |
return the propagator used to cross the tracker | |
Propagator * | getEndCapTkPropagator () const |
return the propagator used in endcaps | |
virtual const MagneticField * | magneticField () const |
return the magneticField | |
TrajectoryStateOnSurface | propagate (const TrajectoryStateOnSurface &tsos, const Plane &plane) const |
TrajectoryStateOnSurface | propagate (const TrajectoryStateOnSurface &tsos, const Surface &surface) const |
TrajectoryStateOnSurface | propagate (const FreeTrajectoryState &fts, const Plane &plane) const |
TrajectoryStateOnSurface | propagate (const FreeTrajectoryState &fts, const Cylinder &cylinder) const |
TrajectoryStateOnSurface | propagate (const TrajectoryStateOnSurface &tsos, const Cylinder &cylinder) const |
TrajectoryStateOnSurface | propagate (const FreeTrajectoryState &fts, const Surface &surface) const |
std::pair < TrajectoryStateOnSurface, double > | propagateWithPath (const FreeTrajectoryState &fts, const Surface &surface) const |
std::pair < TrajectoryStateOnSurface, double > | propagateWithPath (const FreeTrajectoryState &fts, const Plane &plane) const |
std::pair < TrajectoryStateOnSurface, double > | propagateWithPath (const TrajectoryStateOnSurface &tsos, const Cylinder &cylinder) const |
std::pair < TrajectoryStateOnSurface, double > | propagateWithPath (const TrajectoryStateOnSurface &tsos, const Plane &plane) const |
std::pair < TrajectoryStateOnSurface, double > | propagateWithPath (const TrajectoryStateOnSurface &tsos, const Surface &surface) const |
std::pair < TrajectoryStateOnSurface, double > | propagateWithPath (const FreeTrajectoryState &fts, const Cylinder &cylinder) const |
void | setPropagationDirection (PropagationDirection dir) const |
virtual | ~BeamHaloPropagator () |
Private Member Functions | |
void | directionCheck (PropagationDirection dir) const |
Private Attributes | |
Propagator * | theCrossTkProp |
Propagator * | theEndCapTkProp |
const MagneticField * | theField |
A propagator which use different algorithm to propagate within an endcap or to cross over to the other endcap
Definition at line 24 of file BeamHaloPropagator.h.
BeamHaloPropagator::BeamHaloPropagator | ( | Propagator * | aEndCapTkProp, |
Propagator * | aCrossTkProp, | ||
const MagneticField * | field, | ||
PropagationDirection | dir = alongMomentum |
||
) |
Defines which propagator is used inside endcap and in barrel.
Definition at line 53 of file BeamHaloPropagator.cc.
References directionCheck().
Referenced by clone().
: Propagator(dir), theEndCapTkProp(aEndCapTkProp->clone()), theCrossTkProp(aCrossTkProp->clone()), theField(field) { directionCheck(dir); }
BeamHaloPropagator::BeamHaloPropagator | ( | const Propagator & | aEndCapTkProp, |
const Propagator & | aCrossTkProp, | ||
const MagneticField * | field, | ||
PropagationDirection | dir = alongMomentum |
||
) |
Defines which propagator is used inside endcap and in barrel.
Definition at line 60 of file BeamHaloPropagator.cc.
References directionCheck().
: Propagator(dir), theEndCapTkProp(aEndCapTkProp.clone()), theCrossTkProp(aCrossTkProp.clone()), theField(field) { directionCheck(dir); }
BeamHaloPropagator::BeamHaloPropagator | ( | const BeamHaloPropagator & | aProp | ) |
Copy constructor.
Definition at line 67 of file BeamHaloPropagator.cc.
References Propagator::clone(), getCrossTkPropagator(), getEndCapTkPropagator(), theCrossTkProp, and theEndCapTkProp.
: Propagator(aProp.propagationDirection()), theEndCapTkProp(0), theCrossTkProp(0) { if (aProp.theEndCapTkProp) theEndCapTkProp=aProp.getEndCapTkPropagator()->clone(); if (aProp.theCrossTkProp) theCrossTkProp=aProp.getCrossTkPropagator()->clone(); }
BeamHaloPropagator::~BeamHaloPropagator | ( | ) | [virtual] |
virtual destructor
Definition at line 76 of file BeamHaloPropagator.cc.
References theCrossTkProp, and theEndCapTkProp.
{ delete theEndCapTkProp; delete theCrossTkProp; }
virtual BeamHaloPropagator* BeamHaloPropagator::clone | ( | void | ) | const [inline, virtual] |
Virtual constructor (using copy c'tor)
Implements Propagator.
Definition at line 45 of file BeamHaloPropagator.h.
References BeamHaloPropagator(), getCrossTkPropagator(), getEndCapTkPropagator(), magneticField(), and Propagator::propagationDirection().
{ return new BeamHaloPropagator(getEndCapTkPropagator(),getCrossTkPropagator(),magneticField(),propagationDirection()); }
bool BeamHaloPropagator::crossingTk | ( | const FreeTrajectoryState & | fts, |
const Plane & | plane | ||
) | const |
true if the plane and the fts z position have different sign
Definition at line 83 of file BeamHaloPropagator.cc.
References LogDebug, GloballyPositioned< T >::position(), FreeTrajectoryState::position(), and PV3DBase< T, PVType, FrameType >::z().
Referenced by propagate(), and propagateWithPath().
void BeamHaloPropagator::directionCheck | ( | PropagationDirection | dir | ) | const [private] |
Definition at line 34 of file BeamHaloPropagator.cc.
References anyDirection, dir, getCrossTkPropagator(), getEndCapTkPropagator(), Propagator::propagationDirection(), and Propagator::setPropagationDirection().
Referenced by BeamHaloPropagator().
{ //consistency check for direction if (getEndCapTkPropagator()->propagationDirection()!=dir && getEndCapTkPropagator()->propagationDirection()!=anyDirection){ edm::LogError("BeamHaloPropagator")<<"composite propagator set with inconsistent direction components\n" <<"EndCap propagator is: "<<getEndCapTkPropagator()->propagationDirection() <<"\n to be set on: "<<dir; getEndCapTkPropagator()->setPropagationDirection(dir); } if (getCrossTkPropagator()->propagationDirection()!=dir && getCrossTkPropagator()->propagationDirection()!=anyDirection){ edm::LogError("BeamHaloPropagator")<<"composite propagator set with inconsistent direction components\n" <<"Cross propagator is: "<<getCrossTkPropagator()->propagationDirection() <<"\n to be set on: "<<dir; getCrossTkPropagator()->setPropagationDirection(dir); } }
Propagator * BeamHaloPropagator::getCrossTkPropagator | ( | ) | const |
return the propagator used to cross the tracker
Definition at line 130 of file BeamHaloPropagator.cc.
References LogDebug, and theCrossTkProp.
Referenced by BeamHaloPropagator(), clone(), directionCheck(), propagate(), propagateWithPath(), and setPropagationDirection().
{ LogDebug("BeamHaloPropagator")<<"using the Crossing propagator"; return theCrossTkProp;}
Propagator * BeamHaloPropagator::getEndCapTkPropagator | ( | ) | const |
return the propagator used in endcaps
Definition at line 125 of file BeamHaloPropagator.cc.
References LogDebug, and theEndCapTkProp.
Referenced by BeamHaloPropagator(), clone(), directionCheck(), propagate(), propagateWithPath(), and setPropagationDirection().
{ LogDebug("BeamHaloPropagator")<<"using the EndCap propagator"; return theEndCapTkProp;}
virtual const MagneticField* BeamHaloPropagator::magneticField | ( | ) | const [inline, virtual] |
return the magneticField
Implements Propagator.
Definition at line 124 of file BeamHaloPropagator.h.
References theField.
Referenced by clone().
{return theField;}
TrajectoryStateOnSurface BeamHaloPropagator::propagate | ( | const TrajectoryStateOnSurface & | tsos, |
const Cylinder & | cylinder | ||
) | const [inline, virtual] |
Reimplemented from Propagator.
Definition at line 79 of file BeamHaloPropagator.h.
References propagate().
{ return Propagator::propagate(tsos, cylinder); }
TrajectoryStateOnSurface BeamHaloPropagator::propagate | ( | const TrajectoryStateOnSurface & | state, |
const Surface & | sur | ||
) | const [inline, virtual] |
The following three methods are equivalent to the corresponding methods above, but if the starting state is a TrajectoryStateOnSurface, it's better to use it as such rather than use just the FreeTrajectoryState part. It may help some concrete propagators. Only use the generic method if the surface type (plane or cylinder) is not known at the calling point.
Reimplemented from Propagator.
Definition at line 63 of file BeamHaloPropagator.h.
References propagate().
{ return Propagator::propagate(tsos,surface); }
TrajectoryStateOnSurface BeamHaloPropagator::propagate | ( | const FreeTrajectoryState & | fts, |
const Plane & | plane | ||
) | const [virtual] |
Implements Propagator.
Definition at line 94 of file BeamHaloPropagator.cc.
References crossingTk(), getCrossTkPropagator(), getEndCapTkPropagator(), and Propagator::propagate().
{ if (crossingTk(fts,plane)){ return getCrossTkPropagator()->propagate(fts, plane);} else{ return getEndCapTkPropagator()->propagate(fts, plane);} }
TrajectoryStateOnSurface BeamHaloPropagator::propagate | ( | const FreeTrajectoryState & | fts, |
const Cylinder & | cylinder | ||
) | const [virtual] |
Implements Propagator.
Definition at line 104 of file BeamHaloPropagator.cc.
References getCrossTkPropagator(), and Propagator::propagate().
{ return getCrossTkPropagator()->propagate(fts, cylinder); }
TrajectoryStateOnSurface BeamHaloPropagator::propagate | ( | const TrajectoryStateOnSurface & | tsos, |
const Plane & | plane | ||
) | const [inline, virtual] |
Reimplemented from Propagator.
Definition at line 71 of file BeamHaloPropagator.h.
References propagate().
{ return Propagator::propagate(tsos, plane); }
TrajectoryStateOnSurface BeamHaloPropagator::propagate | ( | const FreeTrajectoryState & | state, |
const Surface & | sur | ||
) | const [virtual] |
Propagate from a free state (e.g. position and momentum in in global cartesian coordinates) to a surface. Only use the generic method if the surface type (plane or cylinder) is not known at the calling point.
Reimplemented from Propagator.
Definition at line 88 of file BeamHaloPropagator.cc.
Referenced by propagate().
{ return Propagator::propagate( fts, surface); }
std::pair<TrajectoryStateOnSurface,double> BeamHaloPropagator::propagateWithPath | ( | const TrajectoryStateOnSurface & | tsos, |
const Plane & | plane | ||
) | const [inline, virtual] |
Reimplemented from Propagator.
Definition at line 101 of file BeamHaloPropagator.h.
References propagateWithPath().
{ return Propagator::propagateWithPath(tsos, plane); }
std::pair<TrajectoryStateOnSurface,double> BeamHaloPropagator::propagateWithPath | ( | const TrajectoryStateOnSurface & | state, |
const Surface & | sur | ||
) | const [inline, virtual] |
The following three methods are equivalent to the corresponding methods above, but if the starting state is a TrajectoryStateOnSurface, it's better to use it as such rather than use just the FreeTrajectoryState part. It may help some concrete propagators. Only use the generic method if the surface type (plane or cylinder) is not known at the calling point.
Reimplemented from Propagator.
Definition at line 91 of file BeamHaloPropagator.h.
References propagateWithPath().
{ return Propagator::propagateWithPath(tsos,surface); }
std::pair< TrajectoryStateOnSurface, double > BeamHaloPropagator::propagateWithPath | ( | const FreeTrajectoryState & | fts, |
const Plane & | plane | ||
) | const [virtual] |
Implements Propagator.
Definition at line 110 of file BeamHaloPropagator.cc.
References crossingTk(), getCrossTkPropagator(), getEndCapTkPropagator(), and Propagator::propagateWithPath().
{ if (crossingTk(fts,plane)){ return getCrossTkPropagator()->propagateWithPath(fts, plane);} else{ return getEndCapTkPropagator()->propagateWithPath(fts, plane);} }
std::pair< TrajectoryStateOnSurface, double > BeamHaloPropagator::propagateWithPath | ( | const FreeTrajectoryState & | fts, |
const Cylinder & | cylinder | ||
) | const [virtual] |
Implements Propagator.
Definition at line 120 of file BeamHaloPropagator.cc.
References getCrossTkPropagator(), and Propagator::propagateWithPath().
{ return getCrossTkPropagator()->propagateWithPath(fts, cylinder);}
std::pair<TrajectoryStateOnSurface,double> BeamHaloPropagator::propagateWithPath | ( | const TrajectoryStateOnSurface & | tsos, |
const Cylinder & | cylinder | ||
) | const [inline, virtual] |
Reimplemented from Propagator.
Definition at line 111 of file BeamHaloPropagator.h.
References propagateWithPath().
{ return Propagator::propagateWithPath(tsos, cylinder); }
std::pair<TrajectoryStateOnSurface,double> BeamHaloPropagator::propagateWithPath | ( | const FreeTrajectoryState & | state, |
const Surface & | sur | ||
) | const [inline, virtual] |
The methods propagateWithPath() are identical to the corresponding methods propagate() in what concerns the resulting TrajectoryStateOnSurface, but they provide in addition the exact path length along the trajectory. Only use the generic method if the surface type (plane or cylinder) is not known at the calling point.
Reimplemented from Propagator.
Definition at line 85 of file BeamHaloPropagator.h.
Referenced by propagateWithPath().
{ return Propagator::propagateWithPath(fts,surface); }
void BeamHaloPropagator::setPropagationDirection | ( | PropagationDirection | dir | ) | const [inline, virtual] |
The propagation direction can now be set for every propagator. There is no more distinction between unidirectional and bidirectional at class level. The value "anyDiriction" for PropagationDirection provides the functionality of the ex-BidirectionalPropagator. The values "alongMomentum" and "oppositeToMomentum" provide the functionality of the ex-UnidirectionalPropagator.
Reimplemented from Propagator.
Definition at line 50 of file BeamHaloPropagator.h.
References getCrossTkPropagator(), getEndCapTkPropagator(), and Propagator::setPropagationDirection().
Propagator* BeamHaloPropagator::theCrossTkProp [mutable, private] |
Definition at line 130 of file BeamHaloPropagator.h.
Referenced by BeamHaloPropagator(), getCrossTkPropagator(), and ~BeamHaloPropagator().
Propagator* BeamHaloPropagator::theEndCapTkProp [mutable, private] |
Definition at line 129 of file BeamHaloPropagator.h.
Referenced by BeamHaloPropagator(), getEndCapTkPropagator(), and ~BeamHaloPropagator().
const MagneticField* BeamHaloPropagator::theField [private] |
Definition at line 131 of file BeamHaloPropagator.h.
Referenced by magneticField().