CMS 3D CMS Logo

Public Member Functions | Private Attributes

LocalError Class Reference

#include <LocalError.h>

List of all members.

Public Member Functions

 LocalError ()
 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
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 11 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 ( float  xx,
float  xy,
float  yy 
) [inline]

Definition at line 16 of file LocalError.h.

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

Member Function Documentation

LocalError LocalError::rotate ( float  x,
float  y 
) const [inline]
LocalError LocalError::rotate ( float  phi) const [inline]

Return a new LocalError, rotated by an angle phi.

Definition at line 39 of file LocalError.h.

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

                                     { 
    return rotateCosSin( cos(phi), sin(phi));
  }
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 44 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 28 of file LocalError.h.

References LocalError(), asciidump::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());
  }
float LocalError::xx ( ) const [inline]

Definition at line 19 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(), SiPixelHitEfficiencySource::analyze(), MuonIdVal::analyze(), SiPixelErrorEstimation::analyze(), SiPixelTrackingRecHitsValid::analyze(), SiStripRecHitsValid::analyze(), SiPixelRecHitSource::analyze(), MuonIdDQM::analyze(), DTSegment2DSLPhiQuality::analyze(), SiStripTrackingRecHitsValid::analyze(), FWCSCRecHitProxyBuilder::build(), FWRPCRecHitProxyBuilder::buildViewType(), SiTrackerMultiRecHitUpdatorMTF::calcParameters(), SiTrackerMultiRecHitUpdator::calcParameters(), 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(), SiStripRecHit1D::getKfComponents(), BaseSiTrackerRecHit2DLocalPos::getKfComponents(), HelpertRecHit2DLocalPos::getKfComponents(), GSSiTrackerRecHit2DLocalPos::getKfComponents(), TrackDetectorAssociator::getTAMuonChamberMatches(), CachedTrajectory::getWideTrajectory(), TkPixelMeasurementDet::hasBadComponents(), SiStripRecHit1D::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(), RectangularStripTopology::measurementError(), TrapezoidalStripTopology::measurementError(), RadialStripTopology::measurementError(), RectangularPixelTopology::measurementError(), MuonResidualsFromTrack::MuonResidualsFromTrack(), operator<<(), TRecHit2DPosConstraint::parametersError(), BeamSpotTransientTrackingRecHit::parametersError(), RecHit2DLocalPos::parametersError(), MuonTransientTrackingRecHit::parametersError(), RecHit1D::parametersError(), DTSLRecCluster::parError(), HelpertRecHit2DLocalPos::parError(), CSCRecHit2DValidation::plotResolution(), CSCSegmentValidation::plotResolution(), HIPAlignmentAlgorithm::processHit1D(), HIPAlignmentAlgorithm::processHit2D(), ShallowRechitClustersProducer::produce(), MuonTrackProducer::produce(), AlignmentMuonHIPTrajectorySelector::produce(), TrackingRecHitProjector< ResultingHit >::project(), GSRecHitMatcher::projectOnly(), RecHitPropagator::propagate(), CSCSegAlgoST::prune_bad_hits(), CSCSegAlgoHitPruning::pruneBadHits(), DTRecHitQuality::recHitPositionError(), rotateCosSin(), RoadSearchTrackCandidateMakerAlgorithm::run(), scale(), SiStripRecHit1D::SiStripRecHit1D(), SiTrackerGaussianSmearingRecHitConverter::smearHits(), TkGluedMeasurementDet::testStrips(), TrackEfficiencyMonitor::testTrackerTracks(), trajectoryToResiduals(), ErrorFrameTransformer::transform(), CSCSegAlgoDF::updateParameters(), CSCSegAlgoShowering::updateParameters(), HelpertRecHit2DLocalPos::updateWithAPE(), CSCSegAlgoTC::weightMatrix(), CSCSegAlgoShowering::weightMatrix(), CSCSegAlgoST::weightMatrix(), CSCSegAlgoHitPruning::weightMatrix(), CSCSegAlgoSK::weightMatrix(), CSCSegAlgoDF::weightMatrix(), SimpleNavigableLayer::wellInside(), and MuRodBarrelLayer::xError().

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

Definition at line 20 of file LocalError.h.

References thexy.

