CMS 3D CMS Logo

List of all members | Public Member Functions | Private Types | Private Attributes | Friends
TrajectoryStateClosestToPoint Class Reference

#include <TrajectoryStateClosestToPoint.h>

Public Member Functions

void calculateFTS () const
 
TrackCharge charge () const
 
bool hasError () const
 
bool isValid () const
 
GlobalVector momentum () const
 
const PerigeeTrajectoryErrorperigeeError () const
 
const PerigeeTrajectoryParametersperigeeParameters () const
 
GlobalPoint position () const
 
double pt () const
 
const GlobalPointreferencePoint () const
 
const FreeTrajectoryStatetheState () const
 
 TrajectoryStateClosestToPoint ()
 parameter dimension More...
 
 TrajectoryStateClosestToPoint (const FTS &originalFTS, const GlobalPoint &referencePoint)
 
 TrajectoryStateClosestToPoint (const PerigeeTrajectoryParameters &perigeeParameters, double pt, const GlobalPoint &referencePoint, const MagneticField *field)
 
 TrajectoryStateClosestToPoint (const PerigeeTrajectoryParameters &perigeeParameters, double pt, const PerigeeTrajectoryError &perigeeError, const GlobalPoint &referencePoint, const MagneticField *field)
 

Private Types

typedef FreeTrajectoryState FTS
 
typedef TrajectoryStateOnSurface TSOS
 

Private Attributes

bool errorIsAvailable
 
const MagneticFieldtheField
 
FTS theFTS
 
bool theFTSavailable
 
PerigeeTrajectoryParameters theParameters
 
PerigeeTrajectoryError thePerigeeError
 
double thePt
 
GlobalPoint theRefPoint
 
bool valid
 

Friends

class TrajectoryStateClosestToPointBuilder
 

Detailed Description

Trajectory state defined at a given point on the helix, which is the point of closest approach to the reference point. In addition to the FreeTrajectoryState at that point, it also gives the perigee parameters. This state can also be invalid, e.g. in case the propagation was not successful.

Definition at line 18 of file TrajectoryStateClosestToPoint.h.

Member Typedef Documentation

◆ FTS

Definition at line 20 of file TrajectoryStateClosestToPoint.h.

◆ TSOS

Definition at line 19 of file TrajectoryStateClosestToPoint.h.

Constructor & Destructor Documentation

◆ TrajectoryStateClosestToPoint() [1/4]

TrajectoryStateClosestToPoint::TrajectoryStateClosestToPoint ( )
inline

parameter dimension

Definition at line 24 of file TrajectoryStateClosestToPoint.h.

24 : valid(false), theFTSavailable(false), errorIsAvailable(false) {}

◆ TrajectoryStateClosestToPoint() [2/4]

TrajectoryStateClosestToPoint::TrajectoryStateClosestToPoint ( const PerigeeTrajectoryParameters perigeeParameters,
double  pt,
const GlobalPoint referencePoint,
const MagneticField field 
)
inline

Public constructor, which is used to convert perigee parameters to a FreeTrajectoryState. For the case where no error is provided.

Definition at line 31 of file TrajectoryStateClosestToPoint.h.

35  : theField(field),
38  thePt(pt),
39  valid(true),
40  theFTSavailable(false),
41  errorIsAvailable(false) {}

◆ TrajectoryStateClosestToPoint() [3/4]

TrajectoryStateClosestToPoint::TrajectoryStateClosestToPoint ( const PerigeeTrajectoryParameters perigeeParameters,
double  pt,
const PerigeeTrajectoryError perigeeError,
const GlobalPoint referencePoint,
const MagneticField field 
)
inline

Public constructor, which is used to convert perigee parameters to a FreeTrajectoryState. For the case where an error is provided.

Definition at line 48 of file TrajectoryStateClosestToPoint.h.

53  : theField(field),
56  thePt(pt),
58  valid(true),
59  theFTSavailable(false),
60  errorIsAvailable(true) {}

◆ TrajectoryStateClosestToPoint() [4/4]

TrajectoryStateClosestToPoint::TrajectoryStateClosestToPoint ( const FTS originalFTS,
const GlobalPoint referencePoint 
)

Use the appropriate TrajectoryStateClosestToPointBuilder to get access to this constructor

Definition at line 6 of file TrajectoryStateClosestToPoint.cc.

