On 10/13/2017 08:39 AM, Lucas Campos wrote:
In general, using MatrixTools::apply_boundary_values() is not the way to go
with MPI programs. Rather, use a ConstraintMatrix and incorporate the
boundary
values into the same object as you do with hanging node constraints.
This is the way to go due to correctness, or in the sense of scalability?
MatrixTools::apply_boundary_values() needs access to the elements of the
matrix because it wants to modify elements after they have already been
written into the matrix. That is already difficult if the matrix is owned by
PETSc or Trilinos -- we can get access to these elements, but it is not
efficient to do so.
But the bigger issue is that the function wants to access elements not only
for the rows of constrained DoFs, but also for the columns. That means that
you may have to access elements that are actually stored on other processors
-- something that can not be done efficiently. Consequently,
MatrixTools::apply_boundary_values() does not attempt to eliminate columns of
the matrix, and you will end up with a non-symmetric matrix even if your
problem is symmetric.
It is better to use the approach via ConstraintMatrix that deals with entries
before they even get into the matrix (and therefore in particular before
matrix entries are sent to other processors).
Best
W.
--
------------------------------------------------------------------------
Wolfgang Bangerth email: [email protected]
www: http://www.math.colostate.edu/~bangerth/
--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see
https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.