Let p be given.
We prove the intermediate
claim HpRepl:
p ∈ Repl Y (λa ⇒ apply_fun f a).
An exact proof term for the current goal is Hp.
Let a be given.
rewrite the current goal using Heq (from left to right).
We prove the intermediate
claim Hid:
apply_fun idY a = a.
rewrite the current goal using Hfa (from left to right).
rewrite the current goal using Hc (from left to right).
rewrite the current goal using Hid (from left to right).
Let p be given.
We prove the intermediate
claim Hp0Sing:
(p 0) ∈ {x0}.
An
exact proof term for the current goal is
(ap0_Sigma {x0} (λ_ : set ⇒ Y) p Hp).
We prove the intermediate
claim Hp1Y:
(p 1) ∈ Y.
An
exact proof term for the current goal is
(ap1_Sigma {x0} (λ_ : set ⇒ Y) p Hp).
We prove the intermediate
claim Hp0eq:
(p 0) = x0.
An
exact proof term for the current goal is
(singleton_elem (p 0) x0 Hp0Sing).
We prove the intermediate
claim Heta:
p = (p 0,p 1).
An
exact proof term for the current goal is
(setprod_eta {x0} Y p Hp).
We prove the intermediate
claim Hid1:
apply_fun idY (p 1) = (p 1).
We prove the intermediate
claim Hfp1eq:
apply_fun f (p 1) = (p 0,p 1).
rewrite the current goal using Hfp1 (from left to right).
rewrite the current goal using Hc1 (from left to right).
rewrite the current goal using Hid1 (from left to right).
rewrite the current goal using Hp0eq (from right to left) at position 1.
Use reflexivity.
We prove the intermediate
claim Hp_as_image:
p = apply_fun f (p 1).
rewrite the current goal using Heta (from left to right) at position 1.
rewrite the current goal using Hfp1eq (from right to left).
Use reflexivity.
rewrite the current goal using Hp_as_image (from left to right).
An
exact proof term for the current goal is
(ReplI Y (λa : set ⇒ apply_fun f a) (p 1) Hp1Y).
∎