Simplified independence proof

This commit is contained in:
Niels 2017-09-01 16:56:49 +02:00
parent 40e1f45cfa
commit dfd590724b
1 changed files with 10 additions and 24 deletions

View File

@ -43,18 +43,11 @@ Section isIn.
Context `{Univalence}.
Context {HS : closedSingleton C} {HIn : forall X, C X -> forall a, Decidable (X a)}.
Theorem decidable_A_isIn : forall a b : A, Decidable (Trunc (-1) (b = a)).
Theorem decidable_A_isIn (a b : A) : Decidable (Trunc (-1) (b = a)).
Proof.
intros.
unfold Decidable, closedSingleton in *.
pose (HIn {|a|} (HS a) b).
destruct s.
- unfold singleton in t.
left.
apply t.
- right.
intro p.
unfold singleton in n.
destruct (HIn {|a|} (HS a) b).
- apply (inl t).
- refine (inr(fun p => _)).
strip_truncations.
contradiction (n (tr p)).
Defined.
@ -78,24 +71,17 @@ Section intersect.
{HI : closedIntersection C} {HE : closedEmpty C}
{HS : closedSingleton C} {HDE : hasDecidableEmpty C}.
Theorem decidable_A_intersect : forall a b : A, Decidable (Trunc (-1) (b = a)).
Theorem decidable_A_intersect (a b : A) : Decidable (Trunc (-1) (b = a)).
Proof.
intros.
unfold Decidable, closedEmpty, closedIntersection, closedSingleton, hasDecidableEmpty in *.
unfold Decidable.
pose (HI {|a|} {|b|} (HS a) (HS b)) as IntAB.
pose (HDE ({|a|} {|b|}) IntAB) as IntE.
refine (@Trunc_rec _ _ _ _ _ IntE) ; intros [p | p] ; unfold min_fun, singleton in p.
- right.
intro q.
refine (Trunc_rec _ IntE) ; intros [p | p].
- refine (inr(fun q => _)).
strip_truncations.
rewrite q in p.
enough (a ) as X.
{ apply X. }
rewrite <- p.
cbn.
split ; apply (tr idpath).
refine (transport (fun Z => a Z) p (tr idpath, tr q^)).
- strip_truncations.
destruct p as [a0 [t1 t2]].
destruct p as [? [t1 t2]].
strip_truncations.
apply (inl (tr (t2^ @ t1))).
Defined.