Solve a recursion equation $T(m,n) = T(m+1, n-1) + T(m, n-1)$ $$T(m,n) = T(m+1, n-1) + T(m, n-1)$$
What's the solution of $T(m,n)$? especially, there is a boundary condition $T(k,1) = k $, how to solve it?
I meet this equation when I want to solve a combinatorics problem. I don't have knowledge of how to solve a recursion equation like this. 
 A: The recurrence relation given is
$$T(m,n) = T(m+1, n-1) + T(m, n-1) \tag{1}\label{eq1}$$
with a boundary condition of
$$T(k,1) = k \tag{2}\label{eq2}$$
The first thing I would do is calculate the first few values to see if there's a pattern. 
$$T(k, 2) = T(k + 1, 1) + T(k, 1) = (k + 1) + k = 2k + 1 \tag{3}\label{eq3}$$
$$T(k, 3) = T(k + 1, 2) + T(k, 2) = (2(k + 1) + 1) + (2k + 1) = 4k + 4 \tag{4}\label{eq4}$$
$$T(k, 4) = T(k + 1, 3) + T(k, 3) = (4(k + 1) + 4) + (4k + 4) = 8k + 12 \tag{5}\label{eq5}$$
From just these first few values, it should be fairly clear the coefficient of $k$ in each next value is a power of $2$, in particular for $T(k,i)$ it's $2^{i-1}$. As for the constant term, note that in \eqref{eq2} it's $0$, which is $0$ times $1$. Next, in \eqref{eq3} it's $1$, which is $\frac{1}{2}$ times $2$. For \eqref{eq4} it's $4$, which $1$ times $4$. Finally, for \eqref{eq5} it's $12$, which is $\frac{3}{2}$ times $8$. As you can see, each constant is a multiple of the coefficient of $k$, with this multiple increasing by $\frac{1}{2}$ each time, so for $T(k,i)$, it's $\left(\frac{i-1}{2}\right)2^{i-1} = (i-1)2^{i-2}$. Putting these together, and changing $k,i$ to $m,n$, gives
$$T(m,n) = 2^{n-1}m + (n-1)2^{n-2} \tag{6}\label{eq6}$$
To prove this, you can use any $m$ and induction on $n$. First, note that for $n = 1$, \eqref{eq6} gives $T(m,1) = 2^{0}m + (1-1)2^{-1} = m$, which is true based on the boundary condition given in \eqref{eq2}. Next, assume \eqref{eq6} is true for some $n = j \ge 1$. For $n = j + 1$, \eqref{eq1} gives
\begin{align}
T(m, j + 1) & = T(m + 1, j) + T(m, j) \\
& = (2^{j-1}(m + 1) + (j-1)2^{j-2}) + (2^{j-1}m + (j-1)2^{j-2}) \\
& = (2^{j-1} + 2^{j-1})m + 2^{j-1} + 2(j-1)2^{j-2} \\
& = 2^j m + 2^{j-1} + (j - 1)2^{j-1} \\
& = 2^j m + (1 + j - 1)2^{j-1} \\
& = 2^j m + j2^{j-1} \tag{7}\label{eq7}
\end{align}
As \eqref{eq6} gives $T(m,j+1) = 2^j m + j2^{j-1}$, this matches \eqref{eq7}, thus completing the induction step. This proves by induction that \eqref{eq6} is the formula you're looking for.
