From: bangerth Date: Sun, 13 Jan 2013 19:59:59 +0000 (+0000) Subject: Remove some uses of a deprecated function. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ac07fc4522a65549d174c80dd1758a904cab6415;p=dealii-svn.git Remove some uses of a deprecated function. git-svn-id: https://svn.dealii.org/trunk@28039 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/include/deal.II/lac/constraint_matrix.templates.h b/deal.II/include/deal.II/lac/constraint_matrix.templates.h index d1ad4d3565..1d21d55f8b 100644 --- a/deal.II/include/deal.II/lac/constraint_matrix.templates.h +++ b/deal.II/include/deal.II/lac/constraint_matrix.templates.h @@ -259,24 +259,26 @@ ConstraintMatrix::condense (const SparseMatrix &uncondensed, // copy entries if column will not // be condensed away, distribute // otherwise - for (unsigned int j=uncondensed_struct.get_rowstart_indices()[row]; - j::const_iterator + p = uncondensed.begin(row); + p != uncondensed.end(row); ++p) + if (new_line[p->column()] != -1) + condensed.add (new_line[row], + new_line[p->column()], + p->value()); else { // let c point to the // constraint of this column std::vector::const_iterator c = lines.begin(); - while (c->line != uncondensed_struct.get_column_numbers()[j]) + while (c->line != p->column()) ++c; for (unsigned int q=0; q!=c->entries.size(); ++q) // distribute to rows with // appropriate weight condensed.add (new_line[row], new_line[c->entries[q].first], - uncondensed.global_entry(j) * c->entries[q].second); + p->value() * c->entries[q].second); // take care of inhomogeneity: // need to subtract this element from the @@ -285,7 +287,7 @@ ConstraintMatrix::condense (const SparseMatrix &uncondensed, // row of the inhomogeneous constraint in // the matrix with Gauss elimination if (use_vectors == true) - condensed_vector(new_line[row]) -= uncondensed.global_entry(j) * + condensed_vector(new_line[row]) -= p->value() * c->inhomogeneity; }