NormType#
determines what type of norm to compute with VecNorm(), VecNormBegin()/VecNormEnd() and MatNorm().
Synopsis#
typedef enum {
NORM_1 = 0,
NORM_2 = 1,
NORM_FROBENIUS = 2,
NORM_INFINITY = 3,
NORM_1_AND_2 = 4
} NormType;
Values#
NORM_1- the one norm, \(\|v\| = \sum_i | v_i |\). \(\|A\| = \max_j \| A_{*,j} \|\), maximum column sumNORM_2- the two norm, \(\|v\| = \sqrt{\sum_i |v_i|^2}\) (vectors only)NORM_FROBENIUS- \(\|A\| = \sqrt{\sum_{i,j} |A_{i,j}|^2}\), same asNORM_2for vectorsNORM_INFINITY- \(\|v\| = \max_i |v_i|\). \(\|A\| = \max_i \| A_{i,*} \|_1\), maximum row sumNORM_1_AND_2- computes both the 1 and 2 norm of a vector. The values are stored in two adjacentPetscRealmemory locations
Note#
See Also#
Vectors and Parallel Data, Vec, Mat, VecNorm(), VecNormBegin(), VecNormEnd(), MatNorm(), NORM_1,
NORM_2, NORM_FROBENIUS, NORM_INFINITY, NORM_1_AND_2, ReductionType
Level#
beginner
Location#
Examples#
src/vec/vec/tests/ex37.c
src/tao/tutorials/ex4.c
src/ksp/ksp/utils/lmvm/tests/lmvm_copy_test.c
src/mat/tests/ex2.c
src/mat/tests/ex313.c
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages