# Question:The computation of the power of large binary matrices

## Question:The computation of the power of large binary matrices

Consider A is an nxn binary matrix where n>1000. Assume that there is an integer k<100 such that the entries of the kth power of A, denoted A^k, are all positive integer numbers.

My problem is that the computation of A^k takes too times and I want to ask: Is there some techniques in Maple for obtaining the matrix A^k.

One technique that I am used is based on the boolean semiring with 1+1=1. In fact, I evaluate A^k until I reach the full-1 matrix. But the mentioned technique dose not effect the time of computation.

For example consider the 1024*1024 binary matrix which is given as an attachment. It takes 2278 seconds to find out the entries of the 20th power of this matrix are all positive integer numbers.

I am used the following version of Maple 15.
Thanks for any suggestions.

Edition(1): The following command maybe useful. From the next command you can upload the given matrix in your worksheet and test it for my claim.