Let X, n, e and x be given.
We prove the intermediate
claim HnNat:
nat_p n.
An
exact proof term for the current goal is
(omega_nat_p n HnO).
We prove the intermediate
claim HP0:
P 0.
rewrite the current goal using
(nat_primrec_0 0 step) (from left to right).
Apply andI to the current goal.
An
exact proof term for the current goal is
real_0.
We prove the intermediate
claim HPS:
∀m : set, nat_p m → P m → P (ordsucc m).
Let m be given.
Assume IH: P m.
We prove the intermediate
claim Hsub:
ordsucc m ⊆ n.
We prove the intermediate
claim HmInN:
m ∈ n.
An
exact proof term for the current goal is
(Hsub m (ordsuccI2 m)).
We prove the intermediate
claim HmInSuccN:
m ∈ ordsucc n.
An
exact proof term for the current goal is
(ordsuccI1 n m HmInN).
An exact proof term for the current goal is (IH HmInSuccN).
An exact proof term for the current goal is (HtermR m HmInN).
An exact proof term for the current goal is (Hterm0 m HmInN).
rewrite the current goal using
(nat_primrec_S 0 step m HmNat) (from left to right).
Apply andI to the current goal.
We prove the intermediate claim HPn: P n.
An
exact proof term for the current goal is
(nat_ind P HP0 HPS n HnNat).
We prove the intermediate
claim HnIn:
n ∈ ordsucc n.
An
exact proof term for the current goal is
(ordsuccI2 n).
An exact proof term for the current goal is (HPn HnIn).
∎