20 #ifndef INTERSECTION_LOCAL_H_ 21 #define INTERSECTION_LOCAL_H_ 34 template<
unsigned int dimA,
unsigned int dimB> std::ostream& operator<<(std::ostream& os, const IntersectionLocal<dimA,dimB>& il);
35 template<
unsigned int dimA,
unsigned int dimB> std::ostream& operator<<(std::ostream& os, const IntersectionPoint<dimA,dimB>& ip);
60 unsigned int bulk_element_idx);
70 typedef std::pair<unsigned int, IntersectionLocalBase*>
ILpair;
88 template<
unsigned int dimA,
unsigned int dimB>
99 IntersectionLocal(
unsigned int component_element_idx,
unsigned int bulk_element_idx);
116 unsigned int size()
const;
129 template<
unsigned int dimA,
unsigned int dimB>
131 {
return i_points_; }
133 template<
unsigned int dimA,
unsigned int dimB>
135 {
return i_points_; }
137 template<
unsigned int dimA,
unsigned int dimB>
140 return i_points_[index]; }
142 template<
unsigned int dimA,
unsigned int dimB>
144 {
return i_points_.size(); }
152 template<
unsigned int dimA,
unsigned int dimB>
170 IntersectionPoint(
const arma::vec::fixed<dimA> &comp_coords,
const arma::vec::fixed<dimB> &bulk_coords);
175 const arma::vec::fixed<dimA> &comp_coords()
const;
178 const arma::vec::fixed<dimB> &bulk_coords()
const;
195 template<
unsigned int dimA,
unsigned int dimB>
197 {
return comp_coords_; }
199 template<
unsigned int dimA,
unsigned int dimB>
201 {
return bulk_coords_; }
Common base for intersection object.
arma::vec::fixed< dimB > bulk_coords_
Local coordinates of an IP on simplex<dimB>.
Class represents intersection of two elements.
Class represents an intersection point of simplex<N> and simplex<M>. It contains barycentric coordina...
unsigned int size() const
Returns number of intersection points.
unsigned int bulk_ele_idx() const
Returns index of bulk element.
unsigned int component_ele_idx() const
Returns index of component element.
const arma::vec::fixed< dimA > & comp_coords() const
Returns local coordinates in the Simplex<N>.
const arma::vec::fixed< dimB > & bulk_coords() const
Returns local coordinates in the Simplex<M>.
std::pair< unsigned int, IntersectionLocalBase * > ILpair
First = element index, Second = pointer to intersection object.
arma::vec::fixed< dimA > comp_coords_
Local coordinates of an IP on simplex<dimA>.
unsigned int component_element_idx_
Index of intersecting element in the component.
std::vector< IntersectionPoint< dimA, dimB > > i_points_
Vector of intersection points.
Internal auxiliary class represents an intersection point of simplex<N> and simplex<M>.
std::vector< IntersectionPoint< dimA, dimB > > & points()
Returns intersection points by a reference.
Internal auxiliary class representing intersection object of simplex<dimA> and simplex<dimB>.
virtual double compute_measure() const =0
const IntersectionPoint< dimA, dimB > & operator[](unsigned int index) const
Returns intersection point of given index.
unsigned int bulk_element_idx_
Index of intersecting element in the bulk.