Last active
May 3, 2021 00:29
-
-
Save emarzion/64bb5aed6275482122afe7ce2d41615b to your computer and use it in GitHub Desktop.
Proof that sets with fixed-point operators is closed under binary products.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Definition FPO{X}(Y : (X -> X) -> X) := | |
forall f, f (Y f) = Y f. | |
Section FPOs. | |
Variables A B : Type. | |
Variable Y_A : (A -> A) -> A. | |
Variable Y_B : (B -> B) -> B. | |
Hypothesis Y_A_FPO : FPO Y_A. | |
Hypothesis Y_B_FPO : FPO Y_B. | |
Definition prod_FPO : (A * B -> A * B) -> A * B := | |
fun f => | |
let g : A -> B := | |
fun a => Y_B (fun b => snd (f (a,b))) in | |
let h : A -> A := | |
fun a => fst (f (a, g a)) in | |
let a : A := Y_A h in | |
(a, g a). | |
Lemma prod_FPO_correct : FPO prod_FPO. | |
Proof. | |
intro f. | |
apply injective_projections. | |
- unfold prod_FPO at 2; simpl. | |
rewrite <- Y_A_FPO. | |
reflexivity. | |
- unfold prod_FPO at 2; simpl. | |
rewrite <- Y_B_FPO. | |
reflexivity. | |
Qed. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment