20 theTTrig(config.getParameter<double>(
"tTrig")),
22 theVPropWire(config.getParameter<double>(
"vPropWire")),
31 theTOFCorrType(config.getParameter<
int>(
"tofCorrType")),
32 debug(config.getUntrackedParameter<
bool>(
"debug")),
33 theBXspace(config.getUntrackedParameter<double>(
"bxSpace", 25.))
43 double& tofCorr)
const {
49 float wireCoord = layer->
toLocal(globPos).
y();
50 float propgL = halfL - wireCoord;
55 float flightToHit = globPos.
mag();
56 static const float cSpeed = 29.9792458;
63 tofCorr = -flightToHit / cSpeed;
70 tofCorr = (flightToChamber - flightToHit) / cSpeed;
77 tofCorr = (flightToWire - flightToHit) / cSpeed;
82 <<
" Invalid parameter: tofCorrType = " <<
theTOFCorrType << std::endl;
88 cout <<
"[DTTTrigSyncTOFCorr] Offset (ns): " << tTrig + wirePropCorr - tofCorr << endl
89 <<
" various contributions are: " << endl
90 <<
" tTrig (ns): " << tTrig << endl
91 <<
" Propagation along wire delay (ns): " << wirePropCorr << endl
92 <<
" TOF correction (ns): " << tofCorr << endl
96 return tTrig + wirePropCorr - tofCorr;
102 static const float f2i_convCorr = (25. / 64.);
float wirePosition(int wireNumber) const
Returns the x position in the layer of a given wire number.
Point3DBase< Scalar, LocalTag > LocalPoint
T mag() const
The vector magnitude. Equivalent to sqrt(vec.mag2())
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
double emulatorOffset(const DTWireId &wireId, double &tTrig, double &t0cell) const override
const double theVPropWire
LocalPoint toLocal(const GlobalPoint &gp) const
Conversion to the R.F. of the GeomDet.
const Plane & surface() const
The nominal surface of the GeomDet.
DTTTrigSyncTOFCorr(const edm::ParameterSet &config)
Constructor.
const DTTopology & specificTopology() const
int wire() const
Return the wire number.
~DTTTrigSyncTOFCorr() override
Destructor.
const DTChamber * chamber() const
double offset(const DTLayer *layer, const DTWireId &wireId, const GlobalPoint &globPos, double &tTrig, double &wirePropCorr, double &tofCorr) const override
const PositionType & position() const