Next: , Previous: drop, Up: Composition functions identity-matrix

— Function: grid:identity-matrix dimension &optional scalar type element-type

A rank-two grid with the off-diagonals zero and the diagonal equal to scalar.

The function identity-matrix will create a matrix that has the same number on each element of the diagonal and zeros for other elements.
     ANTIK-USER> (identity-matrix 3 8.0d0)
     #2A((8.0 0.0 0.0) (0.0 8.0 0.0) (0.0 0.0 8.0))