# Computing A^k

Printable View

• Sep 19th 2011, 11:32 AM
farmeruser1
Computing A^k
So it gives me this matrix
$A=\left(\begin{matrix} -1 &0 &1\\5 &3 &2\\6 &0 &4\end{matrix}\right)$
And asks me to compute A^k, where k is any positive integer.
I know I have to use to eigenvectors which I found to be this matrix:
$P=\left(\begin{matrix} -5 &0 &2\\3 &1 &17\\5 &0 &12\end{matrix}\right)$
and the diagonal matrix made out of the eigenvalues:
$D=\left(\begin{matrix} -2 &0 &0\\0 &3 &0\\0 &0 &5\end{matrix}\right)$
Now I know A^k=P*D^k*P^-1 but when I do this I just get something really messy,
Any help will be appreciated.
• Sep 19th 2011, 12:12 PM
FernandoRevilla
Re: Computing A^k
Quote:

Originally Posted by farmeruser1
Now I know A^k=P*D^k*P^-1 but when I do this I just get something really messy. Any help will be appreciated.

Firstly check if $P^{-1}AP=D$ or equivalently if $AP=PD$ .
• Sep 19th 2011, 12:19 PM
farmeruser1
Re: Computing A^k
I have checked and yes they give the same answer. It is from there I do not know what to do.
• Sep 19th 2011, 12:36 PM
FernandoRevilla
Re: Computing A^k
Quote:

Originally Posted by farmeruser1
I have checked and yes they give the same answer. It is from there I do not know what to do.

What is the problem? $A^k=P\textrm{diag}((-2)^k,3^k,5^k)P^{-1}=\ldots$ (only computations).
• Sep 19th 2011, 12:39 PM
Opalg
Re: Computing A^k
Quote:

Originally Posted by farmeruser1
So it gives me this matrix
$A=\left(\begin{matrix} -1 &0 &1\\5 &3 &2\\6 &0 &4\end{matrix}\right)$
And asks me to compute A^k, where k is any positive integer.
I know I have to use to eigenvectors which I found to be this matrix:
$P=\left(\begin{matrix} -5 &0 &2\\3 &1 &17\\5 &0 &12\end{matrix}\right)$
and the diagonal matrix made out of the eigenvalues:
$D=\left(\begin{matrix} -2 &0 &0\\0 &3 &0\\0 &0 &5\end{matrix}\right)$
Now I know A^k=P*D^k*P^-1 but when I do this I just get something really messy,
Any help will be appreciated.

Not that messy really. For $D^k$, just write it as $\begin{bmatrix} (-2)^k &0 &0\\0 &3^k &0\\0 &0 &5^k\end{bmatrix}.$ Then you have to find the inverse of P. Again, that should not be too hard, except that the entries will be fractions (with denominator 70). Finally, it's straightforward to multiply the three matrices together.
• Sep 19th 2011, 01:00 PM
farmeruser1
Re: Computing A^k
So I just computed D^k(P^-1), and as you can see its getting pretty messy, am I doing it a long way?
A^k= P* $D^k(P^-1)=\left(\begin{matrix} (-2^k)(-6/35) &0 &(-2^k)(1/35)\\(3^k)(-7/10) &3^k &(3^k)(-13/10)\\(5^k)(1/14) &0 &(5^k)(1/14)\end{matrix}\right)$
*So that matrix is just D^k*P^-1, I still have to multiply it by P.
• Sep 19th 2011, 01:09 PM
Opalg
Re: Computing A^k
Quote:

Originally Posted by farmeruser1
So I just computed D^k(P^-1), and as you can see its getting pretty messy, am I doing it a long way?
A^k= P* $D^k(P^-1)=\left(\begin{matrix} (-2^k)(-6/35) &0 &(-2^k)(1/35)\\(3^k)(-7/10) &3^k &(3^k)(-13/10)\\(5^k)(1/14) &0 &(5^k)(1/14)\end{matrix}\right)$
*So that matrix is just D^k*P^-1, I still have to multiply it by P.

Well Mr Farmeruser, sometimes a farmer just has to put his boots on and get muddy. Keep going, you're doing it correctly.
• Sep 19th 2011, 02:51 PM
FernandoRevilla
Re: Computing A^k
Another way: using the euclidean division, $x^k=c(x)(x+2)(x-3)(x-5)+ax^2+bx +c\;\;[1]$ . Using the Cayley-Hamilton theorem, $A^k=aA^2+bA+cI\;\;[2]$ . Substituting $x$ by $-2,3,5$ in $[1]$ we get the system

$\begin{Bmatrix}4a-2b+c=(-2)^k\\ 9a+3b+c=3^k\\25a+5b+c=5^k\end{matrix}\;\;[3]$

Solving $[3]$ and substituting in $[2]$ we get $A^k$ . This is not necessarily a faster method but has the advantage that is also valid for non diagonalizable matrices (differentiating [1] conveniently).