up previous next
IsDiagonal

checks if a matrix is diagonal
Syntax
          
IsDiagonal(M: MAT): BOOL

          

Description
This function tests whether the square matrix M is diagonal.

Example
  M := Mat([
           [0, 1, 2],
           [-1, 0, 3],
           [-2, -3, 0]
           ]);
  IsDiagonal(M);
False
-------------------------------


See Also