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

#include <TileDetDescriptor.h>

Collaboration diagram for TileDetDescriptor:

Public Member Functions

 TileDetDescriptor ()
 
 TileDetDescriptor (const float eta_min[], const float eta_max[], const float deta[], const float phi_min, const float phi_max, const float dphi, const float zshift, const float rcenter[], const float dr[], const float zcenter[], const float dz[], const unsigned int n_samp, const int sign_eta)
 
 ~TileDetDescriptor ()
 
void set (const Identifier &id)
 
Identifier identify (void) const
 
int sign_eta () const
 
float eta_min (unsigned int samp) const
 
float eta_max (unsigned int samp) const
 
float deta (unsigned int samp) const
 
int n_eta (unsigned int samp) const
 
float phi_min () const
 
float phi_max () const
 
float dphi () const
 
int n_phi () const
 
float zshift () const
 
float rcenter (unsigned int samp) const
 
float dr (unsigned int samp) const
 
float zcenter (unsigned int samp) const
 
float dz (unsigned int samp) const
 
int n_samp () const
 
float eta (unsigned int eta_channel, unsigned int samp) const
 
float phi (unsigned int phi_channel) const
 
void print () const
 
void set (const float eta_min[], const float eta_max[], const float deta[], const float phi_min, const float phi_max, const float dphi, const float zshift, const float rcenter[], const float dr[], const float zcenter[], const float dz[], const unsigned int n_samp, const unsigned int n_eta[], const unsigned int n_phi, const int sign_eta)
 

Private Attributes

Identifier m_id
 
float m_eta_min [MAX_N_SAMP_TILEDD]
 
float m_eta_max [MAX_N_SAMP_TILEDD]
 
float m_deta [MAX_N_SAMP_TILEDD]
 
float m_phi_min
 
float m_phi_max
 
float m_dphi
 
float m_zshift
 
float m_rcenter [MAX_N_SAMP_TILEDD]
 
float m_dr [MAX_N_SAMP_TILEDD]
 
float m_zcenter [MAX_N_SAMP_TILEDD]
 
float m_dz [MAX_N_SAMP_TILEDD]
 
unsigned int m_n_samp
 
unsigned int m_n_eta [MAX_N_SAMP_TILEDD]
 
unsigned int m_n_phi
 
int m_sign_eta
 

Detailed Description

class TileDetDescriptor

This class contains the detector description information for the Tile calorimeters: Barrel, Ext.Barrel, Gap detector.

There are 3 detectors (bar,ext.bar,gap) * 2 sides = 6 regions in TileCal Granularity in phi is one and the same for all cells in the region and all phi variables are scalars (min_phi, max_phi, dphi, nphi) Granularity in eta can be different for different samplings or towers and all eta variables are arrays (min_eta, max_eta, deta, neta) TileCal has 3 samplings and index in "eta" arrays corresponds to sampling number: eta[0] - samling A, eta[1] - sampling BC, eta[2] - sampling D In Gap detector (detector=3) apart from normal samplings there are 4 so-called gap scintillators. For all these scintillators sampling=3 and tower number is used instead of sampling number to distinguish them. In current geometry gap scintillators are positioned in towers 10,11,13,15 hence information about them is saved in eta[10], eta[11], eta[13], eta[15] variable "n_samp" is the length of "eta" arrays, n_samp=3 for barrel and ext. barrel and n_samp=16 for gap detector. Rcenter[] is the radius of the center of cells in the given sampling It can be used to re-calculate shift in eta due to zshift etashift = zshift * tanh(eta) * tan(2 * atan(exp(-eta))) / Rcenter dr[] is the thickness of the samplings in R

Definition at line 45 of file TileDetDescriptor.h.

Constructor & Destructor Documentation

◆ TileDetDescriptor() [1/2]

TileDetDescriptor::TileDetDescriptor ( )

Definition at line 20 of file TileDetDescriptor.cxx.

