DiagMat -- matrix with given diagonal |
Syntax |
DiagMat(L: LIST): MAT DiagMat(R: RING, L: LIST): MAT |
Description |
Example |
/**/ DiagMat([3,4,5]); matrix(QQ, [ [3, 0, 0], [0, 4, 0], [0, 0, 5] ]) /**/ DiagMat(ZZ,[5,6,7]); matrix(ZZ, [ [5, 0, 0], [0, 6, 0], [0, 0, 7] ]) |
See Also |