CMS 3D CMS Logo

List of all members | Public Member Functions
DDI::CutTubs Class Reference

#include <CutTubs.h>

Inheritance diagram for DDI::CutTubs:
DDI::Solid

Public Member Functions

 CutTubs (double zHalf, double rIn, double rOut, double startPhi, double deltaPhi, double lx, double ly, double lz, double tx, double ty, double tz)
 
void stream (std::ostream &os) const override
 
double volume () const override
 
- Public Member Functions inherited from DDI::Solid
const std::vector< double > & parameters () const
 
void setParameters (std::vector< double > const &p)
 
DDSolidShape shape () const
 
 Solid ()
 
 Solid (DDSolidShape shape)
 
virtual ~Solid ()
 

Additional Inherited Members

- Protected Attributes inherited from DDI::Solid
std::vector< double > p_
 
DDSolidShape shape_
 

Detailed Description

Definition at line 9 of file CutTubs.h.

Constructor & Destructor Documentation

DDI::CutTubs::CutTubs ( double  zHalf,
double  rIn,
double  rOut,
double  startPhi,
double  deltaPhi,
double  lx,
double  ly,
double  lz,
double  tx,
double  ty,
double  tz 
)

Definition at line 13 of file CutTubs.cc.

References ddcuttubs, and DDI::Solid::p_.

20 {
21  p_.emplace_back(zhalf);
22  p_.emplace_back(rIn);
23  p_.emplace_back(rOut);
24  p_.emplace_back(startPhi);
25  p_.emplace_back(deltaPhi);
26  p_.emplace_back(lx);
27  p_.emplace_back(ly);
28  p_.emplace_back(lz);
29  p_.emplace_back(tx);
30  p_.emplace_back(ty);
31  p_.emplace_back(tz);
32 }
Solid()
Definition: Solid.h:14
std::vector< double > p_
Definition: Solid.h:32

Member Function Documentation

void DDI::CutTubs::stream ( std::ostream &  os) const
overridevirtual

Reimplemented from DDI::Solid.

Definition at line 34 of file CutTubs.cc.

References geant_units::operators::convertMmToCm(), geant_units::operators::convertRadToDeg(), and DDI::Solid::p_.

Referenced by volume().

35 {
36  os << " zhalf=" << convertMmToCm( p_[0] )
37  << " rIn=" << convertMmToCm( p_[1] )
38  << " rOut=" << convertMmToCm( p_[2] )
39  << " startPhi=" << convertRadToDeg( p_[3] )
40  << " deltaPhi=" << convertRadToDeg( p_[4] )
41  << " Outside Normal at -z (" << p_[5] << "," << p_[6] << "," << p_[7] << ")"
42  << " Outside Normal at +z (" << p_[8] << "," << p_[9] << "," << p_[10] << ")";
43 }
constexpr NumType convertRadToDeg(NumType radians)
Definition: GeantUnits.h:98
std::vector< double > p_
Definition: Solid.h:32
constexpr NumType convertMmToCm(NumType millimeters)
Definition: GeantUnits.h:110
double DDI::CutTubs::volume ( void  ) const
inlineoverridevirtual

Reimplemented from DDI::Solid.

Definition at line 19 of file CutTubs.h.

References stream().

19 { return -1; }