CMS 3D CMS Logo

LocalTrajectoryError Class Reference

Class providing access to the covariance matrix of a set of relevant parameters of a trajectory in a local, Cartesian frame. More...

#include <TrackingTools/TrajectoryParametrization/interface/LocalTrajectoryError.h>

List of all members.

Public Member Functions

 LocalTrajectoryError (float dx, float dy, float dxdir, float dydir, float dpinv)
 Constructing class from standard deviations of the individual parameters, making the covariance matrix diagonal.
 LocalTrajectoryError (const AlgebraicSymMatrix &aCovarianceMatrix)
 LocalTrajectoryError (const AlgebraicSymMatrix55 &aCovarianceMatrix)
 Constructing class from a full covariance matrix.
 LocalTrajectoryError ()
const AlgebraicSymMatrix55matrix () const
 Returns the covariance matrix.
const AlgebraicSymMatrix matrix_old () const
 Returns the covariance matrix.
void operator *= (double factor)
 Enables the multiplication of the covariance matrix with the scalar "factor".
LocalError positionError () const
 Returns the two-by-two submatrix of the covariance matrix which yields the local position errors as well as the correlation between them.
const AlgebraicSymMatrix55weightMatrix () const

Private Attributes

AlgebraicSymMatrix55 theCovarianceMatrix
boost::shared_ptr
< AlgebraicSymMatrix55
theWeightMatrixPtr


Detailed Description

Class providing access to the covariance matrix of a set of relevant parameters of a trajectory in a local, Cartesian frame.

The errors provided are:

sigma^2(q/p) : charge (plus or minus one) divided by magnitude of momentum
sigma^2(dxdz) : direction tangent in local xz-plane
sigma^2(dydz) : direction tangent in local yz-plane
sigma^2(x) : local x-coordinate
sigma^2(y) : local y-coordinate

plus the relevant correlation terms.

Definition at line 21 of file LocalTrajectoryError.h.


Constructor & Destructor Documentation

LocalTrajectoryError::LocalTrajectoryError (  )  [inline]

Definition at line 24 of file LocalTrajectoryError.h.

00024 {}

LocalTrajectoryError::LocalTrajectoryError ( const AlgebraicSymMatrix55 aCovarianceMatrix  )  [inline]

Constructing class from a full covariance matrix.

The sequence of the parameters is the same as the one described above.

Definition at line 30 of file LocalTrajectoryError.h.

00030                                                                       :
00031     theCovarianceMatrix(aCovarianceMatrix), theWeightMatrixPtr() { }
  LocalTrajectoryError(const AlgebraicSymMatrix& aCovarianceMatrix) :

LocalTrajectoryError::LocalTrajectoryError ( const AlgebraicSymMatrix aCovarianceMatrix  )  [inline]

Definition at line 32 of file LocalTrajectoryError.h.

00032                                                                     :
00033     theCovarianceMatrix(asSMatrix<5>(aCovarianceMatrix)), theWeightMatrixPtr() {}

LocalTrajectoryError::LocalTrajectoryError ( float  dx,
float  dy,
float  dxdir,
float  dydir,
float  dpinv 
)

Constructing class from standard deviations of the individual parameters, making the covariance matrix diagonal.

The sequence of the input parameters is sigma(x), sigma(y), sigma(dxdz), sigma(dydz), sigma(q/p), but the resulting covariance matrix has the same structure as the one described above.

Definition at line 4 of file LocalTrajectoryError.cc.

References theCovarianceMatrix.

00005                                    : theCovarianceMatrix(), theWeightMatrixPtr()
00006 {
00007   theCovarianceMatrix(3,3) = dx*dx;
00008   theCovarianceMatrix(4,4) = dy*dy;
00009   theCovarianceMatrix(1,1) = dxdir*dxdir;
00010   theCovarianceMatrix(2,2) = dydir*dydir;
00011   theCovarianceMatrix(0,0) = dpinv*dpinv;
00012   
00013 }


Member Function Documentation

const AlgebraicSymMatrix55& LocalTrajectoryError::matrix ( void   )  const [inline]

Returns the covariance matrix.

Definition at line 50 of file LocalTrajectoryError.h.

References theCovarianceMatrix.

Referenced by BasicSingleTrajectoryState::checkCartesianError(), BasicSingleTrajectoryState::checkCurvilinError(), TrajectoryStateCombiner::combine(), PFGsfHelper::computeQpMode(), ReferenceTrajectory::construct(), Chi2MeasurementEstimatorForTrackerHits::estimate(), CollinearFitAtTM::fit(), GlobalMuonTrackMatcher::match_Chi2(), MeasurementExtractor::measuredError(), operator<<(), TrajectoryStateTransform::persistentState(), PFGsfHelper::PFGsfHelper(), PixelTrackBuilder::print(), MuonStandaloneAlgorithm::produce(), TrajectorySeedProducer::produce(), StraightLinePropagator::propagatedState(), TrackAssociatorByPosition::quality(), KalmanAlignmentTrackRefitter::refitSingleTracklet(), NuclearInteractionFinder::rescaleError(), TrajectorySegmentBuilder::segments(), CRackTrajectoryBuilder::SortHits(), TrajectorySeedProducer::stateOnDet(), ChargeSignificanceTrajectoryFilter::TBC(), CkfDebugger::testSeed(), DualBzeroTrajectoryFactory::trajectories(), DualTrajectoryFactory::trajectories(), Strip1DMeasurementTransformator::trajectoryError(), StripMeasurementTransformator::trajectoryError(), MaterialEffectsUpdator::updateState(), VolumeMaterialEffectsUpdator::updateState(), and GsfMaterialEffectsUpdator::updateState().

