ATLAS Offline Software
Loading...
Searching...
No Matches
CookieCutterHelpers::PhiSize Struct Reference

Find the size of the cluster in phi using L2 cells. More...

#include <CookieCutterHelpers.h>

Collaboration diagram for CookieCutterHelpers::PhiSize:

Public Member Functions

 PhiSize ()=default
 PhiSize (const CentralPosition &cp0, const xAOD::CaloCluster &cluster)

Public Attributes

float plusB = 0
float minusB = 0
float plusEC = 0
float minusEC = 0

Detailed Description

Find the size of the cluster in phi using L2 cells.

Parameters
cp0the reference position in calo-coordinates
clusterthe cluster filled with L2 and L3 cells

The window is computed using only cells in the second layer. Asymmetric sizes are computed for barrel and endcap. The size is the maximum difference in phi between the center of a cell and the refence, considering separately cells in the barrel and in the endcap. The computation is done separately for the cells with phi < reference phi or >=. A cutoff value of 1 is used.

Definition at line 48 of file CookieCutterHelpers.h.

Constructor & Destructor Documentation

◆ PhiSize() [1/2]

CookieCutterHelpers::PhiSize::PhiSize ( )
default

◆ PhiSize() [2/2]

CookieCutterHelpers::PhiSize::PhiSize ( const CentralPosition & cp0,
const xAOD::CaloCluster & cluster )

Definition at line 77 of file CookieCutterHelpers.cxx.

78{
79 auto cell_itr = cluster.cell_cbegin();
80 auto cell_end = cluster.cell_cend();
81 for (; cell_itr != cell_end; ++cell_itr) {
82
83 const CaloCell* cell = *cell_itr;
84 if (!cell) {
85 continue;
86 }
87
88 const CaloDetDescrElement* dde = cell->caloDDE();
89 if (!dde) {
90 continue;
91 }
92
93 if (cp0.emaxB > 0 && CaloCell_ID::EMB2 == dde->getSampling()) {
94 const float phi0 = cp0.phiB;
95 double cell_phi = proxim(dde->phi_raw(), phi0);
96 if (cell_phi > phi0) {
97 auto diff = cell_phi - phi0;
98 if (diff > plusB) {
99 plusB = diff;
100 }
101 } else {
102 auto diff = phi0 - cell_phi;
103 if (diff > minusB) {
104 minusB = diff;
105 }
106 }
107 } else if (cp0.emaxEC > 0 && CaloCell_ID::EME2 == dde->getSampling()) {
108 const float phi0 = cp0.phiEC;
109 double cell_phi = proxim(dde->phi_raw(), phi0);
110 if (cell_phi > phi0) {
111 auto diff = cell_phi - phi0;
112 if (diff > plusEC) {
113 plusEC = diff;
114 }
115 } else {
116 auto diff = phi0 - cell_phi;
117 if (diff > minusEC) {
118 minusEC = diff;
119 }
120 }
121 }
122 }
123}
void diff(const Jet &rJet1, const Jet &rJet2, std::map< std::string, double > varDiff)
Difference between jets - Non-Class function required by trigger.
Definition Jet.cxx:631
CaloCell_ID::CaloSample getSampling() const
cell sampling
const_cell_iterator cell_cend() const
const_cell_iterator cell_cbegin() const
double proxim(double b, double a)
Definition proxim.h:17

Member Data Documentation

◆ minusB

float CookieCutterHelpers::PhiSize::minusB = 0

Definition at line 51 of file CookieCutterHelpers.h.

◆ minusEC

float CookieCutterHelpers::PhiSize::minusEC = 0

Definition at line 53 of file CookieCutterHelpers.h.

◆ plusB

float CookieCutterHelpers::PhiSize::plusB = 0

Definition at line 50 of file CookieCutterHelpers.h.

◆ plusEC

float CookieCutterHelpers::PhiSize::plusEC = 0

Definition at line 52 of file CookieCutterHelpers.h.


The documentation for this struct was generated from the following files: