Belle II Software development
TOPGeoPrism Class Reference

Geometry parameters of prism. More...

#include <TOPGeoPrism.h>

Inheritance diagram for TOPGeoPrism:
TOPGeoBarSegment TOPGeoBase

Classes

struct  PeelOffRegion
 Parameters of peel-off cookie region (corresponds to 2x2 PMT's) More...
 
struct  UnfoldedWindow
 Unfolded prism exit window. More...
 

Public Member Functions

 TOPGeoPrism ()
 Default constructor.
 
 TOPGeoPrism (double width, double thickness, double length, double exitThickness, double flatLength, const std::string &material, const std::string &name="TOPPrism_")
 Useful constructor.
 
void setAngle (double angle)
 Recalculates flatLength according to given prism angle.
 
void setPeelOffRegions (double size, double offset, double thickness, const std::string &material)
 Sets parameters of the peel-off cookie volumes.
 
void appendPeelOffRegion (unsigned ID, double fraction, double angle)
 Appends peel-off cookie region.
 
double getExitThickness () const
 Returns prism thickness at PMT side.
 
double getFlatLength () const
 Returns the length of a flat surface at prism bottom.
 
double getFullFlatLength () const
 Returns the length of a flat surface at prism bottom including filter.
 
double getAngle () const
 Returns prism angle.
 
double getFilterThickness () const
 Returns wavelength filter thickness (filter on -z side).
 
const std::string & getFilterMaterial () const
 Returns wavelength filter material name (filter on -z side) For backward compatibility, since now the filter is part of TOPGeoPMTArray.
 
double getGlueThickness () const override
 Returns glue thickness (no glue on -z side)
 
double getPeelOffSize () const
 Returns cookie size in x (corresponding to 2x2 PMT)
 
double getPeelOffThickness () const
 Returns peel-off thickness.
 
const std::string & getPeelOffMaterial () const
 Returns peel-off material.
 
const std::vector< PeelOffRegion > & getPeelOffRegions () const
 Returns peel-off cookie regions.
 
double getPeelOffCenter (const PeelOffRegion &region) const
 Returns peel-off offset in x of the given region.
 
std::vector< std::pair< double, double > > getPeelOffContour (const PeelOffRegion &region) const
 Returns the x-y contour of the peel-off region.
 
const std::vector< UnfoldedWindow > & getUnfoldedWindows () const
 Returns unfolded exit windows.
 
int getK0 () const
 Returns index of true window in a vector of unfolded exit windows.
 
bool isConsistent () const override
 Check for consistency of data members.
 
void print (const std::string &title="Prism geometry parameters") const override
 Print the content of the class.
 
void setSurface (const GeoOpticalSurface &surface, double sigmaAlpha)
 Sets optical surface.
 
void setVendorData (const std::string &vendor, const std::string &serialNumber)
 Sets vendor's name and serial number.
 
double getWidth () const
 Returns bar segment width.
 
double getThickness () const
 Returns bar segment thickness.
 
double getLength () const
 Returns bar segment length.
 
double getFullLength () const
 Returns bar segment length including glue.
 
const std::string & getMaterial () const
 Returns bar segment material name.
 
const std::string & getGlueMaterial () const
 Returns glue material name (glue on -z side)
 
double getBrokenGlueFraction () const
 Returns fraction of the delaminated surface.
 
double getBrokenGlueAngle () const
 Returns angle of the delaminated surface.
 
const std::string & getBrokenGlueMaterial () const
 Returns material name which represents broken glue.
 
std::vector< std::pair< double, double > > getBrokenGlueContour () const
 Returns the x-y contour of broken glue.
 
const GeoOpticalSurfacegetSurface () const
 Returns optical surface.
 
double getSurfaceReflectivity (double energy) const
 Returns surface reflectivity at given photon energy.
 
double getSigmaAlpha () const
 Returns geant4 parameter describing surface roughness.
 
const std::string & getVendor () const
 Returns vendor's name.
 
const std::string & getSerialNumber () const
 Returns serial number.
 
void setName (const std::string &name)
 Sets object name.
 
const std::string & getName () const
 Returns object name.
 
virtual void printSurface (const GeoOpticalSurface &surface) const
 Print the content of optical surface.
 
double getReflectivity (const GeoOpticalSurface &surface, double energy) const
 Returns reflectivity of optical surface at given photon energy.
 

Protected Member Functions

void constructContour (double A, double B, double fraction, double angle, std::vector< std::pair< double, double > > &contour) const
 Construct a 2D contour.
 
 ClassDefOverride (TOPGeoBarSegment, 3)
 ClassDef.
 
void printUnderlined (const std::string &title) const
 Print the content of the class.
 
 ClassDef (TOPGeoBase, 1)
 ClassDef.
 

Protected Attributes

float m_width = 0
 bar segment width
 
float m_thickness = 0
 bar segment thickness
 
float m_length = 0
 bar segment length
 
std::string m_material
 bar segment material name
 
float m_glueThickness = 0
 glue thickness
 
std::string m_glueMaterial
 glue material name
 
GeoOpticalSurface m_surface
 optical surface
 
float m_sigmaAlpha = 0
 geant4 parameter for surface roughness
 
float m_brokenFraction = 0
 fraction of broken (delaminated) glue
 
float m_brokenAngle = 0
 angle of broken (delaminated) glue
 
std::string m_brokenGlueMaterial
 broken glue material name
 
std::string m_vendor
 vendor's name
 
std::string m_serialNumber
 serial number
 
std::string m_name
 geometry object name
 

Static Protected Attributes

static double s_unit = Unit::cm
 conversion unit for length
 
static std::string s_unitName
 conversion unit name
 

Private Member Functions

void setGlue (double, const std::string &) override
 Disable setting the glue, since there is none.
 
void setGlueDelamination (double, double, const std::string &) override
 Disable setting the glue delamination, since there is no glue.
 
void unfold () const
 Unfold prism exit window.
 
void reflect (const ROOT::Math::XYVector *points, const ROOT::Math::XYVector *normals, const ROOT::Math::XYVector &orig, const ROOT::Math::XYVector &surf, const ROOT::Math::XYVector &norm, const ROOT::Math::XYVector &slanted, int k, std::vector< UnfoldedWindow > &result) const
 Do unfolding.
 
 ClassDefOverride (TOPGeoPrism, 2)
 do not write out
 

Private Attributes

float m_exitThickness = 0
 thickness at PMT side
 
float m_flatLength = 0
 length of the flat part at the bottom
 
float m_peelOffSize = 0
 size in x of peel-off volume
 
float m_peelOffOffset = 0
 offset in x of the peel-off volume ID = 1
 
float m_peelOffThickness = 0
 thickness of peel-off volume
 
std::string m_peelOffMaterial
 material name of peel-off volume
 
std::vector< PeelOffRegionm_peelOffRegions
 peel-off regions
 
std::vector< UnfoldedWindowm_unfoldedWindows
 cache for unfolded prism exit windows
 
int m_k0 = 0
 do not write out
 

Detailed Description

Geometry parameters of prism.

Definition at line 27 of file TOPGeoPrism.h.

Constructor & Destructor Documentation

◆ TOPGeoPrism() [1/2]

TOPGeoPrism ( )
inline

Default constructor.

Definition at line 68 of file TOPGeoPrism.h.

69 {}

◆ TOPGeoPrism() [2/2]

TOPGeoPrism ( double  width,
double  thickness,
double  length,
double  exitThickness,
double  flatLength,
const std::string &  material,
const std::string &  name = "TOPPrism_" 
)
inline

Useful constructor.

Parameters
widthprism width
thicknessthickness at bar side
lengthprism length
exitThicknessthickness at PMT side
flatLengthlength of the flat part at the bottom
materialprism material name
nameobject name

Definition at line 81 of file TOPGeoPrism.h.

84 :
85 TOPGeoBarSegment(width, thickness, length, material, name),
86 m_exitThickness(exitThickness), m_flatLength(flatLength)
87 {}
TOPGeoBarSegment()
Default constructor.
float m_flatLength
length of the flat part at the bottom
Definition: TOPGeoPrism.h:278
float m_exitThickness
thickness at PMT side
Definition: TOPGeoPrism.h:277

Member Function Documentation

◆ ClassDefOverride()

ClassDefOverride ( TOPGeoPrism  ,
 
)
private

do not write out

ClassDef

◆ getAngle()

double getAngle ( ) const
inline

Returns prism angle.

Returns
angle

Definition at line 144 of file TOPGeoPrism.h.

145 {
147 }
float m_thickness
bar segment thickness
float m_length
bar segment length
double atan(double a)
atan for double
Definition: beamHelpers.h:34

◆ getBrokenGlueAngle()

double getBrokenGlueAngle ( ) const
inlineinherited

Returns angle of the delaminated surface.

Returns
angle

Definition at line 149 of file TOPGeoBarSegment.h.

149{return m_brokenAngle;}
float m_brokenAngle
angle of broken (delaminated) glue

◆ getBrokenGlueFraction()

double getBrokenGlueFraction ( ) const
inlineinherited

Returns fraction of the delaminated surface.

Returns
fraction

Definition at line 143 of file TOPGeoBarSegment.h.

143{return m_brokenFraction;}
float m_brokenFraction
fraction of broken (delaminated) glue

◆ getBrokenGlueMaterial()

const std::string & getBrokenGlueMaterial ( ) const
inlineinherited

Returns material name which represents broken glue.

Returns
material name

Definition at line 155 of file TOPGeoBarSegment.h.

155{return m_brokenGlueMaterial;}
std::string m_brokenGlueMaterial
broken glue material name

◆ getExitThickness()

double getExitThickness ( ) const
inline

Returns prism thickness at PMT side.

Returns
thickness at PMT side

Definition at line 126 of file TOPGeoPrism.h.

126{return m_exitThickness / s_unit;}
static double s_unit
conversion unit for length
Definition: TOPGeoBase.h:86

◆ getFilterMaterial()

const std::string & getFilterMaterial ( ) const
inline

Returns wavelength filter material name (filter on -z side) For backward compatibility, since now the filter is part of TOPGeoPMTArray.

Returns
material name

Definition at line 161 of file TOPGeoPrism.h.

161{return m_glueMaterial;}
std::string m_glueMaterial
glue material name

◆ getFilterThickness()

double getFilterThickness ( ) const
inline

Returns wavelength filter thickness (filter on -z side).

For backward compatibility, since now the filter is part of TOPGeoPMTArray

Returns
thickness

Definition at line 154 of file TOPGeoPrism.h.

154{return m_glueThickness / s_unit;}
float m_glueThickness
glue thickness

◆ getFlatLength()

double getFlatLength ( ) const
inline

Returns the length of a flat surface at prism bottom.

Returns
bottom flat surface length

Definition at line 132 of file TOPGeoPrism.h.

132{return m_flatLength / s_unit;}

◆ getFullFlatLength()

double getFullFlatLength ( ) const
inline

Returns the length of a flat surface at prism bottom including filter.

Returns
bottom flat surface full length

Definition at line 138 of file TOPGeoPrism.h.

138{return (m_flatLength + m_glueThickness) / s_unit;}

◆ getFullLength()

double getFullLength ( ) const
inlineinherited

Returns bar segment length including glue.

Returns
full length

Definition at line 119 of file TOPGeoBarSegment.h.

119{return (m_length + m_glueThickness) / s_unit;}

◆ getGlueMaterial()

const std::string & getGlueMaterial ( ) const
inlineinherited

Returns glue material name (glue on -z side)

Returns
material name

Definition at line 137 of file TOPGeoBarSegment.h.

137{return m_glueMaterial;}

◆ getGlueThickness()

double getGlueThickness ( ) const
inlineoverridevirtual

Returns glue thickness (no glue on -z side)

Returns
thickness

Reimplemented from TOPGeoBarSegment.

Definition at line 167 of file TOPGeoPrism.h.

167{return 0;}

◆ getK0()

int getK0 ( ) const
inline

Returns index of true window in a vector of unfolded exit windows.

Returns
index

Definition at line 225 of file TOPGeoPrism.h.

226 {
227 if (m_unfoldedWindows.empty()) unfold();
228 return m_k0;
229 }
int m_k0
do not write out
Definition: TOPGeoPrism.h:289
std::vector< UnfoldedWindow > m_unfoldedWindows
cache for unfolded prism exit windows
Definition: TOPGeoPrism.h:287
void unfold() const
Unfold prism exit window.
Definition: TOPGeoPrism.cc:129

◆ getLength()

double getLength ( ) const
inlineinherited

Returns bar segment length.

Returns
length

Definition at line 113 of file TOPGeoBarSegment.h.

113{return m_length / s_unit;}

◆ getMaterial()

const std::string & getMaterial ( ) const
inlineinherited

Returns bar segment material name.

Returns
material name

Definition at line 125 of file TOPGeoBarSegment.h.

125{return m_material;}
std::string m_material
bar segment material name

◆ getName()

const std::string & getName ( ) const
inlineinherited

Returns object name.

Returns
object name

Definition at line 51 of file TOPGeoBase.h.

51{return m_name;}
std::string m_name
geometry object name
Definition: TOPGeoBase.h:89

◆ getPeelOffCenter()

double getPeelOffCenter ( const PeelOffRegion region) const
inline

Returns peel-off offset in x of the given region.

Parameters
regionpeel-off region
Returns
offset in x

Definition at line 198 of file TOPGeoPrism.h.

199 {
200 return (m_peelOffOffset - (region.ID - 1) * m_peelOffSize) / s_unit;
201 }
float m_peelOffSize
size in x of peel-off volume
Definition: TOPGeoPrism.h:280
float m_peelOffOffset
offset in x of the peel-off volume ID = 1
Definition: TOPGeoPrism.h:281

◆ getPeelOffMaterial()

const std::string & getPeelOffMaterial ( ) const
inline

Returns peel-off material.

Returns
material name

Definition at line 185 of file TOPGeoPrism.h.

185{return m_peelOffMaterial;}
std::string m_peelOffMaterial
material name of peel-off volume
Definition: TOPGeoPrism.h:283

◆ getPeelOffRegions()

const std::vector< PeelOffRegion > & getPeelOffRegions ( ) const
inline

Returns peel-off cookie regions.

Returns
vector of regions

Definition at line 191 of file TOPGeoPrism.h.

191{return m_peelOffRegions;}
std::vector< PeelOffRegion > m_peelOffRegions
peel-off regions
Definition: TOPGeoPrism.h:284

◆ getPeelOffSize()

double getPeelOffSize ( ) const
inline

Returns cookie size in x (corresponding to 2x2 PMT)

Returns
size in x

Definition at line 173 of file TOPGeoPrism.h.

173{return m_peelOffSize / s_unit;}

◆ getPeelOffThickness()

double getPeelOffThickness ( ) const
inline

Returns peel-off thickness.

Returns
thickness

Definition at line 179 of file TOPGeoPrism.h.

179{return m_peelOffThickness / s_unit;}
float m_peelOffThickness
thickness of peel-off volume
Definition: TOPGeoPrism.h:282

◆ getSerialNumber()

const std::string & getSerialNumber ( ) const
inlineinherited

Returns serial number.

Returns
serial number

Definition at line 194 of file TOPGeoBarSegment.h.

194{return m_serialNumber;}
std::string m_serialNumber
serial number

◆ getSigmaAlpha()

double getSigmaAlpha ( ) const
inlineinherited

Returns geant4 parameter describing surface roughness.

Returns
surface roughness

Definition at line 182 of file TOPGeoBarSegment.h.

182{return m_sigmaAlpha;}
float m_sigmaAlpha
geant4 parameter for surface roughness

◆ getSurface()

const GeoOpticalSurface & getSurface ( ) const
inlineinherited

Returns optical surface.

Returns
optical surface

Definition at line 166 of file TOPGeoBarSegment.h.

166{return m_surface;}
GeoOpticalSurface m_surface
optical surface

◆ getSurfaceReflectivity()

double getSurfaceReflectivity ( double  energy) const
inlineinherited

Returns surface reflectivity at given photon energy.

Parameters
energyphoton energy in [eV]
Returns
reflectivity

Definition at line 173 of file TOPGeoBarSegment.h.

174 {
176 }
double getReflectivity(const GeoOpticalSurface &surface, double energy) const
Returns reflectivity of optical surface at given photon energy.
Definition: TOPGeoBase.cc:72

◆ getThickness()

double getThickness ( ) const
inlineinherited

Returns bar segment thickness.

Returns
thickness

Definition at line 107 of file TOPGeoBarSegment.h.

107{return m_thickness / s_unit;}

◆ getUnfoldedWindows()

const std::vector< UnfoldedWindow > & getUnfoldedWindows ( ) const
inline

Returns unfolded exit windows.

Exit window position is defined where the slanted surface is cutted off.

Returns
vector of unfolded exit windows

Definition at line 215 of file TOPGeoPrism.h.

216 {
217 if (m_unfoldedWindows.empty()) unfold();
218 return m_unfoldedWindows;
219 }

◆ getVendor()

const std::string & getVendor ( ) const
inlineinherited

Returns vendor's name.

Returns
name

Definition at line 188 of file TOPGeoBarSegment.h.

188{return m_vendor;}
std::string m_vendor
vendor's name

◆ getWidth()

double getWidth ( ) const
inlineinherited

Returns bar segment width.

Returns
width

Definition at line 101 of file TOPGeoBarSegment.h.

101{return m_width / s_unit;}
float m_width
bar segment width

◆ setAngle()

void setAngle ( double  angle)
inline

Recalculates flatLength according to given prism angle.

Parameters
angleprism angle

Definition at line 93 of file TOPGeoPrism.h.

94 {
96 }

◆ setGlue()

void setGlue ( double  ,
const std::string &   
)
inlineoverrideprivatevirtual

Disable setting the glue, since there is none.

Reimplemented from TOPGeoBarSegment.

Definition at line 249 of file TOPGeoPrism.h.

249{}

◆ setGlueDelamination()

void setGlueDelamination ( double  ,
double  ,
const std::string &   
)
inlineoverrideprivatevirtual

Disable setting the glue delamination, since there is no glue.

Reimplemented from TOPGeoBarSegment.

Definition at line 254 of file TOPGeoPrism.h.

254{}

◆ setName()

void setName ( const std::string &  name)
inlineinherited

Sets object name.

Parameters
nameobject name

Definition at line 45 of file TOPGeoBase.h.

45{m_name = name;}

◆ setPeelOffRegions()

void setPeelOffRegions ( double  size,
double  offset,
double  thickness,
const std::string &  material 
)
inline

Sets parameters of the peel-off cookie volumes.

Parameters
sizevolume size in x
offsetoffset in x of the center of volume ID = 1
thicknessvolume thickness
materialmaterial name

Definition at line 105 of file TOPGeoPrism.h.

107 {
108 m_peelOffSize = size;
109 m_peelOffOffset = offset;
110 m_peelOffThickness = thickness;
111 m_peelOffMaterial = material;
112 }

◆ setSurface()

void setSurface ( const GeoOpticalSurface surface,
double  sigmaAlpha 
)
inlineinherited

Sets optical surface.

Parameters
surfaceoptical surface
sigmaAlphageant4 parameter for surface roughness

Definition at line 80 of file TOPGeoBarSegment.h.

81 {
82 m_surface = surface;
83 m_sigmaAlpha = sigmaAlpha;
84 }

◆ setVendorData()

void setVendorData ( const std::string &  vendor,
const std::string &  serialNumber 
)
inlineinherited

Sets vendor's name and serial number.

Parameters
vendorvendor's name
serialNumberserial number

Definition at line 91 of file TOPGeoBarSegment.h.

92 {
93 m_vendor = vendor;
94 m_serialNumber = serialNumber;
95 }

Member Data Documentation

◆ m_brokenAngle

float m_brokenAngle = 0
protectedinherited

angle of broken (delaminated) glue

Definition at line 231 of file TOPGeoBarSegment.h.

◆ m_brokenFraction

float m_brokenFraction = 0
protectedinherited

fraction of broken (delaminated) glue

Definition at line 230 of file TOPGeoBarSegment.h.

◆ m_brokenGlueMaterial

std::string m_brokenGlueMaterial
protectedinherited

broken glue material name

Definition at line 232 of file TOPGeoBarSegment.h.

◆ m_exitThickness

float m_exitThickness = 0
private

thickness at PMT side

Definition at line 277 of file TOPGeoPrism.h.

◆ m_flatLength

float m_flatLength = 0
private

length of the flat part at the bottom

Definition at line 278 of file TOPGeoPrism.h.

◆ m_glueMaterial

std::string m_glueMaterial
protectedinherited

glue material name

Definition at line 227 of file TOPGeoBarSegment.h.

◆ m_glueThickness

float m_glueThickness = 0
protectedinherited

glue thickness

Definition at line 226 of file TOPGeoBarSegment.h.

◆ m_k0

int m_k0 = 0
mutableprivate

do not write out

cache for the index of true window in unfolded prism exit windows

Definition at line 289 of file TOPGeoPrism.h.

◆ m_length

float m_length = 0
protectedinherited

bar segment length

Definition at line 224 of file TOPGeoBarSegment.h.

◆ m_material

std::string m_material
protectedinherited

bar segment material name

Definition at line 225 of file TOPGeoBarSegment.h.

◆ m_name

std::string m_name
protectedinherited

geometry object name

Definition at line 89 of file TOPGeoBase.h.

◆ m_peelOffMaterial

std::string m_peelOffMaterial
private

material name of peel-off volume

Definition at line 283 of file TOPGeoPrism.h.

◆ m_peelOffOffset

float m_peelOffOffset = 0
private

offset in x of the peel-off volume ID = 1

Definition at line 281 of file TOPGeoPrism.h.

◆ m_peelOffRegions

std::vector<PeelOffRegion> m_peelOffRegions
private

peel-off regions

Definition at line 284 of file TOPGeoPrism.h.

◆ m_peelOffSize

float m_peelOffSize = 0
private

size in x of peel-off volume

Definition at line 280 of file TOPGeoPrism.h.

◆ m_peelOffThickness

float m_peelOffThickness = 0
private

thickness of peel-off volume

Definition at line 282 of file TOPGeoPrism.h.

◆ m_serialNumber

std::string m_serialNumber
protectedinherited

serial number

Definition at line 234 of file TOPGeoBarSegment.h.

◆ m_sigmaAlpha

float m_sigmaAlpha = 0
protectedinherited

geant4 parameter for surface roughness

Definition at line 229 of file TOPGeoBarSegment.h.

◆ m_surface

GeoOpticalSurface m_surface
protectedinherited

optical surface

Definition at line 228 of file TOPGeoBarSegment.h.

◆ m_thickness

float m_thickness = 0
protectedinherited

bar segment thickness

Definition at line 223 of file TOPGeoBarSegment.h.

◆ m_unfoldedWindows

std::vector<UnfoldedWindow> m_unfoldedWindows
mutableprivate

cache for unfolded prism exit windows

Definition at line 287 of file TOPGeoPrism.h.

◆ m_vendor

std::string m_vendor
protectedinherited

vendor's name

Definition at line 233 of file TOPGeoBarSegment.h.

◆ m_width

float m_width = 0
protectedinherited

bar segment width

Definition at line 222 of file TOPGeoBarSegment.h.


The documentation for this class was generated from the following files: