1 #ifndef MuonAnalysis_MuonAssociators_MatcherUsingTracksAlgorithm_h 2 #define MuonAnalysis_MuonAssociators_MatcherUsingTracksAlgorithm_h 80 bool useFirstMomentum);
159 float &lastDeltaLocalPos,
160 float &lastGlobalDPtRel,
161 float &lastChi2)
const;
170 float &lastDeltaLocalPos,
171 float &lastGlobalDPtRel,
172 float &lastChi2)
const;
180 float &lastDeltaLocalPos,
181 float &lastGlobalDPtRel,
182 float &lastChi2)
const;
FreeTrajectoryState startingState(const reco::Candidate &reco, WhichTrack whichTrack, WhichState whichState) const
Starting state for the propagation.
edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecord > geometryToken_
virtual ~MatcherUsingTracksAlgorithm()
bool match(const reco::Candidate &c1, const reco::Candidate &c2, float &deltaR, float &deltaEta, float &deltaPhi, float &deltaLocalPos, float &deltaPtRel, float &chi2) const
TrajectoryStateOnSurface targetState(const reco::Candidate &reco, WhichTrack whichTrack, WhichState whichState) const
End state for the propagation.
void getConf(const edm::ParameterSet &iConfig, const std::string &whatFor, WhichTrack &whichTrack, WhichState &whichState)
Parse some configuration.
bool matchWithPropagation(const FreeTrajectoryState &start, const FreeTrajectoryState &target, float &lastDeltaR, float &lastDeltaEta, float &lastDeltaPhi, float &lastDeltaLocalPos, float &lastGlobalDPtRel, float &lastChi2) const
edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > magfieldToken_
bool hasChi2() const
Return 'true' if the matcher will produce also chi2.
static double getChi2(const FreeTrajectoryState &start, const FreeTrajectoryState &other, bool diagonalOnly, bool useVertex, bool useFirstMomentum)
bool hasMetrics() const
Return 'true' if the matcher will produce meaningful deltaR, deltaLocalPos, deltaPtRel values...
static const double deltaEta
float maxGlobalMomDeltaEta_
StringCutObjectSelector< reco::Candidate, true > matchedCut_
edm::ESHandle< GlobalTrackingGeometry > geometry_
edm::ESHandle< MagneticField > magfield_
StringCutObjectSelector< reco::Candidate, true > srcCut_
float maxGlobalMomDeltaPhi_
edm::ESHandle< Propagator > propagator_
MatcherUsingTracksAlgorithm(const edm::ParameterSet &iConfig, edm::ConsumesCollector)
bool matchByDirectComparison(const FreeTrajectoryState &start, const FreeTrajectoryState &other, float &lastDeltaR, float &lastDeltaEta, float &lastDeltaPhi, float &lastDeltaLocalPos, float &lastGlobalDPtRel, float &lastChi2) const
Compare directly two states. return true if current pair is the new best match (in that case...
float maxGlobalMomDeltaR_
ROOT::Math::SMatrix< double, 5, 5, ROOT::Math::MatRepSym< double, 5 > > AlgebraicSymMatrix55
static void cropAndInvert(AlgebraicSymMatrix55 &cov, bool diagonalOnly, bool top3by3only)
Possibly crop the 3x3 part of the matrix or remove off-diagonal terms, then invert.
edm::ESGetToken< Propagator, TrackingComponentsRecord > propagatorToken_
void init(const edm::EventSetup &iSetup)
Call this method at the beginning of each run, to initialize geometry, magnetic field and propagators...
reco::TrackRef getTrack(const reco::Candidate &reco, WhichTrack which) const
Get track reference out of a Candidate (via dynamic_cast to reco::RecoCandidate)