PETSc version 3.17.4
Fix/Edit manual page

# MatNorm

Calculates various norms of a matrix.

### Synopsis

    #include "petscmat.h"
    PetscErrorCode MatNorm(Mat mat,NormType type,PetscReal *nrm)

Collective on Mat

### Input Parameters

| mat | - the matrix
| type | - the type of norm, NORM_1, NORM_FROBENIUS, NORM_INFINITY

### Output Parameter

| nrm | - the resulting norm

### Level

intermediate

### Location

src/mat/interface/matrix.c

### Examples

src/ksp/ksp/tutorials/ex21.c.html
src/ksp/ksp/tutorials/ex29.c.html
src/ksp/ksp/tutorials/ex34.c.html
src/ksp/ksp/tutorials/ex76.c.html
src/ksp/ksp/tutorials/ex77.c.html
src/ksp/ksp/tutorials/ex77f.F90.html
src/snes/tutorials/ex48.c.html
src/ts/tutorials/ex14.c.html

### Implementations

MatNorm_MPIAIJ in src/mat/impls/aij/mpi/mpiaij.c
MatNorm_SeqAIJ in src/mat/impls/aij/seq/aij.c
MatNorm_MPIBAIJ in src/mat/impls/baij/mpi/mpibaij.c
MatNorm_SeqBAIJ in src/mat/impls/baij/seq/baij2.c
MatNorm_ConstantDiagonal in src/mat/impls/cdiagonal/cdiagonal.c
MatNorm_MPIDense in src/mat/impls/dense/mpi/mpidense.c
MatNorm_SeqDense in src/mat/impls/dense/seq/dense.c
MatNorm_Elemental in src/mat/impls/elemental/matelem.cxx
MatNorm_H2OPUS in src/mat/impls/h2opus/cuda/math2opus.cu
MatNorm_MPISBAIJ in src/mat/impls/sbaij/mpi/mpisbaij.c
MatNorm_SeqSBAIJ in src/mat/impls/sbaij/seq/sbaij2.c
MatNorm_ScaLAPACK in src/mat/impls/scalapack/matscalapack.c
Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages