Class ShapedBoundary2D#

Inheritance Relationships#

Base Type#

Class Documentation#

class ShapedBoundary2D : public BaseBoundary2D#

The ShapedBoundary2D class defines a boundary geometry for three cases: circle, ellipse, and rectangular shape and calculates the potential created by charges on the boundary surface.

Public Functions

ShapedBoundary2D(int nPoints, int nModes, string shape, double xDim, double yDim)#

Constructor

virtual ~ShapedBoundary2D()#

Destructor

int impactPoint(double x, double y, double z, double px, double py, double pz, double *r_v, double *n_v)#

The method calculates an impact position on the surface and a normal vector at the point of entry. The normal vector is directed into the inner volume. The first vector is a position vector and the second one is a normal to the surface vector. If the particle did not cross the surface we do not know what to do and we will kill it (return TO_BE_KILLED int value).

virtual int isInside(double x, double y)#

Returns IS_INSIDE or IS_OUTSIDE depending on the particle’s position

Protected Attributes

double r_circle_#
double a_ellipse_#
double b_ellipse_#
double a_rect_#
double b_rect_#