Analysis Software
Documentation for
sPHENIX
simulation software
Home page
Related Pages
Modules
Namespaces
Classes
Files
Examples
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
RawTowerGeomv3.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file RawTowerGeomv3.h
1
#ifndef CALOBASE_RAWTOWERGEOMV3_H
2
#define CALOBASE_RAWTOWERGEOMV3_H
3
4
#include "
RawTowerGeom.h
"
5
6
#include "
RawTowerDefs.h
"
7
8
#include <cmath>
9
#include <iostream>
10
11
class
RawTowerGeomv3
:
public
RawTowerGeom
12
{
13
public
:
14
RawTowerGeomv3
() {}
15
RawTowerGeomv3
(
RawTowerDefs::keytype
id
);
16
~RawTowerGeomv3
()
override
{}
17
18
void
identify
(std::ostream&
os
= std::cout)
const override
;
19
20
void
set_id
(
RawTowerDefs::keytype
key)
override
{
_towerid
= key; }
21
RawTowerDefs::keytype
get_id
()
const override
{
return
_towerid
; }
22
23
int
get_bineta
()
const override
;
24
int
get_binphi
()
const override
;
25
26
int
get_column
()
const override
{
return
get_bineta
(); }
27
int
get_row
()
const override
{
return
get_binphi
(); }
28
29
int
get_binl
()
const override
{
return
RawTowerDefs::decode_index3v2
(
_towerid
); }
30
31
void
set_center_x
(
double
x
)
override
32
{
33
_center_x
=
x
;
34
return
;
35
}
36
void
set_center_y
(
double
y
)
override
37
{
38
_center_y
=
y
;
39
return
;
40
}
41
void
set_center_z
(
double
z
)
override
42
{
43
_center_z
=
z
;
44
return
;
45
}
46
47
void
set_size_x
(
double
dx)
override
48
{
49
_size_x
= dx;
50
return
;
51
}
52
void
set_size_y
(
double
dy
)
override
53
{
54
_size_y
=
dy
;
55
return
;
56
}
57
void
set_size_z
(
double
dz
)
override
58
{
59
_size_z
=
dz
;
60
return
;
61
}
62
63
double
get_center_x
()
const override
{
return
_center_x
; }
64
double
get_center_y
()
const override
{
return
_center_y
; }
65
double
get_center_z
()
const override
{
return
_center_z
; }
66
67
double
get_size_x
()
const override
{
return
_size_x
; }
68
double
get_size_y
()
const override
{
return
_size_y
; }
69
double
get_size_z
()
const override
{
return
_size_z
; }
70
double
get_volume
()
const override
{
return
(
_size_x
*
_size_y
*
_size_z
); }
71
72
double
get_center_radius
()
const override
;
73
double
get_eta
()
const override
;
74
double
get_phi
()
const override
;
75
double
get_theta
()
const override
;
76
77
void
set_tower_type
(
int
tt)
override
{
_tower_type
= tt; }
78
int
get_tower_type
()
const override
{
return
_tower_type
; }
79
80
protected
:
81
RawTowerDefs::keytype
_towerid
= ~0;
// complement = 0xFFFFF... independent of integer type (32/64/... bits)
82
83
double
_center_x
= NAN;
84
double
_center_y
= NAN;
85
double
_center_z
= NAN;
86
87
double
_size_x
= NAN;
88
double
_size_y
= NAN;
89
double
_size_z
= NAN;
90
91
int
_tower_type
= -1;
92
93
ClassDefOverride(
RawTowerGeomv3
, 4)
94
};
95
96
#endif
/* CALOBASE_RAWTOWERGEOMV3_H */
coresoftware
blob
master
offline
packages
CaloBase
RawTowerGeomv3.h
Built by
Jin Huang
. updated:
Sat Feb 17 2024 22:18:05
using
1.8.2 with
sPHENIX GitHub integration