7  : theFTS(originalFTS), theRefPoint(referencePoint), valid(true), theFTSavailable(true) {
8  try {
10  if (theFTS.hasError()) {
12  errorIsAvailable = true;
13  } else {
14  errorIsAvailable = false;
15  }
16  theField = &(originalFTS.parameters().magneticField());
17  } catch (const cms::Exception& ex) {
18  if (ex.category() != "PerigeeConversions")
19  throw;
20  edm::LogInfo("TrajectoryStateClosestToPoint_PerigeeConversions")
21  << "Caught exception " << ex.explainSelf() << ".\n";
22  valid = false;
23  }
24 }

References cms::Exception::category(), errorIsAvailable, cms::Exception::explainSelf(), PerigeeConversions::ftsToPerigeeError(), PerigeeConversions::ftsToPerigeeParameters(), FreeTrajectoryState::hasError(), GlobalTrajectoryParameters::magneticField(), FreeTrajectoryState::parameters(), referencePoint(), theField, theFTS, theParameters, thePerigeeError, thePt, and valid.

Member Function Documentation

◆ calculateFTS()

void TrajectoryStateClosestToPoint::calculateFTS ( ) const

◆ charge()

TrackCharge TrajectoryStateClosestToPoint::charge ( void  ) const
inline

Definition at line 94 of file TrajectoryStateClosestToPoint.h.

94 { return theParameters.charge(); }

References PerigeeTrajectoryParameters::charge(), and theParameters.

Referenced by TestOutliers::analyze().

◆ hasError()

bool TrajectoryStateClosestToPoint::hasError ( void  ) const
inline

tells whether the error of the perigee parameters is available.

Definition at line 106 of file TrajectoryStateClosestToPoint.h.

106 { return errorIsAvailable; }

References errorIsAvailable.

◆ isValid()

bool TrajectoryStateClosestToPoint::isValid ( void  ) const
inline

◆ momentum()

GlobalVector TrajectoryStateClosestToPoint::momentum ( ) const
inline

◆ perigeeError()

const PerigeeTrajectoryError& TrajectoryStateClosestToPoint::perigeeError ( ) const
inline

◆ perigeeParameters()

const PerigeeTrajectoryParameters& TrajectoryStateClosestToPoint::perigeeParameters ( ) const
inline

◆ position()

GlobalPoint TrajectoryStateClosestToPoint::position ( ) const
inline

◆ pt()

double TrajectoryStateClosestToPoint::pt ( ) const
inline

◆ referencePoint()

const GlobalPoint& TrajectoryStateClosestToPoint::referencePoint ( ) const
inline

returns the reference point which used to construct the state. It is thus the point with respect to which the impact parameters are defined.

Definition at line 67 of file TrajectoryStateClosestToPoint.h.

67 { return theRefPoint; }

References theRefPoint.

Referenced by PerigeeRefittedTrackState::position(), and TrajectoryStateClosestToPoint().

◆ theState()

const FreeTrajectoryState& TrajectoryStateClosestToPoint::theState ( ) const
inline

Friends And Related Function Documentation

◆ TrajectoryStateClosestToPointBuilder

Definition at line 113 of file TrajectoryStateClosestToPoint.h.

Member Data Documentation

◆ errorIsAvailable

bool TrajectoryStateClosestToPoint::errorIsAvailable
private

◆ theField

const MagneticField* TrajectoryStateClosestToPoint::theField
private

Definition at line 125 of file TrajectoryStateClosestToPoint.h.

Referenced by calculateFTS(), and TrajectoryStateClosestToPoint().

◆ theFTS

FTS TrajectoryStateClosestToPoint::theFTS
mutableprivate

◆ theFTSavailable

bool TrajectoryStateClosestToPoint::theFTSavailable
mutableprivate

Definition at line 134 of file TrajectoryStateClosestToPoint.h.

Referenced by calculateFTS(), and theState().

◆ theParameters

PerigeeTrajectoryParameters TrajectoryStateClosestToPoint::theParameters
private

◆ thePerigeeError

PerigeeTrajectoryError TrajectoryStateClosestToPoint::thePerigeeError
private

◆ thePt

double TrajectoryStateClosestToPoint::thePt
private

◆ theRefPoint

GlobalPoint TrajectoryStateClosestToPoint::theRefPoint
private

Definition at line 129 of file TrajectoryStateClosestToPoint.h.

Referenced by calculateFTS(), momentum(), position(), and referencePoint().

◆ valid

bool TrajectoryStateClosestToPoint::valid
private

Definition at line 133 of file TrajectoryStateClosestToPoint.h.

