33 const std::vector<Trajectory>& trajVec) {
34 if (!trajVec.empty()) {
37 std::vector<std::pair<std::pair<DetId, LocalPoint>,
float> > hitangleassociation;
38 return hitangleassociation;
43 std::vector<std::pair<std::pair<DetId, LocalPoint>,
float> > hitangleassociation;
44 std::vector<TrajectoryMeasurement> TMeas = traj.
measurements();
45 std::vector<TrajectoryMeasurement>::iterator itm;
46 for (itm = TMeas.begin(); itm != TMeas.end(); itm++) {
48 auto thit = itm->recHit();
60 if (monotkdir.
z() != 0) {
75 if (stereotkdir.
z() != 0) {
84 hitangleassociation.push_back(
91 if (trackdirection.
z() != 0) {
95 ((((((
hit->geographicalId()) >> 25) & 0x7f) == 0xd) || ((((
hit->geographicalId()) >> 25) & 0x7f) == 0xe)) &&
96 ((((
hit->geographicalId()) >> 5) & 0x7) > 4))
100 hitangleassociation.push_back(make_pair(make_pair(
hit->geographicalId(),
hit->localPosition()),
angle));
104 return hitangleassociation;
108 double v_xy =
sqrt(
v.x() *
v.x() +
v.y() *
v.y());
110 double Lmax = fabs(pitch /
v.x() * v_xy);
112 LogDebug(
"SiStripFineDelayTLA ") <<
L <<
" vs " << Lmax <<
" Signal contained in strip. Correction is " 114 return v.z() /
v.mag();
116 LogDebug(
"SiStripFineDelayTLA ") <<
L <<
" vs " << Lmax <<
" Signal not contained in strip. Correction is " 117 <<
thickness / pitch *
v.x() / v_xy *
v.z() /
v.mag() <<
" instead of " 119 return thickness / pitch *
v.x() / v_xy *
v.z() /
v.mag();
SiStripRecHit2D stereoHit() const
LocalPoint localPosition() const
LocalPoint toLocal(const GlobalPoint &gp) const
Conversion to the R.F. of the GeomDet.
virtual const Topology & topology() const
void init(const edm::Event &e, const edm::EventSetup &c)
double computeAngleCorr(const LocalVector &v, double pitch, double thickness)
DataContainer const & measurements() const
std::vector< std::pair< std::pair< DetId, LocalPoint >, float > > findtrackangle(const std::vector< Trajectory > &traj)
LocalVector localDirection() const
bool getData(T &iHolder) const
edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > tkGeomToken_
const TrackerGeomDet * idToDet(DetId) const override
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
const GeomDetUnit * monoDet() const
DetId geographicalId() const
virtual ~SiStripFineDelayTLA()
const GeomDetUnit * stereoDet() const
LocalPoint localPosition() const override
SiStripRecHit2D monoHit() const
const TrackerGeometry * tracker
SiStripFineDelayTLA(const edm::ParameterSet &conf, edm::ConsumesCollector iC)
T angle(T x1, T y1, T z1, T x2, T y2, T z2)