An open source method of characteristics neutron transport code.
Union Class Reference

A union of two or more Regions. More...

#include "src/Region.h"

Public Member Functions

 Union ()
 Constructor sets the type of Region (UNION).
 
bool containsPoint (Point *point)
 Determines whether a Point is contained inside the Union. More...
 
- Public Member Functions inherited from Region
 Region ()
 Constructor sets a few pointers to NULL.
 
virtual ~Region ()
 Destructor clears vector of the nodes within the Region.
 
virtual void addNode (Region *node, bool clone=true)
 Add a node to the Region. More...
 
void removeHalfspace (Surface *surface, int halfspace)
 Removes a Node from this Region. More...
 
regionType getRegionType ()
 Return the type of Region (ie, UNION, INTERSECTION, etc). More...
 
void setParentRegion (Region *node)
 Set the parent of the current node/Region. More...
 
RegiongetParentRegion ()
 Get the parent of the current node/Region. More...
 
virtual std::vector< Region * > getNodes ()
 Return a vector of all of the Region's immediate nodes. More...
 
virtual std::vector< Region * > getAllNodes ()
 Return a vector of all of the Region's nodes. More...
 
virtual std::map< int, Halfspace * > getAllSurfaces ()
 Extracts a map of all Halfspaces contained in the Region. More...
 
virtual double getMinX ()
 Return the minimum reachable x-coordinate in the Region. More...
 
virtual double getMaxX ()
 Return the maximum reachable x-coordinate in the Region. More...
 
virtual double getMinY ()
 Return the minimum reachable y-coordinate in the Region. More...
 
virtual double getMaxY ()
 Return the maximum reachable y-coordinate in the Region. More...
 
virtual double getMinZ ()
 Return the minimum reachable z-coordinate in the Region. More...
 
virtual double getMaxZ ()
 Return the maximum reachable z-coordinate in the Region. More...
 
virtual boundaryType getMinXBoundaryType ()
 Return the boundary condition (REFLECTIVE, VACUUM, or INTERFACE) at the minimum reachable x-coordinate in the Region. More...
 
virtual boundaryType getMaxXBoundaryType ()
 Return the boundary condition (REFLECTIVE, VACUUM, or INTERFACE) at the maximum reachable x-coordinate in the Region. More...
 
virtual boundaryType getMinYBoundaryType ()
 Return the boundary condition (REFLECTIVE, VACUUM, or INTERFACE) at the minimum reachable y-coordinate in the Region. More...
 
virtual boundaryType getMaxYBoundaryType ()
 Return the boundary condition (REFLECTIVE, VACUUM, or INTERFACE) at the maximum reachable y-coordinate in the Region. More...
 
virtual boundaryType getMinZBoundaryType ()
 Return the boundary condition (REFLECTIVE, VACUUM, or INTERFACE) at the minimum reachable z-coordinate in the Region. More...
 
virtual boundaryType getMaxZBoundaryType ()
 Return the boundary condition (REFLECTIVE, VACUUM, or INTERFACE) at the maximum reachable z-coordinate in the Region. More...
 
virtual double minSurfaceDist (LocalCoords *coords)
 Computes the minimum distance to a Surface in the Region from a point with a given trajectory at a certain angle stored in a LocalCoords object. More...
 
virtual double minSurfaceDist (Point *point, double azim, double polar=M_PI_2)
 Computes the minimum distance to a Surface in the Region from a point with a given trajectory at a certain angle stored in a LocalCoords object. More...
 
virtual Regionclone ()
 Create a duplicate of the Region. More...
 

Additional Inherited Members

- Protected Attributes inherited from Region
regionType _region_type
 
std::vector< Region * > _nodes
 
Region_parent_region
 

Detailed Description

A union of two or more Regions.

Member Function Documentation

◆ containsPoint()

bool Union::containsPoint ( Point point)
virtual

Determines whether a Point is contained inside the Union.

Queries each of the Union's nodes to determine if the Point is within the Union. This point is only inside the Union if it is contained by at least one node.

Returns
true if the Point is inside the Union; otherwise false

Implements Region.


The documentation for this class was generated from the following files: