CMS 3D CMS Logo

TrapezoidalPlaneBounds.h
Go to the documentation of this file.
1 #ifndef Geom_TrapezoidalPlaneBounds_H
2 #define Geom_TrapezoidalPlaneBounds_H
3 
4 
7 #include <array>
8 
16 class TrapezoidalPlaneBounds /* final */ : public Bounds {
17 public:
18 
26  TrapezoidalPlaneBounds( float be, float te, float a, float t);
27 
28 
30  virtual float length() const { return 2 * hapothem;}
31 
33  virtual float width() const { return 2 * std::max( hbotedge, htopedge);}
34 
36  virtual float thickness() const { return 2 * hthickness;}
37 
40  virtual float widthAtHalfLength() const {return hbotedge+htopedge;}
41 
42  virtual int yAxisOrientation() const;
43 
44  using Bounds::inside;
45 
46  virtual bool inside( const Local2DPoint& p) const;
47 
48  virtual bool inside( const Local3DPoint& p) const;
49 
50  virtual bool inside( const Local3DPoint& p, const LocalError& err, float scale) const;
51 
52  virtual bool inside( const Local2DPoint& p, const LocalError& err, float scale) const;
53 
58  virtual const std::array<const float, 4> parameters() const;
59 
60  virtual Bounds* clone() const;
61 
62 private:
63  // persistent part
64  float hbotedge;
65  float htopedge;
66  float hapothem;
67  float hthickness;
68 
69  // transient part
70  float offset;
71  float tan_a;
72 };
73 
74 #endif // Geom_TrapezoidalPlaneBounds_H
virtual Bounds * clone() const
virtual const std::array< const float, 4 > parameters() const
TrapezoidalPlaneBounds(float be, float te, float a, float t)
virtual float thickness() const
virtual bool inside(const Local2DPoint &p) const
virtual bool inside(const Local3DPoint &) const =0
Determine if the point is inside the bounds.
virtual float widthAtHalfLength() const
double a
Definition: hdecay.h:121
Definition: Bounds.h:22
virtual float length() const
virtual int yAxisOrientation() const
virtual float width() const