Belle II Software development
FourHitVariables Class Reference

Class that allows the calculation of simple variables to estimate the quality of two triplets of hits using four hits. More...

#include <FourHitVariables.h>

Public Member Functions

 FourHitVariables ()
 basic constructor
 
 FourHitVariables (const B2Vector3D &oHit, const B2Vector3D &ocHit, const B2Vector3D &icHit, const B2Vector3D &iHit)
 actual useful constructor
 
void setHits (const B2Vector3D &oHit, const B2Vector3D &ocHit, const B2Vector3D &icHit, const B2Vector3D &iHit)
 Set hits if not given in constructor of if they need to be changed.
 
double getCircleRadiusDifference ()
 calculates dpt-value (dpt= difference in transverse momentum of 2 subsets of the hits), returning unit: cm
 
double getCircleCenterPositionDifference ()
 calculates the distance between the estimated circle centers (using 2 subsets of given hits) in the xy-plane, returning unit: cm
 
double getDeltaPT ()
 calculates dpt-value (dpt= difference in transverse momentum of 2 subsets of the hits), returning unit: GeV/c
 
void setBFieldZ (const double bfieldZ=1.5)
 Set the B-Field value used for pT calculations.
 

Private Attributes

double m_BFieldZ = 1.5
 BField along z to estimate pT.
 
B2Vector3D m_oHit
 outermost hit position
 
B2Vector3D m_ocHit
 second-to-outer hit position
 
B2Vector3D m_icHit
 second-to-inner hit position
 
B2Vector3D m_iHit
 innermost hit position
 
ThreeHitVariables m_outerThreeHitVariables
 ThreeHitVariables getter for the outer three hits.
 
ThreeHitVariables m_innerThreeHitVariables
 ThreeHitVariables getter for the inner three hits.
 

Detailed Description

Class that allows the calculation of simple variables to estimate the quality of two triplets of hits using four hits.

Definition at line 24 of file FourHitVariables.h.

Constructor & Destructor Documentation

◆ FourHitVariables() [1/2]

FourHitVariables ( )
inline

basic constructor

Definition at line 27 of file FourHitVariables.h.

27 : m_oHit(0., 0., 0.), m_ocHit(0., 0., 0.), m_icHit(0., 0., 0.), m_iHit(0., 0., 0.)
28 {};
B2Vector3D m_ocHit
second-to-outer hit position
B2Vector3D m_oHit
outermost hit position
B2Vector3D m_iHit
innermost hit position
B2Vector3D m_icHit
second-to-inner hit position

◆ FourHitVariables() [2/2]

FourHitVariables ( const B2Vector3D oHit,
const B2Vector3D ocHit,
const B2Vector3D icHit,
const B2Vector3D iHit 
)
inline

actual useful constructor

Parameters
oHitB2Vector3D of the outer hit used for calculating the single variables
ocHitB2Vector3D of the second-outer hit used for calculating the single variables
icHitB2Vector3D of the second-inner hit used for calculating the single variables
iHitB2Vector3D of the inner hit used for calculating the single variables

Definition at line 35 of file FourHitVariables.h.

35 :
36 m_oHit(oHit), m_ocHit(ocHit), m_icHit(icHit), m_iHit(iHit)
37 {
38 m_outerThreeHitVariables = ThreeHitVariables(oHit, ocHit, icHit);
39 m_innerThreeHitVariables = ThreeHitVariables(ocHit, icHit, iHit);
40 };
ThreeHitVariables m_innerThreeHitVariables
ThreeHitVariables getter for the inner three hits.
ThreeHitVariables m_outerThreeHitVariables
ThreeHitVariables getter for the outer three hits.

Member Function Documentation

◆ getCircleCenterPositionDifference()

double getCircleCenterPositionDifference ( )
inline

calculates the distance between the estimated circle centers (using 2 subsets of given hits) in the xy-plane, returning unit: cm

Definition at line 73 of file FourHitVariables.h.

74 {
77 if (outerCircleCenter.Perp2() > 1e30 or innerCircleCenter.Perp2() > 1e30) {
78 return NAN;
79 }
80
81 return fabs(outerCircleCenter.Perp() - innerCircleCenter.Perp());
82 }
B2Vector3D getCircleCenterXY()
calculates an estimation of circleCenter position, result is returned as the x and y value of the B2V...
B2Vector3< double > B2Vector3D
typedef for common usage with double
Definition: B2Vector3.h:516

