|
D.5.1.14 intmat_inverse
Procedure from library alexpoly.lib (see alexpoly_lib).
- Usage:
- intmat_inverse(M); intmat M
- Assume:
- M is a lower triangular integer matrix with diagonal entries 1 or -1
- Return:
- intmat, the inverse of M
Example:
| LIB "alexpoly.lib";
intmat M[5][5]=1,0,0,0,0,1,1,0,0,0,2,1,1,0,0,3,1,1,1,0,4,1,1,1,1 ;
intmat U=intmat_inverse(M);
print(U);
==> 1 0 0 0 0
==> -1 1 0 0 0
==> -1 -1 1 0 0
==> -1 0 -1 1 0
==> -1 0 0 -1 1
print(U*M);
==> 1 0 0 0 0
==> 0 1 0 0 0
==> 0 0 1 0 0
==> 0 0 0 1 0
==> 0 0 0 0 1
|
|