Introduction:
Define a "Bit Map" to be a matrix whose entries can only be $0$ or $1$. Then numbers above and beside each column and row indicates how many entries are "filled" with a one.
For example consider,
$$ \begin{array}{c|lcr} & 2 & 2 & 2 \\ \hline 2 & 1 & 0 & 1 \\ 1 & 0 & 1 & 0 \\ 3 & 1 & 1 & 1 \end{array} $$
The $3$ by $3$ matrix depicted above, consists of zeros and ones, and the numbers outside tell you how many ones are in each row/column.
The real problem is finding the solution when all that is given is the above numbers, the number of ones in each column and row, and none of the binary entries are given. Keep in mind, that the inverse solution is NOT unique. Although, there are some interesting symmetries.
Conjecture:
The method to solve for the binary entries given the number of ones in each row and column is layed out as follows. Each entry is assigned a value according to $$g(r,c,i)={{x_c \cdot y_r} \over {o_c \cdot o_r}}$$
where
$r$ is the row number
$c$ is the column number
$i$ is the iteration number which starts at 0
$g(r,c,i)$ is the entry in the $r$th row & the $c$th column at iteration $i$
$x_c(0)$ is the number of entries in the column that can be filled.
$x_c(i)$ is the number of entries in the column that can still be filled.
$y_r(0)$ is the number of entries in the row that can be filled.
$y_r(i)$ is the number of entries in the row that can be filled.
$o_r$ & $o_c$ represent the number of rows and columns in the matrix.
To create the solution to this inverse problem, these steps must be followed. The iteration starts at $i=1$ and all entries in the matrix are undetermined.
(1) Find the maximum $g(r,c,i)$ in the matrix and denote it by $M_i$ fill it's entry to $1$. Denote the row and column it was found in by $m_r$ and $m_c$. Since there will be more than one maximum, pick one at random to proceed.
(2) Take $m_r$ and $m_c$ to use in the next equations.
$$o_r(i+1)=o_r(i)-1$$ $$o_c(i+1)=o_c(i)-1$$ $$x_c(i+1)=x_r(i)-1$$ $$y_r(i+1)=y_r(i)-1$$
(3)
If $o_r(i+1)$ or $o_c(i+1)$ is zero, all g(r,c) must be recalculated. If not, then calculate $g(m_r,m_c,i+1)$ and for the other entries set $g(r,c,i+1)=g(r,c,i)$
(4) If $\sum_c x_c(i)$ or $\sum_r y_r(i)$ equals $\sum_c x_c$ or $\sum_r y_r$ then we are done, fill the other entries with $0$. Otherwise, The iteration is now at $i+1$ move on to $i+2$
Interpretation and Proof
How does one interpret $g$? And how does on prove that this method indeed provides a solution to the problem?
I've noticed that the sum of the $g$ is of the form.... $$\sum g = {{(\sum_c x_c) \cdot (\sum_r y_r)} \over {o_c \cdot o_r}}$$ which may or may not have an interpretation.
As far as the proof is concerned. There is some rough multiplications of probability going on here, which may indicate some kind of convolution of discrete measures perhaps?
I know this is a long post, so there may be typographical errors, feel free to point them out. Also feel free to provide an example of the algorithm failing.
Your problem reminds me of an error detection and correction problem:
A $n^2$ bits message protected by $2n$ bits of redundancy.
The problem is that you can not reconstruct arbitrary messages with that much redundancy, I believe.