◆ getCircleRadiusDifference()

double getCircleRadiusDifference ( )
inline

calculates dpt-value (dpt= difference in transverse momentum of 2 subsets of the hits), returning unit: cm

Definition at line 58 of file FourHitVariables.h.

59 {
62 if (outerCircleCenter.Perp2() > 1e30 or innerCircleCenter.Perp2() > 1e30) {
63 return NAN;
64 }
65 double outerCircleRadius = m_outerThreeHitVariables.calcAvgDistanceXY(outerCircleCenter);
66 double innerCircleRadius = m_innerThreeHitVariables.calcAvgDistanceXY(innerCircleCenter);
67
68 return outerCircleRadius - innerCircleRadius;
69 }
double calcAvgDistanceXY(const B2Vector3D &circleCenter)
helper function which calculates the average distance in XY from the given center

◆ getDeltaPT()

double getDeltaPT ( )
inline

calculates dpt-value (dpt= difference in transverse momentum of 2 subsets of the hits), returning unit: GeV/c

Definition at line 86 of file FourHitVariables.h.

87 {
90 if (outerCircleCenter.Perp2() > 1e30 or innerCircleCenter.Perp2() > 1e30) {
91 return NAN;
92 }
93 double outerCircleRadius = m_outerThreeHitVariables.calcAvgDistanceXY(outerCircleCenter);
94 double innerCircleRadius = m_innerThreeHitVariables.calcAvgDistanceXY(innerCircleCenter);
95
96 return fabs(0.00299792458 * m_BFieldZ * (outerCircleRadius - innerCircleRadius));
97 }
double m_BFieldZ
BField along z to estimate pT.

◆ setBFieldZ()

void setBFieldZ ( const double  bfieldZ = 1.5)
inline

Set the B-Field value used for pT calculations.

Parameters
bfieldZB-Field value to be used

Definition at line 101 of file FourHitVariables.h.

101{ m_BFieldZ = bfieldZ; }

◆ setHits()

void setHits ( const B2Vector3D oHit,
const B2Vector3D ocHit,
const B2Vector3D icHit,
const B2Vector3D iHit 
)
inline

Set hits if not given in constructor of if they need to be changed.

Parameters
oHitB2Vector3D of the outer hit used for calculating the single variables
ocHitB2Vector3D of the second-outer hit used for calculating the single variables
icHitB2Vector3D of the second-inner hit used for calculating the single variables
iHitB2Vector3D of the inner hit used for calculating the single variables

Definition at line 47 of file FourHitVariables.h.

48 {
49 m_oHit = oHit;
50 m_ocHit = ocHit;
51 m_icHit = icHit;
52 m_iHit = iHit;
53 m_outerThreeHitVariables = ThreeHitVariables(oHit, ocHit, icHit);
54 m_innerThreeHitVariables = ThreeHitVariables(ocHit, icHit, iHit);
55 }

Member Data Documentation

◆ m_BFieldZ

double m_BFieldZ = 1.5
private

BField along z to estimate pT.

Definition at line 105 of file FourHitVariables.h.

◆ m_icHit

B2Vector3D m_icHit
private

second-to-inner hit position

Definition at line 111 of file FourHitVariables.h.

◆ m_iHit

B2Vector3D m_iHit
private

innermost hit position

Definition at line 113 of file FourHitVariables.h.

◆ m_innerThreeHitVariables

ThreeHitVariables m_innerThreeHitVariables
private

ThreeHitVariables getter for the inner three hits.

Definition at line 117 of file FourHitVariables.h.

◆ m_ocHit

B2Vector3D m_ocHit
private

second-to-outer hit position

Definition at line 109 of file FourHitVariables.h.

◆ m_oHit

B2Vector3D m_oHit
private

outermost hit position

Definition at line 107 of file FourHitVariables.h.

◆ m_outerThreeHitVariables

ThreeHitVariables m_outerThreeHitVariables
private

ThreeHitVariables getter for the outer three hits.

Definition at line 115 of file FourHitVariables.h.


The documentation for this class was generated from the following file: