CMS 3D CMS Logo

MultiTrajectoryStateTransform Class Reference

#include <TrackingTools/GsfTools/interface/MultiTrajectoryStateTransform.h>

List of all members.

Public Member Functions

TrajectoryStateOnSurface innerStateOnSurface (const reco::GsfTrack &tk, const TrackingGeometry &geom, const MagneticField *field) const
 Construct a TrajectoryStateOnSurface from the reco::GsfTrack innermost or outermost state, requires access to tracking geometry.
TrajectoryStateOnSurface outerStateOnSurface (const reco::GsfTrack &tk, const TrackingGeometry &geom, const MagneticField *field) const

Private Types

enum  { dimension = reco::GsfTrackExtra::dimension }
typedef
reco::GsfTrackExtra::LocalCovarianceMatrix 
CovarianceMatrix
typedef
reco::GsfTrackExtra::LocalParameterVector 
ParameterVector

Private Member Functions

TrajectoryStateOnSurface stateOnSurface (const std::vector< double > &weights, const std::vector< ParameterVector > &parameters, const std::vector< CovarianceMatrix > &covariances, const double &pzSign, const Surface &surface, const MagneticField *field) const


Detailed Description

Definition at line 15 of file MultiTrajectoryStateTransform.h.


Member Typedef Documentation

typedef reco::GsfTrackExtra::LocalCovarianceMatrix MultiTrajectoryStateTransform::CovarianceMatrix [private]

Definition at line 18 of file MultiTrajectoryStateTransform.h.

typedef reco::GsfTrackExtra::LocalParameterVector MultiTrajectoryStateTransform::ParameterVector [private]

Definition at line 17 of file MultiTrajectoryStateTransform.h.


Member Enumeration Documentation

anonymous enum [private]

Enumerator:
dimension 

Definition at line 19 of file MultiTrajectoryStateTransform.h.


Member Function Documentation

TrajectoryStateOnSurface MultiTrajectoryStateTransform::innerStateOnSurface ( const reco::GsfTrack tk,
const TrackingGeometry geom,
const MagneticField field 
) const

Construct a TrajectoryStateOnSurface from the reco::GsfTrack innermost or outermost state, requires access to tracking geometry.

Definition at line 28 of file MultiTrajectoryStateTransform.cc.

References reco::Track::extra(), reco::GsfTrack::gsfExtra(), TrackingGeometry::idToDet(), stateOnSurface(), and GeomDet::surface().

Referenced by GlobalGsfElectronAlgo::calculateTSOS(), GsfElectronAlgo::calculateTSOS(), reco::GsfTransientTrack::innermostMeasurementState(), and GlobalGsfElectronAlgo::superClusterMatching().

00031 {
00032   const Surface& surface = geom.idToDet( DetId( tk.extra()->innerDetId()))->surface();
00033 
00034   const reco::GsfTrackExtraRef& extra(tk.gsfExtra());
00035   return stateOnSurface(extra->innerStateWeights(),
00036                         extra->innerStateLocalParameters(),
00037                         extra->innerStateCovariances(),
00038                         extra->innerStateLocalPzSign(),
00039                         surface,field);
00040 }

TrajectoryStateOnSurface MultiTrajectoryStateTransform::outerStateOnSurface ( const reco::GsfTrack tk,
const TrackingGeometry geom,
const MagneticField field 
) const

Definition at line 13 of file MultiTrajectoryStateTransform.cc.

References reco::Track::extra(), reco::GsfTrack::gsfExtra(), TrackingGeometry::idToDet(), stateOnSurface(), and GeomDet::surface().

Referenced by GlobalGsfElectronAlgo::calculateTSOS(), GsfElectronAlgo::calculateTSOS(), reco::GsfTransientTrack::outermostMeasurementState(), and GlobalGsfElectronAlgo::superClusterMatching().

00016 {
00017   const Surface& surface = geom.idToDet( DetId( tk.extra()->outerDetId()))->surface();
00018 
00019   const reco::GsfTrackExtraRef& extra(tk.gsfExtra());
00020   return stateOnSurface(extra->outerStateWeights(),
00021                         extra->outerStateLocalParameters(),
00022                         extra->outerStateCovariances(),
00023                         extra->outerStateLocalPzSign(),
00024                         surface,field);
00025 }

TrajectoryStateOnSurface MultiTrajectoryStateTransform::stateOnSurface ( const std::vector< double > &  weights,
const std::vector< ParameterVector > &  parameters,
const std::vector< CovarianceMatrix > &  covariances,
const double &  pzSign,
const Surface surface,
const MagneticField field 
) const [private]

Definition at line 43 of file MultiTrajectoryStateTransform.cc.

References dimension, i, j2, asciidump::le, lp, and pars.

Referenced by innerStateOnSurface(), and outerStateOnSurface().

00049 {
00050   if ( weights.empty() )  return TrajectoryStateOnSurface();
00051   
00052   unsigned int nc(weights.size());
00053   AlgebraicVector5 pars;
00054   AlgebraicSymMatrix55 cov;
00055   
00056   std::vector<TrajectoryStateOnSurface> components;
00057   components.reserve(nc);
00058   
00059   // create components TSOSs
00060   for ( unsigned int i=0; i<nc; i++ ) {
00061     // convert parameter vector and covariance matrix
00062     for ( unsigned int j1=0; j1<dimension; j1++ ) {
00063       pars[j1] = parameters[i](j1);
00064       for ( unsigned int j2=0; j2<=j1; j2++ ) 
00065         cov(j1,j2) = covariances[i](j1,j2);          //FIXME: SMatrix copy constructor should handle this!!
00066     }
00067     // create local parameters & errors
00068     LocalTrajectoryParameters lp(pars,pzSign);
00069     LocalTrajectoryError le(cov);
00070     // create component
00071     components.push_back(TrajectoryStateOnSurface(lp,le,surface,field,weights[i]));
00072   }
00073   return 
00074     TrajectoryStateOnSurface(new BasicMultiTrajectoryState(components));
00075 }


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