MatSetInf#

Set every entry (of a given nonzero pattern) of a matrix to positive infinity.

Synopsis#

#include "petscmat.h" 
PetscErrorCode MatSetInf(Mat A)

Logically Collective

Input Parameter#

  • A - the matrix

Notes#

Only the dense types (MATSEQDENSE, MATMPIDENSE, and their device variants) currently implement this operation, which is used to flag a block of solutions that a linear solver failed to compute, as VecFlag() does for a single solution.

The state of A is increased, so an outer solver that tracks it detects the failure even when the entries were already infinite.

See Also#

Mat, MatZeroEntries(), MatSetValues(), VecFlag()

Level#

developer

Location#

src/mat/interface/matrix.c

Implementations#

MatSetInf_MPIDense() in src/mat/impls/dense/mpi/mpidense.c
MatSetInf_SeqDense() in src/mat/impls/dense/seq/dense.c


Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages