ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
WTAJet Class Reference

#include <WTAObject.h>

Inheritance diagram for WTAJet:
Collaboration diagram for WTAJet:

Public Member Functions

 WTAJet (IntOrFloat pt=0, IntOrFloat eta=0, IntOrFloat phi=0, IntOrFloat m=0, IntOrFloat jet_dr2=R2PAR)
 
WTATrigObj GetSeed ()
 
void MergeConstituent (WTATrigObj &tower)
 
void MergeConstituent (WTATrigObj *tower)
 
void MergeWTAJet (WTAJet &targetjet)
 
void PopOutLastConstituent ()
 
const std::vector< WTATrigObj > & GetConstituentList () const
 
unsigned int GetConstituentCount () const
 
IntOrFloat pt () const
 
void pt (IntOrFloat pt)
 
IntOrFloat eta () const
 
void eta (IntOrFloat eta)
 
IntOrFloat phi () const
 
void phi (IntOrFloat phi)
 
IntOrFloat m () const
 
void m (IntOrFloat m)
 
IntOrFloat d_phi_0_2PI (WTATrigObj o2)
 
IntOrFloat d_phi_MPI_PI (WTATrigObj o2)
 
IntOrFloat d_eta (WTATrigObj o2)
 
IntOrFloat dR2 (WTATrigObj o2)
 
bool IsAssocdR (WTATrigObj &tower, IntOrFloat dr2)
 
WTATrigObj operator+ (const WTATrigObj &obj)
 

Private Attributes

WTATrigObj m_Seed
 
std::vector< WTATrigObjm_ConstituentList
 
IntOrFloat m_Jet_dR2
 
IntOrFloat m_pt
 
IntOrFloat m_eta
 
IntOrFloat m_phi
 
IntOrFloat m_m
 

Detailed Description

Definition at line 104 of file WTAObject.h.

Constructor & Destructor Documentation

◆ WTAJet()

WTAJet::WTAJet ( IntOrFloat  pt = 0,
IntOrFloat  eta = 0,
IntOrFloat  phi = 0,
IntOrFloat  m = 0,
IntOrFloat  jet_dr2 = R2PAR 
)
inline

Definition at line 106 of file WTAObject.h.

106  :
107  WTATrigObj(pt, eta, phi, m) {m_Seed = WTATrigObj(pt, eta, phi, m); m_Jet_dR2 = jet_dr2; m_ConstituentList.clear(); m_ConstituentList.push_back(m_Seed);};

Member Function Documentation

◆ d_eta()

IntOrFloat WTATrigObj::d_eta ( WTATrigObj  o2)
inlineinherited

Definition at line 49 of file WTAObject.h.

49 {IntOrFloat tmp = m_eta - o2.eta(); return tmp;}

◆ d_phi_0_2PI()

IntOrFloat WTATrigObj::d_phi_0_2PI ( WTATrigObj  o2)
inlineinherited

Definition at line 77 of file WTAObject.h.

78 {
79  IntOrFloat tmp = m_phi - o2.phi();
80  while(tmp < 0)tmp += 2*PI;
81  while(tmp > 2*PI)tmp -= 2*PI;
82  return tmp;
83 }

◆ d_phi_MPI_PI()

IntOrFloat WTATrigObj::d_phi_MPI_PI ( WTATrigObj  o2)
inlineinherited

Definition at line 84 of file WTAObject.h.

85 {
86  IntOrFloat tmp = m_phi - o2.phi();
87  while(tmp < -PI)tmp += 2*PI;
88  while(tmp > PI)tmp -= 2*PI;
89  return tmp;
90 }

◆ dR2()

IntOrFloat WTATrigObj::dR2 ( WTATrigObj  o2)
inlineinherited

Definition at line 91 of file WTAObject.h.

92 {
93  IntOrFloat d_phi = d_phi_MPI_PI(o2);
94  IntOrFloat d_eta_tmp = d_eta(o2);
95  IntOrFloat tmp = (d_phi * d_phi) + (d_eta_tmp * d_eta_tmp);
96  return tmp;
97 }

