1 #ifndef MuonAnalysis_MuonAssociators_MatcherUsingTracksAlgorithm_h 2 #define MuonAnalysis_MuonAssociators_MatcherUsingTracksAlgorithm_h 118 float &lastDeltaR,
float &lastDeltaEta,
float &lastDeltaPhi,
float &lastDeltaLocalPos,
float &lastGlobalDPtRel,
float &lastChi2)
const ;
123 float &lastDeltaR,
float &lastDeltaEta,
float &lastDeltaPhi,
float &lastDeltaLocalPos,
float &lastGlobalDPtRel,
float &lastChi2)
const ;
127 float &lastDeltaR,
float &lastDeltaEta,
float &lastDeltaPhi,
float &lastDeltaLocalPos,
float &lastGlobalDPtRel,
float &lastChi2)
const ;
virtual ~MatcherUsingTracksAlgorithm()
bool hasChi2() const
Return 'true' if the matcher will produce also chi2.
void getConf(const edm::ParameterSet &iConfig, const std::string &whatFor, WhichTrack &whichTrack, WhichState &whichState)
Parse some configuration.
ROOT::Math::SMatrix< double, 5, 5, ROOT::Math::MatRepSym< double, 5 > > AlgebraicSymMatrix55
static double getChi2(const FreeTrajectoryState &start, const FreeTrajectoryState &other, bool diagonalOnly, bool useVertex, bool useFirstMomentum)
bool matchWithPropagation(const FreeTrajectoryState &start, const FreeTrajectoryState &target, float &lastDeltaR, float &lastDeltaEta, float &lastDeltaPhi, float &lastDeltaLocalPos, float &lastGlobalDPtRel, float &lastChi2) const
static const double deltaEta
float maxGlobalMomDeltaEta_
bool hasMetrics() const
Return 'true' if the matcher will produce meaningful deltaR, deltaLocalPos, deltaPtRel values...
edm::ESHandle< GlobalTrackingGeometry > geometry_
edm::ESHandle< MagneticField > magfield_
MatcherUsingTracksAlgorithm(const edm::ParameterSet &iConfig)
float maxGlobalMomDeltaPhi_
edm::ESHandle< Propagator > propagator_
TrajectoryStateOnSurface targetState(const reco::Candidate &reco, WhichTrack whichTrack, WhichState whichState) const
End state for the propagation.
StringCutObjectSelector< reco::Candidate, true > srcCut_
float maxGlobalMomDeltaR_
FreeTrajectoryState startingState(const reco::Candidate &reco, WhichTrack whichTrack, WhichState whichState) const
Starting state for the propagation.
static void cropAndInvert(AlgebraicSymMatrix55 &cov, bool diagonalOnly, bool top3by3only)
Possibly crop the 3x3 part of the matrix or remove off-diagonal terms, then invert.
bool match(const reco::Candidate &c1, const reco::Candidate &c2, float &deltaR, float &deltaEta, float &deltaPhi, float &deltaLocalPos, float &deltaPtRel, float &chi2) const
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)
StringCutObjectSelector< reco::Candidate, true > matchedCut_
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...