CMS 3D CMS Logo

Public Member Functions | Private Attributes

LocalError Class Reference

#include <LocalError.h>

List of all members.

Public Member Functions

bool invalid () const
 LocalError ()
 LocalError (InvalidError)
 LocalError (float xx, float xy, float yy)
LocalError rotate (float phi) const
 Return a new LocalError, rotated by an angle phi.
LocalError rotate (float x, float y) const
 Return a new LocalError, rotated by an angle defined by the direction (x,y)
LocalError rotateCosSin (float c, float s, float mag2i=1.f) const
 Return a new LocalError, rotated by an angle defined by it's cosine and sine.
LocalError scale (float s) const
bool valid () const
float xx () const
float xy () const
float yy () const

Private Attributes

float thexx
float thexy
float theyy

Detailed Description

A very simple class for 2D error matrix components, used for the local frame.

Definition at line 12 of file LocalError.h.


Constructor & Destructor Documentation

LocalError::LocalError ( ) [inline]

Definition at line 14 of file LocalError.h.

Referenced by rotateCosSin(), and scale().

: thexx(0), thexy(0), theyy(0) {}
LocalError::LocalError ( InvalidError  ) [inline]

Definition at line 15 of file LocalError.h.

: thexx(-9999.e10f), thexy(0), theyy(-9999.e10f) {}
LocalError::LocalError ( float  xx,
float  xy,
float  yy 
) [inline]

Definition at line 17 of file LocalError.h.

                                            :
    thexx(xx), thexy(xy), theyy(yy) {}

Member Function Documentation

bool LocalError::invalid ( ) const [inline]

Definition at line 20 of file LocalError.h.

References thexx.

Referenced by valid().

{ return thexx<-1.e10f;}
LocalError LocalError::rotate ( float  phi) const [inline]

Return a new LocalError, rotated by an angle phi.

Definition at line 44 of file LocalError.h.

References funct::cos(), rotateCosSin(), and funct::sin().

                                     { 
    return rotateCosSin( cos(phi), sin(phi));
  }
LocalError LocalError::rotate ( float  x,
float  y 
) const [inline]
LocalError LocalError::rotateCosSin ( float  c,
float  s,
float  mag2i = 1.f 
) const [inline]

Return a new LocalError, rotated by an angle defined by it's cosine and sine.

Definition at line 49 of file LocalError.h.

References f, LocalError(), xx(), xy(), and yy().

Referenced by rotate().

                                                                    {
    return LocalError( mag2i*( (c*c)*xx() + (s*s)*yy() - 2.f*(c*s)*xy()),
                       mag2i*( (c*s)*(xx() - yy()) +  (c*c-s*s)*xy()) ,
                       mag2i*( (s*s)*xx() + (c*c)*yy() + 2.f*(c*s)*xy())
                     );
  }
LocalError LocalError::scale ( float  s) const [inline]

Return a new LocalError, scaled by a factor interpreted as a number of sigmas (standard deviations). The error matrix components are actually multiplied with the square of the factor.

Definition at line 33 of file LocalError.h.

References LocalError(), alignCSCRings::s, indexGen::s2, xx(), xy(), and yy().

Referenced by CaloDetIdAssociator::crossedElement(), and CachedTrajectory::getWideTrajectory().

                                  { 
    float s2 = s*s;
    return LocalError(s2*xx(), s2*xy(), s2*yy());
  }
bool LocalError::valid ( ) const [inline]
float LocalError::xx ( ) const [inline]

Definition at line 24 of file LocalError.h.

References thexx.

