CMS 3D CMS Logo

Public Member Functions | Private Types | Static Private Member Functions | Private Attributes

MatchedHitRZCorrectionFromBending Class Reference

#include <MatchedHitRZCorrectionFromBending.h>

List of all members.

Public Member Functions

 MatchedHitRZCorrectionFromBending ()
 MatchedHitRZCorrectionFromBending (DetId detId)
 MatchedHitRZCorrectionFromBending (const DetLayer *layer)
void operator() (const ThirdHitPredictionFromCircle &pred, double curvature, const TransientTrackingRecHit &hit, double &r, double &z) const

Private Types

typedef double(* FixupFn )(const ThirdHitPredictionFromCircle &pred, double curvature, double rOrZ, const TransientTrackingRecHit &hit)

Static Private Member Functions

static double tibMatchedHitZFixup (const ThirdHitPredictionFromCircle &pred, double curvature, double rOrZ, const TransientTrackingRecHit &hit)

Private Attributes

FixupFn rFixup
FixupFn zFixup

Detailed Description

Definition at line 10 of file MatchedHitRZCorrectionFromBending.h.


Member Typedef Documentation

typedef double(* MatchedHitRZCorrectionFromBending::FixupFn)(const ThirdHitPredictionFromCircle &pred, double curvature, double rOrZ, const TransientTrackingRecHit &hit) [private]

Definition at line 26 of file MatchedHitRZCorrectionFromBending.h.


Constructor & Destructor Documentation

MatchedHitRZCorrectionFromBending::MatchedHitRZCorrectionFromBending ( ) [inline]

Definition at line 12 of file MatchedHitRZCorrectionFromBending.h.

: rFixup(0), zFixup(0) {}
MatchedHitRZCorrectionFromBending::MatchedHitRZCorrectionFromBending ( DetId  detId)
MatchedHitRZCorrectionFromBending::MatchedHitRZCorrectionFromBending ( const DetLayer layer)

Definition at line 22 of file MatchedHitRZCorrectionFromBending.cc.

References GeometricSearchDet::basicComponents(), DetLayer::subDetector(), sistripsummary::TIB, tibMatchedHitZFixup(), and zFixup.

  : rFixup(0), zFixup(0)
{
  if (layer->subDetector() == GeomDetEnumerators::TIB) {
    const GeometricSearchDet *tibLayer = layer;
    TIBDetId tibDetId(tibLayer->basicComponents()[0]->geographicalId());
    if (tibDetId.isDoubleSide())
      zFixup = tibMatchedHitZFixup;
  }
}

Member Function Documentation

void MatchedHitRZCorrectionFromBending::operator() ( const ThirdHitPredictionFromCircle pred,
double  curvature,
const TransientTrackingRecHit hit,
double &  r,
double &  z 
) const [inline]

Definition at line 16 of file MatchedHitRZCorrectionFromBending.h.

References rFixup, and zFixup.

    {
      if (!rFixup && !zFixup) return;
      if (rFixup) r += rFixup(pred, curvature, z, hit);
      if (zFixup) z += zFixup(pred, curvature, r, hit);
    }
double MatchedHitRZCorrectionFromBending::tibMatchedHitZFixup ( const ThirdHitPredictionFromCircle pred,
double  curvature,
double  rOrZ,
const TransientTrackingRecHit hit 
) [static, private]

Definition at line 34 of file MatchedHitRZCorrectionFromBending.cc.

References ThirdHitPredictionFromCircle::angle(), TransientTrackingRecHit::det(), GeomDet::geographicalId(), and TIBDetId::layer().

Referenced by MatchedHitRZCorrectionFromBending().

{
  // the factors for [ TIB1=0, TIB2=1 ] [ inner string=0, outer string=1 ]
  static const double factors[2][2] = { { -2.4, 2.4 }, { 2.4, -2.4 } };

  TIBDetId det(hit.det()->geographicalId());
  unsigned int layer = det.layer() - 1;
  unsigned int string = !det.isInternalString();
  return factors[layer][string] * pred.angle(curvature, r);
}

Member Data Documentation

Definition at line 34 of file MatchedHitRZCorrectionFromBending.h.

Referenced by operator()().