const unsigned int n_q_points = patch_points.n_quadrature_points;
- unsigned int face_number = 0;
typename std::vector< ::DataOutBase::Patch<dim-1,dim> >::iterator patch = this->patches.begin();
FaceDescriptor face=first_face();
for (unsigned int i=0; (i<data.this_thread)&&(face.first != this->dofs->end()); ++i)
{
++patch;
- ++face_number;
face=next_face(face);
}
// then do the cell data
for (unsigned int dataset=0; dataset<this->cell_data.size(); ++dataset)
{
+ // we need to get at
+ // the number of the
+ // cell to which this
+ // face belongs in
+ // order to access the
+ // cell data. this is
+ // not readily
+ // available, so choose
+ // the following rather
+ // inefficient way:
+ Assert (face.first->active(), ExcCellNotActiveForCellData());
+ const unsigned int cell_number
+ = std::distance (this->dofs->begin_active(),
+ typename DoFHandler<dim>::active_cell_iterator(face.first));
+
if (this->cell_data[dataset].has_block)
{
- const double value = (*this->cell_data[dataset].block_data)(face_number);
+ const double value = (*this->cell_data[dataset].block_data)(cell_number);
for (unsigned int q=0; q<n_q_points; ++q)
patch->data(dataset+this->dof_data.size()*data.n_components,q) =
value;
} else {
- const double value = (*this->cell_data[dataset].single_data)(face_number);
+ const double value = (*this->cell_data[dataset].single_data)(cell_number);
for (unsigned int q=0; q<n_q_points; ++q)
patch->data(dataset+this->dof_data.size()*data.n_components,q) =
value;
(i<data.n_threads)&&(face.first != this->dofs->end()); ++i)
{
++patch;
- ++face_number;
face=next_face(face);
}
};
<h3>deal.II</h3>
<ol>
+ <li> <p>
+ Fixed: The <code class="class">DataOutFaces</code> class was
+ broken for cell data. It should now be correct, although the
+ algorithm used is not optimal, being approximately quadratic in
+ runtime.
+ <br>
+ (WB 2003/02/25)
+ </p>
+
<li> <p>
New: The <code class="member">ConstraintMatrix::shift</code>
function shifts and translates the elements of the constraint