17 #ifndef GZ_MATH_CAPSULE_HH_
18 #define GZ_MATH_CAPSULE_HH_
30 inline namespace GZ_MATH_VERSION_NAMESPACE {
40 template<
typename Precision>
50 public:
Capsule(
const Precision _length,
const Precision _radius);
56 public:
Capsule(
const Precision _length,
const Precision _radius,
61 public: Precision Radius()
const;
65 public:
void SetRadius(
const Precision _radius);
69 public: Precision Length()
const;
73 public:
void SetLength(
const Precision _length);
81 public:
void SetMat(
const Material &_mat);
89 public: std::optional< MassMatrix3<Precision> > MassMatrix()
const;
93 public:
bool operator==(
const Capsule &_capsule)
const;
97 public: Precision Volume()
const;
107 public: Precision DensityFromMass(
const Precision _mass)
const;
121 public:
bool SetDensityFromMass(
const Precision _mass);
124 private: Precision radius = 0.0;
127 private: Precision length = 0.0;
146 #include "gz/math/detail/Capsule.hh"
147 #endif // GZ_MATH_CAPSULE_HH_