CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Private Attributes
GlobalDetRangeZPhi Class Reference

#include <GlobalDetRangeZPhi.h>

Public Types

typedef std::pair< float, float > Range
 

Public Member Functions

 GlobalDetRangeZPhi (const Plane &det)
 
Range phiRange () const
 
Range zRange () const
 

Private Attributes

Range thePhiRange
 
Range theZRange
 

Detailed Description

Implementation class for PhiZMeasurementEstimator etc.

Definition at line 11 of file GlobalDetRangeZPhi.h.

Member Typedef Documentation

typedef std::pair<float,float> GlobalDetRangeZPhi::Range

Definition at line 14 of file GlobalDetRangeZPhi.h.

Constructor & Destructor Documentation

GlobalDetRangeZPhi::GlobalDetRangeZPhi ( const Plane det)

Definition at line 11 of file GlobalDetRangeZPhi.cc.

References i, phi, phimax, phimin, detailsBasic3DVector::z, SiStripMonitorClusterAlca_cfi::zmax, and SiStripMonitorClusterAlca_cfi::zmin.

11  {
12 
13  float dx = plane.bounds().width()/2.;
14  float dy = plane.bounds().length()/2.;
15 
16  vector<Surface::GlobalPoint> corners(4);
17  corners[0] = plane.toGlobal( LocalPoint( -dx, -dy, 0));
18  corners[1] = plane.toGlobal( LocalPoint( -dx, dy, 0));
19  corners[2] = plane.toGlobal( LocalPoint( dx, -dy, 0));
20  corners[3] = plane.toGlobal( LocalPoint( dx, dy, 0));
21 
22  float phimin = corners[0].phi(); float phimax = phimin;
23  float zmin = corners[0].z(); float zmax = zmin;
24  for ( int i=1; i<4; i++) {
25  float phi = corners[i].phi();
26  if ( PhiLess()( phi, phimin)) phimin = phi;
27  if ( PhiLess()( phimax, phi)) phimax = phi;
28 
29  float z = corners[i].z();
30  if ( z < zmin) zmin = z;
31  if ( z > zmax) zmax = z;
32  }
33 
34  theZRange.first = zmin;
35  theZRange.second = zmax;
36  thePhiRange.first = phimin;
37  thePhiRange.second = phimax;
38 
39 }
int i
Definition: DBlmapReader.cc:9
float float float z
Local3DPoint LocalPoint
Definition: LocalPoint.h:11
Definition: DDAxes.h:10

Member Function Documentation

Range GlobalDetRangeZPhi::phiRange ( ) const
inline

Definition at line 19 of file GlobalDetRangeZPhi.h.

References thePhiRange.

Referenced by OuterDetCompatibility::operator()().

19 { return thePhiRange;}
Range GlobalDetRangeZPhi::zRange ( ) const
inline

Definition at line 18 of file GlobalDetRangeZPhi.h.

References theZRange.

Referenced by OuterDetCompatibility::operator()().

18 { return theZRange;}

Member Data Documentation

Range GlobalDetRangeZPhi::thePhiRange
private

Definition at line 23 of file GlobalDetRangeZPhi.h.

Referenced by phiRange().

Range GlobalDetRangeZPhi::theZRange
private

Definition at line 22 of file GlobalDetRangeZPhi.h.

Referenced by zRange().