D.3.1.9 power
.............
Procedure from library matrix.lib (see matrix_lib).

Usage:
power(A,n); A a square-matrix of type intmat or matrix, n=integer

Return:
intmat resp. matrix, the n-th power of A

Note:
for A=intmat and big n the result may be wrong because of int overflow

Example:
LIB "matrix.lib";
intmat A[3][3]=1,2,3,4,5,6,7,8,9;
print(power(A,3));"";
==>    468   576   684
==>   1062  1305  1548
==>   1656  2034  2412
==> 
ring r=0,(x,y,z),dp;
matrix B[3][3]=0,x,y,z,0,0,y,z,0;
print(power(B,3));"";
==> yz2,    xy2+x2z,y3+xyz,
==> y2z+xz2,yz2,    0,     
==> y3+xyz, y2z+xz2,yz2    
==> 

<font size="-1">
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; User manual for <a href="http://www.singular.uni-kl.de/"><i>Singular</i></a> version 2-0-4, October 2002,
generated by <a href="http://www.gnu.org/software/texinfo/"><i>texi2html</i></a>.
</font>

</body>
</html>
