MatIsTranspose#

Test whether a matrix is another one’s transpose, or its own, in which case it tests symmetry.

Synopsis#

#include "petscmat.h" 
PetscErrorCode MatIsTranspose(Mat A, Mat B, PetscReal tol, PetscBool *flg)

Collective

Input Parameters#

  • A - the matrix to test

  • B - the matrix to test against, this can equal the first parameter

  • tol - tolerance, differences between entries smaller than this are counted as zero

Output Parameter#

  • flg - the result

Notes#

The sequential algorithm has a running time of the order of the number of nonzeros; the parallel test involves parallel copies of the block off-diagonal parts of the matrix.

See Also#

Matrices, Mat, MatTranspose(), MatIsSymmetric(), MatIsHermitian()

Level#

intermediate

Location#

src/mat/interface/matrix.c

Implementations#

MatIsTranspose_MPIAIJ() in src/mat/impls/aij/mpi/mpiaij.c
MatIsTranspose_SeqAIJ() in src/mat/impls/aij/seq/aij.c
MatIsTranspose_SeqBAIJ() in src/mat/impls/baij/seq/baij.c
MatIsTranspose_MPISELL() in src/mat/impls/sell/mpi/mpisell.c


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