Efficient CNF Encoding for Selecting 1 from N Objects

In many boolean-satisfiability problems, one must encode the constraint that at most one of n propositional variables is true. With a naïve encoding, this requires O(n) CNF clauses. We present a flexible alternative encoding that only requires O(n) clauses, at the expense of O(n) extra variables. The proposed encoding technique also allows efficie nt encoding of canonicalordering constraints that can aid in the determinat io of unsatisfiable problem instances. Sample applications are given for the pi geon-hole problem and Sudoku puzzles.