Referenced by MuonCSCChamberResidual::addResidual(), TrackDetectorAssociator::addTAMuonSegmentMatch(), SiStripElectronAnalyzer::analyze(), SiStripRecHitsValid::analyze(), SiStripTrackingRecHitsValid::analyze(), SiTrackerMultiRecHitUpdatorMTF::calcParameters(), SiTrackerMultiRecHitUpdator::calcParameters(), 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(), CachedTrajectory::getWideTrajectory(), SiStripRecHit1D::hasPositionAndError(), BaseSiTrackerRecHit2DLocalPos::hasPositionAndError(), DiskSectorBounds::inside(), SimpleDiskBounds::inside(), TrackerRecHit::largerError(), TrackerRecHit::localError(), GlobalMuonTrackMatcher::match_dist(), RectangularStripTopology::measurementError(), TrapezoidalStripTopology::measurementError(), RadialStripTopology::measurementError(), operator<<(), TRecHit2DPosConstraint::parametersError(), RecHit2DLocalPos::parametersError(), MuonTransientTrackingRecHit::parametersError(), HelpertRecHit2DLocalPos::parError(), HIPAlignmentAlgorithm::processHit2D(), AlignmentMuonHIPTrajectorySelector::produce(), TrackingRecHitProjector< ResultingHit >::project(), GSRecHitMatcher::projectOnly(), RecHitPropagator::propagate(), rotateCosSin(), 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 21 of file LocalError.h.

References theyy.

Referenced by MuonCSCChamberResidual::addResidual(), TrackDetectorAssociator::addTAMuonSegmentMatch(), CkfDebugger::analyseCompatibleMeasurements(), SiStripElectronAnalyzer::analyze(), TrackerDpgAnalysis::analyze(), DTSegment4DQuality::analyze(), SiPixelHitEfficiencySource::analyze(), MuonIdVal::analyze(), SiPixelErrorEstimation::analyze(), SiPixelTrackingRecHitsValid::analyze(), SiStripRecHitsValid::analyze(), MuonIdDQM::analyze(), SiPixelRecHitSource::analyze(), SiStripTrackingRecHitsValid::analyze(), FWCSCRecHitProxyBuilder::build(), FWRPCRecHitProxyBuilder::buildViewType(), SiTrackerMultiRecHitUpdatorMTF::calcParameters(), SiTrackerMultiRecHitUpdator::calcParameters(), 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(), TrackDetectorAssociator::getTAMuonChamberMatches(), CachedTrajectory::getWideTrajectory(), TkPixelMeasurementDet::hasBadComponents(), SiStripRecHit1D::hasPositionAndError(), BaseSiTrackerRecHit2DLocalPos::hasPositionAndError(), TrackerMuonHitExtractor::init(), RoadSearchTrackCandidateMakerAlgorithm::initialTrajectory(), TrapezoidalPlaneBounds::inside(), SimpleCylinderBounds::inside(), SimpleConeBounds::inside(), CSCLayerGeometry::inside(), GeneralTrapezoidalPlaneBounds::inside(), DiskSectorBounds::inside(), GeneralNSurfaceDelimitedBounds::inside(), RectangularPlaneBounds::inside(), SimpleDiskBounds::inside(), ShallowGainCalibration::IsFarFromBorder(), DeDxDiscriminatorTools::IsFarFromBorder(), SiStripGainFromData::IsFarFromBorder(), TrackerRecHit::largerError(), TrackerRecHit::localError(), TwoBodyDecayTrajectoryFactory::match(), GlobalMuonTrackMatcher::match_dist(), BarrelMeasurementEstimator::maximalLocalDisplacement(), ForwardMeasurementEstimator::maximalLocalDisplacement(), Chi2MeasurementEstimatorBase::maximalLocalDisplacement(), cms::HICSeedMeasurementEstimator::maximalLocalDisplacement(), DTTopology::measurementError(), RectangularStripTopology::measurementError(), TrapezoidalStripTopology::measurementError(), RadialStripTopology::measurementError(), RectangularPixelTopology::measurementError(), operator<<(), TRecHit2DPosConstraint::parametersError(), RecHit2DLocalPos::parametersError(), MuonTransientTrackingRecHit::parametersError(), HelpertRecHit2DLocalPos::parError(), CSCRecHit2DValidation::plotResolution(), CSCSegmentValidation::plotResolution(), HIPAlignmentAlgorithm::processHit2D(), ShallowRechitClustersProducer::produce(), MuonTrackProducer::produce(), AlignmentMuonHIPTrajectorySelector::produce(), TrackingRecHitProjector< ResultingHit >::project(), GSRecHitMatcher::projectOnly(), RecHitPropagator::propagate(), rotateCosSin(), RoadSearchTrackCandidateMakerAlgorithm::run(), scale(), 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 53 of file LocalError.h.

Referenced by xx().

float LocalError::thexy [private]

Definition at line 54 of file LocalError.h.

Referenced by xy().

float LocalError::theyy [private]

Definition at line 55 of file LocalError.h.

Referenced by yy().