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 159 of file JetAnalyzer_HeavyIons_matching.h.

Member Function Documentation

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 161 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.

161  {
162  MyJet jet1_pair1 = A1.first;
163  MyJet jet2_pair1 = A1.second;
164  MyJet jet1_pair2 = A2.first;
165  MyJet jet2_pair2 = A2.second;
166  float delr1 = deltaRR(jet1_pair1.eta, jet1_pair1.phi, jet2_pair1.eta, jet2_pair1.phi);
167  float delr2 = deltaRR(jet1_pair2.eta, jet1_pair2.phi, jet2_pair2.eta, jet2_pair2.phi);
168 
169  return ((delr1 < delr2) && (jet1_pair1.pt > jet1_pair2.pt));
170 
171  }
static float deltaRR(float eta1, float phi1, float eta2, float phi2)