Portage::IntersectClipper< SourceMeshType, TargetMeshType > Class Template Reference

2-D intersection algorithm for arbitrary convex and non-convex polyhedra More...

#include <intersect_clipper.h>

Public Types

typedef std::vector< Wonton::Point< 2 > > Poly
 Alias for a collection of Points. More...
 
typedef std::pair< double, Wonton::Point< 2 > > Moment
 Alias to provide volume and centroid. More...
 

Public Member Functions

 IntersectClipper (const SourceMeshType &s, const TargetMeshType &t)
 Constructor taking a source mesh s and a target mesh t. More...
 
std::vector< std::vector< double > > operator() (const int cellA, const int cellB) const
 Intersect two cells and return the first two moments. More...
 
 IntersectClipper ()=default
 Default constructor. More...
 
 IntersectClipper (const IntersectClipper &)=delete
 Copy constructor (disabled) More...
 
IntersectClipperoperator= (const IntersectClipper &)=delete
 Assignment operator (disabled) More...
 

Detailed Description

template<typename SourceMeshType, typename TargetMeshType = SourceMeshType>
class Portage::IntersectClipper< SourceMeshType, TargetMeshType >

2-D intersection algorithm for arbitrary convex and non-convex polyhedra

Template Parameters
SourceMeshTypeThe mesh type of the input mesh.
TargetMeshTypeThe mesh type of the output mesh.

The intersect class is templated on MeshWrapper type. You must provide a method to convert the template cells to an IntersectClipper::Poly.

Member Typedef Documentation

◆ Moment

template<typename SourceMeshType , typename TargetMeshType = SourceMeshType>
typedef std::pair<double, Wonton::Point<2> > Portage::IntersectClipper< SourceMeshType, TargetMeshType >::Moment

Alias to provide volume and centroid.

◆ Poly

template<typename SourceMeshType , typename TargetMeshType = SourceMeshType>
typedef std::vector<Wonton::Point<2> > Portage::IntersectClipper< SourceMeshType, TargetMeshType >::Poly

Alias for a collection of Points.

Constructor & Destructor Documentation

◆ IntersectClipper() [1/3]

template<typename SourceMeshType , typename TargetMeshType = SourceMeshType>
Portage::IntersectClipper< SourceMeshType, TargetMeshType >::IntersectClipper ( const SourceMeshType &  s,
const TargetMeshType &  t 
)
inline

Constructor taking a source mesh s and a target mesh t.

◆ IntersectClipper() [2/3]

template<typename SourceMeshType , typename TargetMeshType = SourceMeshType>
Portage::IntersectClipper< SourceMeshType, TargetMeshType >::IntersectClipper ( )
default

Default constructor.

◆ IntersectClipper() [3/3]

template<typename SourceMeshType , typename TargetMeshType = SourceMeshType>
Portage::IntersectClipper< SourceMeshType, TargetMeshType >::IntersectClipper ( const IntersectClipper< SourceMeshType, TargetMeshType > &  )
delete

Copy constructor (disabled)

Member Function Documentation

◆ operator()()

template<typename SourceMeshType , typename TargetMeshType = SourceMeshType>
std::vector<std::vector<double> > Portage::IntersectClipper< SourceMeshType, TargetMeshType >::operator() ( const int  cellA,
const int  cellB 
) const
inline

Intersect two cells and return the first two moments.

Parameters
[in]cellAfirst cell index to intersect
[in]cellBsecond cell index to intersect
Returns
list of moments; ret[0] == 0th moment; ret[1] == first moment

◆ operator=()

template<typename SourceMeshType , typename TargetMeshType = SourceMeshType>
IntersectClipper& Portage::IntersectClipper< SourceMeshType, TargetMeshType >::operator= ( const IntersectClipper< SourceMeshType, TargetMeshType > &  )
delete

Assignment operator (disabled)


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