I have a matrix of the following form:
$$A=\begin{bmatrix} 2 & 0 & 0 & 0 \\-1 & 2 & 0 & 0\\ 0 & -1 & 2 & 0\\ 0 & 0 & -1 & 2 \end{bmatrix}$$
which, in general, can be any size with the pattern continued parallel the diagonal. (I didn't know how to show ellipsis in a matrix with LaTeX, feel free to edit if you know how).
I want to find an inverse for this matrix in general for any given size of the matrix. What should I do? I had thought of maybe splitting the matrix up into two matrices, one with all the diagonal terms and one with all the off-diagonal terms and finding the inverse of their sum but I didn't know if that would be helpful/possible.
Instead of using the matrix write it as linear transformation: so the given one is the matrix of $T$ satisfying $Te_i = 2e_i -e_{i+1}$ for $i<n$ and $Te_n = 2e_n$.
Now the inverse $S$ of this $T$ has to send the vectors in the rhs to those in the corresponding lhs. $S(2e_n) = e_n$ and so $ S(e_n) =\frac12e_n$. Then $S(2e_{n-1})= Se_n+e_{n-1}$ And so $Se_{n-1} = \frac12e_{n-1} +\frac12e_n$. Ths way you can work it out for any size without going through inverse calculation (though both are esentally the same).