CMS 3D CMS Logo

Functions | Variables

align::tpb Namespace Reference

Functions

unsigned int halfBarrelNumber (align::ID)
 Half barrel number is 1 at left side (-x) and 2 at right side (+x).
unsigned int ladderNumber (align::ID)
unsigned int layerNumber (align::ID)
 Layer number increases with rho from 1 to 3.
unsigned int moduleNumber (align::ID)
 Module number increases with z from 1 to 8.

Variables

const unsigned int lpqc [] = {5, 8, 11}
 Number of ladders for each quarter cylinder.

Function Documentation

unsigned int align::tpb::halfBarrelNumber ( align::ID  id) [inline]

Half barrel number is 1 at left side (-x) and 2 at right side (+x).

Definition at line 68 of file TPBNameSpace.h.

References trackerHits::c, prof2calltree::l, PXBDetId::ladder(), PXBDetId::layer(), and lpqc.

Referenced by TrackerCounters::TrackerCounters().

{
  PXBDetId detId(id);

  unsigned int l = detId.ladder(); // increases with phi
  unsigned int c = detId.layer() - 1;

  return l > lpqc[c] && l <= 3 * lpqc[c] ? 1 : 2;
}
unsigned int align::tpb::ladderNumber ( align::ID  id) [inline]

Ladder number increases from 1 at the top to 2 * lpqc at the bottom of each half cylinder.

Definition at line 45 of file TPBNameSpace.h.

References trackerHits::c, prof2calltree::l, PXBDetId::ladder(), PXBDetId::layer(), and lpqc.

Referenced by TrackerCounters::TrackerCounters().

{
  PXBDetId detId(id);

  unsigned int l = detId.ladder(); // increases with phi
  unsigned int c = detId.layer() - 1;

// Ladder in 1st quadrant: number = lpqc + 1 - l     (1 to lpqc)
// Ladder in 2nd quadrant: number = l - lpqc         (1 to lpqc)
// Ladder in 3rd quadrant: number = l - lpqc         (lpqc + 1 to 2 * lpqc)
// Ladder in 4th quadrant: number = 5 * lpqc + 1 - l (lpqc + 1 to 2 * lpqc)

  return l > 3 * lpqc[c] ? // ladder in 4th quadrant
    5 * lpqc[c] + 1 - l :
    (l > lpqc[c] ? // ladder not in 1st quadrant
     l - lpqc[c] : lpqc[c] + 1 - l);
}
unsigned int align::tpb::layerNumber ( align::ID  id) [inline]

Layer number increases with rho from 1 to 3.

Definition at line 63 of file TPBNameSpace.h.

References PXBDetId::layer().

Referenced by TrackerCounters::TrackerCounters().

{
  return PXBDetId(id).layer();
}
unsigned int align::tpb::moduleNumber ( align::ID  id) [inline]

Module number increases with z from 1 to 8.

Definition at line 40 of file TPBNameSpace.h.

References PXBDetId::module().

Referenced by TrackerCounters::TrackerCounters().

{
  return PXBDetId(id).module();
}

Variable Documentation

const unsigned int align::tpb::lpqc[] = {5, 8, 11}

Number of ladders for each quarter cylinder.

Definition at line 23 of file TPBNameSpace.h.

Referenced by halfBarrelNumber(), and ladderNumber().