|
ATLAS Offline Software
|
Go to the documentation of this file.
23 const int circuitsPerRow,
24 const int cellColumnsPerCircuit,
25 const int cellRowsPerCircuit,
26 const int diodeColumnsPerCircuit,
27 const int diodeRowsPerCircuit) :
28 m_numberOfCircuits(circuitsPerColumn*circuitsPerRow),
29 m_numberOfCircuitsPerColumn(circuitsPerColumn),
30 m_numberOfCircuitsPerRow(circuitsPerRow),
31 m_columnsPerCircuit(cellColumnsPerCircuit),
32 m_rowsPerCircuit(cellRowsPerCircuit),
33 m_columns(circuitsPerRow*diodeColumnsPerCircuit),
34 m_rows(circuitsPerColumn*diodeRowsPerCircuit)
37 if (!
m_columns)
throw std::runtime_error(
"PixelReadoutScheme: Number of columns is 0");
38 if (!
m_rows)
throw std::runtime_error(
"PixelReadoutScheme: Number of columns is 0");
47 if (!readoutId.
isValid())
return 0;
61 if (!readoutId.
isValid())
return {};
68 if (!numConnected ||
static_cast<int>(
number) >= numConnected)
return {};
71 return {newPhiIndex, readoutId.
etaIndex()};
78 if (!cellId.
isValid())
return {};
86 return {newPhiIndex, cellId.
etaIndex()};
93 if (!cellId.
isValid())
return cellId;
97 if (newPhiIndex ==
phiIndex)
return {};
98 return {newPhiIndex, cellId.
etaIndex()};
103 const std::vector<int> &connections)
void set(const int lowerIndex, const std::vector< int > &connections)
int numberOfConnectedCells(const SiReadoutCellId &readoutId) const
number of cells connected to this readout.
bool isValid() const
Test if its in a valid state.
int phiIndex() const
Get phi index. Equivalent to strip().
SiReadoutCellId readoutIdOfCell(const SiCellId &cellId) const
Readout id of this diode.
int readoutOfDiode(const int index) const
Return readout cell id of this diode, Must check outsideDiode first.
int etaIndex() const
Get eta index.
int gangedCell(const int index) const
If the diode is gnaged return the other diode.
bool outsideReadout(const int index) const
Check if the readout cell is in the range; Also for index of gangedCell.
SiCellId connectedCell(const SiReadoutCellId &readoutId, unsigned int number) const
Cell ids of cell connected to this readout.
PixelMultipleConnection1D m_rowConnections
multiple connections for rows
int connectedCell(const int index, unsigned int number) const
Return the diode index corresponding the this readout.
void addMultipleRowConnection(const int lowerRow, const std::vector< int > &connections)
Add a new multiple connection for rows: lower diode row for which the connection scheme is given vect...
int m_columns
Number of columns.
unsigned int phiIndex(float phi, float binsize)
calculate phi index for a given phi
int m_rows
Number of rows.
bool outsideDiode(const int cell) const
Check if the diode is in the range:
SiCellId gangedCell(const SiCellId &cellId) const
If cell is ganged return the other cell, otherwise return an invalid id.
int numberOfConnectedCells(const int index) const
Return the number of diodes that are connected to this readout cell, Must check outsideReadout first.