CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Orb.h
Go to the documentation of this file.
1 #ifndef DDI_Orb_h
2 #define DDI_Orb_h
3 
4 #include <iosfwd>
5 #include "Solid.h"
7 
8 namespace DDI {
9 
10  class Orb : public Solid
11  {
12  public:
13  Orb(double rMax)
14  : Solid(ddorb)
15  {
16  p_.push_back(rMax);
17  }
18  ~Orb() { }
19 
20  double volume() const { return (4.*Geom::pi()*p_[0]*p_[0]*p_[0])/3.; }
21  void stream(std::ostream & os) const;
22  };
23 
24 }
25 #endif // DDI_Orb_h
double volume() const
Definition: Orb.h:20
void stream(std::ostream &os) const
Definition: Orb.cc:5
~Orb()
Definition: Orb.h:18
Definition: Orb.h:10
Orb(double rMax)
Definition: Orb.h:13
std::vector< double > p_
Definition: Solid.h:32
constexpr double pi()
Definition: Pi.h:31