21  :
22  m_phi_min(0),
23  m_phi_max(0),
24  m_dphi(0),
25  m_zshift(0),
26  m_n_samp(0),
27  m_n_phi(0),
28  m_sign_eta(0)
29 {
30  AtlasDetectorID atlas;
31  m_id = atlas.tile();
32  memset(m_eta_min, 0, MAX_N_SAMP_TILEDD*sizeof(float));
33  memset(m_eta_max, 0, MAX_N_SAMP_TILEDD*sizeof(float));
34  memset(m_deta, 0, MAX_N_SAMP_TILEDD*sizeof(float));
35  memset(m_rcenter, 0, MAX_N_SAMP_TILEDD*sizeof(float));
36  memset(m_dr, 0, MAX_N_SAMP_TILEDD*sizeof(float));
37  memset(m_zcenter, 0, MAX_N_SAMP_TILEDD*sizeof(float));
38  memset(m_dz, 0, MAX_N_SAMP_TILEDD*sizeof(float));
39  memset(m_n_eta, 0, MAX_N_SAMP_TILEDD*sizeof(int));
40 }

◆ TileDetDescriptor() [2/2]

TileDetDescriptor::TileDetDescriptor ( const float  eta_min[],
const float  eta_max[],
const float  deta[],
const float  phi_min,
const float  phi_max,
const float  dphi,
const float  zshift,
const float  rcenter[],
const float  dr[],
const float  zcenter[],
const float  dz[],
const unsigned int  n_samp,
const int  sign_eta 
)

Definition at line 42 of file TileDetDescriptor.cxx.

57  , m_dphi(dphi)
58  , m_zshift(zshift)
59  , m_n_samp(n_samp)
60  , m_n_phi((unsigned int) ((phi_max - phi_min)/dphi + 0.5))
62 {
63  AtlasDetectorID atlas;
64  m_id = atlas.tile();
65  for (unsigned int i=0; i<n_samp; ++i) {
66  m_eta_min[i] = eta_min[i];
67  m_eta_max[i] = eta_max[i];
68  m_deta[i] = deta[i];
69  m_rcenter[i] = rcenter[i];
70  m_dr[i] = dr[i];
71  m_zcenter[i] = zcenter[i];
72  m_dz[i] = dz[i];
73  m_n_eta[i] = ((unsigned int) ((eta_max[i] - eta_min[i])/deta[i] + 0.5));
74  }
75  for (unsigned int i=n_samp; i<MAX_N_SAMP_TILEDD; ++i) {
76  m_eta_min[i] = 0;
77  m_eta_max[i] = 0;
78  m_deta[i] = 0;
79  m_rcenter[i] = 0;
80  m_dr[i] = 0;
81  m_zcenter[i] = 0;
82  m_dz[i] = 0;
83  m_n_eta[i] = 0;
84  }
85 }

◆ ~TileDetDescriptor()

TileDetDescriptor::~TileDetDescriptor ( )
inline

Definition at line 135 of file TileDetDescriptor.h.

136 {}

Member Function Documentation

◆ deta()

float TileDetDescriptor::deta ( unsigned int  samp) const
inline

Definition at line 152 of file TileDetDescriptor.h.

153 {
154  assert (samp < m_n_samp);
155 
156  return m_deta[samp];
157 }

◆ dphi()

float TileDetDescriptor::dphi ( ) const
inline

Definition at line 176 of file TileDetDescriptor.h.

177 {
178  return m_dphi;
179 }

◆ dr()

float TileDetDescriptor::dr ( unsigned int  samp) const
inline

Definition at line 198 of file TileDetDescriptor.h.

199 {
200  assert (samp < m_n_samp);
201 
202  return m_dr[samp];
203 }

◆ dz()

float TileDetDescriptor::dz ( unsigned int  samp) const
inline

Definition at line 212 of file TileDetDescriptor.h.

213 {
214  assert (samp < m_n_samp);
215 
216  return m_dz[samp];
217 }

◆ eta()

float TileDetDescriptor::eta ( unsigned int  eta_channel,
unsigned int  samp 
) const
inline

Definition at line 229 of file TileDetDescriptor.h.

230 {
231  assert (samp < m_n_samp);
232  assert (eta_channel < m_n_eta[samp]);
233 
234  return (m_sign_eta*(((float)eta_channel + 0.5)*m_deta[samp] + m_eta_min[samp]));
235 }

◆ eta_max()

float TileDetDescriptor::eta_max ( unsigned int  samp) const
inline

