|
ATLAS Offline Software
|
Go to the documentation of this file.
11 #ifndef FOURMOMUTILS_XAODP4HELPERS_H
12 #define FOURMOMUTILS_XAODP4HELPERS_H
41 return p1.rapidity() -
p2.rapidity();
56 return p1.eta() -
p2.eta();
111 double deltaR2(
double rapidity1,
double phi1,
double rapidity2,
double phi2 )
114 const double dRapidity = rapidity1-rapidity2;
115 return dRapidity*dRapidity +
dPhi*
dPhi;
150 double deltaR(
double rapidity1,
double phi1,
double rapidity2,
double phi2 )
175 double dR,
bool useRapidity=
true )
201 const double absPA = std::abs( pA.
p4().P() );
202 const double absPB = std::abs( pB.
p4().P() );
203 return absPA - absPB;
217 #endif // FOURMOMUTILS_XAODP4HELPERS_H
double deltaAbsP(const xAOD::IParticle &pA, const xAOD::IParticle &pB)
Get the delta-| | between two particles.
virtual double rapidity() const =0
The true rapidity (y) of the particle.
double deltaPhi(double phiA, double phiB)
delta Phi in range [-pi,pi[
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
P4Helpers provides static helper functions for kinematic calculation on objects deriving from I4Momen...
double deltaR2(double rapidity1, double phi1, double rapidity2, double phi2)
from bare rapidity,phi
Class providing the definition of the 4-vector interface.
bool greater(double a, double b)
Compare two FP numbers, working around x87 precision issues.
double deltaRapidity(const xAOD::IParticle &p1, const xAOD::IParticle &p2)
Computes efficiently .
double deltaR(double rapidity1, double phi1, double rapidity2, double phi2)
from bare bare rapidity,phi
bool dPhi(const xAOD::TauJet &tau, const xAOD::TauTrack &track, double &out)
Workaround x86 precision issues for FP inequality comparisons.
Principal data object for Missing ET.
std::vector< std::string > remainder(const std::vector< std::string > &v1, const std::vector< std::string > &v2)
list of entries in a vector that are not in another
virtual FourMom_t p4() const =0
The full 4-momentum of the particle.
virtual double eta() const =0
The pseudorapidity ( ) of the particle.
double deltaEta(const xAOD::IParticle &p1, const xAOD::IParticle &p2)
Computes efficiently .
virtual double phi() const =0
The azimuthal angle ( ) of the particle.
bool isInDeltaR(const xAOD::IParticle &p1, const xAOD::IParticle &p2, double dR, bool useRapidity=true)
Check if 2 xAOD::IParticle are in a cone.
bool dEta(const xAOD::TauJet &tau, const xAOD::TauTrack &track, double &out)