CMS 3D CMS Logo

BeamHaloPropagator Class Reference

A propagator which use different algorithm to propagate within an endcap or to cross over to the other endcap. More...

#include <TrackingTools/GeomPropagators/interface/BeamHaloPropagator.h>

Inheritance diagram for BeamHaloPropagator:

Propagator

List of all members.

Public Member Functions

 BeamHaloPropagator (const BeamHaloPropagator &)
 Copy constructor.
 BeamHaloPropagator (const Propagator &aEndCapTkProp, const Propagator &aCrossTkProp, const MagneticField *field, PropagationDirection dir=alongMomentum)
 Defines which propagator is used inside endcap and in barrel.
 BeamHaloPropagator (Propagator *aEndCapTkProp, Propagator *aCrossTkProp, const MagneticField *field, PropagationDirection dir=alongMomentum)
 Defines which propagator is used inside endcap and in barrel.
virtual BeamHaloPropagatorclone () 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
PropagatorgetCrossTkPropagator () const
 return the propagator used to cross the tracker
PropagatorgetEndCapTkPropagator () const
 return the propagator used in endcaps
virtual const MagneticFieldmagneticField () const
 return the magneticField
TrajectoryStateOnSurface propagate (const TrajectoryStateOnSurface &tsos, const Cylinder &cylinder) const
TrajectoryStateOnSurface propagate (const FreeTrajectoryState &fts, const Cylinder &cylinder) const
TrajectoryStateOnSurface propagate (const TrajectoryStateOnSurface &tsos, const Plane &plane) const
TrajectoryStateOnSurface propagate (const FreeTrajectoryState &fts, const Plane &plane) const
TrajectoryStateOnSurface propagate (const TrajectoryStateOnSurface &tsos, const Surface &surface) const
 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.
