nx_folkgame_sow_gate.nx
buildroot/runtime/nx_folkgame_sow_gate.nx
about
nx_folkgame_sow_gate.nx -- GATE for the sow (mancala) family of nx_folkgame_sow_lib.
THE LOAD-BEARING TOOTH IS T8: seed conservation over an EXHAUSTIVE game tree. Sowing moves seeds
and never creates or destroys one, so the total must equal perside*2*seeds at EVERY node of the
tree, not at a sampled few. A sowing loop that is off by one anywhere -- a wrap that drops a seed,
a capture that adds one, a relay that re-sows a pit it already emptied -- breaks it at some node,
and no implementation can satisfy it across thousands of positions by accident.
HONEST SCOPE, STATED PLAINLY: this is an INVARIANT, not a published constant. Unlike the align
family's 255168 there is no cheap external number for these boards. Conservation proves the seeds
are handled correctly; it does NOT prove the capture rules match Oware as played. The external
anchor for that is OpenSpiel's Oware, graded THOROUGHLY-TESTED in its own table, and cross-checking
against it is the named open rung. A green here means the arithmetic is sound and says nothing
stronger.
T9 CARRIES THE ANTI-VACUITY: the conservation checker is proven able to FAIL by planting a seed
into a live position and asserting the total goes wrong. A checker that has only ever agreed has
not been shown to check anything.
license_tier: ORIGINAL No hw writes (Rule 26).
dependencies 2 imports · 0 importers
imports: nx_folkgame_sow_lib.nxnx_gate_verdict.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 21 | const FGG_SPEC: *u8 = "knowledge/compare/folkgames.sow" |
| 24 | const FGG_OWARE_CELLS: i64 = 12 |
| 25 | const FGG_OWARE_TOTAL: i64 = 48 |
| 26 | const FGG_OWARE_OPEN: i64 = 6 |
| 27 | const FGG_KALAH_CELLS: i64 = 14 |
| 28 | const FGG_CONGKAK_TOTAL: i64 = 98 |
| 29 | const FGG_PALLAN_TOTAL: i64 = 84 |
| 33 | const FGG_WALK_DEPTH: i64 = 6 |
functions
| 35 | func fgg_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n } called by 1: main |
| 38 | func fgg_walk(base: i64, snap: *i64, sw: i64, mvb: *i64, mm: i64, probe: *i64, d: i64, maxd: i64, bad: *i64) -> i64 |
| 57 | func fgg_open_moves(base: i64, probe: *i64) -> i64 |
| 65 | func main() -> i64 |