◆ eta() [1/2]

IntOrFloat WTATrigObj::eta ( ) const
inlineinherited

Definition at line 40 of file WTAObject.h.

40 {return m_eta;};

◆ eta() [2/2]

void WTATrigObj::eta ( IntOrFloat  eta)
inlineinherited

Definition at line 41 of file WTAObject.h.

41 {m_eta = eta;};

◆ GetConstituentCount()

unsigned int WTAJet::GetConstituentCount ( ) const
inline

Definition at line 115 of file WTAObject.h.

115 {return m_ConstituentList.size();}; // Need to quickly access the jet's constituent number

◆ GetConstituentList()

const std::vector<WTATrigObj>& WTAJet::GetConstituentList ( ) const
inline

Definition at line 114 of file WTAObject.h.

114 {return m_ConstituentList;};

◆ GetSeed()

WTATrigObj WTAJet::GetSeed ( )
inline

Definition at line 109 of file WTAObject.h.

109 {return m_Seed;};

◆ IsAssocdR()

bool WTATrigObj::IsAssocdR ( WTATrigObj tower,
IntOrFloat  dr2 
)
inlineinherited

Definition at line 99 of file WTAObject.h.

99  {
100  auto dR2 = this->dR2(tower);
101  return dR2 <= dr2;
102 }

◆ m() [1/2]

IntOrFloat WTATrigObj::m ( ) const
inlineinherited

Definition at line 44 of file WTAObject.h.

44 {return m_m;};

◆ m() [2/2]

void WTATrigObj::m ( IntOrFloat  m)
inlineinherited

Definition at line 45 of file WTAObject.h.

45 {m_m = m;};

◆ MergeConstituent() [1/2]

void WTAJet::MergeConstituent ( WTATrigObj tower)
inline

Definition at line 123 of file WTAObject.h.

124 {
125  this->pt(this->pt() + tower.pt());// Scalar sum, WTA
126  m_ConstituentList.push_back(tower);
127 }

◆ MergeConstituent() [2/2]

void WTAJet::MergeConstituent ( WTATrigObj tower)
inline

Definition at line 129 of file WTAObject.h.

130 {
131  this->pt(this->pt() + tower->pt());// Scalar sum, WTA
132  m_ConstituentList.push_back(*tower);
133 }

◆ MergeWTAJet()

void WTAJet::MergeWTAJet ( WTAJet targetjet)
inline

Definition at line 135 of file WTAObject.h.

136 {
137  WTATrigObj tmptower(targetjet.pt(), targetjet.eta(), targetjet.phi(), targetjet.m());
138  this->pt(this->pt() + tmptower.pt()); // Scalar sum, WTA
139  std::vector<WTATrigObj> tmp_const_list = targetjet.GetConstituentList();
140  m_ConstituentList.insert(m_ConstituentList.end(), tmp_const_list.begin(), tmp_const_list.end());
141 
142 }

◆ operator+()

WTATrigObj WTATrigObj::operator+ ( const WTATrigObj obj)
inlineinherited

Definition at line 60 of file WTAObject.h.

60  {
61  WTATrigObj new_obj;
62  new_obj.m_pt = this->pt() + obj.pt(); // Current default is the scalar sum, WTA
63  new_obj.m_eta = this->eta();
64  new_obj.m_phi = this->phi();
65  new_obj.m_m = this->m();
66  return new_obj;
67  };

◆ phi() [1/2]

IntOrFloat WTATrigObj::phi ( ) const
inlineinherited

Definition at line 42 of file WTAObject.h.

42 {return m_phi;};

◆ phi() [2/2]

void WTATrigObj::phi ( IntOrFloat  phi)
inlineinherited

Definition at line 43 of file WTAObject.h.

43 {m_phi = phi;};

◆ PopOutLastConstituent()