TrajectoryStateOnSurface propagate (const FreeTrajectoryState &fts, const Surface &surface) const
 Propagate from a free state (e.g.
std::pair
< TrajectoryStateOnSurface,
double > 
propagateWithPath (const TrajectoryStateOnSurface &tsos, const Cylinder &cylinder) const
std::pair
< TrajectoryStateOnSurface,
double > 
propagateWithPath (const FreeTrajectoryState &fts, const Cylinder &cylinder) const
std::pair
< TrajectoryStateOnSurface,
double > 
propagateWithPath (const TrajectoryStateOnSurface &tsos, const Plane &plane) const
std::pair
< TrajectoryStateOnSurface,
double > 
propagateWithPath (const FreeTrajectoryState &fts, const Plane &plane) const
std::pair
< TrajectoryStateOnSurface,
double > 
propagateWithPath (const TrajectoryStateOnSurface &tsos, const Surface &surface) const
 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.
std::pair
< TrajectoryStateOnSurface,
double > 
propagateWithPath (const FreeTrajectoryState &fts, const Surface &surface) const
 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.
void setPropagationDirection (PropagationDirection dir)
 The propagation direction can now be set for every propagator.
virtual ~BeamHaloPropagator ()
 virtual destructor

Private Member Functions

void directionCheck (PropagationDirection dir) const

Private Attributes

PropagatortheCrossTkProp
PropagatortheEndCapTkProp
const MagneticFieldtheField


Detailed Description

A propagator which use different algorithm to propagate within an endcap or to cross over to the other endcap.

Author:
Jean-Roch VLIMANT UCSB

Definition at line 24 of file BeamHaloPropagator.h.


Constructor & Destructor Documentation

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 52 of file BeamHaloPropagator.cc.

References directionCheck().

Referenced by clone().

00053                                                            :
00054   Propagator(dir), theEndCapTkProp(aEndCapTkProp->clone()), theCrossTkProp(aCrossTkProp->clone()), theField(field) { 
00055   directionCheck(dir);
00056 }

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 59 of file BeamHaloPropagator.cc.

References directionCheck().

00060                                                            :
00061   Propagator(dir), theEndCapTkProp(aEndCapTkProp.clone()), theCrossTkProp(aCrossTkProp.clone()), theField(field) {
00062   directionCheck(dir);
00063 }

BeamHaloPropagator::BeamHaloPropagator ( const BeamHaloPropagator aProp  ) 

Copy constructor.

Definition at line 66 of file BeamHaloPropagator.cc.

References Propagator::clone(), getCrossTkPropagator(), getEndCapTkPropagator(), theCrossTkProp, and theEndCapTkProp.

00066                                                                       :
00067   Propagator(aProp.propagationDirection()), theEndCapTkProp(0), theCrossTkProp(0) { 
00068   if (aProp.theEndCapTkProp)
00069     theEndCapTkProp=aProp.getEndCapTkPropagator()->clone();
00070   if (aProp.theCrossTkProp)
00071     theCrossTkProp=aProp.getCrossTkPropagator()->clone();
00072 }

BeamHaloPropagator::~BeamHaloPropagator (  )  [virtual]

virtual destructor

Definition at line 75 of file BeamHaloPropagator.cc.

References theCrossTkProp, and theEndCapTkProp.

00075                                         {
00076 
00077   delete theEndCapTkProp;
00078   delete theCrossTkProp;
00079 
00080 }


Member Function Documentation

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().

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 82 of file BeamHaloPropagator.cc.

References LogDebug, GloballyPositioned< T >::position(), FreeTrajectoryState::position(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by propagate(), and propagateWithPath().

00082                                                                                             {
00083   LogDebug("BeamHaloPropagator")<<"going from: "<<fts.position()<<" to: "<<plane.position()<<"\n"
00084                                 <<"and hence "<<((fts.position().z()*plane.position().z()<0)?"crossing":"not crossing");
00085   return (fts.position().z()*plane.position().z()<0);}

void BeamHaloPropagator::directionCheck ( PropagationDirection  dir  )  const [private]

Definition at line 33 of file BeamHaloPropagator.cc.

References anyDirection, getCrossTkPropagator(), getEndCapTkPropagator(), Propagator::propagationDirection(), and Propagator::setPropagationDirection().

Referenced by BeamHaloPropagator().

00033                                                                      {
00034 
00035   //consistency check for direction
00036   if (getEndCapTkPropagator()->propagationDirection()!=dir && getEndCapTkPropagator()->propagationDirection()!=anyDirection){
00037     edm::LogError("BeamHaloPropagator")<<"composite propagator set with inconsistent direction components\n"
00038                                   <<"EndCap propagator is: "<<getEndCapTkPropagator()->propagationDirection()
00039                                   <<"\n to be set on: "<<dir;
00040     getEndCapTkPropagator()->setPropagationDirection(dir);
00041   }
00042 
00043   if (getCrossTkPropagator()->propagationDirection()!=dir && getCrossTkPropagator()->propagationDirection()!=anyDirection){
00044     edm::LogError("BeamHaloPropagator")<<"composite propagator set with inconsistent direction components\n"
00045                                   <<"Cross propagator is: "<<getCrossTkPropagator()->propagationDirection()
00046                                   <<"\n to be set on: "<<dir;
00047     getCrossTkPropagator()->setPropagationDirection(dir);
00048   }
00049   
00050 }

Propagator * BeamHaloPropagator::getCrossTkPropagator (  )  const

return the propagator used to cross the tracker

Definition at line 129 of file BeamHaloPropagator.cc.

References LogDebug, and theCrossTkProp.

Referenced by BeamHaloPropagator(), clone(), directionCheck(), propagate(), propagateWithPath(), and setPropagationDirection().

00129                                                            {
00130   LogDebug("BeamHaloPropagator")<<"using the Crossing propagator";
00131   return theCrossTkProp;}

Propagator * BeamHaloPropagator::getEndCapTkPropagator (  )  const

return the propagator used in endcaps

Definition at line 124 of file BeamHaloPropagator.cc.

References LogDebug, and theEndCapTkProp.

Referenced by BeamHaloPropagator(), clone(), directionCheck(), propagate(), propagateWithPath(), and setPropagationDirection().

00124                                                             {
00125   LogDebug("BeamHaloPropagator")<<"using the EndCap propagator";
00126   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().

00124 {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 Propagator::propagate().

00080                                                                        {
00081       return Propagator::propagate(tsos, cylinder);
00082     }

TrajectoryStateOnSurface BeamHaloPropagator::propagate ( const FreeTrajectoryState fts,
const Cylinder cylinder 
) const [virtual]

Implements Propagator.

Definition at line 103 of file BeamHaloPropagator.cc.

References getCrossTkPropagator(), and Propagator::propagate().

00104                                                                                     {
00105   return getCrossTkPropagator()->propagate(fts, cylinder);
00106 }

TrajectoryStateOnSurface BeamHaloPropagator::propagate ( const TrajectoryStateOnSurface tsos,
const Plane plane 
) const [inline, virtual]

Reimplemented from Propagator.

Definition at line 71 of file BeamHaloPropagator.h.

References Propagator::propagate().

00072                                                                  {
00073       return Propagator::propagate(tsos, plane);
00074     }

TrajectoryStateOnSurface BeamHaloPropagator::propagate ( const FreeTrajectoryState fts,
const Plane plane 
) const [virtual]

Implements Propagator.

Definition at line 93 of file BeamHaloPropagator.cc.

References crossingTk(), getCrossTkPropagator(), getEndCapTkPropagator(), and Propagator::propagate().

00094                                                                               {
00095 
00096   if (crossingTk(fts,plane)){
00097     return getCrossTkPropagator()->propagate(fts, plane);}
00098   else{
00099     return getEndCapTkPropagator()->propagate(fts, plane);}
00100 }

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 Propagator::propagate().

00064                                                                      {
00065       return Propagator::propagate(tsos,surface);
00066     }

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 87 of file BeamHaloPropagator.cc.

References Propagator::propagate().

00088                                                                                   {
00089   return Propagator::propagate( fts, surface);
00090 }

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 Propagator::propagateWithPath().

00112                                                         {
00113         return Propagator::propagateWithPath(tsos, cylinder);
00114       }

std::pair< TrajectoryStateOnSurface, double > BeamHaloPropagator::propagateWithPath ( const FreeTrajectoryState fts,
const Cylinder cylinder 
) const [virtual]

Implements Propagator.

Definition at line 119 of file BeamHaloPropagator.cc.

References getCrossTkPropagator(), and Propagator::propagateWithPath().

00121 {  return getCrossTkPropagator()->propagateWithPath(fts, cylinder);}

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 Propagator::propagateWithPath().

00102                                                   {
00103         return Propagator::propagateWithPath(tsos, plane);
00104       }

std::pair< TrajectoryStateOnSurface, double > BeamHaloPropagator::propagateWithPath ( const FreeTrajectoryState fts,
const Plane plane 
) const [virtual]

Implements Propagator.

Definition at line 109 of file BeamHaloPropagator.cc.

References crossingTk(), getCrossTkPropagator(), getEndCapTkPropagator(), and Propagator::propagateWithPath().

00111 {
00112   if (crossingTk(fts,plane)){
00113     return getCrossTkPropagator()->propagateWithPath(fts, plane);}
00114   else{
00115     return getEndCapTkPropagator()->propagateWithPath(fts, plane);}
00116 }

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 Propagator::propagateWithPath().

00092                                                       {
00093         return Propagator::propagateWithPath(tsos,surface);
00094       }

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.

References Propagator::propagateWithPath().

00086                                                       {
00087         return Propagator::propagateWithPath(fts,surface);
00088       }

void BeamHaloPropagator::setPropagationDirection ( PropagationDirection  dir  )  [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().


Member Data Documentation

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().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:15:00 2009 for CMSSW by  doxygen 1.5.4