CMS 3D CMS Logo

DiskSectorBounds.h
Go to the documentation of this file.
1 #ifndef RecoTracker_TkDetLayers_DiskSectorBounds_h
2 #define RecoTracker_TkDetLayers_DiskSectorBounds_h
3 
7 #include <algorithm>
8 #include <cmath>
9 #include <cassert>
10 
11 #pragma GCC visibility push(hidden)
12 class DiskSectorBounds final : public Bounds {
13 public:
14  DiskSectorBounds(float rmin, float rmax, float zmin, float zmax, float phiExt)
15  : theRmin(rmin), theRmax(rmax), theZmin(zmin), theZmax(zmax), thePhiExtH(0.5f * phiExt) {
16  assert(thePhiExtH > 0);
17  if (theRmin > theRmax)
19  if (theZmin > theZmax)
21  theOffset = theRmin + 0.5f * (theRmax - theRmin);
22  }
23 
24  float length() const override { return theRmax - theRmin * std::cos(thePhiExtH); }
25  float width() const override { return 2.f * theRmax * std::sin(thePhiExtH); }
26  float thickness() const override { return theZmax - theZmin; }
27 
28  bool inside(const Local3DPoint& p) const override;
29 
30  bool inside(const Local3DPoint& p, const LocalError& err, float scale) const override;
31 
32  Bounds* clone() const override { return new DiskSectorBounds(*this); }
33 
34  float innerRadius() const { return theRmin; }
35  float outerRadius() const { return theRmax; }
36  float phiHalfExtension() const { return thePhiExtH; }
37 
38 private:
39  float theRmin;
40  float theRmax;
41  float theZmin;
42  float theZmax;
43  float thePhiExtH;
44  float theOffset;
45 };
46 
47 #pragma GCC visibility pop
48 #endif
DiskSectorBounds::outerRadius
float outerRadius() const
Definition: DiskSectorBounds.h:35
DiskSectorBounds::innerRadius
float innerRadius() const
Definition: DiskSectorBounds.h:34
DiskSectorBounds::inside
bool inside(const Local3DPoint &p) const override
Determine if the point is inside the bounds.
Definition: DiskSectorBounds.cc:5
DiskSectorBounds
Definition: DiskSectorBounds.h:12
f
double f[11][100]
Definition: MuScleFitUtils.cc:78
DiskSectorBounds::thePhiExtH
float thePhiExtH
Definition: DiskSectorBounds.h:43
DiskSectorBounds::length
float length() const override
Definition: DiskSectorBounds.h:24
AlCaHLTBitMon_ParallelJobs.p
p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
Bounds
Definition: Bounds.h:18
cms::cuda::assert
assert(be >=bs)
SiStripMonitorCluster_cfi.zmin
zmin
Definition: SiStripMonitorCluster_cfi.py:200
DiskSectorBounds::theZmin
float theZmin
Definition: DiskSectorBounds.h:41
funct::sin
Sin< T >::type sin(const T &t)
Definition: Sin.h:22
DiskSectorBounds::theOffset
float theOffset
Definition: DiskSectorBounds.h:44
funct::cos
Cos< T >::type cos(const T &t)
Definition: Cos.h:22
std::swap
void swap(edm::DataFrameContainer &lhs, edm::DataFrameContainer &rhs)
Definition: DataFrameContainer.h:209
SiStripMonitorCluster_cfi.zmax
zmax
Definition: SiStripMonitorCluster_cfi.py:201
LocalError.h
DiskSectorBounds::theRmax
float theRmax
Definition: DiskSectorBounds.h:40
Bounds.h
Point3DBase< float, LocalTag >
DiskSectorBounds::clone
Bounds * clone() const override
Definition: DiskSectorBounds.h:32
DiskSectorBounds::DiskSectorBounds
DiskSectorBounds(float rmin, float rmax, float zmin, float zmax, float phiExt)
Definition: DiskSectorBounds.h:14
Scenarios_cff.scale
scale
Definition: Scenarios_cff.py:2186
runTheMatrix.err
err
Definition: runTheMatrix.py:288
LocalError
Definition: LocalError.h:12
DiskSectorBounds::phiHalfExtension
float phiHalfExtension() const
Definition: DiskSectorBounds.h:36
DiskSectorBounds::theZmax
float theZmax
Definition: DiskSectorBounds.h:42
LocalPoint.h
DiskSectorBounds::width
float width() const override
Definition: DiskSectorBounds.h:25
DiskSectorBounds::theRmin
float theRmin
Definition: DiskSectorBounds.h:39
DiskSectorBounds::thickness
float thickness() const override
Definition: DiskSectorBounds.h:26