ATLAS Offline Software
|
The JetElementKeyBase object provides the key for each JetElement or JetInput depending on its eta,phi coords. More...
#include <JetElementKeyBase.h>
Public Types | |
enum | JERegion { Barrel =0, EndBarrel =1, EndCap1 =2, EndCap2 =3, EndCap3 =4, FCAL =5 } |
Public Member Functions | |
virtual | ~JetElementKeyBase () |
virtual unsigned int | jeKey (const xAOD::TriggerTower &tower) |
returns key of passed tower More... | |
virtual unsigned int | jeKey (const xAOD::JetElement &jetElement) |
returns key of passed jetelement More... | |
virtual unsigned int | jeKey (const double phi, const double eta) |
returns the key of the passed coords More... | |
virtual unsigned int | jeKey (const Coordinate coord) |
returns the key of the passed Coordinate More... | |
unsigned int | leftEtaKey (const double phi, const double eta) |
returns key of JE in +ve eta dir. More... | |
unsigned int | rightEtaKey (const double phi, const double eta) |
returns key of JE in -ve eta dir. More... | |
unsigned int | upPhiKey (const double phi, const double eta) |
returns key of next JE in +ve phi dir. More... | |
unsigned int | downPhiKey (const double phi, const double eta) |
returns key of next JE in -ve phi dir. More... | |
Coordinate | getCentre (const double phi, const double eta) |
returns the central coordinate of the JE which contains the passed coord More... | |
Coordinate | getCentre (const Coordinate coord) |
returns the central coordinate of the JE which contains the passed coord More... | |
Coordinate | rightEta (const double phi, const double eta) |
Functions for finding coordinates of neighbouring JEs. More... | |
Coordinate | leftEta (const double phi, const double eta) |
returns key of JE in -ve eta dir. More... | |
Coordinate | downPhi (const double phi, const double eta) |
returns coord of next JE in -ve phi dir. More... | |
Coordinate | upPhi (const double phi, const double eta) |
returns coord of next JE in +ve phi dir. More... | |
Coordinate | rightEta (const Coordinate coord) |
returns eta coord of JE in +ve eta dir. More... | |
Coordinate | leftEta (const Coordinate coord) |
returns key of JE in -ve eta dir. More... | |
Coordinate | downPhi (const Coordinate coord) |
returns coord of next JE in -ve phi dir. More... | |
Coordinate | upPhi (const Coordinate coord) |
returns coord of next JE in +ve phi dir. More... | |
Coordinate | upperLeft (const double phi, const double eta) |
Coordinate | upperRight (const double phi, const double eta) |
Coordinate | lowerLeft (const double phi, const double eta) |
Coordinate | lowerRight (const double phi, const double eta) |
Coordinate | upperLeft (const Coordinate coord) |
Coordinate | upperRight (const Coordinate coord) |
Coordinate | lowerLeft (const Coordinate coord) |
Coordinate | lowerRight (const Coordinate coord) |
double | dPhi (const double phi, const double eta) const |
return height of JE More... | |
double | dPhi () const |
return height of JE More... | |
double | dPhi (const Coordinate &coord) const |
return height of JE More... | |
double | dEta (const double phi, const double eta) const |
return width of JE More... | |
double | dEta () const |
return width of JE More... | |
double | dEta (const Coordinate &coord) const |
return width of JE More... | |
unsigned int | region (double eta) const |
returns region number at eta, where region is: More... | |
JERegion | jeRegion (const Coordinate &coord) const |
bool | isFCAL (double eta) const |
returns TRUE if this coordinate is in the FCAL More... | |
virtual double | eta () const |
returns the centre of the TT at eta_coord: More... | |
virtual double | phi () const |
returns phi coordinate of centre of relevant trigger tower. More... | |
unsigned int | key (double phi, double eta) |
calculates a map key from passed phi, eta coordinates More... | |
unsigned int | key (const Coordinate &coord) |
returns the key of the passed Coordinate More... | |
Coordinate | coord () const |
return central coords of current key value. More... | |
Protected Member Functions | |
JetElementKeyBase (double phi, double eta) | |
takes phi and eta and constructs a JetElementKeyBase object which can return the key for this coord More... | |
JetElementKeyBase (const Coordinate coord) | |
constructs a JetElementKeyBase object More... | |
JetElementKeyBase () | |
constructs a JetElementKeyBase object More... | |
void | setupRegionData () |
get region data from TrigT1CaloDefs and put in more useful format - vectors More... | |
void | setupJetRegionData () |
Does same as setupRegionData, except in FCAL where uses phi granularity appropriate for the jet trigger. More... | |
ICoordinate * | convertCoordsToIntegers (double phi, double eta) |
converts the coordinates and corrects for overflows etc. More... | |
virtual int | sign (int temp) const |
returns -1 if temp is -ve and +1 if it is +ve. More... | |
virtual int | sign (double temp) const |
returns -1 if temp is -ve and +1 if it is +ve. More... | |
int | round (double a) const |
rounds number to nearest whole number More... | |
int | sharpRound (double a) const |
rounds number as follows (-1.0 to 0.0) -> -1, (0.0 to 1.0) -> 0, (1.0 to 2.0)->1 etc. More... | |
int | sharpRound2 (int a, int b) const |
divides a/b and returns a number as follows (where +b means +ve b): if 0<a<+b, then n=1, if +b<a<+2b, n=2, if -b<a<0, n=-1, if -2b<a<-b, n=-2 More... | |
void | setupThisKeyValues () |
Protected Attributes | |
int | m_iphi |
integer phi coord More... | |
int | m_ieta |
integer eta coord More... | |
double | m_eta |
eta coordinate of key More... | |
double | m_phi |
phi coordinate of key More... | |
int | m_phiBin |
phi bin More... | |
int | m_etaBin |
eta bin More... | |
double | m_centralPhi |
this is the coordinate of the centre of the relevant trigger tower. More... | |
double | m_centralEta |
this is the coordinate of the centre of the relevant trigger tower. More... | |
bool | m_debug |
turns DEBUG code on and off More... | |
Private Member Functions | |
BinAndCoord * | calculateTriggerBin (ICoordinate *iCoord) |
converts integer phi, eta coordinates to phi, eta trigger bins. More... | |
void | analCoordChecking (const Coordinate &coord) |
this is a bit over the top, but it looks to see if the calculated coordinate matches a coordinate centre that JetElementKeyBase would return. More... | |
Private Attributes | |
bool | m_debugKeyBase |
set to true to turn debugging info on More... | |
std::vector< double > | m_regionEtaCentre |
holds central coords of JEs in regions: Region Eta 0 <2.2 1 2.2-2.4 2 2.4-2.7 3 2.7-2.9 4 2.9-3.2 5 3.2-4.9 More... | |
std::vector< double > | m_regionWidth |
holds width of JEs in regions: More... | |
std::vector< double > | m_regionHeight |
holds height of JEs in regions: More... | |
The JetElementKeyBase object provides the key for each JetElement or JetInput depending on its eta,phi coords.
The key is an integer number that uniquely identifies each tower, and is needed by the STL map container: the map holds trigger towers and we retrieve them using their keys.
Definition at line 55 of file JetElementKeyBase.h.
Enumerator | |
---|---|
Barrel | |
EndBarrel | |
EndCap1 | |
EndCap2 | |
EndCap3 | |
FCAL |
Definition at line 65 of file JetElementKeyBase.h.
|
virtual |
Definition at line 70 of file JetElementKeyBase.cxx.
|
protected |
takes phi and eta and constructs a JetElementKeyBase object which can return the key for this coord
Definition at line 41 of file JetElementKeyBase.cxx.
|
protected |
constructs a JetElementKeyBase object
Definition at line 61 of file JetElementKeyBase.cxx.
|
protected |
constructs a JetElementKeyBase object
Definition at line 51 of file JetElementKeyBase.cxx.
|
private |
this is a bit over the top, but it looks to see if the calculated coordinate matches a coordinate centre that JetElementKeyBase would return.
It doesn't return any errors or anything as it's purely being used in tests external to Athena
Definition at line 502 of file JetElementKeyBase.cxx.
|
privatevirtual |
converts integer phi, eta coordinates to phi, eta trigger bins.
Returns coordinates of centre of JEs
Implements LVL1::KeyUtilities.
Definition at line 77 of file JetElementKeyBase.cxx.
|
protectedinherited |
converts the coordinates and corrects for overflows etc.
For instance, if phi is negative this routine converts to the equivalent positive position.
For instance, if phi is negative this routine converts to the equivalent positive position. *todo tidy up a bit.
Definition at line 110 of file KeyUtilities.cxx.
|
inherited |
return central coords of current key value.
Definition at line 199 of file KeyUtilities.cxx.
double LVL1::JetElementKeyBase::dEta | ( | ) | const |
|
virtual |
return width of JE
Implements LVL1::KeyUtilities.
Definition at line 393 of file JetElementKeyBase.cxx.
return width of JE
return width of JE at (phi,eta)
Definition at line 380 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::downPhi | ( | const Coordinate | coord | ) |
returns coord of next JE in -ve phi dir.
Definition at line 306 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::downPhi | ( | const double | phi, |
const double | eta | ||
) |
returns key of next JE in -ve phi dir.
Definition at line 312 of file JetElementKeyBase.cxx.
double LVL1::JetElementKeyBase::dPhi | ( | ) | const |
|
virtual |
return height of JE
Implements LVL1::KeyUtilities.
Definition at line 375 of file JetElementKeyBase.cxx.
return height of JE
return height of JE at (phi,eta)
Definition at line 362 of file JetElementKeyBase.cxx.
|
virtualinherited |
returns the centre of the TT at eta_coord:
returns the eta coord of the centre of the relevent trigger tower
Definition at line 150 of file KeyUtilities.cxx.
Coordinate LVL1::JetElementKeyBase::getCentre | ( | const Coordinate | coord | ) |
returns the central coordinate of the JE which contains the passed coord
Definition at line 498 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::getCentre | ( | const double | phi, |
const double | eta | ||
) |
bool LVL1::JetElementKeyBase::isFCAL | ( | double | eta | ) | const |
returns TRUE if this coordinate is in the FCAL
Definition at line 430 of file JetElementKeyBase.cxx.
|
virtual |
returns the key of the passed Coordinate
returns trigger tower key of passed Coordinate
Definition at line 178 of file JetElementKeyBase.cxx.
returns the key of the passed coords
returns trigger tower key of passed coords
Definition at line 172 of file JetElementKeyBase.cxx.
|
virtual |
returns key of passed jetelement
returns the key of the passed tower
Definition at line 163 of file JetElementKeyBase.cxx.
|
virtual |
JetElementKeyBase::JERegion LVL1::JetElementKeyBase::jeRegion | ( | const Coordinate & | coord | ) | const |
Definition at line 415 of file JetElementKeyBase.cxx.
|
inherited |
returns the key of the passed Coordinate
returns trigger tower key of passed Coordinate
Definition at line 101 of file KeyUtilities.cxx.
|
inherited |
calculates a map key from passed phi, eta coordinates
returns key
calculates a map key from passed phi, eta coordinates
Definition at line 82 of file KeyUtilities.cxx.
Coordinate LVL1::JetElementKeyBase::leftEta | ( | const Coordinate | coord | ) |
returns key of JE in -ve eta dir.
Definition at line 213 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::leftEta | ( | const double | phi, |
const double | eta | ||
) |
returns key of JE in +ve eta dir.
returns key of JE in -ve eta dir.
Definition at line 218 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::lowerLeft | ( | const Coordinate | coord | ) |
Definition at line 351 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::lowerLeft | ( | const double | phi, |
const double | eta | ||
) |
Definition at line 329 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::lowerRight | ( | const Coordinate | coord | ) |
Definition at line 356 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::lowerRight | ( | const double | phi, |
const double | eta | ||
) |
Definition at line 335 of file JetElementKeyBase.cxx.
|
virtualinherited |
returns phi coordinate of centre of relevant trigger tower.
returns phi coordinate of the centre of the relevent trigger tower.
Definition at line 159 of file KeyUtilities.cxx.
unsigned int LVL1::JetElementKeyBase::region | ( | double | eta | ) | const |
returns region number at eta, where region is:
Definition at line 397 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::rightEta | ( | const Coordinate | coord | ) |
returns eta coord of JE in +ve eta dir.
Definition at line 257 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::rightEta | ( | const double | phi, |
const double | eta | ||
) |
Functions for finding coordinates of neighbouring JEs.
returns eta coord of JE in +ve eta dir.
Definition at line 230 of file JetElementKeyBase.cxx.
returns key of JE in -ve eta dir.
returns key of JE in +ve eta dir.
Definition at line 224 of file JetElementKeyBase.cxx.
|
protectedinherited |
|
protected |
Does same as setupRegionData, except in FCAL where uses phi granularity appropriate for the jet trigger.
Definition at line 463 of file JetElementKeyBase.cxx.
|
protected |
get region data from TrigT1CaloDefs and put in more useful format - vectors
Definition at line 436 of file JetElementKeyBase.cxx.
|
protectedinherited |
|
protectedinherited |
rounds number as follows (-1.0 to 0.0) -> -1, (0.0 to 1.0) -> 0, (1.0 to 2.0)->1 etc.
Definition at line 190 of file KeyUtilities.cxx.
|
protectedinherited |
divides a/b and returns a number as follows (where +b means +ve b): if 0<a<+b, then n=1, if +b<a<+2b, n=2, if -b<a<0, n=-1, if -2b<a<-b, n=-2
Definition at line 194 of file KeyUtilities.cxx.
|
protectedvirtualinherited |
returns -1 if temp is -ve and +1 if it is +ve.
returns 0 if temp =0
Definition at line 169 of file KeyUtilities.cxx.
|
protectedvirtualinherited |
returns -1 if temp is -ve and +1 if it is +ve.
returns 0 if temp =0
Definition at line 164 of file KeyUtilities.cxx.
Coordinate LVL1::JetElementKeyBase::upperLeft | ( | const Coordinate | coord | ) |
Definition at line 341 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::upperLeft | ( | const double | phi, |
const double | eta | ||
) |
Definition at line 317 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::upperRight | ( | const Coordinate | coord | ) |
Definition at line 346 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::upperRight | ( | const double | phi, |
const double | eta | ||
) |
Definition at line 323 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::upPhi | ( | const Coordinate | coord | ) |
returns coord of next JE in +ve phi dir.
Definition at line 279 of file JetElementKeyBase.cxx.
Coordinate LVL1::JetElementKeyBase::upPhi | ( | const double | phi, |
const double | eta | ||
) |
|
protectedinherited |
this is the coordinate of the centre of the relevant trigger tower.
Definition at line 122 of file KeyUtilities.h.
|
protectedinherited |
this is the coordinate of the centre of the relevant trigger tower.
Definition at line 119 of file KeyUtilities.h.
|
protectedinherited |
turns DEBUG code on and off
Definition at line 124 of file KeyUtilities.h.
|
private |
set to true to turn debugging info on
Definition at line 166 of file JetElementKeyBase.h.
|
protectedinherited |
eta coordinate of key
Definition at line 110 of file KeyUtilities.h.
|
protectedinherited |
eta bin
Definition at line 116 of file KeyUtilities.h.
|
protectedinherited |
integer eta coord
Definition at line 108 of file KeyUtilities.h.
|
protectedinherited |
integer phi coord
Definition at line 106 of file KeyUtilities.h.
|
protectedinherited |
phi coordinate of key
Definition at line 112 of file KeyUtilities.h.
|
protectedinherited |
phi bin
Definition at line 114 of file KeyUtilities.h.
|
private |
holds central coords of JEs in regions: Region Eta 0 <2.2 1 2.2-2.4 2 2.4-2.7 3 2.7-2.9 4 2.9-3.2 5 3.2-4.9
Definition at line 175 of file JetElementKeyBase.h.
|
private |
holds height of JEs in regions:
Definition at line 179 of file JetElementKeyBase.h.
|
private |
holds width of JEs in regions:
Definition at line 177 of file JetElementKeyBase.h.