Definition at line 145 of file TileDetDescriptor.h.

146 {
147  assert (samp < m_n_samp);
148 
149  return m_eta_max[samp];
150 }

◆ eta_min()

float TileDetDescriptor::eta_min ( unsigned int  samp) const
inline

Definition at line 138 of file TileDetDescriptor.h.

139 {
140  assert (samp < m_n_samp);
141 
142  return m_eta_min[samp];
143 }

◆ identify()

Identifier TileDetDescriptor::identify ( void  ) const
inline

Definition at line 249 of file TileDetDescriptor.h.

250 {
251  return m_id;
252 }

◆ n_eta()

int TileDetDescriptor::n_eta ( unsigned int  samp) const
inline

Definition at line 159 of file TileDetDescriptor.h.

160 {
161  assert (samp < m_n_samp);
162 
163  return m_n_eta[samp];
164 }

◆ n_phi()

int TileDetDescriptor::n_phi ( ) const
inline

Definition at line 181 of file TileDetDescriptor.h.

182 {
183  return m_n_phi;
184 }

◆ n_samp()

int TileDetDescriptor::n_samp ( ) const
inline

Definition at line 219 of file TileDetDescriptor.h.

220 {
221  return m_n_samp;
222 }

◆ phi()

float TileDetDescriptor::phi ( unsigned int  phi_channel) const
inline

Definition at line 237 of file TileDetDescriptor.h.

238 {
239  assert (phi_channel < m_n_phi);
240 
241  return (((float)phi_channel + 0.5)*m_dphi + m_phi_min);
242 }

◆ phi_max()

float TileDetDescriptor::phi_max ( ) const
inline

Definition at line 171 of file TileDetDescriptor.h.

172 {
173  return m_phi_max;
174 }

◆ phi_min()

float TileDetDescriptor::phi_min ( ) const
inline

Definition at line 166 of file TileDetDescriptor.h.

167 {
168  return m_phi_min;
169 }

◆ print()

void TileDetDescriptor::print ( ) const

Definition at line 125 of file TileDetDescriptor.cxx.

126 {
127  std::cout << std::endl << " TileDetDescriptor print: "
128  << std::endl << std::endl;
129 
130  std::cout << " phi min phi max dphi nphi zshift sign_eta nsamp"
131  << std::endl;
132  std::cout << std::setiosflags(std::ios::fixed);
133  std::cout
134  << std::setw(9) << std::setprecision(4) << m_phi_min << " "
135  << std::setw(9) << std::setprecision(4) << m_phi_max << " "
136  << std::setw(9) << std::setprecision(4) << m_dphi << " "
137  << std::setw(6) << std::setprecision(4) << m_n_phi << " "
138  << std::setw(8) << std::setprecision(2) << m_zshift << " "
139  << std::setw(7) << std::setprecision(4) << m_sign_eta<< " "
140  << std::setw(7) << std::setprecision(4) << m_n_samp << " "
141  << std::endl;
142 
143  std::cout << " eta min eta max deta neta radius dR Z dZ"
144  << std::endl;
145 
146  for (unsigned int i=0; i<m_n_samp; ++i) {
147  std::cout
148  << std::setw(9) << std::setprecision(4) << m_eta_min[i] << " "
149  << std::setw(9) << std::setprecision(4) << m_eta_max[i] << " "
150  << std::setw(9) << std::setprecision(4) << m_deta[i] << " "
151  << std::setw(6) << std::setprecision(4) << m_n_eta[i] << " "
152  << std::setw(9) << std::setprecision(2) << m_rcenter[i] << " "
153  << std::setw(9) << std::setprecision(2) << m_dr[i] << " "
154  << std::setw(9) << std::setprecision(2) << m_zcenter[i] << " "
155  << std::setw(9) << std::setprecision(2) << m_dz[i] << " "
156  << std::endl;
157  }
158 
159  std::cout << std::resetiosflags(std::ios::fixed);
160 }

◆ rcenter()

float TileDetDescriptor::rcenter ( unsigned int  samp) const
inline

Definition at line 191 of file TileDetDescriptor.h.

192 {
193  assert (samp < m_n_samp);
194 
195  return m_rcenter[samp];
196 }

◆ set() [1/2]

