#include <JetConvergenceDistance.h>
Public Member Functions | |
JetConvergenceDistance (double etaToPhiBandwidthRatio, double relativePtBandwidth) | |
double | operator() (const fftjet::RecombinedJet< VectorLike > &jet1, const fftjet::RecombinedJet< VectorLike > &jet2) const |
Private Member Functions | |
JetConvergenceDistance () | |
Private Attributes | |
double | etaBw_ |
double | phiBw_ |
double | ptBw_ |
Definition at line 10 of file JetConvergenceDistance.h.
fftjetcms::JetConvergenceDistance::JetConvergenceDistance | ( | double | etaToPhiBandwidthRatio, |
double | relativePtBandwidth | ||
) |
fftjetcms::JetConvergenceDistance::JetConvergenceDistance | ( | ) | [private] |
double fftjetcms::JetConvergenceDistance::operator() | ( | const fftjet::RecombinedJet< VectorLike > & | jet1, |
const fftjet::RecombinedJet< VectorLike > & | jet2 | ||
) | const |
Definition at line 18 of file JetConvergenceDistance.cc.
References etaBw_, M_PI, mag2(), phiBw_, ptBw_, and mathSSE::sqrt().
{ const double deta = (j1.vec().Eta() - j2.vec().Eta())/etaBw_; double dphi = j1.vec().Phi() - j2.vec().Phi(); if (dphi > M_PI) dphi -= (2.0*M_PI); else if (dphi < -M_PI) dphi += (2.0*M_PI); dphi /= phiBw_; const double mag1 = j1.magnitude(); const double mag2 = j2.magnitude(); double dmag = 0.0; if (mag1 > 0.0 || mag2 > 0.0) dmag = 2.0*(mag1 - mag2)/(mag1 + mag2)/ptBw_; return sqrt(deta*deta + dphi*dphi + dmag*dmag); }
double fftjetcms::JetConvergenceDistance::etaBw_ [private] |
Definition at line 24 of file JetConvergenceDistance.h.
Referenced by operator()().
double fftjetcms::JetConvergenceDistance::phiBw_ [private] |
Definition at line 25 of file JetConvergenceDistance.h.
Referenced by operator()().
double fftjetcms::JetConvergenceDistance::ptBw_ [private] |
Definition at line 26 of file JetConvergenceDistance.h.
Referenced by operator()().