Skip to content

[Lean] Write prepared XOR into an existing paired tape block - #1933

Draft
jamesyc wants to merge 1 commit into
CrocSwap:mainfrom
jamesyc:lean-prepared-xor-writeback
Draft

jamesyc wants to merge 1 commit into
CrocSwap:mainfrom
jamesyc:lean-prepared-xor-writeback

Conversation

@jamesyc

@jamesyc jamesyc commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

Coverage

Explicit author-checked context: upstream main 0b1cccf; kappa = 836330098538459/500000000000000000 = 0.001672660197076918. These generic machines do not establish or change the selected exponent.

Two unchanged checked modules implement finite-symbol target-track writeback and connect the actual prepared XOR output through one charged controller transition. The destination's other track and all four original/work tapes are retained.

Finite coverage: arbitrary equal-width paired source/destination blocks, including zero width. The primitive returns both heads and clears scratch in exactly 7n+9 transitions with at most 2n+4 represented cells. The six-tape prepared pipeline has genuine first halt at most 25n+34, n=max input widths; actual entrance volume V gives time at most 25V and every-prefix cells at most 73V.

Conditional-interface coverage: supplied encoded Boolean words, marked existing destination of exactly the required capacity, pristine preparation workspaces and reached isolated slot entrance. Destination target bits and incoming scratch are overwritten/cleared, not reversibly restored. No allocation or key lookup is silently supplied.

Full-theorem coverage: ambient packed-slot access/framing, operand-field representation, resizing, dirty history restoration, recursive accounting and the full selected multiplication/runtime theorem remain open. Finite-alphabet represented cells are not a free arbitrary-integer encoding.

Evidence and reproduction

Twelve standard-only axiom probes and four complete printed types were accepted by local Lean 4.21.0 checks and independent source/terminal reviews, without diagnostics. The public manifest binds exact source bytes, theorem scopes and prerequisite hashes. REPRODUCE.md contains prospective fresh-scratch commands. No extra local CI preflight, relocated replay, installer or archive build was run for submission.

Reuse ten unchanged public prerequisites without copying them: PR1921 at 69fefa9, PR1840 at 3f1b064, and PR488 at 34eb901. Historical PR488 context and its existing deprecation warnings remain provenance.

Bounded overlap and attribution

PR565 at 890b290 compacts/copies a counter into pristine output. PR488 prepares work copies, and PR1921 produces a fresh paired XOR block. This chunk writes one track of an existing paired block while retaining the other and charges the enclosing handoff. No first-copy, global novelty or optimality claim is made. OVERLAP.json records the bounded comparison.

James Chang with OpenAI assistance; Apache-2.0. Existing source notices, prerequisite credits and Lean core attribution are retained.

Two checked reusable writeback modules with public prerequisites.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant