ATLAS Offline Software
Public Member Functions | Private Member Functions | Private Attributes | List of all members
InDetDD::PixelReadoutScheme Class Reference

#include <PixelReadoutScheme.h>

Collaboration diagram for InDetDD::PixelReadoutScheme:

Public Member Functions

 PixelReadoutScheme (const int circuitsPerColumn, const int circuitsPerRow, const int cellColumnsPerCircuit, const int cellRowsPerCircuit, const int diodeColumnsPerCircuit, const int diodeRowsPerCircuit)
 Constructor with parameters: More...
 
 ~PixelReadoutScheme ()
 Destructor: More...
 
int numberOfCircuits () const
 total number of circuits: More...
 
int numberOfCircuitsPerColumn () const
 number of circuits per column: More...
 
int numberOfCircuitsPerRow () const
 number of circuits per row: More...
 
int columnsPerCircuit () const
 number of cell columns per circuit: More...
 
int rowsPerCircuit () const
 number of cell rows per circuit: More...
 
int columns () const
 number of cell columns per module: More...
 
int rows () const
 number of cell rows per module: More...
 
int numberOfConnectedCells (const SiReadoutCellId &readoutId) const
 number of cells connected to this readout. More...
 
SiCellId connectedCell (const SiReadoutCellId &readoutId, unsigned int number) const
 Cell ids of cell connected to this readout. More...
 
SiReadoutCellId readoutIdOfCell (const SiCellId &cellId) const
 Readout id of this diode. More...
 
SiCellId gangedCell (const SiCellId &cellId) const
 If cell is ganged return the other cell, otherwise return an invalid id. More...
 
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 vector containing, for each diode, the readout cell row number to which the corresponding diode is connected. More...
 

Private Member Functions

 PixelReadoutScheme ()
 

Private Attributes

PixelMultipleConnection1D m_rowConnections
 multiple connections for rows More...
 
int m_numberOfCircuits
 total number of circuits More...
 
int m_numberOfCircuitsPerColumn
 number of circuits per column More...
 
int m_numberOfCircuitsPerRow
 number of circuits per row More...
 
int m_columnsPerCircuit
 number of cell columns per circuit More...
 
int m_rowsPerCircuit
 number of cell rows per circuit More...
 
int m_columns
 Number of columns. More...
 
int m_rows
 Number of rows. More...
 

Detailed Description

Class used to describe the connection scheme of a diode matrix to a set of readout circuits

Author
David Calvet
  • modified on 5/10/04 Davide Costanzo. Replace PixelModulePosition with SiCellId
  • modified: Grant Gorfine, Andreas Salzburger

Definition at line 35 of file PixelReadoutScheme.h.

Constructor & Destructor Documentation

◆ PixelReadoutScheme() [1/2]

InDetDD::PixelReadoutScheme::PixelReadoutScheme ( const int  circuitsPerColumn,
const int  circuitsPerRow,
const int  cellColumnsPerCircuit,
const int  cellRowsPerCircuit,
const int  diodeColumnsPerCircuit,
const int  diodeRowsPerCircuit 
)

Constructor with parameters:

number of circuits in one circuit column number of circuits in one circuit row number of cell columns per circuit number of cell rows per circuit number of diode columns connected to one circuit number of diode rows connected to one circuit

Definition at line 22 of file PixelReadoutScheme.cxx.

27  :
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)
35 {
36  // protect against 0 columns or rows
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");
39 }

◆ ~PixelReadoutScheme()

InDetDD::PixelReadoutScheme::~PixelReadoutScheme ( )
inline

Destructor:

Definition at line 136 of file PixelReadoutScheme.h.

137 {}

◆ PixelReadoutScheme() [2/2]

InDetDD::PixelReadoutScheme::PixelReadoutScheme ( )
private

Member Function Documentation

◆ addMultipleRowConnection()

void InDetDD::PixelReadoutScheme::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 vector containing, for each diode, the readout cell row number to which the corresponding diode is connected.

Definition at line 102 of file PixelReadoutScheme.cxx.

104 {
105 
106  m_rowConnections.set(lowerIndex, connections);
107 }

◆ columns()

int InDetDD::PixelReadoutScheme::columns ( ) const
inline

number of cell columns per module:

Definition at line 164 of file PixelReadoutScheme.h.

165 {
166  return m_columns;
167 }

