CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Chi2Strip1DEstimator.cc
Go to the documentation of this file.
6 using namespace std;
7 
8 pair<bool,double>
10  const TrackingRecHit& hit) const {
11 
12  if(//hit.isMatched() ||
13  hit.detUnit()->type().isTrackerPixel()
14  ) return HitReturnType(false,0.);
15 
16 
17  const StripTopology* topology =
18  dynamic_cast<const StripTopology*>(&(hit.detUnit()->topology()));
19 
20  double m = topology->measurementPosition(hit.localPosition()).x();
21 
22  double x = topology->measurementPosition(state.localPosition()).x();
23 
24  double V =
25  topology->measurementError(hit.localPosition(),
26  hit.localPositionError()).uu();
27  double C =
28  topology->measurementError(state.localPosition(),
29  state.localError().positionError()).uu();
30  double r = m - x;
31  double R = V + C;
32 
33  double est = r*r/R;
34 
35  return returnIt(est);
36 }
37 
virtual const GeomDetType & type() const
Definition: GeomDet.cc:85
CaloTopology const * topology(0)
virtual const Topology & topology() const
Definition: GeomDet.cc:81
virtual std::pair< bool, double > estimate(const TrajectoryStateOnSurface &, const TrackingRecHit &) const
LocalError positionError() const
T x() const
Cartesian x coordinate.
virtual MeasurementError measurementError(const LocalPoint &, const LocalError &) const =0
virtual MeasurementPoint measurementPosition(const LocalPoint &) const =0
const LocalTrajectoryError & localError() const
bool isTrackerPixel() const
Definition: GeomDetType.cc:29
std::pair< bool, double > HitReturnType
virtual LocalError localPositionError() const =0
virtual const GeomDetUnit * detUnit() const
virtual LocalPoint localPosition() const =0