Given a $m\times n$ matrix of non-negative integers. A "reduction" of this matrix can be done on one row/column of this matrix, by subtracting the minimum of the row/column from all other numbers of that row/column. For example,
$$ \begin{bmatrix} 29 & 19 & 17 & 12 \\ 32 & 30 & 26 & 28 \\ 3 & 21 & 7 & 9 \\ 18 & 13 & 10 & 15 \end{bmatrix} $$
can be "reduced" on the second row by subtracting 26 from all four numbers, resulting in
$$ \begin{bmatrix} 29 & 19 & 17 & 12 \\ 6 & 4 & 0 & 2 \\ 3 & 21 & 7 & 9 \\ 18 & 13 & 10 & 15 \end{bmatrix} $$
Such reduction can be repeatedly done on every row/column, and the result is always still a non-negative integer matrix. On the other hand, each row/column can be effectively reduced only once, because subsequent reductions end up subtracting 0 and do not change the matrix.
Hence, reduce each row and column once in any order, and the matrix is completely reduced. The question is: consider the sum of numbers in the final matrix, what is the minimum of this sum, among all possible completely reduced matrices? Further, how do we find out an ordering of reductions that achieves the minimum?
The order of reduction does affect the sum of numbers in the final matrix. For the matrix above, reducing [row 1, row 2, row 3, row 4, col 2] gives a sum of 73, while reducing [col 1, col 2, col 3, col 4, row 1, row 2] gives a sum of 81.
I am interested in an (efficient) algorithm that solves this problem (or better still, if there exists a closed form of the minimum). One can always brute-force through all $(m+n)!$ ordering of reductions and find the minimum, but that would be quite uninteresting.