Belle II Software development
PXDRecoHit.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11#include <vxd/dataobjects/VxdID.h>
12
13// ROOT includes
14#include <TMatrixD.h>
15
16// GenFit includes
17#include <genfit/PlanarMeasurement.h>
18#include <genfit/HMatrixUV.h>
19
20namespace genfit {
21 class TrackCandHit;
22}
23
24namespace Belle2 {
29 class PXDTrueHit;
30 class PXDCluster;
31
53 class PXDRecoHit: public genfit::PlanarMeasurement {
54 public:
55
57 PXDRecoHit();
58
72 explicit PXDRecoHit(const PXDTrueHit* hit, const genfit::TrackCandHit* trackCandHit = NULL, float sigmaU = -1, float sigmaV = -1);
73
82 explicit PXDRecoHit(const PXDCluster* hit, float sigmaU, float sigmaV, float covUV);
83
95 explicit PXDRecoHit(const PXDCluster* hit, const genfit::TrackCandHit* trackCandHit = NULL);
96
98 genfit::AbsMeasurement* clone() const override;
99
101 /* This method allows to provide hit position dependent on track direction. */
102 virtual std::vector<genfit::MeasurementOnPlane*> constructMeasurementsOnPlane(const genfit::StateOnPlane& state) const override;
103
105 VxdID getSensorID() const { return m_sensorID; }
106
108 const PXDTrueHit* getTrueHit() const { return m_trueHit; }
110 const PXDCluster* getCluster() const { return m_cluster; }
111
113 float getU() const { return rawHitCoords_(0); }
115 float getV() const { return rawHitCoords_(1); }
116
118 float getUVariance() const { return rawHitCov_(0, 0); }
120 float getVVariance() const { return rawHitCov_(1, 1); }
122 float getUVCov() const { return rawHitCov_(0, 1); }
123
125 float getEnergyDep() const { return m_energyDep; }
126
128 //float getEnergyDepError() const { return m_energyDepError; }
129
131 float getShapeLikelyhood(const genfit::StateOnPlane& state) const;
132
134 virtual const genfit::AbsHMatrix* constructHMatrix(const genfit::AbsTrackRep*) const override { return new genfit::HMatrixUV(); };
135
136 private:
137
138 enum { HIT_DIMENSIONS = 2 };
139
145 //float m_energyDepError; /**< error in dep. energy.*/
147 unsigned short m_sensorID;
148
150 void setDetectorPlane();
151
153 TVectorD applyPlanarDeformation(TVectorD hitCoords, std::vector<double> planarParameters, const genfit::StateOnPlane& state) const;
154
155 ClassDefOverride(PXDRecoHit, 9)
156 };
157
159} // namespace Belle2
The PXD Cluster class This class stores all information about reconstructed PXD clusters The position...
Definition PXDCluster.h:30
float getShapeLikelyhood(const genfit::StateOnPlane &state) const
Get deposited energy error.
virtual std::vector< genfit::MeasurementOnPlane * > constructMeasurementsOnPlane(const genfit::StateOnPlane &state) const override
Methods that actually interface to Genfit.
float getV() const
Get v coordinate.
Definition PXDRecoHit.h:115
float m_energyDep
transient member (not written out during streaming)
Definition PXDRecoHit.h:144
float getUVariance() const
Get u coordinate variance.
Definition PXDRecoHit.h:118
float getEnergyDep() const
Get deposited energy.
Definition PXDRecoHit.h:125
unsigned short m_sensorID
Unique sensor identifier.
Definition PXDRecoHit.h:147
const PXDTrueHit * getTrueHit() const
Get pointer to the TrueHit used when creating this RecoHit, can be NULL if created from something els...
Definition PXDRecoHit.h:108
float getVVariance() const
Get v coordinate variance.
Definition PXDRecoHit.h:120
const PXDTrueHit * m_trueHit
Pointer to the TrueHit used when creating this object.
Definition PXDRecoHit.h:141
PXDRecoHit()
Default constructor for ROOT IO.
Definition PXDRecoHit.cc:27
const PXDCluster * m_cluster
transient member (not written out during streaming)
Definition PXDRecoHit.h:143
TVectorD applyPlanarDeformation(TVectorD hitCoords, std::vector< double > planarParameters, const genfit::StateOnPlane &state) const
Apply planar deformation of sensors.
void setDetectorPlane()
Set up Detector plane information.
float getUVCov() const
Get u-v error covariance.
Definition PXDRecoHit.h:122
const PXDCluster * getCluster() const
Get pointer to the Cluster used when creating this RecoHit, can be NULL if created from something els...
Definition PXDRecoHit.h:110
VxdID getSensorID() const
Get the compact ID.
Definition PXDRecoHit.h:105
@ HIT_DIMENSIONS
sensitive Dimensions of the Hit
Definition PXDRecoHit.h:138
genfit::AbsMeasurement * clone() const override
Creating a deep copy of this hit.
virtual const genfit::AbsHMatrix * constructHMatrix(const genfit::AbsTrackRep *) const override
Construct the hessian matrix.
Definition PXDRecoHit.h:134
float getU() const
Get u coordinate.
Definition PXDRecoHit.h:113
Class PXDTrueHit - Records of tracks that either enter or leave the sensitive volume.
Definition PXDTrueHit.h:31
Class to uniquely identify a any structure of the PXD and SVD.
Definition VxdID.h:32
Abstract base class for different kinds of events.