Belle II Software development
TOPGeoHoneycombPanel.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11#include <top/dbobjects/TOPGeoBase.h>
12#include <string>
13#include <vector>
14#include <utility>
15
16namespace Belle2 {
26 public:
27
32 {}
33
49 double length,
50 double minThickness,
51 double maxThickness,
52 double radius,
53 double edgeWidth,
54 double y,
55 int N,
56 const std::string& material,
57 const std::string& edgeMaterial,
58 const std::string& name = "TOPHoneycombPanel"): TOPGeoBase(name),
59 m_width(width), m_length(length), m_minThickness(minThickness),
60 m_maxThickness(maxThickness), m_radius(radius), m_edgeWidth(edgeWidth),
61 m_y(y), m_N(N), m_material(material), m_edgeMaterial(edgeMaterial)
62 {}
63
68 double getWidth() const {return m_width / s_unit;}
69
74 double getLength() const {return m_length / s_unit;}
75
80 double getMinThickness() const {return m_minThickness / s_unit;}
81
86 double getMaxThickness() const {return m_maxThickness / s_unit;}
87
92 double getRadius() const {return m_radius / s_unit;}
93
98 double getEdgeWidth() const {return m_edgeWidth / s_unit;}
99
104 double getY() const {return m_y / s_unit;}
105
110 const std::string& getMaterial() const {return m_material;}
111
116 const std::string& getEdgeMaterial() const {return m_edgeMaterial;}
117
118
125 void appendContour(std::vector<std::pair<double, double> >& contour,
126 double y0,
127 bool fromLeftToRight) const;
128
133 bool isConsistent() const override;
134
139 virtual void print(const std::string& title = "QBB honeycomb panel geometry parameters") const override;
140
141 private:
142
143 float m_width = 0;
144 float m_length = 0;
145 float m_minThickness = 0;
146 float m_maxThickness = 0;
147 float m_radius = 0;
148 float m_edgeWidth = 0;
149 float m_y = 0;
150 int m_N = 0;
151 std::string m_material;
152 std::string m_edgeMaterial;
156 };
157
158
160} // end namespace Belle2
161
Base class for geometry parameters.
Definition: TOPGeoBase.h:25
Geometry parameters of honeycomb panel.
double getWidth() const
Returns panel width.
int m_N
number of flat surfaces to approximate curved surface
double getMaxThickness() const
Returns panel maximal thickness.
TOPGeoHoneycombPanel(double width, double length, double minThickness, double maxThickness, double radius, double edgeWidth, double y, int N, const std::string &material, const std::string &edgeMaterial, const std::string &name="TOPHoneycombPanel")
Full constructor.
std::string m_material
material name
std::string m_edgeMaterial
material name of reinforced edge
const std::string & getEdgeMaterial() const
Returns material name of reinforced edge.
float m_radius
radius of curved surface
double getMinThickness() const
Returns panel minimal thickness.
float m_minThickness
minimal thickness
ClassDefOverride(TOPGeoHoneycombPanel, 1)
ClassDef.
TOPGeoHoneycombPanel()
Default constructor.
double getY() const
Returns y position of the flat surface in local (bar) frame.
const std::string & getMaterial() const
Returns material name.
double getRadius() const
Returns radius of curved surface.
float m_y
y position of the flat surface in local (bar) frame
float m_maxThickness
maximal thickness
float m_edgeWidth
width of the reinforced edge
double getEdgeWidth() const
Returns width of the reinforced edge.
double getLength() const
Returns panel length.
bool isConsistent() const override
Check for consistency of data members.
static double s_unit
conversion unit for length
Definition: TOPGeoBase.h:86
void appendContour(std::vector< std::pair< double, double > > &contour, double y0, bool fromLeftToRight) const
Appends curved surface to contour.
virtual void print(const std::string &title="QBB honeycomb panel geometry parameters") const override
Print the content of the class.
Abstract base class for different kinds of events.