CMS 3D CMS Logo

List of all members | Public Member Functions
JetAnalyzer_HeavyIons_matching::CompareMatchedJets Struct Reference

Public Member Functions

bool operator() (const ABJetPair &A1, const ABJetPair &A2) const
 A-B jet match. More...
 

Detailed Description

Definition at line 146 of file JetAnalyzer_HeavyIons_matching.h.

Member Function Documentation

◆ operator()()

bool JetAnalyzer_HeavyIons_matching::CompareMatchedJets::operator() ( const ABJetPair A1,
const ABJetPair A2 
) const
inline

A-B jet match.

Jet1 1st pair

Jet2 1st pair

Jet1 2nd pair

Jet2 2nd pair

Definition at line 148 of file JetAnalyzer_HeavyIons_matching.h.

References JetAnalyzer_HeavyIons_matching::deltaRR(), JetAnalyzer_HeavyIons_matching::MyJet::eta, JetAnalyzer_HeavyIons_matching::MyJet::phi, and JetAnalyzer_HeavyIons_matching::MyJet::pt.

148  {
149  MyJet jet1_pair1 = A1.first;
150  MyJet jet2_pair1 = A1.second;
151  MyJet jet1_pair2 = A2.first;
152  MyJet jet2_pair2 = A2.second;
153  float delr1 = deltaRR(jet1_pair1.eta, jet1_pair1.phi, jet2_pair1.eta, jet2_pair1.phi);
154  float delr2 = deltaRR(jet1_pair2.eta, jet1_pair2.phi, jet2_pair2.eta, jet2_pair2.phi);
155 
156  return ((delr1 < delr2) && (jet1_pair1.pt > jet1_pair2.pt));
157  }
static float deltaRR(float eta1, float phi1, float eta2, float phi2)