HerdSoftware
0.3.2
|
Data structure for single silicon layer geometry parameters. More...
#include <dataobjects/SiliconDetectorGeoParams.h>
Classes | |
struct | WaferLookupTable |
Internal lookup table used to speedup WaferID queries as function of position. More... | |
Public Member Functions | |
SiliconDetectorGeoParams () | |
Default constructor. More... | |
SiliconDetectorGeoParams (RefFrame::Side dside, size_t layerNumber, RefFrame::Direction stripMainSegm) | |
Construct a new SiliconDetectorGeoParams object. More... | |
~SiliconDetectorGeoParams () override=default | |
Virtual destructor. More... | |
size_t | NWafers () const |
Get the total number of wafers in a single layer. More... | |
float | StripPitch () const |
Get strip pitch.Calls ChannelPitch. Kept for backwards compatibility. More... | |
int | NStripsPerLadder () const |
Number of strips for each ladder. More... | |
float | FirstStripPosition () const |
Get distance of first strip from wafer edge. More... | |
const AxesArray< int > & | NWafersPerLadder () const |
Get the number of wafers that make up a ladder. This is intended as number of wafers along each direction, and basically defines the ladder orientation. As a convention the number of wafers in the normal plane direction is one. More... | |
const AxesArray< int > & | NLadders () const |
Get the number of ladder that make up a layer. This is intended as number of ladders along each direction. As a convention the number of ladders in the normal plane direction is one. More... | |
const AxesArray< float > & | WaferSize () const |
Get the dimensions of the single wafer. More... | |
Point | ElementPosition (unsigned int volID) const override |
Get position of a given strip. More... | |
Point | StripPosition (unsigned int volID) const |
Get position of a given strip. More... | |
const Point & | WaferPosition (unsigned int volID) const |
Get position of a given wafer in layer. More... | |
Point | LadderPosition (unsigned int ladderID) const |
Get position of a given ladder. More... | |
std::pair< RefFrame::Direction, RefFrame::Direction > | StripSegmentationDirections () const |
Return the segmentation directions of the silicon strips. More... | |
std::pair< RefFrame::Direction, RefFrame::Direction > | WaferSegmentationDirections () const |
Return the segmentation directions of the silicon Wafers. More... | |
std::pair< RefFrame::Direction, RefFrame::Direction > | LadderSegmentationDirections () const |
Return the segmentation directions of the silicon Ladders. More... | |
unsigned int | LadderIDFromStripID (unsigned int stripID) const |
Retrieves the volume ID of the ladder containing the strip with the given volumeID. More... | |
unsigned int | LadderIDFromWaferID (unsigned int waferID) const |
Retrieves the volume ID of the ladder containing the wafer with the given volumeID. More... | |
std::pair< unsigned int, unsigned int > | WaferIDsFromLadderID (unsigned int ladderID) const |
Retrieves the volume ID of the first and last wafers contained in the ladder with the given volumeID. More... | |
std::pair< unsigned int, unsigned int > | StripIDsFromLadderID (unsigned int ladderID) const |
Retrieves the volume ID of the first and last strip contained in the ladder with the given volumeID. More... | |
unsigned int | StripIDOnLadder (unsigned int stripID) const |
Returns the strip ID on ladder. More... | |
unsigned int | WaferID (const Point &position) const |
Utility function to get waferID from a set of coordinates. More... | |
unsigned int | ElementID (const Point &position) const override |
Utility function to get volumeID from a set of coordinates. Reimplemented in derived classes. More... | |
unsigned int | StripID (const Point &position) const |
Utility function to get stripID from a set of coordinates. Calls ElementID. More... | |
void | SetSideAndStripMainSegmDir (RefFrame::Side dside, RefFrame::Direction segmDir) |
Set the detector side and the main segmentation direction for strips. Calls SetSideAndMainSegmDir. Kept for backwards compatibility. More... | |
void | SetSideAndMainSegmDir (RefFrame::Side dside, RefFrame::Direction segmDir) override |
Set the detector side and the main segmentation direction for channels. More... | |
void | SetStripPitch (float pitch) |
Set the strip pitch. More... | |
void | SetNStripsPerLadder (int nStrips) |
Set the number of strips per ladder. More... | |
void | SetNWafersPerLadder (AxesArray< int > nWafers) |
Set the number of wafers in each ladder along each axis. More... | |
void | SetNLadders (AxesArray< int > nLadders) |
Set the number of ladders along each axis. More... | |
void | SetWaferSize (const AxesArray< float > &sizes) |
Set the wafer sizes along the three axes. More... | |
void | SetWaferPosition (size_t waferID, Point position) |
Set the wafer position for a given wafer. More... | |
![]() | |
TrackingDetectorGeoParams () | |
Default constructor. More... | |
virtual | ~TrackingDetectorGeoParams ()=default |
Virtual destructor. More... | |
virtual const RefFrame::Side & | Side () const |
Return the detector side this layer is in. More... | |
virtual size_t | LayerNumber () const |
Return the layer number for this layer in its detector. More... | |
virtual bool | HasTungsten () const |
Check if layer is preceded by tungsten plane. More... | |
float | TungstenThickness () const |
Get the tungsten layer thickness. More... | |
virtual float | ElementPitch () const |
Get element pitch. More... | |
virtual RefFrame::Direction | NormalDirection () const |
Get the normal direction to the detector. More... | |
virtual std::pair< RefFrame::Direction, RefFrame::Direction > | SegmentationDirections () const |
Return the segmentation directions of the tracking elements. More... | |
virtual void | SetHasTungsten (bool value) |
Set the tungsten flag. More... | |
virtual void | SetTungstenThickness (float value) |
Set the tungsten plane thickness. More... | |
Protected Member Functions | |
void | UpdateLUT () const |
Position of all the Si wafers. More... | |
Protected Attributes | |
struct Herd::SiliconDetectorGeoParams::WaferLookupTable | m_waferLUT |
![]() | |
RefFrame::Side | _side |
size_t | _layerNumber |
Detector side. More... | |
RefFrame::Direction | _normalDir |
Layer number. More... | |
RefFrame::Direction | _mainSegmDir |
Normal direction. More... | |
RefFrame::Direction | _secSegmDir |
Main segmentation direction for elements. More... | |
float | _elementPitch |
Secondary segmentation direction for elements. More... | |
bool | _hasTungsten |
Element pitch. More... | |
float | _tungstenThickness |
True if layer is preceded by a tungsten plane. More... | |
Private Attributes | |
float | _firstStripPos |
int | _nStripsPerLadder |
Position of the first strip w.r.t the left border of the wafer [cm];. More... | |
AxesArray< float > | _waferSize |
Number of strips in each wafer. More... | |
AxesArray< int > | _nWafersPerLadder |
Dimensions of a Si wafer along the three axes. More... | |
AxesArray< int > | _nLadders |
Number of wafers in each ladder along the three axes. More... | |
std::vector< Point > | _waferPos |
Number of ladders in each wafer along the three axes. More... | |
Data structure for single silicon layer geometry parameters.
|
inline |
Default constructor.
Herd::SiliconDetectorGeoParams::SiliconDetectorGeoParams | ( | RefFrame::Side | dside, |
size_t | layerNumber, | ||
RefFrame::Direction | stripMainSegm | ||
) |
Construct a new SiliconDetectorGeoParams object.
dside | The detector side. |
stripMainSegm | The main segmentation direction for strips. |
|
overridedefault |
Virtual destructor.
|
overridevirtual |
Utility function to get volumeID from a set of coordinates. Reimplemented in derived classes.
position | The coordinates of the point (normal coordinate is ignored). |
Implements Herd::TrackingDetectorGeoParams.
|
overridevirtual |
Get position of a given strip.
stripID | The unique ID of the strip. |
Implements Herd::TrackingDetectorGeoParams.
|
inline |
Get distance of first strip from wafer edge.
unsigned int Herd::SiliconDetectorGeoParams::LadderIDFromStripID | ( | unsigned int | stripID | ) | const |
Retrieves the volume ID of the ladder containing the strip with the given volumeID.
stripID | The volumeID of the strip. |
unsigned int Herd::SiliconDetectorGeoParams::LadderIDFromWaferID | ( | unsigned int | waferID | ) | const |
Retrieves the volume ID of the ladder containing the wafer with the given volumeID.
waferID | The volumeID of the wafer. |
Point Herd::SiliconDetectorGeoParams::LadderPosition | ( | unsigned int | ladderID | ) | const |
Get position of a given ladder.
ladderID | The unique ID of the ladder. |
std::pair< RefFrame::Direction, RefFrame::Direction > Herd::SiliconDetectorGeoParams::LadderSegmentationDirections | ( | ) | const |
Return the segmentation directions of the silicon Ladders.
The first element of the returned pair is the direction along which the volume ID increases by 1 (the so called "main segmentation direction"), the second element is the other segmentation direction (the "secondary segmentation direction"). For the silicon strip the main segmentation direction is the natural one defined by the strip orientation.
std::runtime_error | if the normal direction setting is not valid. |
|
inline |
Get the number of ladder that make up a layer. This is intended as number of ladders along each direction. As a convention the number of ladders in the normal plane direction is one.
|
inline |
Number of strips for each ladder.
|
inline |
Get the total number of wafers in a single layer.
|
inline |
Get the number of wafers that make up a ladder. This is intended as number of wafers along each direction, and basically defines the ladder orientation. As a convention the number of wafers in the normal plane direction is one.
void Herd::SiliconDetectorGeoParams::SetNLadders | ( | AxesArray< int > | nLadders | ) |
Set the number of ladders along each axis.
The value for the orthogonal axis must be 1.
nLadders | The number of ladders along each direction |
std::runtime_error | if the number of ladders along the orthogonal direction is not 1. |
void Herd::SiliconDetectorGeoParams::SetNStripsPerLadder | ( | int | nStrips | ) |
Set the number of strips per ladder.
Must be called after SetSideAndStripMainSegmDir and SetWaferSize. This method computes and sets also the strip pitch.
nStrips | The number of strips per ladder. |
std::runtime_error | if this method is called before SetSideAndStripMainSegmDir or SetWaferSize. |
void Herd::SiliconDetectorGeoParams::SetNWafersPerLadder | ( | AxesArray< int > | nWafers | ) |
Set the number of wafers in each ladder along each axis.
Must be called after SetSideAndStripMainSegmDir. The number of wafers must be 1 along the normal and along the strip main segmentation direction.
nWafers | The number of wafers |
std::runtime_error | if this method is called before SetSideAndStripMainSegmDir. |
std::runtime_error | if the number of wafers along the orthogonal direction and along the strip main segmentation direction is not 1. |
|
overridevirtual |
Set the detector side and the main segmentation direction for channels.
dside | The side. |
segmDir | the main segmentation direction for channels. |
Implements Herd::TrackingDetectorGeoParams.
|
inline |
Set the detector side and the main segmentation direction for strips. Calls SetSideAndMainSegmDir. Kept for backwards compatibility.
dside | The side. |
segmDir | the main segmentation direction for strips. |
void Herd::SiliconDetectorGeoParams::SetStripPitch | ( | float | pitch | ) |
Set the strip pitch.
Must be called after SetSideAndStripMainSegmDir and SetWaferSize. This method computes and sets also the position of the first strip.
pitch | the strip pitch [cm]. |
std::runtime_error | if this method is called before SetSideAndStripMainSegmDir or SetWaferSize. |
|
inline |
Set the wafer position for a given wafer.
See the wiki page for the wafer numbering convention.
waferID | |
position |
|
inline |
Set the wafer sizes along the three axes.
Must be called before SetStripPitch and SetNStripsPerLadder.
sizes | the size of the wafer along each axis [cm]. |
|
inline |
Utility function to get stripID from a set of coordinates. Calls ElementID.
This method is just a more descriptive name for ElementID.
position | The coordinates of the point (normal coordinate is ignored). |
unsigned int Herd::SiliconDetectorGeoParams::StripIDOnLadder | ( | unsigned int | stripID | ) | const |
Returns the strip ID on ladder.
This method computes the relative strip ID on the ladder for the given strip. This will return 0 for the first strip of the ladder etc.
stripID | The absolute strip ID. |
std::pair< unsigned int, unsigned int > Herd::SiliconDetectorGeoParams::StripIDsFromLadderID | ( | unsigned int | ladderID | ) | const |
Retrieves the volume ID of the first and last strip contained in the ladder with the given volumeID.
ladderID | The volumeID of the ladder. |
|
inline |
Get strip pitch.Calls ChannelPitch. Kept for backwards compatibility.
|
inline |
Get position of a given strip.
stripID | The unique ID of the strip. |
|
inline |
Return the segmentation directions of the silicon strips.
The first element of the returned pair is the direction along which the volume ID increases by 1 (the so called "main segmentation direction"), the second element is the other segmentation direction (the "secondary segmentation direction"). For the silicon strip the main segmentation direction is the natural one defined by the strip orientation.
std::runtime_error | if the normal direction setting is not valid. |
|
protected |
Position of all the Si wafers.
unsigned int Herd::SiliconDetectorGeoParams::WaferID | ( | const Point & | position | ) | const |
Utility function to get waferID from a set of coordinates.
position | The coordinates of the point (normal coordinate is ignored). |
std::pair< unsigned int, unsigned int > Herd::SiliconDetectorGeoParams::WaferIDsFromLadderID | ( | unsigned int | ladderID | ) | const |
Retrieves the volume ID of the first and last wafers contained in the ladder with the given volumeID.
ladderID | The volumeID of the ladder. |
|
inline |
std::pair< RefFrame::Direction, RefFrame::Direction > Herd::SiliconDetectorGeoParams::WaferSegmentationDirections | ( | ) | const |
Return the segmentation directions of the silicon Wafers.
The first element of the returned pair is the direction along which the volume ID increases by 1 (the so called "main segmentation direction"), the second element is the other segmentation direction (the "secondary segmentation direction"). For the silicon strip the main segmentation direction is the natural one defined by the strip orientation.
std::runtime_error | if the normal direction setting is not valid. |
|
inline |
Get the dimensions of the single wafer.
|
private |
|
private |
Number of wafers in each ladder along the three axes.
|
private |
Position of the first strip w.r.t the left border of the wafer [cm];.
|
private |
Dimensions of a Si wafer along the three axes.
|
private |
Number of ladders in each wafer along the three axes.
|
private |
Number of strips in each wafer.
|
protected |