Constraints

Constraints are sets of values that define a puzzle under investigation. They include a board, a set of pieces, and a list of true/false flags that define rules for the puzzle. Constraints are passed to a solver program that finds and records all solutions to a puzzle.

These are meant for tiling puzzles (use polycubes/polyominos to fill a footprint with no gaps or overlaps) and packing puzzles (pack a set of polycubes into a specified volume)

Constraint Type

Types of constraints:

Board and Piece Supply

The board is a list of coordinates that define a 2D or 3D space that will be filled by pieces.

The piece supply is the set of pieces that fill the board.

Constraint Flags

Constraint flags are true/false values defining rules for a puzzle. Here's a list of constraint flags and what they mean.

Gaps

Overflow: Pieces extending beyond their board's footprint.

Overhangs: where a piece (or part of a piece) is above a different piece or empty space.

Coloring: preventing similar pieces from being placed together. At most one of these can be true. If none of these are true and there are color restrictions enabled, all pieces get the same color.

Color-Based Restrictions: how close is allowed? If all of these are true, coloring has no effect.

Other Restrictions on how pieces meet:

Turning Pieces

Leftovers

Ideas for future constraints