Forming a new matrix by adding the same number to any row or column Say that two $m\times n$ matrices, where $m,n\ge 2$, are related if one can be obtained from the other after a finite number of steps, where at each step we add any real number to all elements of any one row or column. For example, $\left(\begin{array}{cc}
0 & 0\\0 & 0
\end{array}\right)$
and
$\left(\begin{array}{cc}
1 & 3\\0 & 2
\end{array}\right)$
are related since the latter can be obtained from the former by adding $1s$ to the first row, and then adding $2s$ to the second column.
Question What matrices are related to the $m\times n$ zero matrix? Also, given two related matrices, how can we determine the minimum number of steps to generate one from the other?

The motivation of this question is the transportation problem: it can be shown that transportation problems with related cost matrices have the same optimum solutions. (A matrix of nonnegative elements $(x_{ij})$ is feasible if $\sum_i x_{ij}=d_j$ and $\sum_j x_{ij}=s_i$ for some constants $d_j$ and $s_i$ with $\sum_j d_j=\sum_i s_i$, and is optimal if it minimises over all feasible matrices the sum $\sum_{i,j} x_{ij}c_{ij}$ for a given cost matrix $(c_{ij})$.) 
 A: Let $A_i$ be the matrix that has ones in the $i$-th row and zeroes everywhere else. Let $B_j$ be the matrix that has ones in the $j$-th column  and zeroes everywhere else. I believe that the set you are looking for is the linear shell of 
$$\{
A_1,A_2,\dots, A_m, B_1,B_2,\dots, B_n
\}.$$
A: After giving more thought, the question turned out a lot simpler than anticipated.

Claim A $m\times n$ matrix $\textbf{P}$ is related to the zero matrix of the same size iff its rows (or, equivalently, its columns) follow the same progression. That is, $P_{ij}-P_{i1}=P_{1j}-P_{11}\forall i,j$.
Proof Observe that row progression holds in the zero matrix. Also when adding a real number to all elements of any row or column of the matrix, row progression is retained. Hence the row of any matrix similar to the zero matrix must follow the same progression.
Conversely, suppose that the rows of $\textbf{P}$ follow the same progression. Then, we can add a real number to all elements of each row to make it each row equal to the first. The elements of each column are now all identical, so we can make them zero. Hence $\textbf{P}$ is related to the zero matrix.

This naturally describes an algorithm to make the zero matrix from a related matrix: make all the rows the same, then make the columns zero (this works for columns first then rows of course). This necessarily terminates in at most $m+n-1$ steps.