00050                                              {
00051     return theCovarianceMatrix;
00052   }

const AlgebraicSymMatrix LocalTrajectoryError::matrix_old (  )  const [inline]

Returns the covariance matrix.

Definition at line 57 of file LocalTrajectoryError.h.

References asHepMatrix(), and theCovarianceMatrix.

00057                                               {
00058     return asHepMatrix(theCovarianceMatrix);
00059   }

void LocalTrajectoryError::operator *= ( double  factor  )  [inline]

Enables the multiplication of the covariance matrix with the scalar "factor".

Definition at line 76 of file LocalTrajectoryError.h.

References theCovarianceMatrix, and theWeightMatrixPtr.

00076                                    {
00077     theCovarianceMatrix *= factor;
00078     if ((theWeightMatrixPtr.get() != 0) && (factor != 0.0)) { (*theWeightMatrixPtr) /= factor; } 
00079   }

LocalError LocalTrajectoryError::positionError (  )  const [inline]

Returns the two-by-two submatrix of the covariance matrix which yields the local position errors as well as the correlation between them.

Definition at line 85 of file LocalTrajectoryError.h.

References theCovarianceMatrix.

Referenced by CkfDebugger::analyseCompatibleMeasurements(), TkGluedMeasurementDet::checkHitProjection(), MuRingForwardDoubleLayer::compatible(), ForwardDetLayer::compatible(), MuRingForwardLayer::compatibleDets(), Chi2Strip1DEstimator::estimate(), Chi2StripEstimator::estimate(), Chi2MeasurementEstimatorBase::estimate(), AlignmentMonitorMuonHIP::event(), AlignmentMonitorMuonResiduals::event(), AlignmentMonitorGeneric::event(), RoadSearchTrackCandidateMakerAlgorithm::extrapolateTrajectory(), TkStripMeasurementDet::fastMeasurements(), TrackerValidationVariables::fillHitQuantities(), RoadSearchTrackCandidateMakerAlgorithm::FindBestHits(), TrackDetectorAssociator::getTAMuonChamberMatches(), DeDxDiscriminatorProducer::IsFarFromBorder(), SiStripGainFromData::IsFarFromBorder(), GlobalMuonTrackMatcher::match_dist(), BarrelMeasurementEstimator::maximalLocalDisplacement(), ForwardMeasurementEstimator::maximalLocalDisplacement(), Chi2MeasurementEstimatorBase::maximalLocalDisplacement(), cms::HICSeedMeasurementEstimator::maximalLocalDisplacement(), AlignmentMuonHIPTrajectorySelector::produce(), TrajectorySeedProducer::produce(), RoadSearchTrackCandidateMakerAlgorithm::run(), TkGluedMeasurementDet::testStrips(), TrackEfficiencyMonitor::testTrackerTracks(), trajectoryToResiduals(), SimpleNavigableLayer::wellInside(), and MuRodBarrelLayer::xError().

00085                                    {
00086     return LocalError( theCovarianceMatrix(3,3),theCovarianceMatrix(3,4),
00087                        theCovarianceMatrix(4,4));
00088   }

const AlgebraicSymMatrix55& LocalTrajectoryError::weightMatrix ( void   )  const [inline]

Definition at line 61 of file LocalTrajectoryError.h.

References python::tagInventory::inv, theCovarianceMatrix, and theWeightMatrixPtr.

00061                                                    {
00062         if (theWeightMatrixPtr.get() == 0) {
00063                 int ifail;
00064                 boost::shared_ptr<AlgebraicSymMatrix55> inv(
00065                           new AlgebraicSymMatrix55(theCovarianceMatrix.Inverse(ifail))
00066                 );
00067                 theWeightMatrixPtr = inv;
00068         }
00069         return *theWeightMatrixPtr;
00070   }


Member Data Documentation

AlgebraicSymMatrix55 LocalTrajectoryError::theCovarianceMatrix [private]

Definition at line 91 of file LocalTrajectoryError.h.

Referenced by LocalTrajectoryError(), matrix(), matrix_old(), operator *=(), positionError(), and weightMatrix().

boost::shared_ptr<AlgebraicSymMatrix55> LocalTrajectoryError::theWeightMatrixPtr [mutable, private]

Definition at line 92 of file LocalTrajectoryError.h.

Referenced by operator *=(), and weightMatrix().


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