![]() |
An open source method of characteristics neutron transport code.
|
Represents a general Surface in 3D. More...
#include "src/Surface.h"
Public Member Functions | |
| Surface (const int id=0, const char *name="") | |
| Constructor assigns unique ID and user-defined ID for a Surface. More... | |
| virtual | ~Surface () |
| Destructor. | |
| int | getUid () const |
| Return the Surface's unique ID. More... | |
| int | getId () const |
| Return the Surface's user-defined ID. More... | |
| char * | getName () const |
| Return the user-defined name of the Surface. More... | |
| surfaceType | getSurfaceType () |
| Return the type of Surface (ie, XPLANE, ZYCLINDER, etc). More... | |
| boundaryType | getBoundaryType () |
| Returns the type of boundary conditions for this Surface (REFLECTIVE, VACUUM or BOUNDARY_NONE). More... | |
| double | getMin (int axis, int halfspace) |
| Returns the minimum coordinate in the axis direction of the space defined by halfspace and this surface. More... | |
| double | getMax (int axis, int halfspace) |
| Returns the maximum coordinate in the axis direction of the space defined by halfspace and this surface. More... | |
| virtual double | getMinX (int halfspace)=0 |
| Returns the minimum x value for one of this Surface's halfspaces. More... | |
| virtual double | getMaxX (int halfspace)=0 |
| Returns the maximum x value for one of this Surface's halfspaces. More... | |
| virtual double | getMinY (int halfspace)=0 |
| Returns the minimum y value for one of this Surface's halfspaces. More... | |
| virtual double | getMaxY (int halfspace)=0 |
| Returns the maximum y value for one of this Surface's halfspaces. More... | |
| virtual double | getMinZ (int halfspace)=0 |
| Returns the minimum z value for one of this Surface's halfspaces. More... | |
| virtual double | getMaxZ (int halfspace)=0 |
| Returns the maximum z value for one of this Surface's halfspaces. More... | |
| void | setName (const char *name) |
| Sets the name of the Surface. More... | |
| void | setBoundaryType (const boundaryType boundary_type) |
| Sets the boundary condition type (ie, VACUUM or REFLECTIVE) for this Surface. More... | |
| void | addNeighborCell (int halfspace, Cell *cell) |
| Adds a neighbor Cell to this Surface's collection of neighbors. More... | |
| virtual double | evaluate (const Point *point) const =0 |
| Evaluate a Point using the Surface's potential equation. More... | |
| virtual int | intersection (Point *point, double azim, double polar, Point *points)=0 |
| Finds the intersection Point with this Surface from a given Point and trajectory defined by an angle. More... | |
| bool | isPointOnSurface (Point *point) |
| Return true or false if a Point is on or off of a Surface. More... | |
| bool | isCoordOnSurface (LocalCoords *coord) |
| Return true or false if a LocalCoord is on or off of a Surface. More... | |
| double | getMinDistance (Point *point, double azim, double polar) |
| Finds the minimum distance to a Surface. More... | |
| double | getMinDistance (LocalCoords *coord) |
| Finds the minimum distance to a Surface. More... | |
| virtual std::string | toString ()=0 |
| Converts this Surface's attributes to a character array. More... | |
| void | printString () |
| Prints a string representation of all of the Surface's objects to the console. | |
Protected Attributes | |
| int | _uid |
| int | _id |
| char * | _name |
| surfaceType | _surface_type |
| boundaryType | _boundary_type |
| std::map< int, std::vector< Cell * > *> | _neighbors |
Static Protected Attributes | |
| static int | _n = 0 |
Represents a general Surface in 3D.
The Surface class and its subclasses are used to define the geometry for an OpenMOC simulation using a constructive solid geometry (CSG) formalism. Surfaces are used during ray tracing of charateristic tracks across the geometry.
| Surface::Surface | ( | const int | id = 0, |
| const char * | name = "" |
||
| ) |
| void Surface::addNeighborCell | ( | int | halfspace, |
| Cell * | cell | ||
| ) |
|
pure virtual |
| boundaryType Surface::getBoundaryType | ( | ) |
| int Surface::getId | ( | ) | const |
| double Surface::getMax | ( | int | axis, |
| int | halfspace | ||
| ) |
Returns the maximum coordinate in the axis direction of the space defined by halfspace and this surface.
Returns the maximum coordinate in the axis direction of the surface.
| axis | The axis of interest (0 = x, 1 = y, 2 = z) |
| halfspace | the halfspace to consider |
|
pure virtual |
|
pure virtual |
|
pure virtual |
| double Surface::getMin | ( | int | axis, |
| int | halfspace | ||
| ) |
Returns the minimum coordinate in the axis direction of the space defined by halfspace and this surface.
Returns the minimum coordinate in the axis direction of the surface.
| axis | The axis of interest (0 = x, 1 = y, 2 = z) |
| halfspace | the halfspace to consider |
|
inline |
Finds the minimum distance to a Surface.
Finds the minimum distance to a Surface from a Point with a given trajectory defined by an azim/polar to this Surface. If the trajectory will not intersect the Surface, returns INFINITY.
| point | a pointer to the Point of interest |
| azim | the azimuthal angle defining the trajectory in radians |
| polar | the polar angle defining the trajectory in radians |
| double Surface::getMinDistance | ( | LocalCoords * | coords | ) |
Finds the minimum distance to a Surface.
Finds the miniumum distance to a Surface from a LocalCoords with a trajectory defined by an angle to this Surface. If the trajectory will not intersect the Surface, returns INFINITY.
| coords | a pointer to a localcoords object |
|
pure virtual |
|
pure virtual |
|
pure virtual |
| char * Surface::getName | ( | ) | const |
| surfaceType Surface::getSurfaceType | ( | ) |
|
pure virtual |
Finds the intersection Point with this Surface from a given Point and trajectory defined by an angle.
| point | pointer to the Point of interest |
| azim | the azimuthal angle (in radians) |
| polar | the polar angle (in radians) |
| points | array of Points to store the intersection locations |
| bool Surface::isCoordOnSurface | ( | LocalCoords * | coord | ) |
| bool Surface::isPointOnSurface | ( | Point * | point | ) |
| void Surface::setBoundaryType | ( | const boundaryType | boundary_type | ) |
| void Surface::setName | ( | const char * | name | ) |
|
pure virtual |
|
protected |
The type of boundary condition to be used for this Surface (ie, VACUUM or REFLECTIVE)
|
protected |
A user-defined id for each Surface created
|
staticprotected |
A static counter for the number of Surfaces in a simulation
|
protected |
A user-defined name for the Surface
|
protected |
The type of Surface (ie, XPLANE, ZCYLINDER, etc)
|
protected |
A monotonically increasing unique ID for each Surface created