Section hoas.
Definition mu' := Eval cbn -[enc] in rho (λ mu P n, (P n) (!!K n) (λ Sn, mu P Sn) (!!(ext S) n)).
End hoas.
unfold mu'; Lproc.
Qed.
Hint Resolve mu'_proc : LProc.
(* the mu combinator:*)
Definition mu :term := lam (mu' #0 (ext 0)).
unfold mu. Lproc.
Qed.
Hint Resolve mu_proc : LProc.

Lemma mu_sound v : lambda v -> mu P == v -> exists n, v = ext n /\ P (ext n) == ext true /\ (forall n', n' < n -> P (ext n') == ext false).