This is a small aside. While reading a paper by Grüner, Laue, and Meringer on generation by homomorphism they mentioned the Gale-Ryser (GR) theorem. As it turns out, this is a nice small theorem closely related to the better known Erdős-Gallai (EG).

So, GR says that given two partitions of an integer (

As with most mathematics, that's quite terse and full of terminology like 'dominates' : but it's relatively simple. Here is an example:

The partitions

Finally, the matrix can be interpreted as a bipartite graph as shown in the lower right panel. There is an edge between vertices (i, j) if there is a 1 in the cell for (i, j) in the matrix. It's quite hard to see the connections on a graph drawn like this, but it should be clear that there are only edges

There's a nice proof by Manfred Krause of the theorem, and a very readable slideshow on the relationship between GR and EG here called "Variations on the Erdos-Gallai" by Grant Cairns.

So, GR says that given two partitions of an integer (

*p*and*q)*there exists a (0, 1) matrix*A*iff*p**dominates*q*such that the row sum vector*r(A)*=*p*and the column sum vector*c(A)*=*q*.As with most mathematics, that's quite terse and full of terminology like 'dominates' : but it's relatively simple. Here is an example:

*p*and*q*are at the top left, they both sum to 10. Next,*p*is transposed to get*p**= [5, 4, 1] and this is compared to q at the bottom left. Since the sum at each point in the sequence is greater (or equal) for*p**than*q*, the former dominates. One possible matrix is at the top left with the row sum vector to the right, and the column sum vector below.Finally, the matrix can be interpreted as a bipartite graph as shown in the lower right panel. There is an edge between vertices (i, j) if there is a 1 in the cell for (i, j) in the matrix. It's quite hard to see the connections on a graph drawn like this, but it should be clear that there are only edges

*between*the two sets {0, 1, 2, 3} and {4, 5, 6, 7, 8} and not*within*these.There's a nice proof by Manfred Krause of the theorem, and a very readable slideshow on the relationship between GR and EG here called "Variations on the Erdos-Gallai" by Grant Cairns.

## Comments

I'm not sure about how this theorem will deal with a matrix like the sums are p = [0,0,3], q = [0,0,3]. I know that is not a valid (binary) matrix , but it seems that the theorem is telling me otherwise.

Can you help me with that?

Well, [0,0,3] is not a valid partition either. Another way to think about it is that such a sequence could never be the degree sequence of a simple connected graph, since two of the vertices would necessarily be disconnected since they have degree 0.