1#ifndef included_AMP_Geometry_Shell
2#define included_AMP_Geometry_Shell
4#include "AMP/geometry/LogicalGeometry.h"
25 explicit Shell( std::shared_ptr<const AMP::Database> db );
32 explicit Shell(
double r_min,
double r_max );
38 std::string
getName() const override final {
return "Shell"; }
39 bool isConvex() const override final {
return true; }
43 int NSurface() const override final {
return 2; }
50 double volume() const override final;
51 void displace( const
double *x ) override final;
55 bool operator==( const
Geometry &rhs ) const override final;
Simple class to store the array dimensions.
A class used to abstract away geometry information from an application or mesh.
A class used to abstract away logical geometry based operations.
A class used to abstract away geometry information from an application or mesh.
std::array< double, 3 > d_offset
std::unique_ptr< AMP::Geometry::Geometry > clone() const override final
Clone the object.
Point logical(const Point &x) const override final
Return the logical position.
int surface(const Point &x) const override final
Get the surface id.
std::pair< Point, Point > box() const override final
Return the bounding box.
Shell(int64_t)
Construct from restart.
Shell(double r_min, double r_max)
Construct a Shell geometry.
ArraySize getLogicalGridSize(const ArraySize &x) const override final
Return the logical grid size.
int NSurface() const override final
Get the number of surfaces.
double volume() const override final
Return the volume.
double distance(const Point &pos, const Point &dir) const override final
Calculate the distance to the object given a ray.
std::string getName() const override final
Get the name of the geometry.
Point centroid() const override final
Return the centroid.
Point surfaceNorm(const Point &x) const override final
Return the outward normal to a surface.
Point physical(const Point &x) const override final
Return the physical position.
bool inside(const Point &pos) const override final
Is the point in the geometry.
void writeRestart(int64_t) const override
Write restart data to file.
Shell(std::shared_ptr< const AMP::Database > db)
Construct a Shell geometry.
bool isConvex() const override final
Is the object convex.
Point nearest(const Point &pos) const override final
Calculate the nearest point on the surface.
void displace(const double *x) override final
Displace the entire geometry.