Minor fixes to combinatorial optimization