void TileDetDescriptor::set ( const float  eta_min[],
const float  eta_max[],
const float  deta[],
const float  phi_min,
const float  phi_max,
const float  dphi,
const float  zshift,
const float  rcenter[],
const float  dr[],
const float  zcenter[],
const float  dz[],
const unsigned int  n_samp,
const unsigned int  n_eta[],
const unsigned int  n_phi,
const int  sign_eta 
)

Definition at line 88 of file TileDetDescriptor.cxx.

103 {
104  m_phi_min = phi_min;
105  m_phi_max = phi_max;
106  m_dphi = dphi;
107  m_zshift = zshift;
108  m_n_samp = n_samp;
109  m_n_phi = n_phi;
111 
112  for (unsigned int i=0; i<n_samp; ++i) {
113  m_eta_min[i] = eta_min[i];
114  m_eta_max[i] = eta_max[i];
115  m_deta[i] = deta[i];
116  m_rcenter[i] = rcenter[i];
117  m_dr[i] = dr[i];
118  m_zcenter[i] = zcenter[i];
119  m_dz[i] = dz[i];
120  m_n_eta[i] = n_eta[i];
121  }
122 }

◆ set() [2/2]

void TileDetDescriptor::set ( const Identifier id)
inline

Definition at line 244 of file TileDetDescriptor.h.

245 {
246  m_id = id;
247 }

◆ sign_eta()

int TileDetDescriptor::sign_eta ( ) const
inline

Definition at line 224 of file TileDetDescriptor.h.

225 {
226  return m_sign_eta;
227 }

◆ zcenter()

float TileDetDescriptor::zcenter ( unsigned int  samp) const
inline

Definition at line 205 of file TileDetDescriptor.h.

206 {
207  assert (samp < m_n_samp);
208 
209  return m_zcenter[samp];
210 }

◆ zshift()

float TileDetDescriptor::zshift ( ) const
inline

Definition at line 186 of file TileDetDescriptor.h.

187 {
188  return m_zshift;
189 }

Member Data Documentation

◆ m_deta

float TileDetDescriptor::m_deta[MAX_N_SAMP_TILEDD]
private

Definition at line 120 of file TileDetDescriptor.h.

◆ m_dphi

float TileDetDescriptor::m_dphi
private

Definition at line 123 of file TileDetDescriptor.h.

◆ m_dr

float TileDetDescriptor::m_dr[MAX_N_SAMP_TILEDD]
private

Definition at line 126 of file TileDetDescriptor.h.

◆ m_dz

float TileDetDescriptor::m_dz[MAX_N_SAMP_TILEDD]
private

Definition at line 128 of file TileDetDescriptor.h.

◆ m_eta_max

float TileDetDescriptor::m_eta_max[MAX_N_SAMP_TILEDD]
private

Definition at line 119 of file TileDetDescriptor.h.

◆ m_eta_min

float TileDetDescriptor::m_eta_min[MAX_N_SAMP_TILEDD]
private

Definition at line 118 of file TileDetDescriptor.h.

◆ m_id

Identifier TileDetDescriptor::m_id
private

Definition at line 117 of file TileDetDescriptor.h.

◆ m_n_eta

unsigned int TileDetDescriptor::m_n_eta[MAX_N_SAMP_TILEDD]
private

Definition at line 130 of file TileDetDescriptor.h.

◆ m_n_phi

unsigned int TileDetDescriptor::m_n_phi
private

Definition at line 131 of file TileDetDescriptor.h.

◆ m_n_samp

unsigned int TileDetDescriptor::m_n_samp
private

Definition at line 129 of file TileDetDescriptor.h.

◆ m_phi_max

float TileDetDescriptor::m_phi_max
private

Definition at line 122 of file TileDetDescriptor.h.

◆ m_phi_min

float TileDetDescriptor::m_phi_min
private

Definition at line 121 of file TileDetDescriptor.h.

◆ m_rcenter

float TileDetDescriptor::m_rcenter[MAX_N_SAMP_TILEDD]
private

Definition at line 125 of file TileDetDescriptor.h.

◆ m_sign_eta

int TileDetDescriptor::m_sign_eta
private

Definition at line 132 of file TileDetDescriptor.h.

