  The graphical realization of a given degree sequence and given partition
adjacency matrix simultaneously is a relevant problem in data driven modeling
of networks. Here we formulate common generalizations of this problem and the
Exact Matching Problem, and solve them with an algebraic Monte-Carlo algorithm
that runs in polynomial time if the number of partition classes is bounded.
