Not official documentation. This is an unofficial explainer of John N. Shutt's vau calculus. It is not written, reviewed or endorsed by John N. Shutt, Dale Schumacher, Mitchell Wand, or any author of the cited sources. An AI model (Claude) drafted the text and the Lean, and no person has reviewed them. The text may contain errors; the Lean statements are the ground truth for what is proved, and the cited sources are the ground truth for the theory.
The Lean covers the pure vau-x calculus (no delta-rules)
and a model of vau-e (environments,
$vau, derived
$lambda) with this project's additions (encapsulation types, an actor model). It does not formalize Shutt's general framework; confluence is proved directly for these concrete rules only.
Licence of this repository: MIT License . Cited works keep their own copyright; only short, attributed phrases are quoted.
# Reduction schemata and their compatible closure
The seven general schemata of vau-x (thesis (9.25)), with this project's names:
|-------------|-------------------------------------------------------------------|------------|
| eval-self | `[eval S] -> S` | (9.25S) |
| eval-pair | `[eval (T1 . T2)] -> [combine [eval T1] T2]` | (9.25p) |
| eval-wrap | `[eval <T>] -> <[eval T]>` | (9.25a) |
| beta-vau | `[combine <vau x.T> V] -> T[x <- V]` | (9.25beta) |
| combine-wrap| `[combine <T0> (T1 ... Tm)] -> [combine T0 ([eval T1] ... [eval Tm])]` | (9.25gamma) |
| parse-pair | `[combine <vau2.T0> (T1 . T2)] -> [combine [combine T0 T1] T2]` | (9.25vau2) |
| parse-nil | `[combine <vau0.T> ()] -> T` | (9.25vau0) |
The delta-rule schema (9.25delta) is left out: the set of delta-rules is empty here.
`Top` is the rules at the top of a term. `Step` is their compatible closure: a rule may fire at
any position, including inside operands and inside operative bodies. `Steps` is zero or more
steps, and `Conv` is the equational theory (the equivalence closure of `Step`).
/-- The seven general schemata, at the top of a term. -/
| evalPair (a b : Term ) : Top (eval (pair a b)) (comb (eval a) b)
| evalWrap (t : Term ) : Top (eval (wrap t)) (wrap (eval t))
| parsePair (t a b : Term ) : Top (comb (vau2 t) (pair a b)) (comb (comb t a) b)
| parseNil (t : Term ) : Top (comb (vau0 t) nil) t
/-- One step: the compatible closure of `Top`. -/
/-- Reflexive-transitive closure of a relation (defined here to avoid a Mathlib dependency). -/
inductive Star {X : Type } (r : X -> X -> Prop ) : X -> X -> Prop where ¶ plain English
| refl (t : X ) : Star r t t
| tail {a b c : X } : Star r a b -> r b c -> Star r a c
/-- Zero or more steps, `->*`. -/
/-- Equivalence closure of a relation. -/
inductive EqvGen {X : Type } (r : X -> X -> Prop ) : X -> X -> Prop where ¶ plain English
| rel {a b : X } : r a b -> EqvGen r a b
/-- The equational theory of vau-x: `T1 = T2` iff they are joined by a zigzag of steps. -/
variable {X Y : Type } {r : X -> X -> Prop }
theorem single {a b : X } (h : r a b) : Star r a b := .tail (.refl a) h¶ node
| tail _ hs ih => exact .tail ih hs
theorem head {a b c : X } (h1 : r a b) (h2 : Star r b c) : Star r a c := ¶ node
/-- A closure is preserved by any map that preserves single steps. -/
theorem map {r' : Y -> Y -> Prop } (f : X -> Y ) (hf : forall {a b}, r a b -> r' (f a) (f b))¶ node
{a b : X } (h : Star r a b) : Star r' (f a) (f b) := by
| tail _ hs ih => exact .tail ih (hf hs)
theorem mono {r' : X -> X -> Prop } (hr : forall {a b}, r a b -> Star r' a b) {a b : X }¶ node
| tail _ hs ih => exact trans ih (hr hs)
| tail _ hs ih => exact .trans ih (.rel hs)
/-! ## Congruence of `Steps` -/
Steps (.pair a b) (.pair a' b') :=
Steps (.comb a b) (.comb a' b') :=
/-! ## Contexts: `Step` is compatible -/
/-- One-hole contexts. Plugging does not rename: a context may capture free variables of the
term put into the hole, as contexts do in the thesis. -/
/-- Put a term into the hole of a context. -/
| .vau c, t => .vau (c.plug t)
| .vau0 c, t => .vau0 (c.plug t)
| .vau2 c, t => .vau2 (c.plug t)
| .wrap c, t => .wrap (c.plug t)
| .eval c, t => .eval (c.plug t)
| .pairL c b, t => .pair (c.plug t) b
| .pairR a c, t => .pair a (c.plug t)
| .combL c b, t => .comb (c.plug t) b
| .combR a c, t => .comb a (c.plug t)
/-- `Step` is compatible: a step inside any one-hole context is a step of the whole term. -/
| vau _ ih => exact .vau ih
| vau0 _ ih => exact .vau0 ih
| vau2 _ ih => exact .vau2 ih
| wrap _ ih => exact .wrap ih
| eval _ ih => exact .eval ih
| pairL _ b ih => exact .pairL b ih
| pairR a _ ih => exact .pairR a ih
| combL _ b ih => exact .combL b ih
| combR a _ ih => exact .combR a ih
/-- Conversely, every step is a top-level rule inside some one-hole context. So `Step` is the
smallest compatible relation that contains the rules. -/
| top h => exact Exists .intro Ctx .hole (Exists .intro _ (Exists .intro _ (And .intro h (And .intro rfl rfl))))
| vau _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .vau c) (by simpa [Ctx.plug ] using hc)
| vau0 _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .vau0 c) (by simpa [Ctx.plug ] using hc)
| vau2 _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .vau2 c) (by simpa [Ctx.plug ] using hc)
| wrap _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .wrap c) (by simpa [Ctx.plug ] using hc)
| eval _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .eval c) (by simpa [Ctx.plug ] using hc)
| pairL b _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .pairL c b) (by simpa [Ctx.plug ] using hc)
| pairR a _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .pairR a c) (by simpa [Ctx.plug ] using hc)
| combL b _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .combL c b) (by simpa [Ctx.plug ] using hc)
| combR a _ ih => exact ih.elim fun c hc => Exists .intro (Ctx .combR a c) (by simpa [Ctx.plug ] using hc)
| symm _ ih => exact .symm ih
| trans _ _ ih1 ih2 => exact .trans ih1 ih2
| tail _ hs ih => subst ih; exact absurd hs (hn _)
The vau calculus is the work of John N. Shutt (PhD thesis, WPI, 2010). This explainer and its Lean are unofficial and were drafted by Claude (AI); no person has reviewed them. The Lean statements are the ground truth for what is proved; the cited sources are the ground truth for the theory. Repository: tangentproofs/vau-calculus (MIT License). Part of the tangentproofs/vau-calculus index . Progress is stored only in this browser.
This is the verbatim Lean of tangentproofs/vau-calculus at commit 2e29dbf, reproduced under its licence (MIT License; licence text ). The plain-English pages are unofficial and may be wrong.