CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Attributes
TrajectoryStateAccessor Class Reference

#include <TrajectoryStateAccessor.h>

Public Member Functions

float inversePtError () const
 
 TrajectoryStateAccessor (const FreeTrajectoryState &fts)
 

Private Attributes

const FreeTrajectoryStatetheFts
 

Detailed Description

Helper class to obtain the uncertainty on specific trajectory parameters.

Definition at line 10 of file TrajectoryStateAccessor.h.

Constructor & Destructor Documentation

TrajectoryStateAccessor::TrajectoryStateAccessor ( const FreeTrajectoryState fts)
inline

Definition at line 13 of file TrajectoryStateAccessor.h.

13  :
14  theFts(fts) {}
const FreeTrajectoryState & theFts

Member Function Documentation

float TrajectoryStateAccessor::inversePtError ( ) const

Definition at line 5 of file TrajectoryStateAccessor.cc.

References corr, FreeTrajectoryState::curvilinearError(), CurvilinearTrajectoryError::matrix(), FreeTrajectoryState::momentum(), PV3DBase< T, PVType, FrameType >::perp2(), mathSSE::sqrt(), theFts, and PV3DBase< T, PVType, FrameType >::z().

Referenced by ThresholdPtTrajectoryFilter::test().

6 {
7  GlobalVector momentum = theFts.momentum();
8  AlgebraicSymMatrix55 const & errMatrix = theFts.curvilinearError().matrix();
9 
10  float ptRec2= momentum.perp2();
11  float pzRec = momentum.z();
12  float pzRec2 = pzRec*pzRec;
13  float CosTheta2 = (pzRec2)/(ptRec2+pzRec2);
14  float SinTheta2 = 1.f-CosTheta2;
15 
16  float par2 = CosTheta2/ptRec2;
17 
18  float InvpErr=errMatrix(0,0);
19  float thetaErr=errMatrix(1,1);
20  float corr=errMatrix(0,1);
21 
22  float invPtErr2 =
23  ( InvpErr + par2*thetaErr -
24  2.f*std::sqrt(par2)*corr
25  )/(SinTheta2);
26  return std::sqrt(invPtErr2);
27 }
const FreeTrajectoryState & theFts
ROOT::Math::SMatrix< double, 5, 5, ROOT::Math::MatRepSym< double, 5 > > AlgebraicSymMatrix55
T perp2() const
Definition: PV3DBase.h:71
const CurvilinearTrajectoryError & curvilinearError() const
T sqrt(T t)
Definition: SSEVec.h:18
T z() const
Definition: PV3DBase.h:64
GlobalVector momentum() const
JetCorrectorParameters corr
Definition: classes.h:5
const AlgebraicSymMatrix55 & matrix() const

Member Data Documentation

const FreeTrajectoryState& TrajectoryStateAccessor::theFts
private

Definition at line 20 of file TrajectoryStateAccessor.h.

Referenced by inversePtError().