A procedure for finding the k-th power of a matrix
Branko Malesevic Faculty of Electrical Engineering University of Belgrade, Serbia malesh@EUnet.yu
Ivana Jovovic PhD student, Faculty of Mathematics University of Belgrade, Serbia ivana121@EUnet.yu
Introduction
This worksheet demonstrates the use of Maple in Linear Algebra.
We give a new procedure (PowerMatrix) in Maple for finding the k-th power of n-by-n square matrix A, in a symbolic form, for any positive integer k, k>=n. The algorithm is based on an application of Cayley-Hamilton theorem. We used the fact that the entries of the matrix A^k satisfy the same recurrence relation which is determined by the characteristic polynomial of the matrix A (see [1]). The order of these recurrences is n-d, where d is the lowest degree of the characteristic polynomial of the matrix A.
For non-singular matrices the procedure can be extended for k not only a positive integer.
Initialization
Procedure Definition
PowerMatrix
Input data are a square matrix A and a parameter k. Elements of the matrix A can be numbers and/or parameters. The parameter k can take numeric value or be a symbol. The output data is the k-th power of the matrix. The procedure PowerMatrix is as powerful as the procedure rsolve.
Examples
Example 1.
Example 2.
The example is from [4], page 272, exercise 19.
Example 3.
# Warning! In this example MatrixPower and MatrixFunction procedures cannot be done in real-time.
Example 4.
Replace ':' with ';' and see result!
The example is from [3], page 101.
Example 5. and Example 6.
Pay attention what happens for singular matrices.
Example 5.
The example is from [2], page 151, exercise 23.
Example 6.
References
[1] Branko Malesevic. Some combinatorial aspects of the composition of a set of functions. NSJOM., 2006 (36), 3-9. http://www.im.ns.ac.yu/NSJOM/Papers/36_1/NSJOM_36_1_003_009.pdf or http://arxiv.org/abs/math.CO/0409287 . [2] John B. Johnston, G. Baley Price, Fred S. Van Vleck. Linear Equations and Matrices. Addison-Wesley, 1966.
[3] Carl D. Meyer. Matrix Analysis and Applied Linear Algebra . SIAM, 2001.
[4] Robert Messer. Linear Algebra Gateway to Mathematics. New York: Harper-Collins College Publisher, 1993.
Conclusions
This procedure has an educational character. It is an interesting demonstration for finding the k-th power of a matrix in a symbolic form. Sometimes, it gives solutions in the better form than the existing procedure MatrixPower (see example 4.). See also example 5. and example 6., where we consider singular matrices. In these cases the procedure MatrixPower does not give a solution. The procedure PowerMatrix calculates the k-th power of any singular matrix. In some examples it is possible to get a solution in the better form with using the procedure allvalues (see example 3.).
Acknowledgment: Research partially supported by MNTRS, Serbia, Grant No. 144020.
Legal Notice: The copyright for this application is owned by the author(s). Neither Maplesoft nor the author are responsible for any errors contained within and are not liable for any damages resulting from the use of this material. This application is intended for non-commercial, non-profit use only. Contact the author for permission if you wish to use this application in for-profit activities.