Flow123d
JS_before_hm-1713-g943b6bc16
|
Go to the documentation of this file.
20 unsigned int bulk_element_idx)
21 : component_element_idx_(component_element_idx), bulk_element_idx_(bulk_element_idx)
25 template<
unsigned int dimA,
unsigned int dimB>
29 template<
unsigned int dimA,
unsigned int dimB>
34 template<
unsigned int dimA,
unsigned int dimB>
39 for(
unsigned int i = 0; i < iaux.
size(); i++)
46 template<
unsigned int dimA,
unsigned int dimB>
51 template<
unsigned int dimA,
unsigned int dimB>
57 if(i_points_.size() > 1)
58 for(
unsigned int i=0; i < i_points_.size()-1; i++)
60 length += abs(i_points_[i].comp_coords()[0] - i_points_[i+1].comp_coords()[0]);
71 double subtotal = 0.0;
74 for(
unsigned int j = 2; j <
i_points_.size();j++){
80 return fabs(subtotal/2);
85 template<
unsigned int dimA,
unsigned int dimB>
89 template<
unsigned int dimA,
unsigned int dimB>
93 template<
unsigned int dimA,
unsigned int dimB>
95 : comp_coords_(p.local_bcoords_A().subvec(1,dimA)), bulk_coords_(p.local_bcoords_B().subvec(1,dimB))
98 template<
unsigned int dimA,
unsigned int dimB>
100 const arma::vec::fixed< dimB >& bulk_coords)
101 : comp_coords_(comp_coords), bulk_coords_(bulk_coords)
106 template<
unsigned int dimA,
unsigned int dimB>
113 double complement = 1.0;
114 for(
unsigned int i=0; i<dimA; i++)
116 c += comp_coords_[i] * (*comp_ele.
node(i+1));
117 complement -= comp_coords_[i];
119 c += complement * (*comp_ele.
node(0));
129 os <<
"IntersectionLocal<" << dimA <<
"," << dimB <<
">: c " << il.component_element_idx_ <<
", b " <<
130 il.bulk_element_idx_ <<
", size " << il.
i_points_.size() << endl;
131 for (
unsigned int i = 0; i < il.
i_points_.size(); i++) {
132 os << i <<
": " << il[i] << endl;
140 for(
unsigned j= 0; j < dimA-1; j++)
144 for(
unsigned j= 0; j < dimB-1; j++)
~IntersectionPoint()
Destructor.
ostream & operator<<(ostream &os, const IntersectionLocal< dimA, dimB > &il)
template ostream & operator<<< 2, 3 >(ostream &os, const IntersectionPoint< 2, 3 > &s)
double compute_measure() const override
Computes the relative measure of intersection object.
arma::vec::fixed< dimB > bulk_coords_
Local coordinates of an IP on simplex<dimB>.
IntersectionPoint()
Default constructor.
arma::vec3 coords(ElementAccessor< 3 > comp_ele) const
template ostream & operator<<< 2, 2 >(ostream &os, const IntersectionPoint< 2, 2 > &s)
std::vector< IntersectionPoint< dimA, dimB > > i_points_
Vector of intersection points.
NodeAccessor< 3 > node(unsigned int ni) const
Internal class representing intersection object.
unsigned int size() const
Returns number of intersection points.
Internal auxiliary class representing intersection object of simplex<dimA> and simplex<dimB>.
template ostream & operator<<< 1, 3 >(ostream &os, const IntersectionPoint< 1, 3 > &s)
Class represents intersection of two elements.
Class represents an intersection point of simplex<N> and simplex<M>. It contains barycentric coordina...
#define ASSERT_LT_DBG(a, b)
Definition of comparative assert macro (Less Than) only for debug mode.
arma::vec::fixed< dimA > comp_coords_
Local coordinates of an IP on simplex<dimA>.
template ostream & operator<<< 1, 2 >(ostream &os, const IntersectionPoint< 1, 2 > &s)
IntersectionLocal()
Default constructor.
~IntersectionLocal()
Destructor.
Internal class representing intersection point.
Common base for intersection object.
Classes with algorithms for computation of intersections of meshes.