Referenced by isValid(), and TrajectoryStateClosestToPoint().

TrajectoryStateClosestToPoint::theParameters
PerigeeTrajectoryParameters theParameters
Definition: TrajectoryStateClosestToPoint.h:130
FreeTrajectoryState::hasError
bool hasError() const
Definition: FreeTrajectoryState.h:77
PerigeeConversions::ftsToPerigeeParameters
PerigeeTrajectoryParameters ftsToPerigeeParameters(const FTS &originalFTS, const GlobalPoint &referencePoint, double &pt)
Definition: PerigeeConversions.cc:7
TrajectoryStateClosestToPoint::calculateFTS
void calculateFTS() const
Definition: TrajectoryStateClosestToPoint.cc:26
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
TrajectoryStateClosestToPoint::theFTS
FTS theFTS
Definition: TrajectoryStateClosestToPoint.h:127
TrajectoryStateClosestToPoint::thePt
double thePt
Definition: TrajectoryStateClosestToPoint.h:131
TrajectoryStateClosestToPoint::errorIsAvailable
bool errorIsAvailable
Definition: TrajectoryStateClosestToPoint.h:135
TrajectoryStateException
Common base class.
Definition: TrajectoryStateExceptions.h:12
PerigeeConversions::positionFromPerigee
GlobalPoint positionFromPerigee(const PerigeeTrajectoryParameters &parameters, const GlobalPoint &referencePoint)
Definition: PerigeeConversions.cc:63
GlobalTrajectoryParameters
Definition: GlobalTrajectoryParameters.h:15
TrajectoryStateClosestToPoint::perigeeError
const PerigeeTrajectoryError & perigeeError() const
Definition: TrajectoryStateClosestToPoint.h:84
TrajectoryStateClosestToPoint::perigeeParameters
const PerigeeTrajectoryParameters & perigeeParameters() const
Definition: TrajectoryStateClosestToPoint.h:73
TrajectoryStateClosestToPoint::pt
double pt() const
Definition: TrajectoryStateClosestToPoint.h:78
FreeTrajectoryState::parameters
const GlobalTrajectoryParameters & parameters() const
Definition: FreeTrajectoryState.h:79
TrajectoryStateClosestToPoint::thePerigeeError
PerigeeTrajectoryError thePerigeeError
Definition: TrajectoryStateClosestToPoint.h:132
TrajectoryStateClosestToPoint::valid
bool valid
Definition: TrajectoryStateClosestToPoint.h:133
TrajectoryStateClosestToPoint::theRefPoint
GlobalPoint theRefPoint
Definition: TrajectoryStateClosestToPoint.h:129
PerigeeTrajectoryParameters::charge
TrackCharge charge() const
Definition: PerigeeTrajectoryParameters.h:44
PerigeeConversions::curvilinearError
CurvilinearTrajectoryError curvilinearError(const PerigeeTrajectoryError &perigeeError, const GlobalTrajectoryParameters &gtp)
Definition: PerigeeConversions.cc:57
PerigeeConversions::momentumFromPerigee
GlobalVector momentumFromPerigee(const AlgebraicVector3 &momentum, const TrackCharge &charge, const GlobalPoint &referencePoint, const MagneticField *field)
Definition: PerigeeConversions.cc:79
cms::Exception::explainSelf
virtual std::string explainSelf() const
Definition: Exception.cc:108
TrajectoryStateClosestToPoint::theField
const MagneticField * theField
Definition: TrajectoryStateClosestToPoint.h:125
GlobalTrajectoryParameters::magneticField
const MagneticField & magneticField() const
Definition: GlobalTrajectoryParameters.h:106
TrajectoryStateClosestToPoint::isValid
bool isValid() const
Definition: TrajectoryStateClosestToPoint.h:111
cms::Exception
Definition: Exception.h:70
TrajectoryStateClosestToPoint::referencePoint
const GlobalPoint & referencePoint() const
Definition: TrajectoryStateClosestToPoint.h:67
TrajectoryStateClosestToPoint::FTS
FreeTrajectoryState FTS
Definition: TrajectoryStateClosestToPoint.h:20
PerigeeConversions::ftsToPerigeeError
PerigeeTrajectoryError ftsToPerigeeError(const FTS &originalFTS)
Definition: PerigeeConversions.cc:51
cms::Exception::category
std::string const & category() const
Definition: Exception.cc:143
TrajectoryStateClosestToPoint::theFTSavailable
bool theFTSavailable
Definition: TrajectoryStateClosestToPoint.h:134