Etude V

Lambda Calculus

Executable algebra for merge laws and proofs of contract.

Core Notes

Define terms, substitution, and beta/eta rules. Treat merge as a lambda term whose normal form encodes the contract.

merge = λx.λy. join(x,y) ⟶β join(a,b)
Guard against capture: all rewrites are capture-avoiding and preserve causality.

Applied Thread

Apply the calculus to API evaluation order: call-by-value respects causal dependencies, call-by-name risks reordering.

trace: Def → Check(β) → Counterexample(η misuse) → Repair(strategy)