Belle II Software  release-05-02-19
DriftLengthEstimator Struct Reference

Helper construct implementing the (re)estimation of the drift length for various hit objects. More...

#include <DriftLengthEstimator.h>

Public Member Functions

void exposeParameters (ModuleParamList *moduleParamList, const std::string &prefix)
 Add the parameters of the estimator to the module.
 
double updateDriftLength (CDCRecoHit2D &recoHit2D)
 Update the drift length of the reconstructed hit in place.
 
double updateDriftLength (CDCRecoHit3D &recoHit3D, double tanLambda)
 Update the drift length of the reconstructed hit in place.
 
void updateDriftLength (CDCFacet &facet)
 Reestimate the drift length of all three contained drift circles. More...
 
void updateDriftLength (CDCSegment2D &segment)
 Update the drift length of the contained reconstructed hit in place.
 
void updateDriftLength (CDCSegment3D &segment, double tanLambda)
 Update the drift length of the contained reconstructed hit in place.
 
void updateDriftLength (CDCTrack &track, double tanLambda)
 Update the drift length of the contained reconstructed hit in place.
 

Public Attributes

bool m_param_useAlphaInDriftLength = true
 Parameter : Switch to serve the alpha angle to the drift length translator.
 
double m_param_tofMassScale = NAN
 Parameter : Mass to estimate the velocity in the flight time to the hit.
 

Detailed Description

Helper construct implementing the (re)estimation of the drift length for various hit objects.

Definition at line 38 of file DriftLengthEstimator.h.

Member Function Documentation

◆ updateDriftLength()

void updateDriftLength ( CDCFacet facet)

Reestimate the drift length of all three contained drift circles.

Using the additional flight direction information the accuracy of the drift length can be increased alot helping the filters following this step

Definition at line 90 of file DriftLengthEstimator.cc.

91 {
92  CDC::RealisticTDCCountTranslator tdcCountTranslator;
93  const FlightTimeEstimator& flightTimeEstimator = FlightTimeEstimator::instance();
94 
95  const UncertainParameterLine2D& line = facet.getFitLine();
96  Vector2D flightDirection = line->tangential();
97  Vector2D centralPos2D = line->closest(facet.getMiddleWire().getRefPos2D());
98  double alpha = centralPos2D.angleWith(flightDirection);
100  alpha = 0;
101  }
102 
103  auto doUpdate = [&](CDCRLWireHit & rlWireHit, Vector2D recoPos2D) {
104  const CDCWire& wire = rlWireHit.getWire();
105  const CDCHit* hit = rlWireHit.getWireHit().getHit();
106  const bool rl = rlWireHit.getRLInfo() == ERightLeft::c_Right;
107  const double beta = 1;
108  double flightTimeEstimate = flightTimeEstimator.getFlightTime2D(recoPos2D, alpha, beta);
109  double driftLength = tdcCountTranslator.getDriftLength(hit->getTDCCount(),
110  wire.getWireID(),
111  flightTimeEstimate,
112  rl,
113  wire.getRefZ(),
114  alpha);
115  rlWireHit.setRefDriftLength(driftLength);
116  };
117 
118  doUpdate(facet.getStartRLWireHit(), facet.getStartRecoPos2D());
119  doUpdate(facet.getMiddleRLWireHit(), facet.getMiddleRecoPos2D());
120  doUpdate(facet.getEndRLWireHit(), facet.getEndRecoPos2D());
121 
122  // More accurate implementation
123  // double startDriftLength = updateDriftLength(facet.getStartRecoHit2D());
124  // facet.getStartRLWireHit().setRefDriftLength(startDriftLength);
125 
126  // double middleDriftLength = updateDriftLength(facet.getMiddleRecoHit2D());
127  // facet.getMiddleRLWireHit().setRefDriftLength(middleDriftLength);
128 
129  // double endDriftLength = updateDriftLength(facet.getEndRecoHit2D());
130  // facet.getEndRLWireHit().setRefDriftLength(endDriftLength);
131 }

The documentation for this struct was generated from the following files:
Belle2::CDC::RealisticTDCCountTranslator
Translator mirroring the realistic Digitization.
Definition: RealisticTDCCountTranslator.h:36
Belle2::CDCHit
Class containing the result of the unpacker in raw data and the result of the digitizer in simulation...
Definition: CDCHit.h:51
Belle2::TrackFindingCDC::DriftLengthEstimator::m_param_useAlphaInDriftLength
bool m_param_useAlphaInDriftLength
Parameter : Switch to serve the alpha angle to the drift length translator.
Definition: DriftLengthEstimator.h:66
Belle2::CDC::RealisticTDCCountTranslator::getDriftLength
double getDriftLength(unsigned short tdcCount, const WireID &wireID=WireID(), double timeOfFlightEstimator=0, bool leftRight=false, double z=0, double alpha=0, double theta=static_cast< double >(TMath::Pi()/2.), unsigned short adcCount=0) override
Get Drift length.
Definition: RealisticTDCCountTranslator.cc:106
Belle2::TrackFindingCDC::FlightTimeEstimator::instance
static const FlightTimeEstimator & instance(std::unique_ptr< FlightTimeEstimator > replacement=nullptr)
Getter for the instance.
Definition: FlightTimeEstimator.cc:23