87 std::unique_ptr<reco::Track> ret;
90 if (nhits <2)
return ret;
98 std::vector<GlobalPoint>
points(nhits);
110 if (circle.curvature() > 1.e-4) {
112 float valPt = 1.f/invPt;
115 charge = (chargeTmp>0) ? -1 : 1;
116 float valPhi = (charge>0) ? std::atan2(circle.center().x(),-circle.center().y()) : std::atan2(-circle.center().x(),circle.center().y());
122 initMom *= 10000./initMom.
perp();
124 theta = initMom.
theta();
132 float sin2th =
sqr(
sin(theta));
135 float zErr = vertexErr.czz();
136 float transverseErr = vertexErr.cxx();
137 C[3][3] = transverseErr;
138 C[4][4] = zErr*sin2th + transverseErr*(1-sin2th);
148 DetId outerDetId = 0;
150 for (
unsigned int iHit = 0; iHit <
hits.size(); iHit++) {
155 if (!state.
isValid())
return ret;
158 outerState = updator.
update(state, *recHit);
159 if (!outerState.
isValid())
return ret;
165 DetId innerDetId = 0;
167 for (
int iHit = 2; iHit >= 0; --iHit) {
171 if (!state.
isValid())
return ret;
174 innerState = updator.
update(state, *recHit);
175 if (!innerState.
isValid())
return ret;
181 if (!impactPointState.
isValid())
return ret;
190 impactPointState = updator.
update(impactPointState, bsrh);
192 if (!impactPointState.
isValid())
return ret;
202 ret = std::make_unique<reco::Track>(
chi2,
ndof,
pos, mom,
float originRBound() const
bounds the particle vertex in the transverse plane
void rescaleError(double factor)
const Propagator * theOPropagator
const Propagator * thePropagator
TrackCharge charge() const
GlobalPoint const & origin() const
const TrackerGeometry * theTracker
GlobalPoint toGlobal(const Local2DPoint &lp) const
Conversion to the global R.F. from the R.F. of the GeomDet.
const CurvilinearTrajectoryError & curvilinearError() const
Sin< T >::type sin(const T &t)
Geom::Theta< T > theta() const
def setup(process, global_tag, zero_tesla=False)
GlobalPoint globalPosition() const
ROOT::Math::SMatrix< double, 5, 5, ROOT::Math::MatRepSym< double, 5 > > AlgebraicSymMatrix55
const Plane & surface() const
The nominal surface of the GeomDet.
const MagneticField * theField
Geom::Theta< T > theta() const
T inversePt(T curvature, const edm::EventSetup &iSetup)
TrajectoryStateOnSurface update(const TrajectoryStateOnSurface &, const TrackingRecHit &) const override
const SurfaceType & surface() const
static PlanePointer build(Args &&...args)
Cos< T >::type cos(const T &t)
Tan< T >::type tan(const T &t)
float originZBound() const
bounds the particle vertex in the longitudinal plane
std::shared_ptr< TrackingRecHit const > RecHitPointer
virtual RecHitPointer build(const TrackingRecHit *p) const =0
build a tracking rechit from an existing rechit
const reco::BeamSpot * theBeamSpot
const TransientTrackingRecHitBuilder * theTTRHBuilder
XYZVectorD XYZVector
spatial vector with cartesian internal representation
XYZPointD XYZPoint
point in space with cartesian internal representation
float ptMin() const
minimal pt of interest
TrajectoryStateOnSurface propagate(STA const &state, SUR const &surface) const
GlobalVector globalMomentum() const
const TrackerGeomDet * idToDet(DetId) const override
const RotationType & rotation() const
DetId geographicalId() const
const PositionType & position() const
Global3DVector GlobalVector