CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
reco::VertexGhostTrackState Class Reference

#include <VertexGhostTrackState.h>

Inheritance diagram for reco::VertexGhostTrackState:
reco::BasicGhostTrackState

Public Member Functions

CovarianceMatrix cartesianCovariance () const override
 
GlobalError cartesianError () const override
 
GlobalPoint globalPosition () const override
 
 VertexGhostTrackState (const GlobalPoint &pos, const CovarianceMatrix &cov)
 
Vertex vertexStateOnGhostTrack (const GhostTrackPrediction &pred, bool withMeasurementError) const override
 
Vertex vertexStateOnMeasurement (const GhostTrackPrediction &pred, bool withGhostTrackError) const override
 
- Public Member Functions inherited from reco::BasicGhostTrackState
virtual bool isValid () const
 
double lambda () const
 
virtual bool linearize (const GhostTrackPrediction &pred, bool initial, double lambda)
 
virtual bool linearize (const GhostTrackPrediction &pred, double lambda)
 
virtual void reset ()
 
void setWeight (double weight)
 
double weight () const
 
virtual ~BasicGhostTrackState ()
 

Private Member Functions

pointer clone () const override
 

Private Attributes

CovarianceMatrix covariance_
 
GlobalPoint position_
 

Additional Inherited Members

- Public Types inherited from reco::BasicGhostTrackState
using BGTS = BasicGhostTrackState
 
typedef math::Error< 3 >::type CovarianceMatrix
 
using pointer = Proxy::pointer
 
using Proxy = ProxyBase11< BGTS >
 
typedef std::pair< GlobalPoint, GlobalErrorVertex
 
- Static Public Member Functions inherited from reco::BasicGhostTrackState
template<typename T , typename... Args>
static std::shared_ptr< BGTSbuild (Args &&... args)
 
- Protected Attributes inherited from reco::BasicGhostTrackState
double lambda_ = 0
 
double weight_ = 1.
 

Detailed Description

Definition at line 15 of file VertexGhostTrackState.h.

Constructor & Destructor Documentation

◆ VertexGhostTrackState()

reco::VertexGhostTrackState::VertexGhostTrackState ( const GlobalPoint pos,
const CovarianceMatrix cov 
)
inline

Definition at line 17 of file VertexGhostTrackState.h.

17 : position_(pos), covariance_(cov) {}

Member Function Documentation

◆ cartesianCovariance()

CovarianceMatrix reco::VertexGhostTrackState::cartesianCovariance ( ) const
inlineoverridevirtual

Implements reco::BasicGhostTrackState.

Definition at line 21 of file VertexGhostTrackState.h.

21 { return covariance_; }

References covariance_.

◆ cartesianError()

GlobalError reco::VertexGhostTrackState::cartesianError ( ) const
inlineoverridevirtual

Implements reco::BasicGhostTrackState.

Definition at line 20 of file VertexGhostTrackState.h.

20 { return covariance_; }

References covariance_.

◆ clone()

pointer reco::VertexGhostTrackState::clone ( void  ) const
inlineoverrideprivatevirtual

Implements reco::BasicGhostTrackState.

Definition at line 27 of file VertexGhostTrackState.h.

27 { return build<VertexGhostTrackState>(*this); }

◆ globalPosition()

GlobalPoint reco::VertexGhostTrackState::globalPosition ( ) const
inlineoverridevirtual

Implements reco::BasicGhostTrackState.

Definition at line 19 of file VertexGhostTrackState.h.

19 { return position_; }

References position_.

◆ vertexStateOnGhostTrack()

BasicGhostTrackState::Vertex VertexGhostTrackState::vertexStateOnGhostTrack ( const GhostTrackPrediction pred,
bool  withMeasurementError 
) const
overridevirtual

Implements reco::BasicGhostTrackState.

Definition at line 37 of file VertexGhostTrackState.cc.

38  {
39  using namespace ROOT::Math;
40 
41  GlobalPoint origin = pred.origin();
42  GlobalVector direction = pred.direction();
43 
44  double rho2 = pred.rho2();
45  double rho = std::sqrt(rho2);
46  double lambda = (position_ - origin) * direction / rho2;
47  GlobalPoint pos = origin + lambda * direction;
48 
49  Vector3 b = conv(direction) / rho;
50  Vector3 ca = conv(position_ - pos);
51 
52  Matrix33 pA = TensorProd(b, b);
53  Matrix33 pB = TensorProd(b, ca);
54 
55  Matrix36 jacobian;
56  jacobian.Place_at(-pA + Matrix33(SMatrixIdentity()), 0, 0);
57  jacobian.Place_at(pB / rho, 0, 3);
58  Matrix3S error = Similarity(jacobian, pred.cartesianError(lambda));
59 
60  if (withMeasurementError)
61  error += Similarity(pA, covariance_);
62 
63  return Vertex(pos, error);
64 }

References b, reco::GhostTrackPrediction::cartesianError(), conv, covariance_, reco::GhostTrackPrediction::direction(), relativeConstraints::error, reco::BasicGhostTrackState::lambda(), reco::GhostTrackPrediction::origin(), position_, reco::GhostTrackPrediction::rho2(), and mathSSE::sqrt().

◆ vertexStateOnMeasurement()

BasicGhostTrackState::Vertex VertexGhostTrackState::vertexStateOnMeasurement ( const GhostTrackPrediction pred,
bool  withGhostTrackError 
) const
overridevirtual

Implements reco::BasicGhostTrackState.

Definition at line 66 of file VertexGhostTrackState.cc.

67  {
68  return Vertex(position_, covariance_);
69 }

References covariance_, and position_.

Member Data Documentation

◆ covariance_

CovarianceMatrix reco::VertexGhostTrackState::covariance_
private

◆ position_

GlobalPoint reco::VertexGhostTrackState::position_
private
Vector3DBase
Definition: Vector3DBase.h:8
conv
static HepMC::IO_HEPEVT conv
Definition: BeamHaloProducer.cc:48
pos
Definition: PixelAliasList.h:18
ZElectronSkim_cff.rho
rho
Definition: ZElectronSkim_cff.py:38
reco::VertexGhostTrackState::position_
GlobalPoint position_
Definition: VertexGhostTrackState.h:29
relativeConstraints.error
error
Definition: relativeConstraints.py:53
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
Point3DBase< float, GlobalTag >
b
double b
Definition: hdecay.h:118
ROOT::Math
Definition: Transform3DPJ.h:41
reco::BasicGhostTrackState::Vertex
std::pair< GlobalPoint, GlobalError > Vertex
Definition: BasicGhostTrackState.h:27
reco::GhostTrackPrediction::direction
const GlobalVector direction() const
Definition: GhostTrackPrediction.h:63
reco::GhostTrackPrediction::rho2
double rho2() const
Definition: GhostTrackPrediction.h:53
reco::VertexGhostTrackState::covariance_
CovarianceMatrix covariance_
Definition: VertexGhostTrackState.h:30
reco::GhostTrackPrediction::origin
const GlobalPoint origin() const
Definition: GhostTrackPrediction.h:62
reco::GhostTrackPrediction::cartesianError
CartesianError cartesianError(double lambda=0.) const
Definition: GhostTrackPrediction.cc:146
reco::BasicGhostTrackState::lambda
double lambda() const
Definition: BasicGhostTrackState.h:40