|
ATLAS Offline Software
|
Go to the documentation of this file.
5 #ifndef SCT_CHIPUTILS_H
6 #define SCT_CHIPUTILS_H
26 inline constexpr
unsigned int getChip(
unsigned int side,
bool swap,
unsigned int strip) {
57 const int strip{sct_id.
strip(stripId)};
59 throw std::range_error(
"Invalid SCT strip");
62 return getChip(
static_cast<unsigned int>(sct_id.
side(stripId)),
96 assert( (
side==0 && physical_chip_id<6) || (
side ==1 && physical_chip_id<12));
125 assert( geometrical_chip_id<6 &&
side<2);
140 geometrical_chip_id);
153 unsigned int chip_flags = (
side==0 ? physical_chip_flags : physical_chip_flags>>
N_CHIPS_PER_SIDE);
155 unsigned int chip_flags_out=0;
160 chip_flags_out |= (chip_flags & 1);
163 chip_flags = chip_flags_out;
177 physical_chip_flags);
constexpr unsigned int N_STRIPS_PER_CHIP
This is an Identifier helper class for the SCT subdetector. This class is a factory for creating comp...
constexpr unsigned int getChip(unsigned int side, bool swap, unsigned int strip)
Get the physical chip ID for the given strip.
constexpr unsigned int N_SIDES
constexpr unsigned int getGeometricalFromPhysicalChipID(unsigned int side, bool swap, unsigned int physical_chip_id)
Get the geometrical chip ID from a physica chip ID.
constexpr unsigned int getPhysicalFromGeometricalChipID(unsigned int side, bool swap, unsigned int geometrical_chip_id)
Get the physical chip ID from a geometrical chip ID.
bool swapPhiReadoutDirection() const
Determine if readout direction between online and offline needs swapping.
constexpr unsigned int N_STRIPS_PER_SIDE
int strip(const Identifier &id) const
constexpr unsigned int getGeometricalChipID(unsigned int strip)
Get the geometrical chip ID for the given strip.
int side(const Identifier &id) const
constexpr unsigned int getGeometricalFromPhysicalChipFlags(unsigned int side, bool swap, unsigned int physical_chip_flags)
Convert a word in which each bit represents the status of a certain physical chip to a word in which ...
virtual Identifier identify() const override final
identifier of this detector element (inline)
constexpr unsigned int N_CHIPS_PER_SIDE