◆ columnsPerCircuit()

int InDetDD::PixelReadoutScheme::columnsPerCircuit ( ) const
inline

number of cell columns per circuit:

Definition at line 154 of file PixelReadoutScheme.h.

155 {
156  return m_columnsPerCircuit;
157 }

◆ connectedCell()

SiCellId InDetDD::PixelReadoutScheme::connectedCell ( const SiReadoutCellId readoutId,
unsigned int  number 
) const

Cell ids of cell connected to this readout.

Definition at line 59 of file PixelReadoutScheme.cxx.

60 {
61  if (!readoutId.isValid()) return {};
62 
63  // Do quick check to see if it is outside ganged pixel range.
64  int phiIndex = readoutId.phiIndex();
65  if (m_rowConnections.outsideReadout(phiIndex)) return readoutId;
66 
68  if (!numConnected || static_cast<int>(number) >= numConnected) return {};
69 
70  int newPhiIndex = m_rowConnections.connectedCell(phiIndex, number);
71  return {newPhiIndex, readoutId.etaIndex()};
72 }

◆ gangedCell()

SiCellId InDetDD::PixelReadoutScheme::gangedCell ( const SiCellId cellId) const

If cell is ganged return the other cell, otherwise return an invalid id.

Definition at line 91 of file PixelReadoutScheme.cxx.

92 {
93  if (!cellId.isValid()) return cellId;
94  int phiIndex = cellId.phiIndex();
95  if (m_rowConnections.outsideReadout(phiIndex)) return {}; // Invalid ID
96  int newPhiIndex = m_rowConnections.gangedCell(phiIndex);
97  if (newPhiIndex == phiIndex) return {}; // Invalid ID
98  return {newPhiIndex, cellId.etaIndex()};
99 }

◆ numberOfCircuits()

int InDetDD::PixelReadoutScheme::numberOfCircuits ( ) const
inline

total number of circuits:

Definition at line 139 of file PixelReadoutScheme.h.

140 {
141  return m_numberOfCircuits;
142 }

◆ numberOfCircuitsPerColumn()

int InDetDD::PixelReadoutScheme::numberOfCircuitsPerColumn ( ) const
inline

number of circuits per column:

Definition at line 144 of file PixelReadoutScheme.h.

145 {
147 }

◆ numberOfCircuitsPerRow()

int InDetDD::PixelReadoutScheme::numberOfCircuitsPerRow ( ) const
inline

number of circuits per row:

Definition at line 149 of file PixelReadoutScheme.h.

150 {
152 }

◆ numberOfConnectedCells()

int InDetDD::PixelReadoutScheme::numberOfConnectedCells ( const SiReadoutCellId readoutId) const

number of cells connected to this readout.

Definition at line 45 of file PixelReadoutScheme.cxx.

46 {
47  if (!readoutId.isValid()) return 0;
48 
49  // Do quick check to see if it is outside ganged pixel range.
50  int phiIndex = readoutId.phiIndex();
52 
54 
55 }

◆ readoutIdOfCell()

SiReadoutCellId InDetDD::PixelReadoutScheme::readoutIdOfCell ( const SiCellId cellId) const

Readout id of this diode.

Definition at line 76 of file PixelReadoutScheme.cxx.

77 {
78  if (!cellId.isValid()) return {};
79 
80  int phiIndex = cellId.phiIndex();
81  int newPhiIndex = phiIndex;
84  }
85 
86  return {newPhiIndex, cellId.etaIndex()};
87 
88 }

◆ rows()

int InDetDD::PixelReadoutScheme::rows ( ) const
inline

number of cell rows per module:

Definition at line 169 of file PixelReadoutScheme.h.

170 {
171  return m_rows;
172 }

◆ rowsPerCircuit()

int InDetDD::PixelReadoutScheme::rowsPerCircuit ( ) const
inline

number of cell rows per circuit:

Definition at line 159 of file PixelReadoutScheme.h.

160 {
161  return m_rowsPerCircuit;
162 }

Member Data Documentation

◆ m_columns

int InDetDD::PixelReadoutScheme::m_columns
private

Number of columns.

Definition at line 128 of file PixelReadoutScheme.h.

◆ m_columnsPerCircuit

int InDetDD::PixelReadoutScheme::m_columnsPerCircuit
private

number of cell columns per circuit

