Class EdgeBoundaryStrategy

Class EdgeBoundaryStrategy#

Inheritance Relationships#

Base Type#

Class Documentation#

class EdgeBoundaryStrategy : public BoundaryStrategy

Implements methods for edge boundary conditions.

The simulation area is assumed to have edge boundary conditions at x = side_x, y = side_y.

Public Functions

inline EdgeBoundaryStrategy(double side_x, double side_y)
inline ~EdgeBoundaryStrategy()
virtual double distance(const Point &p1, const Point &p2) override

Calculates the distance between two points.

Parameters:
  • p1[in] first point

  • p2[in] second point

Returns:

The distance between the points.

virtual Point relative_pos(const Point &p1, const Point &p2) override

Returns the relative position of the second point to the first.

Parameters:
  • loc1[in] point 1

  • loc2[in] point 2

Returns:

The relative coordinates of the second point.