CbmRoot
|
Algorithm for hit finding in the sensors of the CBM-STS. More...
#include <CbmStsAlgoFindHits.h>
Public Member Functions | |
CbmStsAlgoFindHits () | |
Constructor. More... | |
CbmStsAlgoFindHits (const CbmStsAlgoFindHits &)=delete | |
Copy constructor (disabled) More... | |
CbmStsAlgoFindHits & | operator= (const CbmStsAlgoFindHits &)=delete |
Assignment operator (disabled) More... | |
virtual | ~CbmStsAlgoFindHits () |
Destructor More... | |
Long64_t | Exec (const std::vector< CbmStsCluster > &clustersF, const std::vector< CbmStsCluster > &clustersB, std::vector< CbmStsHit > &hits, UInt_t address, Double_t timeCutSig, Double_t timeCutAbs, Double_t dY, UInt_t nStrips, Double_t pitch, Double_t stereoF, Double_t stereoB, Double_t lorentzF, Double_t lorentzB, TGeoHMatrix *matrix) |
Execute algorithm. More... | |
Private Member Functions | |
void | CreateHit (Double_t xLocal, Double_t yLocal, Double_t varX, Double_t varY, Double_t varXY, const CbmStsCluster &clusterF, const CbmStsCluster &clusterB, UInt_t indexF, UInt_t indexB, Double_t du=0., Double_t dv=0.) |
Create a new hit in the output array. More... | |
void | GetClusterPosition (Double_t ClusterCentre, Double_t &xCluster, Int_t &side) |
Int_t | GetSide (Double_t channel) const |
std::pair< Int_t, Int_t > | GetStrip (UInt_t channel) const |
Get strip and side from module channel. More... | |
Bool_t | Intersect (Double_t xF, Double_t exF, Double_t xB, Double_t exB, Double_t &x, Double_t &y, Double_t &varX, Double_t &varY, Double_t &varXY) |
Intersection point of two strips / cluster centres. More... | |
Int_t | IntersectClusters (const CbmStsCluster &clusterF, const CbmStsCluster &clusterB, UInt_t indexF, UInt_t indexB) |
Find the intersection points of two clusters. More... | |
Bool_t | IsInside (Double_t x, Double_t y) |
Check whether a point (x,y) is inside the active area. More... | |
ClassDef (CbmStsAlgoFindHits, 1) | |
Private Attributes | |
UInt_t | fAddress = 0 |
Unique address for hits (sensor) More... | |
Double_t | fTimeCutSig = 0. |
Time cut on clusters in error units. More... | |
Double_t | fTimeCutAbs = 0. |
Time cut on clusters in ns. More... | |
UInt_t | fNofStrips = 0 |
Number of strips. More... | |
Double_t | fDx = 0. |
Active size in x [cm]. More... | |
Double_t | fDy = 0. |
Active size in y [cm]. More... | |
Double_t | fPitch = 0. |
Strip pitch [cm]. More... | |
Double_t | fStereoF = 0. |
Stereo angle front side [deg]. More... | |
Double_t | fStereoB = 0. |
Stereo angle back side [deg]. More... | |
Double_t | fLorentzF = 0. |
Lorentz shift correction front side [cm]. More... | |
Double_t | fLorentzB = 0. |
Lorentz shift correction back side [cm]. More... | |
TGeoHMatrix * | fMatrix = nullptr |
Double_t | fTanStereoF = 0. |
///< Transformation matrix to global C.S. More... | |
Double_t | fTanStereoB = 0. |
Tangent of stereo angle back side. More... | |
Double_t | fErrorFac = 0. |
For calculation of the hit error. More... | |
std::vector< CbmStsHit > * | fHits = nullptr |
Output vector of hits. More... | |
Algorithm for hit finding in the sensors of the CBM-STS.
A hit is constructed from two clusters, one from the front side, the other one from the back side of the sensor, if they two clusters have a geometrical intersection in the active sensor area, and if they are compatible in time. The algorithm combines front-side with back-side clusters and checks for these conditions. The hit coordinates are transformed into the global coordinate system.
The loop over the clusters was optimised by F. Boeck for application to free-streaming data (not sorted into events).
Definition at line 34 of file CbmStsAlgoFindHits.h.
CbmStsAlgoFindHits::CbmStsAlgoFindHits | ( | ) |
Constructor.
Definition at line 24 of file CbmStsAlgoFindHits.cxx.
|
delete |
Copy constructor (disabled)
|
inlinevirtual |
Destructor
Definition at line 50 of file CbmStsAlgoFindHits.h.
|
private |
|
private |
Create a new hit in the output array.
xLocal | hit x coordinate in sensor system [cm] |
yLocal | hit y coordinate in sensor system [cm] |
varX | Variance in x [cm^2] |
varY | Variance in y [cm^2] |
varXY | Covariance of x and y [cm^2] |
clusterF | Front-side cluster |
clusterB | Back-side cluster |
indexF | Index of front-side cluster |
indexB | Index of back-side cluster |
du | Error in u coordinate (across strips front side) [cm] |
dv | Error in v coordinate (across strips back side) [cm] |
Definition at line 29 of file CbmStsAlgoFindHits.cxx.
References fAddress, fHits, fMatrix, CbmStsCluster::GetTime(), and CbmStsCluster::GetTimeError().
Referenced by IntersectClusters().
Long64_t CbmStsAlgoFindHits::Exec | ( | const std::vector< CbmStsCluster > & | clustersF, |
const std::vector< CbmStsCluster > & | clustersB, | ||
std::vector< CbmStsHit > & | hits, | ||
UInt_t | address, | ||
Double_t | timeCutSig, | ||
Double_t | timeCutAbs, | ||
Double_t | dY, | ||
UInt_t | nStrips, | ||
Double_t | pitch, | ||
Double_t | stereoF, | ||
Double_t | stereoB, | ||
Double_t | lorentzF, | ||
Double_t | lorentzB, | ||
TGeoHMatrix * | matrix | ||
) |
Execute algorithm.
clustersF | Input clusters front side |
clusterB | Input clusters back side |
hits | Output hits |
Hit | address ( = module address) |
timeCutSig | Time cut in units of cluster time error |
timeCutAbs | Time cut in ns |
dY | Vertical size of the active sensor area [cm] |
nStrips | Number of strips (same for both sensor sides) |
pitch | Strip ptch [cm] (same for both sensor sides) |
stereoF | Strip stereo angle sensor front side [deg] |
stereoB | Strip stereo angle sensor back side [deg] |
lorentzF | Mean Lorentz shift front side (electrons) [cm] |
lorentzB | Mean Lorentz shift back side (holes) [cm] |
matrix | Transformation matrix from local to global C.S. |
Definition at line 85 of file CbmStsAlgoFindHits.cxx.
References fabs(), fAddress, fDx, fDy, fErrorFac, fHits, fLorentzB, fLorentzF, fMatrix, fNofStrips, fPitch, fStereoB, fStereoF, fTanStereoB, fTanStereoF, CbmStsCluster::GetTime(), CbmStsCluster::GetTimeError(), hits, and IntersectClusters().
Referenced by CbmStsRecoModule::Reconstruct().
|
private |
Get the cluster position at the top edge of the sensor.
[in] | centre | Cluster centre in (module) channel units |
[out] | xCluster | Cluster position at readout edge |
[out] | side | Sensor side [0 = front, 1 = back] |
A correction for the Lorentz shift is applied.
Definition at line 185 of file CbmStsAlgoFindHits.cxx.
References fLorentzB, fLorentzF, fPitch, and GetStrip().
Referenced by IntersectClusters().
|
inlineprivate |
Get the side of the sensor from the module channel number The channel number can also be the cluster position, so it needs not be integer.
channel | Channel number |
Definition at line 130 of file CbmStsAlgoFindHits.h.
References fNofStrips.
|
private |
Get strip and side from module channel.
[in] | channel | Channel number in module |
[in] | sensorId | Sensor index in module @value Pair of strip number and side |
Note: This must be the inverse of GetModuleChannel.
Definition at line 220 of file CbmStsAlgoFindHits.cxx.
References fNofStrips.
Referenced by GetClusterPosition().
|
private |
Intersection point of two strips / cluster centres.
[in] | xF | x coordinate on read-out edge, front side [cm] |
[in] | exF | uncertainty on xF [cm] |
[in] | xB | x coordinate on read-out edge, back side [cm] |
[in] | eBF | uncertainty on xB [cm] |
[out] | x | x coordinate of crossing [cm] |
[out] | y | y coordinate of crossing [cm] |
[out] | varX | Variance in x [cm^2] |
[out] | varY | Variance in y [cm^2] |
[out] | varXY | Covariance of x and y [cm^2] |
This function calculates the intersection point of two lines starting at xF and xB at the top edge with slopes corresponding to the respective stereo angle.
All coordinates are in the sensor frame with the origin in the bottom left corner of the active area.
Definition at line 246 of file CbmStsAlgoFindHits.cxx.
References fDx, fDy, fErrorFac, fStereoB, fStereoF, fTanStereoB, fTanStereoF, IsInside(), x, and y.
Referenced by IntersectClusters().
|
private |
Find the intersection points of two clusters.
clusterF | Cluster on front side |
clusterB | Cluster on back side |
indexF | Index of cluster on front side |
indexB | Index of cluster on back side |
For each intersection point, a hit is created.
Definition at line 310 of file CbmStsAlgoFindHits.cxx.
References CreateHit(), fDx, fDy, fPitch, fStereoB, fStereoF, fTanStereoB, fTanStereoF, GetClusterPosition(), CbmStsCluster::GetPosition(), CbmStsCluster::GetPositionError(), and Intersect().
Referenced by Exec().
|
private |
Check whether a point (x,y) is inside the active area.
x | x coordinate in the local c.s. [cm] |
y | y coordinate in the local c.s. [cm] |
The coordinates have to be given in the local coordinate system (origin in the sensor centre).
Definition at line 403 of file CbmStsAlgoFindHits.cxx.
References fDx, fDy, x, and y.
Referenced by Intersect().
|
delete |
Assignment operator (disabled)
|
private |
Unique address for hits (sensor)
Definition at line 203 of file CbmStsAlgoFindHits.h.
Referenced by CreateHit(), and Exec().
|
private |
Active size in x [cm].
Definition at line 207 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), Intersect(), IntersectClusters(), and IsInside().
|
private |
Active size in y [cm].
Definition at line 208 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), Intersect(), IntersectClusters(), and IsInside().
|
private |
For calculation of the hit error.
Definition at line 217 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), and Intersect().
|
private |
Output vector of hits.
Definition at line 220 of file CbmStsAlgoFindHits.h.
Referenced by CreateHit(), and Exec().
|
private |
Lorentz shift correction back side [cm].
Definition at line 213 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), and GetClusterPosition().
|
private |
Lorentz shift correction front side [cm].
Definition at line 212 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), and GetClusterPosition().
|
private |
Definition at line 214 of file CbmStsAlgoFindHits.h.
Referenced by CreateHit(), and Exec().
|
private |
Number of strips.
Definition at line 206 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), GetSide(), and GetStrip().
|
private |
Strip pitch [cm].
Definition at line 209 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), GetClusterPosition(), and IntersectClusters().
|
private |
Stereo angle back side [deg].
Definition at line 211 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), Intersect(), and IntersectClusters().
|
private |
Stereo angle front side [deg].
Definition at line 210 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), Intersect(), and IntersectClusters().
|
private |
Tangent of stereo angle back side.
Definition at line 216 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), Intersect(), and IntersectClusters().
|
private |
///< Transformation matrix to global C.S.
Tangent of stereo angle front side
Definition at line 215 of file CbmStsAlgoFindHits.h.
Referenced by Exec(), Intersect(), and IntersectClusters().
|
private |
Time cut on clusters in ns.
Definition at line 205 of file CbmStsAlgoFindHits.h.
|
private |
Time cut on clusters in error units.
Definition at line 204 of file CbmStsAlgoFindHits.h.