Referenced by MuonCSCChamberResidual::addResidual(), MuonDT13ChamberResidual::addResidual(), MuonDT2ChamberResidual::addResidual(), TrackDetectorAssociator::addTAMuonSegmentMatch(), CkfDebugger::analyseCompatibleMeasurements(), SiStripElectronAnalyzer::analyze(), TrackerDpgAnalysis::analyze(), DTSegment4DQuality::analyze(), DTSegment2DQuality::analyze(), MuonIdVal::analyze(), SiPixelErrorEstimation::analyze(), SiPixelTrackingRecHitsValid::analyze(), SiStripRecHitsValid::analyze(), MuonIdDQM::analyze(), SiPixelRecHitSource::analyze(), DTSegment2DSLPhiQuality::analyze(), SiStripTrackingRecHitsValid::analyze(), FWCSCRecHitProxyBuilder::build(), FWRPCRecHitProxyBuilder::buildViewType(), CSCPairResidualsConstraint::calculatePhi(), TkGluedMeasurementDet::checkHitProjection(), MuRingForwardDoubleLayer::compatible(), ForwardDetLayer::compatible(), MuRingForwardLayer::compatibleDets(), CSCSegAlgoST::correctTheCovX(), CaloDetIdAssociator::crossedElement(), CSCValidation::doRecHits(), AlignmentMonitorMuonResiduals::event(), AlignmentMonitorGeneric::event(), RoadSearchTrackCandidateMakerAlgorithm::extrapolateTrajectory(), SiPixelRecHitsValid::fillBarrel(), CSCSegAlgoHitPruning::fillChiSquared(), CSCSegAlgoSK::fillChiSquared(), CSCSegAlgoTC::fillChiSquared(), CSCSegAlgoST::fillChiSquared(), SiPixelRecHitsValid::fillForward(), TrackerValidationVariables::fillHitQuantities(), ReferenceTrajectory::fillMeasurementAndError(), MuonIdProducer::fillMuonId(), CSCEfficiency::fillRechitsSegments_info(), RoadSearchTrackCandidateMakerAlgorithm::FindBestHits(), SETFilter::findChi2(), CollinearFitAtTM2::fit(), CollinearFitAtTM::fit(), DTSegmentUpdator::fit(), CSCSegAlgoHitPruning::fitSlopes(), CSCSegAlgoST::fitSlopes(), CSCSegAlgoTC::fitSlopes(), CSCSegAlgoSK::fitSlopes(), GlobalTrajectoryBuilderBase::fixTEC(), BaseSiTrackerRecHit2DLocalPos::getKfComponents(), HelpertRecHit2DLocalPos::getKfComponents(), GSSiTrackerRecHit2DLocalPos::getKfComponents(), BaseTrackerRecHit::getKfComponents1D(), BaseTrackerRecHit::getKfComponents2D(), TrackDetectorAssociator::getTAMuonChamberMatches(), CachedTrajectory::getWideTrajectory(), TkPixelMeasurementDet::hasBadComponents(), BaseTrackerRecHit::hasPositionAndError(), BaseSiTrackerRecHit2DLocalPos::hasPositionAndError(), TrackerMuonHitExtractor::init(), TrapezoidalPlaneBounds::inside(), GeneralTrapezoidalPlaneBounds::inside(), CSCLayerGeometry::inside(), DiskSectorBounds::inside(), GeneralNSurfaceDelimitedBounds::inside(), RectangularPlaneBounds::inside(), SimpleDiskBounds::inside(), DTSegmentExtendedCand::isCompatible(), TrackerRecHit::largerError(), TrackerRecHit::localError(), TwoBodyDecayTrajectoryFactory::match(), GlobalMuonTrackMatcher::match_dist(), BarrelMeasurementEstimator::maximalLocalDisplacement(), ForwardMeasurementEstimator::maximalLocalDisplacement(), Chi2MeasurementEstimatorBase::maximalLocalDisplacement(), cms::HICSeedMeasurementEstimator::maximalLocalDisplacement(), DTTopology::measurementError(), RadialStripTopology::measurementError(), MuonResidualsFromTrack::MuonResidualsFromTrack(), operator<<(), RecHit2DLocalPos::parametersError(), BeamSpotTransientTrackingRecHit::parametersError(), MuonTransientTrackingRecHit::parametersError(), GCC11_FINAL::parametersError(), KFBasedPixelFitter::MyBeamSpotHit::parametersError(), RecHit1D::parametersError(), DTSLRecCluster::parError(), HelpertRecHit2DLocalPos::parError(), CSCRecHit2DValidation::plotResolution(), CSCSegmentValidation::plotResolution(), HIPAlignmentAlgorithm::processHit1D(), HIPAlignmentAlgorithm::processHit2D(), MuonTrackProducer::produce(), AlignmentMuonHIPTrajectorySelector::produce(), TrackingRecHitProjector< ResultingHit >::project(), GSRecHitMatcher::projectOnly(), RecHitPropagator::propagate(), CSCSegAlgoST::prune_bad_hits(), CSCSegAlgoHitPruning::pruneBadHits(), DTRecHitQuality::recHitPositionError(), rotateCosSin(), RoadSearchTrackCandidateMakerAlgorithm::run(), TrackCandidateProducer::sameLocalParameters(), scale(), StateSegmentMatcher::setAPE2d(), StateSegmentMatcher::setAPE4d(), SiTrackerGaussianSmearingRecHitConverter::smearHits(), TkGluedMeasurementDet::testStrips(), TrackEfficiencyMonitor::testTrackerTracks(), trajectoryToResiduals(), ErrorFrameTransformer::transform(), CSCSegAlgoShowering::updateParameters(), CSCSegAlgoDF::updateParameters(), HelpertRecHit2DLocalPos::updateWithAPE(), CSCSegAlgoTC::weightMatrix(), CSCSegAlgoST::weightMatrix(), CSCSegAlgoShowering::weightMatrix(), CSCSegAlgoHitPruning::weightMatrix(), CSCSegAlgoSK::weightMatrix(), CSCSegAlgoDF::weightMatrix(), SimpleNavigableLayer::wellInside(), and MuRodBarrelLayer::xError().