◆ m_zcenter

float TileDetDescriptor::m_zcenter[MAX_N_SAMP_TILEDD]
private

Definition at line 127 of file TileDetDescriptor.h.

◆ m_zshift

float TileDetDescriptor::m_zshift
private

Definition at line 124 of file TileDetDescriptor.h.


The documentation for this class was generated from the following files:
TileDetDescriptor::eta_max
float eta_max(unsigned int samp) const
Definition: TileDetDescriptor.h:145
TileDetDescriptor::m_phi_min
float m_phi_min
Definition: TileDetDescriptor.h:121
TileDetDescriptor::m_dphi
float m_dphi
Definition: TileDetDescriptor.h:123
CaloCellPos2Ntuple.int
int
Definition: CaloCellPos2Ntuple.py:24
TileDetDescriptor::phi_min
float phi_min() const
Definition: TileDetDescriptor.h:166
TileDetDescriptor::dphi
float dphi() const
Definition: TileDetDescriptor.h:176
TileDetDescriptor::zshift
float zshift() const
Definition: TileDetDescriptor.h:186
TileDetDescriptor::m_n_phi
unsigned int m_n_phi
Definition: TileDetDescriptor.h:131
TileDetDescriptor::dz
float dz(unsigned int samp) const
Definition: TileDetDescriptor.h:212
TileDetDescriptor::sign_eta
int sign_eta() const
Definition: TileDetDescriptor.h:224
TileDetDescriptor::phi_max
float phi_max() const
Definition: TileDetDescriptor.h:171
MAX_N_SAMP_TILEDD
#define MAX_N_SAMP_TILEDD
Definition: TileDetDescriptor.h:17
TileDetDescriptor::m_rcenter
float m_rcenter[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:125
TileDetDescriptor::n_eta
int n_eta(unsigned int samp) const
Definition: TileDetDescriptor.h:159
TileDetDescriptor::dr
float dr(unsigned int samp) const
Definition: TileDetDescriptor.h:198
TileDetDescriptor::rcenter
float rcenter(unsigned int samp) const
Definition: TileDetDescriptor.h:191
TileDetDescriptor::m_zcenter
float m_zcenter[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:127
TileDetDescriptor::m_deta
float m_deta[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:120
lumiFormat.i
int i
Definition: lumiFormat.py:85
TileDetDescriptor::zcenter
float zcenter(unsigned int samp) const
Definition: TileDetDescriptor.h:205
TileDetDescriptor::n_samp
int n_samp() const
Definition: TileDetDescriptor.h:219
TileDetDescriptor::m_dz
float m_dz[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:128
TileDetDescriptor::eta_min
float eta_min(unsigned int samp) const
Definition: TileDetDescriptor.h:138
TileDetDescriptor::m_dr
float m_dr[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:126
AtlasDetectorID::tile
Identifier tile(void) const
Definition: AtlasDetectorID.cxx:45
TileDetDescriptor::m_eta_min
float m_eta_min[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:118
TileDetDescriptor::deta
float deta(unsigned int samp) const
Definition: TileDetDescriptor.h:152
id
SG::auxid_t id
Definition: Control/AthContainers/Root/debug.cxx:227
TileDetDescriptor::m_eta_max
float m_eta_max[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:119
TileDetDescriptor::m_sign_eta
int m_sign_eta
Definition: TileDetDescriptor.h:132
TileDetDescriptor::m_n_samp
unsigned int m_n_samp
Definition: TileDetDescriptor.h:129
TileDetDescriptor::m_n_eta
unsigned int m_n_eta[MAX_N_SAMP_TILEDD]
Definition: TileDetDescriptor.h:130
TileDetDescriptor::m_id
Identifier m_id
Definition: TileDetDescriptor.h:117
TileDetDescriptor::m_zshift
float m_zshift
Definition: TileDetDescriptor.h:124
TileDetDescriptor::n_phi
int n_phi() const
Definition: TileDetDescriptor.h:181
AtlasDetectorID
This class provides an interface to generate or decode an identifier for the upper levels of the dete...
Definition: AtlasDetectorID.h:57
TileDetDescriptor::m_phi_max
float m_phi_max
Definition: TileDetDescriptor.h:122