Skip to content

Extract real-world BST model and pointer-machine simulation - #3

Merged
slef merged 1 commit into
mainfrom
real-world-bst-model
Nov 15, 2026
Merged

slef merged 1 commit into
mainfrom
real-world-bst-model

Conversation

@alby-bot

Copy link
Copy Markdown
Collaborator

This extracts the real-world BST foundation onto current main so the book can use it independently of the unfinished paper formalizations.

The semantic model has fixed finite control, bounded words and local node access, with separately charged machine time and BST operations. Its connection to the pinned CSLib Frontier Tarjan pointer machine proves all six parent-linked BST primitives and compiles an entire finite controller into one program. Successful requests taking T source steps take at most 19T + 3 target instructions; sequences cost at most 19T + 3m. The compiler preserves exact record count and uses fixed code and register counts.

Includes the public audited interfaces, four regression suites (represented trees, rotations, metadata, repeated requests and failed checks), and a Models chapter with links to the checked declarations. The existing CSLib/mathlib pins are unchanged; Frontier is pinned at 86efa56d47a44812fab049080fba87d7635db63b.

Scope: forward simulation assumes positive word width and an existing representation of a nonempty tree. Initial heap construction and its cost, source total service/proportional time, and the algorithm-specific Theorem 7 and ComboBST preservation proofs remain open. No unrelated finger-paper modules are included.

Validation:

  • lake build --wfail (library, regressions and abstract/axiom audits).
  • cd book && node scripts/extract.mjs && npm run check (declaration extraction, book build/lint, 30 tests, page checks).
  • git diff --check.

@slef
slef merged commit 380f988 into main Nov 15, 2026
6 checks passed
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.

2 participants