ATLAS Offline Software
Functions
AnalysisUtils::Delta Namespace Reference

compute \( \Delta \) More...

Functions

double phi (const INavigable4Momentum *p1, const INavigable4Momentum *p2)
 \( \Delta\phi \) More...
 
double R (const INavigable4Momentum *p1, const double v_eta, const double v_phi)
 \( \Delta{R} \) More...
 
double R (const INavigable4Momentum *p1, const INavigable4Momentum *p2)
 \( \Delta{R} \) More...
 

Detailed Description

compute \( \Delta \)

Function Documentation

◆ phi()

double AnalysisUtils::Delta::phi ( const INavigable4Momentum p1,
const INavigable4Momentum p2 
)
inline

\( \Delta\phi \)

Definition at line 39 of file AnalysisMisc.h.

39  {
40  double phi1 = (p1->phi()>M_PI) ? p1->phi()-2*M_PI : p1->phi();
41  double phi2 = (p2->phi()>M_PI) ? p2->phi()-2*M_PI : p2->phi();
42  double dphi = fabs(phi1-phi2);
43  if(dphi>M_PI) dphi = 2*M_PI-dphi;
44  return dphi;
45  }

◆ R() [1/2]

double AnalysisUtils::Delta::R ( const INavigable4Momentum p1,
const double  v_eta,
const double  v_phi 
)
inline

\( \Delta{R} \)

Definition at line 49 of file AnalysisMisc.h.

49  {
50  double phi1 = (p1->phi()>M_PI) ? p1->phi()-2*M_PI : p1->phi();
51  double phi2 = (v_phi>M_PI) ? v_phi-2*M_PI : v_phi;
52  double dphi = fabs(phi1-phi2);
53  if(dphi>M_PI) dphi = 2*M_PI-dphi;
54  double deta = p1->eta() - v_eta;
55  return sqrt(dphi*dphi+deta*deta);
56  }

◆ R() [2/2]

double AnalysisUtils::Delta::R ( const INavigable4Momentum p1,
const INavigable4Momentum p2 
)
inline

\( \Delta{R} \)

Definition at line 60 of file AnalysisMisc.h.

60  {
61  return R (p1, p2->eta(), p2->phi());
62  }
AnalysisUtils::Match::R
bool R(const INavigable4Momentum *t, COLL *coll, int &index, double &deltaR, double &deltaE)
find the closest element in R (not check PDG ID) - with a condition on E
Definition: AnalysisMisc.h:241
TRTCalib_cfilter.p1
p1
Definition: TRTCalib_cfilter.py:130
M_PI
#define M_PI
Definition: ActiveFraction.h:11
TRTCalib_cfilter.p2
p2
Definition: TRTCalib_cfilter.py:131