Functions | |
FreeTrajectoryState | initialFreeState (const reco::Track &tk, const MagneticField *field) |
FreeTrajectoryState | innerFreeState (const reco::Track &tk, const MagneticField *field) |
TrajectoryStateOnSurface | innerStateOnSurface (const reco::Track &tk, const TrackingGeometry &geom, const MagneticField *field) |
FreeTrajectoryState | outerFreeState (const reco::Track &tk, const MagneticField *field) |
TrajectoryStateOnSurface | outerStateOnSurface (const reco::Track &tk, const TrackingGeometry &geom, const MagneticField *field) |
PTrajectoryStateOnDet | persistentState (const TrajectoryStateOnSurface &ts, unsigned int detid) |
TrajectoryStateOnSurface | transientState (const PTrajectoryStateOnDet &ts, const Surface *surface, const MagneticField *field) |
FreeTrajectoryState trajectoryStateTransform::initialFreeState | ( | const reco::Track & | tk, |
const MagneticField * | field | ||
) |
Construct a FreeTrajectoryState from the reco::Track innermost or outermost state, does not require access to tracking geometry
Definition at line 68 of file TrajectoryStateTransform.cc.
References reco::TrackBase::charge(), reco::TrackBase::covariance(), reco::TrackBase::momentum(), pos, and reco::TrackBase::vertex().
Referenced by TrackDetectorAssociator::associate(), V0Fitter::fitAll(), TrackAssociatorByPosition::getState(), TSGForRoadSearch::IPfts(), TSGFromPropagation::outerTkState(), FastTSGFromPropagation::outerTkState(), MuonErrorMatrixAdjuster::produce(), MuonTrackingRegionBuilder::region(), MatcherUsingTracksAlgorithm::startingState(), and PropagateToMuon::startingState().
{ Basic3DVector<float> pos( tk.vertex()); GlobalPoint gpos( pos); Basic3DVector<float> mom( tk.momentum()); GlobalVector gmom( mom); GlobalTrajectoryParameters par( gpos, gmom, tk.charge(), field); CurvilinearTrajectoryError err( tk.covariance()); return FreeTrajectoryState( par, err); }
FreeTrajectoryState trajectoryStateTransform::innerFreeState | ( | const reco::Track & | tk, |
const MagneticField * | field | ||
) |
Definition at line 80 of file TrajectoryStateTransform.cc.
References reco::TrackBase::charge(), reco::Track::extra(), reco::Track::innerMomentum(), reco::Track::innerPosition(), and pos.
Referenced by BetaCalculatorECAL::addInfoToCandidate(), TrackDetectorAssociator::associate(), innerStateOnSurface(), EgammaHLTPixelMatchElectronAlgo::process(), TrackClusterSplitter::produce(), MatcherUsingTracksAlgorithm::startingState(), and PropagateToMuon::startingState().
{ Basic3DVector<float> pos( tk.innerPosition()); GlobalPoint gpos( pos); Basic3DVector<float> mom( tk.innerMomentum()); GlobalVector gmom( mom); GlobalTrajectoryParameters par( gpos, gmom, tk.charge(), field); CurvilinearTrajectoryError err( tk.extra()->innerStateCovariance()); return FreeTrajectoryState( par, err); }
TrajectoryStateOnSurface trajectoryStateTransform::innerStateOnSurface | ( | const reco::Track & | tk, |
const TrackingGeometry & | geom, | ||
const MagneticField * | field | ||
) |
Construct a TrajectoryStateOnSurface from the reco::Track innermost or outermost state, requires access to tracking geometry
Definition at line 106 of file TrajectoryStateTransform.cc.
References reco::Track::extra(), TrackingGeometry::idToDet(), innerFreeState(), and GeomDet::surface().
Referenced by ConversionProducer::checkPhi(), GlobalMuonTrackMatcher::convertToTSOSMuHit(), GlobalMuonTrackMatcher::convertToTSOSTkHit(), MuonShowerInformationFiller::getCompatibleDets(), NuclearTrackCorrector::getInitialState(), GlobalTrajectoryBuilderBase::getTransientRecHits(), GlobalCosmicMuonTrajectoryBuilder::getTransientRecHits(), ConversionSeedFilter::getTSOS(), reco::TrackTransientTrack::innermostMeasurementState(), TSGFromPropagation::innerState(), FastTSGFromPropagation::innerState(), reco::modules::CosmicTrackSplitter::makeCandidate(), reco::modules::TrackerTrackHitFilter::makeCandidate(), GlobalCosmicMuonTrajectoryBuilder::match(), TkConvValidator::recalculateMomentumAtFittedVertex(), MatcherUsingTracksAlgorithm::targetState(), and GlobalCosmicMuonTrajectoryBuilder::trajectories().
{ const Surface& surface = geom.idToDet( DetId( tk.extra()->innerDetId()))->surface(); return TrajectoryStateOnSurface( innerFreeState( tk, field), surface); }
FreeTrajectoryState trajectoryStateTransform::outerFreeState | ( | const reco::Track & | tk, |
const MagneticField * | field | ||
) |
Definition at line 93 of file TrajectoryStateTransform.cc.
References reco::TrackBase::charge(), reco::Track::extra(), reco::Track::outerMomentum(), reco::Track::outerPosition(), and pos.
Referenced by TrackDetectorAssociator::associate(), outerStateOnSurface(), MatcherUsingTracksAlgorithm::startingState(), and PropagateToMuon::startingState().
{ Basic3DVector<float> pos( tk.outerPosition()); GlobalPoint gpos( pos); Basic3DVector<float> mom( tk.outerMomentum()); GlobalVector gmom( mom); GlobalTrajectoryParameters par( gpos, gmom, tk.charge(), field); CurvilinearTrajectoryError err( tk.extra()->outerStateCovariance()); return FreeTrajectoryState( par, err); }
TrajectoryStateOnSurface trajectoryStateTransform::outerStateOnSurface | ( | const reco::Track & | tk, |
const TrackingGeometry & | geom, | ||
const MagneticField * | field | ||
) |
Definition at line 114 of file TrajectoryStateTransform.cc.
References reco::Track::extra(), TrackingGeometry::idToDet(), outerFreeState(), and GeomDet::surface().
Referenced by GlobalMuonTrackMatcher::convertToTSOSMuHit(), GlobalMuonTrackMatcher::convertToTSOSTk(), GlobalMuonTrackMatcher::convertToTSOSTkHit(), MuonShowerInformationFiller::getCompatibleDets(), NuclearTrackCorrector::getInitialState(), ConversionProducer::getTrackImpactPosition(), reco::modules::CosmicTrackSplitter::makeCandidate(), reco::modules::TrackerTrackHitFilter::makeCandidate(), GlobalCosmicMuonTrajectoryBuilder::match(), reco::TrackTransientTrack::outermostMeasurementState(), MatcherUsingTracksAlgorithm::targetState(), and GlobalCosmicMuonTrajectoryBuilder::trajectories().
{ const Surface& surface = geom.idToDet( DetId( tk.extra()->outerDetId()))->surface(); return TrajectoryStateOnSurface( outerFreeState( tk, field), surface); }
PTrajectoryStateOnDet trajectoryStateTransform::persistentState | ( | const TrajectoryStateOnSurface & | ts, |
unsigned int | detid | ||
) |
should check if corresponds to m
should check if corresponds to m
Definition at line 16 of file TrajectoryStateTransform.cc.
References cond::rpcobgas::detid, TrajectoryStateOnSurface::hasError(), i, j, gen::k, TrajectoryStateOnSurface::localError(), TrajectoryStateOnSurface::localParameters(), m, LocalTrajectoryError::matrix(), and TrajectoryStateOnSurface::surfaceSide().
Referenced by SiStripElectronSeedGenerator::altCheckHitsAndTSOS(), SeedForPhotonConversion1Leg::buildSeed(), SeedFromConsecutiveHitsCreator::buildSeed(), SeedFromGenericPairOrTriplet::buildSeed(), SeedForPhotonConversionFromQuadruplets::buildSeed(), SiStripElectronSeedGenerator::checkHitsAndTSOS(), SeedFromNuclearInteraction::construct(), RPCSeedPattern::createFakeSeed(), MuonSeedCreator::createSeed(), TSGFromPropagation::createSeed(), FastTSGFromPropagation::createSeed(), RPCSeedPattern::createSeed(), OutInConversionSeedFinder::createSeed(), InOutConversionSeedFinder::createSeed(), MuonSeedFromRecHits::createSeed(), RoadSearchTrackCandidateMakerAlgorithm::createSeedTrajectory(), SiStripElectronAlgo::findElectron(), SeedFromProtoTrack::init(), reco::modules::CosmicTrackSplitter::makeCandidate(), reco::modules::TrackerTrackHitFilter::makeCandidate(), SETSeedFinder::makeSeed(), GlobalTrackerMuonAlignment::muonFitter(), ElectronSeedGenerator::prepareElTrackSeed(), FastElectronSeedGenerator::prepareElTrackSeed(), RoadSearchTrackCandidateMakerAlgorithm::PrepareTrackCandidates(), L2MuonSeedGenerator::produce(), TrajectorySeedFromMuonProducer::produce(), TrackCandidateProducer::produce(), SETMuonSeedProducer::produce(), TrackerToMuonPropagator::produce(), cms::CosmicTrackFinder::produce(), ConvBremSeedProducer::produce(), CSCOverlapsTrackPreparation::produce(), cms::CkfTrackCandidateMakerBase::produceBase(), TSGForRoadSearch::pushTrajectorySeed(), KalmanAlignmentTrackRefitter::refitSingleTracklet(), TrackInfoProducerAlgorithm::run(), RoadSearchTrackCandidateMakerAlgorithm::run(), SeedGeneratorForCRack::seeds(), SimpleCosmicBONSeeder::seeds(), SeedGeneratorForCosmics::seeds(), GlobalTrackerMuonAlignment::trackFitter(), OutInConversionTrackFinder::tracks(), InOutConversionTrackFinder::tracks(), StandAloneMuonTrajectoryBuilder::trajectories(), CosmicSeedCreator::trajectorySeed(), and CosmicMuonSeedGenerator::tsosToSeed().
{ int surfaceSide = static_cast<int>(ts.surfaceSide()); if (ts.hasError()) { AlgebraicSymMatrix55 m = ts.localError().matrix(); int dim = 5; float localErrors[15]; int k = 0; for (int i=0; i<dim; i++) { for (int j=0; j<=i; j++) { localErrors[k++] = m(i,j); } } return PTrajectoryStateOnDet(ts.localParameters(), localErrors, detid, surfaceSide); } return PTrajectoryStateOnDet(ts.localParameters(), detid, surfaceSide); }
TrajectoryStateOnSurface trajectoryStateTransform::transientState | ( | const PTrajectoryStateOnDet & | ts, |
const Surface * | surface, | ||
const MagneticField * | field | ||
) |
Definition at line 43 of file TrajectoryStateTransform.cc.
References PTrajectoryStateOnDet::error(), PTrajectoryStateOnDet::hasError(), i, j, gen::k, m, PTrajectoryStateOnDet::parameters(), and PTrajectoryStateOnDet::surfaceSide().
Referenced by TestHits::analyze(), ElectronSeedAnalyzer::analyze(), TrackBuildingAnalyzer::analyze(), TestSmoothHits::analyze(), TrackerSeedCleaner::clean(), MuonCkfTrajectoryBuilder::findCompatibleMeasurements(), BaseCkfTrajectoryBuilder::findStateAndLayers(), MuonTrackAnalyzer::getSeedTSOS(), MuonSeedsAnalyzer::getSeedTSOS(), MuonSeedTrack::getSeedTSOS(), ConversionSeedFilter::getTSOS(), MuonRoadTrajectoryBuilder::makeTrajectories_0(), CtfSpecialSeedGenerator::postCheck(), TrackCandidateProducer::produce(), TrackProducerWithSCAssociation::produce(), ConversionSeedFilterCharge::produce(), BaseCkfTrajectoryBuilder::seedMeasurements(), MuonSeedCleaner::SeedMomentum(), MuonSeedCleaner::SeedPosition(), SeedTransformer::seedTransientState(), StartingLayerFinder::startingLayers(), CRackTrajectoryBuilder::startingTSOS(), CosmicTrajectoryBuilder::startingTSOS(), FastTSGFromPropagation::trackerSeeds(), and CosmicMuonTrajectoryBuilder::trajectories().
{ AlgebraicSymMatrix55 m; bool errInv=true; if (ts.hasError()) { errInv = false; int dim = 5; int k = 0; for (int i=0; i<dim; i++) { for (int j=0; j<=i; j++) { m(i,j) = ts.error(k++); // NOTE: here we do a cast float => double. } } } return TrajectoryStateOnSurface( ts.parameters(), errInv ? LocalTrajectoryError(InvalidError()) : LocalTrajectoryError(m), *surface, field, static_cast<SurfaceSide>(ts.surfaceSide())); }