{ return thexx;}
float LocalError::xy ( ) const [inline]

Definition at line 25 of file LocalError.h.

References thexy.

Referenced by MuonCSCChamberResidual::addResidual(), TrackDetectorAssociator::addTAMuonSegmentMatch(), SiStripElectronAnalyzer::analyze(), SiStripRecHitsValid::analyze(), SiStripTrackingRecHitsValid::analyze(), CSCPairResidualsConstraint::calculatePhi(), TkGluedMeasurementDet::checkHitProjection(), CaloDetIdAssociator::crossedElement(), CSCValidation::doRecHits(), CSCSegAlgoHitPruning::fillChiSquared(), CSCSegAlgoSK::fillChiSquared(), CSCSegAlgoTC::fillChiSquared(), CSCSegAlgoST::fillChiSquared(), ReferenceTrajectory::fillMeasurementAndError(), CSCEfficiency::fillRechitsSegments_info(), SETFilter::findChi2(), CollinearFitAtTM2::fit(), CollinearFitAtTM::fit(), CSCSegAlgoHitPruning::fitSlopes(), CSCSegAlgoST::fitSlopes(), CSCSegAlgoTC::fitSlopes(), CSCSegAlgoSK::fitSlopes(), BaseSiTrackerRecHit2DLocalPos::getKfComponents(), HelpertRecHit2DLocalPos::getKfComponents(), GSSiTrackerRecHit2DLocalPos::getKfComponents(), BaseTrackerRecHit::getKfComponents2D(), CachedTrajectory::getWideTrajectory(), BaseTrackerRecHit::hasPositionAndError(), BaseSiTrackerRecHit2DLocalPos::hasPositionAndError(), DiskSectorBounds::inside(), SimpleDiskBounds::inside(), TrackerRecHit::largerError(), TrackerRecHit::localError(), StripCPEfromTemplate::localParameters(), GlobalMuonTrackMatcher::match_dist(), RadialStripTopology::measurementError(), operator<<(), RecHit2DLocalPos::parametersError(), MuonTransientTrackingRecHit::parametersError(), GCC11_FINAL::parametersError(), HelpertRecHit2DLocalPos::parError(), HIPAlignmentAlgorithm::processHit2D(), AlignmentMuonHIPTrajectorySelector::produce(), TrackingRecHitProjector< ResultingHit >::project(), GSRecHitMatcher::projectOnly(), RecHitPropagator::propagate(), rotateCosSin(), TrackCandidateProducer::sameLocalParameters(), scale(), SiTrackerGaussianSmearingRecHitConverter::smearHits(), TkGluedMeasurementDet::testStrips(), ErrorFrameTransformer::transform(), CSCSegAlgoDF::updateParameters(), CSCSegAlgoShowering::updateParameters(), HelpertRecHit2DLocalPos::updateWithAPE(), CSCSegAlgoTC::weightMatrix(), CSCSegAlgoShowering::weightMatrix(), CSCSegAlgoST::weightMatrix(), CSCSegAlgoHitPruning::weightMatrix(), CSCSegAlgoSK::weightMatrix(), and CSCSegAlgoDF::weightMatrix().

{ return thexy;}
float LocalError::yy ( ) const [inline]

Definition at line 26 of file LocalError.h.

References theyy.

