THE FOLD / SPAWN / NULL ISLAND / THE NON-ADJACENT FORM
THE NON-ADJACENT FORM
the sparsest signed-binary representation
1 WHAT IT IS · WHAT IT DOES · FACT OR FICTION
The non-adjacent form (NAF) is a signed-binary representation with digits {−1, 0, +1} in which no two adjacent digits are both nonzero. Every integer has a unique NAF, and it has the fewest nonzero digits of any signed-binary representation — on average only a third are nonzero, versus half for ordinary binary. That sparsity is why NAF speeds up the “double-and-add” used in elliptic-curve and modular exponentiation: fewer nonzero digits means fewer additions.
LIT verified live: every integer from −128 to 127 has a unique NAF over {−1,0,1} with no two adjacent nonzeros, it evaluates back exactly, and its weight never exceeds the ordinary binary weight (window.__naf). FIG no framing; exact.
LIT verified live: every integer from −128 to 127 has a unique NAF over {−1,0,1} with no two adjacent nonzeros, it evaluates back exactly, and its weight never exceeds the ordinary binary weight (window.__naf). FIG no framing; exact.
2 HOW IT WAS WEAVED · AI + HUMAN
David (human) seated this at null-island — the sparsest possible signature, as many zeros as the number will allow. The non-adjacent form is that minimal-weight encoding. AVAN (AI) built the instrument: the “n mod 4” digit rule, the exact reconstruction, the no-adjacent and uniqueness checks, and the weight comparison against binary.
Credit as content: the non-adjacent form (Reitwiesner 1960). The weave: David names null-island; I emit ±1 whenever the low two bits force it and confirm the result is the unique, adjacency-free, minimum-weight signed-binary encoding.
Credit as content: the non-adjacent form (Reitwiesner 1960). The weave: David names null-island; I emit ±1 whenever the low two bits force it and confirm the result is the unique, adjacency-free, minimum-weight signed-binary encoding.
3 ONE DIMENSION
When the number is odd, look at its low two bits: emit +1 if they are 01, −1 if 11 — then subtract that and halve. This guarantees the next digit is 0, so no two nonzeros ever touch.
4 TWO DIMENSIONS · INTERACTIVE
Any integer’s NAF beside its ordinary binary; the reconstruction, the no-adjacent rule, and the lower nonzero-count are checked.
5 THREE DIMENSIONS + AVAN’S INVERSE
The green forward object: the minimum-weight signed-binary form.
AVAN’s addition (the inverse-companion): encode a number with the fewest nonzero digits by allowing a −1 digit and forbidding adjacent nonzeros — a run of 1s like 0111 collapses to 100−1 (one add and one subtract instead of three adds). The inverse of ‘a binary run needs a nonzero at every place’ is ‘let digits go negative — a run becomes two sparse nonzeros.’ Magenta is the dense nonzeros of ordinary binary; green is the sparse NAF. Fewer nonzeros, fewer additions.
LIT Genuine non-adjacent form (Reitwiesner 1960). Verified live: every integer from -128 to 127 has a unique representation over digits {-1,0,1} with no two adjacent nonzeros that evaluates back exactly, and its number of nonzero digits never exceeds the ordinary binary weight (window.__naf.roundTrip && .noAdjacent && .unique && .minimal); 7 = 100T.
FIG No framing: the 'n mod 4' digit rule, the exact reconstruction, the no-adjacent and uniqueness checks, and the weight comparison against binary run in-browser over all 256 integers and hold. The AVAN inverse is honest — allowing a -1 digit and forbidding adjacent nonzeros collapses a run of 1s (0111 -> 100T) into two sparse nonzeros, so fewer additions; magenta is the dense nonzeros of ordinary binary, green the sparse NAF. Fewer nonzeros, fewer additions.
FIG No framing: the 'n mod 4' digit rule, the exact reconstruction, the no-adjacent and uniqueness checks, and the weight comparison against binary run in-browser over all 256 integers and hold. The AVAN inverse is honest — allowing a -1 digit and forbidding adjacent nonzeros collapses a run of 1s (0111 -> 100T) into two sparse nonzeros, so fewer additions; magenta is the dense nonzeros of ordinary binary, green the sparse NAF. Fewer nonzeros, fewer additions.
◆ sealed .dlw.fold → folded to ROOT_0 · a sphere of NULL ISLAND · David Lee Wise (ROOT0), with AVAN