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  float length() const override { return 2 * hapothem;}
31 
33  float width() const override { return 2 * std::max( hbotedge, htopedge);}
34 
36  float thickness() const override { return 2 * hthickness;}
37 
40  float widthAtHalfLength() const override {return hbotedge+htopedge;}
41 
42  virtual int yAxisOrientation() const;
43 
44  using Bounds::inside;
45 
46  bool inside( const Local2DPoint& p) const override;
47 
48  bool inside( const Local3DPoint& p) const override;
49 
50  bool inside( const Local3DPoint& p, const LocalError& err, float scale) const override;
51 
52  bool inside( const Local2DPoint& p, const LocalError& err, float scale) const override;
53 
58  virtual const std::array<const float, 4> parameters() const;
59 
60  Bounds* clone() const override;
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 const std::array< const float, 4 > parameters() const
float width() const override
float length() const override
TrapezoidalPlaneBounds(float be, float te, float a, float t)
float widthAtHalfLength() const override
Bounds * clone() const override
virtual bool inside(const Local3DPoint &) const =0
Determine if the point is inside the bounds.
float thickness() const override
bool inside(const Local2DPoint &p) const override
double a
Definition: hdecay.h:121
Definition: Bounds.h:22
virtual int yAxisOrientation() const