* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the subface of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Derived elements will have to
* implement this function. They
* of one element to the face of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Base elements of this element will
* have to implement this function. They
* of one element to the subface of
* the neighboring element.
* The size of the matrix is
- * then @p dofs_per_face times
- * <tt>source.dofs_per_face</tt>.
+ * then <tt>source.dofs_per_face</tt> times
+ * <tt>this->dofs_per_face</tt>.
*
* Base elements of this element will
* have to implement this function. They
// previous steps of the hp hanging node
// procedure.
- Assert (face_constraints.m () == dofs_mother.size (),
+ Assert (face_constraints.n () == dofs_mother.size (),
ExcDimensionMismatch(dofs_mother.size (),
face_constraints.n()));
- Assert (face_constraints.n () == dofs_child.size (),
+ Assert (face_constraints.m () == dofs_child.size (),
ExcDimensionMismatch(dofs_child.size (),
face_constraints.m()));
Assert (n_dofs_mother <= n_dofs_child,
ExcInternalError ());
- for (unsigned int col=0; col!=n_dofs_child; ++col)
+ for (unsigned int row=0; row!=n_dofs_child; ++row)
{
bool constraint_already_satisfied = false;
// the corresponding global dof
// indices
for (unsigned int i=0; i<n_dofs_mother; ++i)
- if (face_constraints (i,col) == 1.0)
- if (dofs_mother[i] == dofs_child[col])
+ if (face_constraints (row,i) == 1.0)
+ if (dofs_mother[i] == dofs_child[row])
{
constraint_already_satisfied = true;
break;
if (constraint_already_satisfied == false)
{
- constraints.add_line (dofs_child[col]);
+ constraints.add_line (dofs_child[row]);
for (unsigned int i=0; i!=n_dofs_mother; ++i)
- if (face_constraints(i,col) != 0)
+ if (face_constraints(row,i) != 0)
{
#ifdef WOLFGANG
- std::cout << " " << dofs_child[col]
- << " -> " << face_constraints (i,col) << " * "
+ std::cout << " " << dofs_child[row]
+ << " -> " << face_constraints (row,i) << " * "
<< dofs_mother[i]
<< std::endl;
#endif
- constraints.add_entry (dofs_child[col],
+ constraints.add_entry (dofs_child[row],
dofs_mother[i],
- face_constraints (i,col));
+ face_constraints (row,i));
}
}
}
// properties of a
// finite element onto
// that mesh
- face_constraints.reinit (n_dofs_on_mother,
- n_dofs_on_children);
+ face_constraints.reinit (n_dofs_on_children,
+ n_dofs_on_mother);
cell->get_fe()
.get_subface_interpolation_matrix (subface->get_fe(subface_fe_index),
c, face_constraints);
dofs_on_mother.resize (n_dofs_on_mother);
cell->face(face)->get_dof_indices (dofs_on_mother, cell->active_fe_index ());
- FullMatrix<double> fc_mother_ipol (n_dofs_on_children,
- n_dofs_on_mother);
- FullMatrix<double> fc_mother_sface (n_dofs_on_children,
- n_dofs_on_mother);
+ FullMatrix<double> fc_mother_ipol (n_dofs_on_mother,
+ n_dofs_on_children);
+ FullMatrix<double> fc_mother_sface (n_dofs_on_mother,
+ n_dofs_on_children);
dominating_fe.get_face_interpolation_matrix (cell->get_fe(),
fc_mother_ipol);
- fc_ipol_sface.mmult (fc_mother_sface, fc_mother_ipol);
+ fc_mother_ipol.mmult (fc_mother_sface, fc_ipol_sface);
// Add constraints to global constraint
// matrix.
// Now create the element
// constraint for this subface.
- FullMatrix<double> fc_child_sface_ipol (n_dofs_on_children,
- n_dofs_on_mother);
- FullMatrix<double> fc_child_sface_sface (n_dofs_on_children,
- n_dofs_on_mother);
+ FullMatrix<double> fc_child_sface_ipol (n_dofs_on_mother,
+ n_dofs_on_children);
+ FullMatrix<double> fc_child_sface_sface (n_dofs_on_mother,
+ n_dofs_on_children);
dominating_fe.get_subface_interpolation_matrix
(subface->get_fe(subface_fe_index),
c, fc_child_sface_ipol);
- fc_ipol_sface.mmult (fc_child_sface_sface, fc_child_sface_ipol);
+ fc_child_sface_ipol.mmult (fc_child_sface_sface, fc_ipol_sface);
// Add constraints to global constraint
// matrix.
// Now create the element
// constraint for this subface.
- FullMatrix<double> face_constraints (dofs_on_mother.size(),
- dofs_on_children.size());
+ FullMatrix<double> face_constraints (dofs_on_children.size(),
+ dofs_on_mother.size());
cell->get_fe().get_face_interpolation_matrix (neighbor->get_fe (),
face_constraints);
ExcDimensionMismatch (interpolation_matrix.m(),
0));
Assert (interpolation_matrix.n() == 0,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ ExcDimensionMismatch (interpolation_matrix.n(),
0));
}
ExcDimensionMismatch (interpolation_matrix.m(),
0));
Assert (interpolation_matrix.n() == 0,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ ExcDimensionMismatch (interpolation_matrix.n(),
0));
}
ExcDimensionMismatch (interpolation_matrix.m(),
0));
Assert (interpolation_matrix.n() == 0,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ ExcDimensionMismatch (interpolation_matrix.n(),
0));
}
ExcDimensionMismatch (interpolation_matrix.m(),
0));
Assert (interpolation_matrix.n() == 0,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ ExcDimensionMismatch (interpolation_matrix.n(),
0));
}
ExcDimensionMismatch (interpolation_matrix.m(),
0));
Assert (interpolation_matrix.n() == 0,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ ExcDimensionMismatch (interpolation_matrix.n(),
0));
}
ExcDimensionMismatch (interpolation_matrix.m(),
0));
Assert (interpolation_matrix.n() == 0,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ ExcDimensionMismatch (interpolation_matrix.n(),
0));
}
typename FiniteElement<dim>::
ExcInterpolationNotImplemented());
- Assert (interpolation_matrix.m() == this->dofs_per_face,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ Assert (interpolation_matrix.n() == this->dofs_per_face,
+ ExcDimensionMismatch (interpolation_matrix.n(),
this->dofs_per_face));
- Assert (interpolation_matrix.n() == x_source_fe.dofs_per_face,
+ Assert (interpolation_matrix.m() == x_source_fe.dofs_per_face,
ExcDimensionMismatch (interpolation_matrix.m(),
x_source_fe.dofs_per_face));
if (fabs (matrix_entry) < eps)
matrix_entry = 0.0;
- interpolation_matrix(j,i) = matrix_entry;
+ interpolation_matrix(i,j) = matrix_entry;
}
}
- // make sure that the column sum of
+ // make sure that the row sum of
// each of the matrices is 1 at
// this point. this must be so
// since the shape functions sum up
double sum = 0.;
for (unsigned int i=0; i<this->dofs_per_face; ++i)
- sum += interpolation_matrix(i,j);
+ sum += interpolation_matrix(j,i);
Assert (std::fabs(sum-1) < 2e-14*this->degree*(dim-1),
ExcInternalError());
typename FiniteElement<dim>::
ExcInterpolationNotImplemented());
- Assert (interpolation_matrix.m() == this->dofs_per_face,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ Assert (interpolation_matrix.n() == this->dofs_per_face,
+ ExcDimensionMismatch (interpolation_matrix.n(),
this->dofs_per_face));
- Assert (interpolation_matrix.n() == x_source_fe.dofs_per_face,
+ Assert (interpolation_matrix.m() == x_source_fe.dofs_per_face,
ExcDimensionMismatch (interpolation_matrix.m(),
x_source_fe.dofs_per_face));
if (fabs (matrix_entry) < eps)
matrix_entry = 0.0;
- interpolation_matrix(j,i) = matrix_entry;
+ interpolation_matrix(i,j) = matrix_entry;
}
}
- // make sure that the column sum of
+ // make sure that the row sum of
// each of the matrices is 1 at
// this point. this must be so
// since the shape functions sum up
double sum = 0.;
for (unsigned int i=0; i<this->dofs_per_face; ++i)
- sum += interpolation_matrix(i,j);
+ sum += interpolation_matrix(j,i);
Assert (std::fabs(sum-1) < 2e-14*this->degree*(dim-1),
ExcInternalError());
typename FiniteElement<dim>::
ExcInterpolationNotImplemented());
- Assert (interpolation_matrix.m() == this->dofs_per_face,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ Assert (interpolation_matrix.n() == this->dofs_per_face,
+ ExcDimensionMismatch (interpolation_matrix.n(),
this->dofs_per_face));
- Assert (interpolation_matrix.n() == x_source_fe.dofs_per_face,
+ Assert (interpolation_matrix.m() == x_source_fe.dofs_per_face,
ExcDimensionMismatch (interpolation_matrix.m(),
x_source_fe.dofs_per_face));
ExcNotImplemented());
// get the interpolation from the bases
- base_to_base_interpolation.reinit (base.dofs_per_face,
- base_other.dofs_per_face);
+ base_to_base_interpolation.reinit (base_other.dofs_per_face,
+ base.dofs_per_face);
base.get_face_interpolation_matrix (base_other,
base_to_base_interpolation);
if (fe_other_system->face_system_to_base_index(j).first
==
std::make_pair (base_index_other, multiplicity_other))
- interpolation_matrix(i, j)
- = base_to_base_interpolation(this->face_system_to_base_index(i).second,
- fe_other_system->face_system_to_base_index(j).second);
+ interpolation_matrix(j, i)
+ = base_to_base_interpolation(fe_other_system->face_system_to_base_index(j).second,
+ this->face_system_to_base_index(i).second);
// advance to the next base element
// for this and the other
typename FiniteElement<dim>::
ExcInterpolationNotImplemented());
- Assert (interpolation_matrix.m() == this->dofs_per_face,
- ExcDimensionMismatch (interpolation_matrix.m(),
+ Assert (interpolation_matrix.n() == this->dofs_per_face,
+ ExcDimensionMismatch (interpolation_matrix.n(),
this->dofs_per_face));
- Assert (interpolation_matrix.n() == x_source_fe.dofs_per_face,
+ Assert (interpolation_matrix.m() == x_source_fe.dofs_per_face,
ExcDimensionMismatch (interpolation_matrix.m(),
x_source_fe.dofs_per_face));
ExcNotImplemented());
// get the interpolation from the bases
- base_to_base_interpolation.reinit (base.dofs_per_face,
- base_other.dofs_per_face);
+ base_to_base_interpolation.reinit (base_other.dofs_per_face,
+ base.dofs_per_face);
base.get_subface_interpolation_matrix (base_other,
subface,
base_to_base_interpolation);
if (fe_other_system->face_system_to_base_index(j).first
==
std::make_pair (base_index_other, multiplicity_other))
- interpolation_matrix(i, j)
- = base_to_base_interpolation(this->face_system_to_base_index(i).second,
- fe_other_system->face_system_to_base_index(j).second);
+ interpolation_matrix(j, i)
+ = base_to_base_interpolation(fe_other_system->face_system_to_base_index(j).second,
+ this->face_system_to_base_index(i).second);
// advance to the next base element
// for this and the other