chombo-discharge
CD_CylinderSdf.H
Go to the documentation of this file.
1 /* chombo-discharge
2  * Copyright © 2021 SINTEF Energy Research.
3  * Please refer to Copyright.txt and LICENSE in the chombo-discharge root directory.
4  */
5 
12 #ifndef CD_CylinderSdf_H
13 #define CD_CylinderSdf_H
14 
15 // Chombo includes
16 #include <BaseIF.H>
17 
18 // Our includes
19 #include <CD_NamespaceHeader.H>
20 
24 class CylinderSdf : public BaseIF
25 {
26 public:
34  CylinderSdf(const RealVect& a_center1, const RealVect& a_center2, const Real& a_radius, const bool& a_fluidInside);
35 
40  CylinderSdf(const CylinderSdf& a_inputIF);
41 
46  virtual Real
47  value(const RealVect& a_point) const;
48 
52  virtual BaseIF*
53  newImplicitFunction() const;
54 
55 protected:
59  RealVect m_endPoint1;
60 
64  RealVect m_endPoint2;
65 
69  RealVect m_top;
70 
74  RealVect m_axis;
75 
79  RealVect m_center;
80 
84  Real m_length;
85 
89  Real m_radius;
90 
95 };
96 
97 #include <CD_NamespaceFooter.H>
98 
99 #endif
Declaration of a cylinder IF class.
Definition: CD_CylinderSdf.H:25
RealVect m_center
Center.
Definition: CD_CylinderSdf.H:79
virtual BaseIF * newImplicitFunction() const
IF factory method.
Definition: CD_CylinderSdf.cpp:87
CylinderSdf(const RealVect &a_center1, const RealVect &a_center2, const Real &a_radius, const bool &a_fluidInside)
Constructor.
Definition: CD_CylinderSdf.cpp:19
RealVect m_axis
Top.
Definition: CD_CylinderSdf.H:74
Real m_radius
Cylinder radius.
Definition: CD_CylinderSdf.H:89
RealVect m_top
Top.
Definition: CD_CylinderSdf.H:69
RealVect m_endPoint1
One end poitn.
Definition: CD_CylinderSdf.H:59
virtual Real value(const RealVect &a_point) const
Test whether inside or not.
Definition: CD_CylinderSdf.cpp:47
Real m_length
Cylinder length.
Definition: CD_CylinderSdf.H:84
bool m_fluidInside
Inside or outside domain.
Definition: CD_CylinderSdf.H:94
RealVect m_endPoint2
The other end point.
Definition: CD_CylinderSdf.H:64