From: Guido Kanschat Date: Fri, 21 Oct 2005 13:54:53 +0000 (+0000) Subject: output the failing UMFPack function name on error X-Git-Tag: v8.0.0~12959 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=646ff1a6c758ff9e17e960cca48817ba2efe39f4;p=dealii.git output the failing UMFPack function name on error git-svn-id: https://svn.dealii.org/trunk@11644 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/lac/include/lac/sparse_direct.h b/deal.II/lac/include/lac/sparse_direct.h index 1ae3a8ecf6..a25959c3ae 100644 --- a/deal.II/lac/include/lac/sparse_direct.h +++ b/deal.II/lac/include/lac/sparse_direct.h @@ -1168,10 +1168,17 @@ class SparseDirectUMFPACK : public Subscriptor Vector &rhs_and_solution); /** - * Exception + * One of the UMFPack routines + * threw an error. The error code + * is included in the output and + * can be looked up in the + * UMFPack user manual. The name + * of the routine is included for + * reference. */ - DeclException1 (ExcUMFPACKError, int, - << "UMFPACK returned error status " << arg1); + DeclException2 (ExcUMFPACKError, char*, int, + << "UMFPACK routine " << arg1 + << " returned error status " << arg2); private: /** diff --git a/deal.II/lac/source/sparse_direct.cc b/deal.II/lac/source/sparse_direct.cc index c1dcd5684e..9534cee1a3 100644 --- a/deal.II/lac/source/sparse_direct.cc +++ b/deal.II/lac/source/sparse_direct.cc @@ -1793,13 +1793,13 @@ factorize (const SparseMatrix &matrix) &Ap[0], &Ai[0], &Ax[0], &symbolic_decomposition, &control[0], 0); - AssertThrow (status == UMFPACK_OK, ExcUMFPACKError(status)); + AssertThrow (status == UMFPACK_OK, ExcUMFPACKError("umfpack_di_symbolic", status)); status = umfpack_di_numeric (&Ap[0], &Ai[0], &Ax[0], symbolic_decomposition, &numeric_decomposition, &control[0], 0); - AssertThrow (status == UMFPACK_OK, ExcUMFPACKError(status)); + AssertThrow (status == UMFPACK_OK, ExcUMFPACKError("umfpack_di_numeric", status)); umfpack_di_free_symbolic (&symbolic_decomposition) ; } @@ -1830,7 +1830,7 @@ SparseDirectUMFPACK::solve (Vector &rhs_and_solution) const rhs_and_solution.begin(), rhs.begin(), numeric_decomposition, &control[0], 0); - AssertThrow (status == UMFPACK_OK, ExcUMFPACKError(status)); + AssertThrow (status == UMFPACK_OK, ExcUMFPACKError("umfpack_di_solve", status)); }