void WTAJet::PopOutLastConstituent ( )
inline

Definition at line 144 of file WTAObject.h.

145 {
146  WTATrigObj lastconst = m_ConstituentList.back(); //std::vector::back() returns the last element
147  this->pt(this->pt() - lastconst.pt()); // Scalar subtraction, WTA
148  m_ConstituentList.pop_back(); // Popback the last element
149 }

◆ pt() [1/2]

IntOrFloat WTATrigObj::pt ( ) const
inlineinherited

Definition at line 38 of file WTAObject.h.

38 {return m_pt;};

◆ pt() [2/2]

void WTATrigObj::pt ( IntOrFloat  pt)
inlineinherited

Definition at line 39 of file WTAObject.h.

39 {m_pt = pt;};

Member Data Documentation

◆ m_ConstituentList

std::vector<WTATrigObj> WTAJet::m_ConstituentList
private

Definition at line 119 of file WTAObject.h.

◆ m_eta

IntOrFloat WTATrigObj::m_eta
privateinherited

Definition at line 71 of file WTAObject.h.

◆ m_Jet_dR2

IntOrFloat WTAJet::m_Jet_dR2
private

Definition at line 120 of file WTAObject.h.

◆ m_m

IntOrFloat WTATrigObj::m_m
privateinherited

Definition at line 73 of file WTAObject.h.

◆ m_phi

IntOrFloat WTATrigObj::m_phi
privateinherited

Definition at line 72 of file WTAObject.h.

◆ m_pt

IntOrFloat WTATrigObj::m_pt
privateinherited

Definition at line 70 of file WTAObject.h.

◆ m_Seed

WTATrigObj WTAJet::m_Seed
private

Definition at line 118 of file WTAObject.h.


The documentation for this class was generated from the following file:
WTATrigObj::phi
IntOrFloat phi() const
Definition: WTAObject.h:42
WTATrigObj::m_phi
IntOrFloat m_phi
Definition: WTAObject.h:72
WTATrigObj::m_m
IntOrFloat m_m
Definition: WTAObject.h:73
PI
const float PI
Definition: test_isolaitonTool.cxx:61
WTAJet::m_Seed
WTATrigObj m_Seed
Definition: WTAObject.h:115
WTATrigObj::pt
IntOrFloat pt() const
Definition: WTAObject.h:38
WTAJet::m_ConstituentList
std::vector< WTATrigObj > m_ConstituentList
Definition: WTAObject.h:119
WTATrigObj::m_pt
IntOrFloat m_pt
Definition: WTAObject.h:67
WTATrigObj::m
IntOrFloat m() const
Definition: WTAObject.h:44
WTATrigObj::d_eta
IntOrFloat d_eta(WTATrigObj o2)
Definition: WTAObject.h:49
WTATrigObj::dR2
IntOrFloat dR2(WTATrigObj o2)
Definition: WTAObject.h:91
DeMoUpdate.tmp
string tmp
Definition: DeMoUpdate.py:1167
WTATrigObj
Definition: WTAObject.h:33
WTAJet::GetConstituentList
const std::vector< WTATrigObj > & GetConstituentList() const
Definition: WTAObject.h:114
python.changerun.o2
o2
Definition: changerun.py:43
WTATrigObj::eta
IntOrFloat eta() const
Definition: WTAObject.h:40
WTATrigObj::m_eta
IntOrFloat m_eta
Definition: WTAObject.h:71
WTATrigObj::d_phi_MPI_PI
IntOrFloat d_phi_MPI_PI(WTATrigObj o2)
Definition: WTAObject.h:84
WTAJet::m_Jet_dR2
IntOrFloat m_Jet_dR2
Definition: WTAObject.h:120
WTATrigObj::WTATrigObj
WTATrigObj(IntOrFloat pt=0, IntOrFloat eta=0, IntOrFloat phi=0, IntOrFloat m=0)
Definition: WTAObject.h:35