test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DiskSectorBounds.h
Go to the documentation of this file.
1 #ifndef RecoTracker_TkDetLayers_DiskSectorBounds_h
2 #define RecoTracker_TkDetLayers_DiskSectorBounds_h
3 
4 
8 #include <algorithm>
9 #include <cmath>
10 #include <cassert>
11 
12 #pragma GCC visibility push(hidden)
13 class DiskSectorBounds final : public Bounds {
14 public:
15 
16  DiskSectorBounds( float rmin, float rmax, float zmin, float zmax, float phiExt) :
17  theRmin(rmin), theRmax(rmax), theZmin(zmin), theZmax(zmax), thePhiExtH(0.5f*phiExt) {
18  assert(thePhiExtH>0);
21  theOffset = theRmin + 0.5f*(theRmax-theRmin);
22  }
23 
24  virtual float length() const { return theRmax-theRmin*std::cos(thePhiExtH);}
25  virtual float width() const { return 2.f*theRmax*std::sin(thePhiExtH);}
26  virtual float thickness() const { return theZmax-theZmin;}
27 
28 
29 
30  virtual bool inside( const Local3DPoint& p) const;
31 
32  virtual bool inside( const Local3DPoint& p, const LocalError& err, float scale) const;
33 
34  virtual Bounds* clone() const {
35  return new DiskSectorBounds(*this);
36  }
37 
38  float innerRadius() const {return theRmin;}
39  float outerRadius() const {return theRmax;}
40  float phiHalfExtension() const {return thePhiExtH;}
41 
42  private:
43  float theRmin;
44  float theRmax;
45  float theZmin;
46  float theZmax;
47  float thePhiExtH;
48  float theOffset;
49  };
50 
51 #pragma GCC visibility pop
52 #endif
53 
virtual float thickness() const
virtual bool inside(const Local3DPoint &p) const
Determine if the point is inside the bounds.
Sin< T >::type sin(const T &t)
Definition: Sin.h:22
assert(m_qm.get())
float innerRadius() const
void swap(edm::DataFrameContainer &lhs, edm::DataFrameContainer &rhs)
Cos< T >::type cos(const T &t)
Definition: Cos.h:22
virtual Bounds * clone() const
double f[11][100]
float phiHalfExtension() const
virtual float width() const
Definition: Bounds.h:22
virtual float length() const
float outerRadius() const
DiskSectorBounds(float rmin, float rmax, float zmin, float zmax, float phiExt)