Exemplo n.º 1
0
//==============================================================================
int Ifpack2_LocalFilter::ExtractDiagonalCopy(Tpetra_Vector & Diagonal) const
{
    if (!Diagonal.Map().SameAs(*Map_))
        IFPACK2_CHK_ERR(-1);
    Diagonal = *Diagonal_;
    return(0);
}
//==============================================================================
int Ifpack2_ReorderFilter::
ExtractDiagonalCopy(Tpetra_Vector & Diagonal) const
{
  Tpetra_Vector DiagonalTilde(Diagonal.Map());
  IFPACK2_CHK_ERR(Matrix()->ExtractDiagonalCopy(DiagonalTilde));
  IFPACK2_CHK_ERR((Reordering_->P(DiagonalTilde,Diagonal)));
  return(0);
}