taocp

This site has no text of the book. Keep your own copy of TAOCP next to it. See what is checked.

The code

The Lean code is in tamnd/taocp-lean. Its root namespace is TAOCP. It builds with Lean v4.36.0 and Mathlib v4.36.0.

Build

git clone https://github.com/tamnd/taocp-lean
cd taocp-lean
lake exe cache get
lake build

Layout

Path Content
TAOCP/Notation/ the notation of the book as thin names over Mathlib
TAOCP/Library/ the general results that many nodes use
TAOCP/Algorithm/ the algorithm model: Knuth's computational method and the knuth_algorithm elaborator
TAOCP/MIX/, TAOCP/MMIX/ the two machines and their program logic
TAOCP/Problems/ the statements of the exercises, pinned by hash
TAOCP/Solutions/ the proofs, kept apart from the statements
TAOCP/Fidelity/ the fidelity checks of each statement

Names

The statement of exercise 42 of Section 1.2.6 is TAOCP.S1_2_6.Ex42.statement. Its answer, when it has one, is TAOCP.S1_2_6.Ex42.answer, and its proof is TAOCP.S1_2_6.Ex42.solved. Spec 06 gives the full rules.

The source of this page. Markdown. Something is wrong? Report it.