Definition at line 126 of file PixelReadoutScheme.h.

◆ m_numberOfCircuits

int InDetDD::PixelReadoutScheme::m_numberOfCircuits
private

total number of circuits

Definition at line 123 of file PixelReadoutScheme.h.

◆ m_numberOfCircuitsPerColumn

int InDetDD::PixelReadoutScheme::m_numberOfCircuitsPerColumn
private

number of circuits per column

Definition at line 124 of file PixelReadoutScheme.h.

◆ m_numberOfCircuitsPerRow

int InDetDD::PixelReadoutScheme::m_numberOfCircuitsPerRow
private

number of circuits per row

Definition at line 125 of file PixelReadoutScheme.h.

◆ m_rowConnections

PixelMultipleConnection1D InDetDD::PixelReadoutScheme::m_rowConnections
private

multiple connections for rows

Definition at line 122 of file PixelReadoutScheme.h.

◆ m_rows

int InDetDD::PixelReadoutScheme::m_rows
private

Number of rows.

Definition at line 129 of file PixelReadoutScheme.h.

◆ m_rowsPerCircuit

int InDetDD::PixelReadoutScheme::m_rowsPerCircuit
private

number of cell rows per circuit

Definition at line 127 of file PixelReadoutScheme.h.


The documentation for this class was generated from the following files:
InDetDD::PixelMultipleConnection1D::set
void set(const int lowerIndex, const std::vector< int > &connections)
Definition: PixelMultipleConnection1D.cxx:39
InDetDD::PixelReadoutScheme::m_numberOfCircuitsPerColumn
int m_numberOfCircuitsPerColumn
number of circuits per column
Definition: PixelReadoutScheme.h:124
InDetDD::PixelReadoutScheme::m_numberOfCircuitsPerRow
int m_numberOfCircuitsPerRow
number of circuits per row
Definition: PixelReadoutScheme.h:125
InDetDD::PixelMultipleConnection1D::readoutOfDiode
int readoutOfDiode(const int index) const
Return readout cell id of this diode, Must check outsideDiode first.
Definition: PixelMultipleConnection1D.h:116
InDetDD::PixelReadoutScheme::m_numberOfCircuits
int m_numberOfCircuits
total number of circuits
Definition: PixelReadoutScheme.h:123
InDetDD::PixelMultipleConnection1D::gangedCell
int gangedCell(const int index) const
If the diode is gnaged return the other diode.
Definition: PixelMultipleConnection1D.h:121
InDetDD::PixelMultipleConnection1D::outsideReadout
bool outsideReadout(const int index) const
Check if the readout cell is in the range; Also for index of gangedCell.
Definition: PixelMultipleConnection1D.h:94
InDetDD::PixelReadoutScheme::m_rowConnections
PixelMultipleConnection1D m_rowConnections
multiple connections for rows
Definition: PixelReadoutScheme.h:122
InDetDD::PixelMultipleConnection1D::connectedCell
int connectedCell(const int index, unsigned int number) const
Return the diode index corresponding the this readout.
Definition: PixelMultipleConnection1D.h:111
InDetDD::PixelReadoutScheme::m_rowsPerCircuit
int m_rowsPerCircuit
number of cell rows per circuit
Definition: PixelReadoutScheme.h:127
python.selection.number
number
Definition: selection.py:20
InDetDD::PixelReadoutScheme::m_columns
int m_columns
Number of columns.
Definition: PixelReadoutScheme.h:128
eflowRec::phiIndex
unsigned int phiIndex(float phi, float binsize)
calculate phi index for a given phi
Definition: EtaPhiLUT.cxx:23
InDetDD::PixelReadoutScheme::m_rows
int m_rows
Number of rows.
Definition: PixelReadoutScheme.h:129
InDetDD::PixelReadoutScheme::m_columnsPerCircuit
int m_columnsPerCircuit
number of cell columns per circuit
Definition: PixelReadoutScheme.h:126
InDetDD::PixelMultipleConnection1D::outsideDiode
bool outsideDiode(const int cell) const
Check if the diode is in the range:
Definition: PixelMultipleConnection1D.h:100
InDetDD::PixelMultipleConnection1D::numberOfConnectedCells
int numberOfConnectedCells(const int index) const
Return the number of diodes that are connected to this readout cell, Must check outsideReadout first.
Definition: PixelMultipleConnection1D.h:106