Find a formula for the powers of a matrix The matrix $A$ is $3 \times 3$, upper triangular with all entries equal to $1$. Find the formula for $A^n$.
What I have so far:
$A^n$ is $3 \times 3$, upper triangular, diagonal entries are $1$, and $$a_{12} = a_{23} = n.$$ I can't figure out the formula for the entry $a_{13}.$
Thank you.
Also if you don't mind, how do I prevent LaTeX symbols from skipping to a new line?
 A: We have
$A= I_3+B$, where
$$
B=\left(\begin{array}{rrr}0&1&1\\0&0&1\\0&0&0\end{array}\right)
$$
and hence
$$
B^2=\left(\begin{array}{rrr}0&0&1\\0&0&0\\0&0&0\end{array}\right)
$$
and $B^3=0$.
Because $B$ commutes with the identity matrix, the usual binomial theorem holds, and we get
$$
A^n=(I_3+B)^n=\sum_{k=0}^n{n\choose k}B^k=\sum_{k=0}^2{n\choose k}B^k
=I_3+{n\choose 1}B+{n\choose2}B^2.
$$
A: You mean
$$
A = \begin{bmatrix}
1&1&1\\
0&1&1\\
0&0&1
\end{bmatrix}?
$$
You may guess a formula for the $(1,3)$ coefficient of $A^{n}$, and then use induction. Say
$$
A^n = \begin{bmatrix}
1&n-1&a(n-1)\\
0&1&n-1\\
0&0&1
\end{bmatrix},
$$
then
$$
A^{n} = A^{n-1} \cdot A
=
\begin{bmatrix}
1&n&1+n-1+a(n-1)\\
0&1&n\\
0&0&1
\end{bmatrix}.
$$
So $a(1) = 1$ and $a(n) = a(n-1) + n$, which leads to
$$
a(n) = 1 + 2 + \dots + n = \frac{n(n+1)}{2}.
$$
A: Hint: remember that $\displaystyle \sum_{i=1}^n i = \frac{n(n+1)}{2}$
Now, what are we doing when we're successively multiplying $\left( \begin{array}{ccc} 1 & 1 & 1 \\ 0 & 1 & 1 \\ 0 & 0 & 1 \end{array} \right) \left( \begin{array}{ccc} 1 & n & f(n) \\ 0 & 1 & n \\ 0 & 0 & 1 \end{array} \right)$?  What happens to $f(n)$ to get to $f(n+1)$?
