ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Reconstruction
Jet
JetSubStructureUtils
Root
KtDeltaR.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
JetSubStructureUtils/KtDeltaR.h
"
6
#include "fastjet/ClusterSequence.hh"
7
#include "fastjet/JetDefinition.hh"
8
#include "
FourMomUtils/xAODP4Helpers.h
"
9
#include <math.h>
10
#include <cmath>
11
using namespace
std
;
12
using namespace
JetSubStructureUtils
;
13
14
double
KtDeltaR::result
(
const
fastjet::PseudoJet &
jet
)
const
15
{
16
vector<fastjet::PseudoJet> constit_pseudojets =
jet
.constituents();
17
if
( constit_pseudojets.size() < 2 ) {
18
//Jet has fewer than 2 constituents.
19
return
0.0;
20
}
21
22
fastjet::JetDefinition jetdef = fastjet::JetDefinition(fastjet::kt_algorithm,
m_jetrad
);
23
fastjet::ClusterSequence cs(constit_pseudojets, jetdef);
24
std::vector<fastjet::PseudoJet> outjets = cs.exclusive_jets(2);
25
if
( outjets.size() < 2 ) {
26
//"Fewer than two subjets found.
27
return
0.0;
28
}
29
30
return
xAOD::P4Helpers::deltaR
(outjets[0].
eta
(), outjets[0].
phi
(),
31
outjets[1].
eta
(), outjets[1].
phi
());
32
}
eta
Scalar eta() const
pseudorapidity method
Definition
AmgMatrixBasePlugin.h:83
phi
Scalar phi() const
phi method
Definition
AmgMatrixBasePlugin.h:67
KtDeltaR.h
JetSubStructureUtils::KtDeltaR::m_jetrad
double m_jetrad
Definition
KtDeltaR.h:19
JetSubStructureUtils::KtDeltaR::result
virtual double result(const fastjet::PseudoJet &jet) const
Definition
KtDeltaR.cxx:14
JetSubStructureUtils
Definition
Angularity.h:10
jet
Definition
JetCalibTools_PlotJESFactors.cxx:23
std
STL namespace.
xAOD::P4Helpers::deltaR
double deltaR(double rapidity1, double phi1, double rapidity2, double phi2)
from bare bare rapidity,phi
Definition
xAODP4Helpers.h:150
xAODP4Helpers.h
Generated on
for ATLAS Offline Software by
1.17.0