Referenced by MuonCSCChamberResidual::addResidual(), TrackDetectorAssociator::addTAMuonSegmentMatch(), CkfDebugger::analyseCompatibleMeasurements(), SiStripElectronAnalyzer::analyze(), DTSegment4DQuality::analyze(), TrackerDpgAnalysis::analyze(), MuonIdVal::analyze(), SiPixelErrorEstimation::analyze(), SiPixelTrackingRecHitsValid::analyze(), SiStripRecHitsValid::analyze(), SiPixelRecHitSource::analyze(), MuonIdDQM::analyze(), SiStripTrackingRecHitsValid::analyze(), FWCSCRecHitProxyBuilder::build(), FWRPCRecHitProxyBuilder::buildViewType(), CSCPairResidualsConstraint::calculatePhi(), TkGluedMeasurementDet::checkHitProjection(), MuRingForwardDoubleLayer::compatible(), ForwardDetLayer::compatible(), MuRingForwardLayer::compatibleDets(), CaloDetIdAssociator::crossedElement(), CSCValidation::doRecHits(), ConversionBarrelEstimator::estimate(), ConversionForwardEstimator::estimate(), AlignmentMonitorMuonResiduals::event(), AlignmentMonitorGeneric::event(), SiPixelRecHitsValid::fillBarrel(), CSCSegAlgoHitPruning::fillChiSquared(), CSCSegAlgoSK::fillChiSquared(), CSCSegAlgoTC::fillChiSquared(), CSCSegAlgoST::fillChiSquared(), SiPixelRecHitsValid::fillForward(), TrackerValidationVariables::fillHitQuantities(), ReferenceTrajectory::fillMeasurementAndError(), MuonIdProducer::fillMuonId(), CSCEfficiency::fillRechitsSegments_info(), RoadSearchTrackCandidateMakerAlgorithm::FindBestHits(), SETFilter::findChi2(), CollinearFitAtTM2::fit(), CollinearFitAtTM::fit(), CSCSegAlgoHitPruning::fitSlopes(), CSCSegAlgoST::fitSlopes(), CSCSegAlgoTC::fitSlopes(), CSCSegAlgoSK::fitSlopes(), GlobalTrajectoryBuilderBase::fixTEC(), BaseSiTrackerRecHit2DLocalPos::getKfComponents(), HelpertRecHit2DLocalPos::getKfComponents(), GSSiTrackerRecHit2DLocalPos::getKfComponents(), BaseTrackerRecHit::getKfComponents2D(), TrackDetectorAssociator::getTAMuonChamberMatches(), CachedTrajectory::getWideTrajectory(), TkPixelMeasurementDet::hasBadComponents(), BaseTrackerRecHit::hasPositionAndError(), BaseSiTrackerRecHit2DLocalPos::hasPositionAndError(), TrackerMuonHitExtractor::init(), RoadSearchTrackCandidateMakerAlgorithm::initialTrajectory(), SimpleConeBounds::inside(), SimpleCylinderBounds::inside(), TrapezoidalPlaneBounds::inside(), GeneralTrapezoidalPlaneBounds::inside(), CSCLayerGeometry::inside(), DiskSectorBounds::inside(), GeneralNSurfaceDelimitedBounds::inside(), RectangularPlaneBounds::inside(), SimpleDiskBounds::inside(), ShallowGainCalibration::IsFarFromBorder(), DeDxDiscriminatorTools::IsFarFromBorder(), SiStripGainFromData::IsFarFromBorder(), TrackerRecHit::largerError(), TrackerRecHit::localError(), StripCPEfromTemplate::localParameters(), TwoBodyDecayTrajectoryFactory::match(), GlobalMuonTrackMatcher::match_dist(), BarrelMeasurementEstimator::maximalLocalDisplacement(), ForwardMeasurementEstimator::maximalLocalDisplacement(), Chi2MeasurementEstimatorBase::maximalLocalDisplacement(), cms::HICSeedMeasurementEstimator::maximalLocalDisplacement(), DTTopology::measurementError(), RadialStripTopology::measurementError(), operator<<(), RecHit2DLocalPos::parametersError(), MuonTransientTrackingRecHit::parametersError(), GCC11_FINAL::parametersError(), HelpertRecHit2DLocalPos::parError(), CSCSegmentValidation::plotResolution(), CSCRecHit2DValidation::plotResolution(), HIPAlignmentAlgorithm::processHit2D(), MuonTrackProducer::produce(), AlignmentMuonHIPTrajectorySelector::produce(), TrackingRecHitProjector< ResultingHit >::project(), GSRecHitMatcher::projectOnly(), RecHitPropagator::propagate(), rotateCosSin(), RoadSearchTrackCandidateMakerAlgorithm::run(), TrackCandidateProducer::sameLocalParameters(), scale(), StateSegmentMatcher::setAPE4d(), SiTrackerGaussianSmearingRecHitConverter::smearHits(), TkGluedMeasurementDet::testStrips(), TrackEfficiencyMonitor::testTrackerTracks(), trajectoryToResiduals(), ErrorFrameTransformer::transform(), CSCSegAlgoShowering::updateParameters(), CSCSegAlgoDF::updateParameters(), HelpertRecHit2DLocalPos::updateWithAPE(), CSCSegAlgoTC::weightMatrix(), CSCSegAlgoST::weightMatrix(), CSCSegAlgoShowering::weightMatrix(), CSCSegAlgoHitPruning::weightMatrix(), CSCSegAlgoSK::weightMatrix(), CSCSegAlgoDF::weightMatrix(), and SimpleNavigableLayer::wellInside().

{ return theyy;}

Member Data Documentation

float LocalError::thexx [private]

Definition at line 58 of file LocalError.h.

Referenced by invalid(), and xx().

float LocalError::thexy [private]

Definition at line 59 of file LocalError.h.

Referenced by xy().

float LocalError::theyy [private]

Definition at line 60 of file LocalError.h.

Referenced by yy().