Chain Constraints

Previous experiments proved CRT decomposition helps -- but any coprime moduli give similar results. This experiment asks: does THIS ring's specific structure (chain-constrained primes) outperform arbitrary coprimes of similar sizes?

The chain primes satisfy algebraic constraints: 3^2-2=7, 5*7=1 mod 17, 3^2+2=11. These relationships between the ring's seven primes create a tight web. Do they help prediction?

The Experiment

Same 471-character corpus, same tally-based bigram prediction, same majority-vote CRT reconstruction. Two sets of moduli:

RING: [8, 9, 25, 49, 11, 13, 17]. Product = 214,414,200. Chain-constrained primes with 6+ algebraic relationships.

RANDOM: [8, 9, 23, 47, 11, 13, 19]. Product = 211,469,544 (1.4% different). Same sizes, all coprime, no chain relationships. Four moduli shared (8, 9, 11, 13).

Results: No Advantage

Character-level accuracy: TIED at 172/470 (36.6%) for both ring and random. Channel-level score: ring 1341, random 1355 -- random wins by 14 (1.0%). The chain constraints provide no prediction advantage.

Ring accuracy
172/470 (36.6%)
Same as HDC baseline. Chain structure adds nothing to tally decoding.
Random accuracy
172/470 (36.6%)
TIED. Arbitrary coprimes of similar sizes match the ring.
Ring ch_score
1341/3290
Sum of per-channel correct predictions across 470 bigrams.
Random ch_score
1355/3290
Random wins by 14 (1.0%). Driven entirely by one channel.

Channel-Level Analysis

Four shared moduli (8, 9, 11, 13) produce IDENTICAL per-channel scores -- proving the experimental infrastructure is correct. The difference comes from three non-shared channels:

mod 25 vs mod 23
172 vs 192 (-20)
mod-23 (prime) beats mod-25 (5^2). Prime moduli have more uniform char distribution.
mod 49 vs mod 47
172 vs 172 (0)
Tied. Both near 49: similar collision patterns for 128 ASCII chars.
mod 17 vs mod 19
191 vs 185 (+6)
Ring's mod-17 wins. Smaller modulus = fewer residue classes = better statistics.
Shared channels
4/4 identical
mod 8, mod 9, mod 11, mod 13: same modulus = same prediction. Control verified.

4-Channel Reconstruction

Using only the first 4 channels ([8,9,25,49] for ring; [8,9,23,47] for random), reconstruct the full character. Products 88,200 and 77,832 both exceed 128, so both uniquely determine any ASCII character from 4 channels.

Ring 4ch
168/470
Channels [8,9,25,49] (product 88,200). 4-channel accuracy.
Random 4ch
164/470
Channels [8,9,23,47] (product 77,832). 4 fewer correct.
Advantage
+4 (marginal)
2.4% advantage, likely within statistical noise at n=470.

Why Chain Constraints Don't Help

Chain constraints (3^2-2=7, 5*7=1 mod 17) are relationships between PRIMES, not between element residues. For a character c, (c%25 * c%49) % 17 does NOT equal c%17 -- it fails for 118 of 128 characters. The constraints create the ring's algebraic identity but don't constrain individual elements.

For ASCII text (chars 0-127 in a ring of 214 million), the characters are far below the ring's scale. Any 3 channels with product > 128 uniquely determine the character. The chain's cross-channel redundancy is structurally present but statistically invisible at text scale.

CRT advantage = statistical tractability. It comes from the decomposition TECHNIQUE, not from this particular ring's chain structure. The ring's chain constraints may matter for ring-scale tasks (multiplicative structure, eigenvalue computation) but not for text prediction.

Source code · Public domain (CC0)

Report issue

.ax source compiled to WASM via self-hosting compiler. Zero HTML authored.