I want to find solutions for the following problem. It seems to be a classic problem in integer programmimg and logistics, but I don't know its name.
Find a matrix of m rows and n columns, with non-negative entries, such that the sum of the entries in each row are, respectively, m given integers and the sum of the entries in each column are, also respectively, another n given integers.
Also, the entries will be limited to given maximum integers, and in some cases those entries will be 0.
In reality, I am interested in an algorithm for extracting all solutions (maybe I should ask in the Programming StackExchange if this is not the correct place). In the end, my goal is to find a solution which makes the maximum possible number of entries equal to zero.
This problem comes from allocating teachers (columns) for classes on days (rows) so that they come to work the least possible number of days (the non-zero entries).
Just to have a better idea of the sizes of each parameter: m=5, n=100, entries are bounded to 5 or 6, when not set to 0 from the beginning.