Designer guide
Mathdoku Designer is an authoring tool: you carve a grid into cages while a solver re-checks the puzzle after every edit. This guide walks the workflow from a blank grid to a saved, publishable puzzle. New to the genre? Start with the puzzle rules.
Creating a puzzle
Choose File > New… and pick a grid size from 2×2 to 9×9. The Designer generates a random hidden solution — a Latin square — for the new puzzle. You never type cage targets yourself: as you draw cages, each target is computed from that solution, so every cage you commit is automatically consistent with at least one valid grid.
Candidate marks in every open cell show which values can still go there given the cages committed so far. As your cages accumulate constraints, the candidates narrow.
Building cages
Cage construction is keyboard-driven, directly on the grid:
- Arrow keys move the selection from cell to cell.
- Shift+Arrow extends a provisional cage from the selected cell, one neighbor at a time. A provisional cage is a sketch — it has a shape but no operator yet.
- Enter commits the provisional cage (or starts a single-cell cage on an uncovered cell) and opens the operator picker.
- Escape on a committed cage demotes it back to a provisional sketch so you can re-choose its operator; Delete removes it outright.
- Tab jumps between committed cages, and Cmd/Ctrl+Z undoes the last change.
Choosing operators
When you commit a cage, the operator picker shows one tab per operator that is valid for the cage's shape, each labeled with the target derived from the hidden solution — for example +9, ×20, or −1. Click a tab (or use the arrow keys and Enter, or type +, −, x, or /) to fix the cage's operation.
Operators that cannot produce a valid target for the cage are simply not offered: a division tab appears only when one of the two solution values exactly divides the other. Single-cell cages become givens — their value is shown outright, no operator symbol.
Checking solvability and uniqueness
The Designer re-solves the puzzle after every edit, and the results are always on screen:
- Candidate marks in each open cell show the values that can still legally go there. When a change eliminates candidates, the removed values flash so you can see what your edit accomplished.
- Cage statistics below the grid show, for the selected cage, how many viable multisets (value combinations) and tuples (ordered placements) remain — a direct readout of how constraining the cage is.
- The solution count appears below the grid once every cell is caged. 1 solution means the puzzle is fair and publishable; more than one means it needs further constraint. Because targets are derived from the hidden solution, the count can never reach zero — a Designer puzzle is always solvable.
Saving and exporting
File > Save (Cmd/Ctrl+S) writes the puzzle as a
.mathdoku file — a plain JSON document containing
the cage structure and the fixed solution. File > Save
As… writes a copy under a new name, and
File > Open… loads a previously saved
puzzle. The Designer reopens your most recent file on launch.
Because the format is plain JSON, a saved puzzle is also an export: it can be versioned in git, shared, or transformed by other tools. Note that the file includes the solution, so share accordingly.
The in-browser demo is ephemeral — it has no file system, so Save and Open are desktop-only. Install the desktop app to keep what you make.