Require Export GeoCoq.Elements.OriginalProofs.lemma_parallelsymmetric.
Require Export GeoCoq.Elements.OriginalProofs.proposition_29.

Section Euclid.

Context `{Ax:euclidean_euclidean}.

Lemma proposition_30A : 
   forall A B C D E F G H K, 
   Par A B E F -> Par C D E F -> BetS G H K -> BetS A G B -> BetS E H F -> BetS C K D -> TS A G H F -> TS F H K C ->
   Par A B C D.
Proof.
(* Goal: forall (A B C D E F G H K : @Point Ax0) (_ : @Par Ax0 A B E F) (_ : @Par Ax0 C D E F) (_ : @BetS Ax0 G H K) (_ : @BetS Ax0 A G B) (_ : @BetS Ax0 E H F) (_ : @BetS Ax0 C K D) (_ : @TS Ax0 A G H F) (_ : @TS Ax0 F H K C), @Par Ax0 A B C D *)
intros.
(* Goal: @Par Ax0 A B C D *)
assert (Par E F C D) by (conclude lemma_parallelsymmetric).
(* Goal: @Par Ax0 A B C D *)
assert (neq G H) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq H G) by (conclude lemma_inequalitysymmetric).
let Tf:=fresh in
assert (Tf:exists P, (BetS H G P /\ Cong G P G H)) by (conclude lemma_extension);destruct Tf as [P];spliter.
(* Goal: @Par Ax0 A B C D *)
assert (BetS P G H) by (conclude axiom_betweennesssymmetry).
(* Goal: @Par Ax0 A B C D *)
assert (BetS P G K) by (conclude lemma_3_7b).
let Tf:=fresh in
assert (Tf:exists M, (BetS A M F /\ Col G H M /\ nCol G H A)) by (conclude_def TS );destruct Tf as [M];spliter.
let Tf:=fresh in
assert (Tf:exists N, (BetS F N C /\ Col H K N /\ nCol H K F)) by (conclude_def TS );destruct Tf as [N];spliter.
(* Goal: @Par Ax0 A B C D *)
assert (~ Meet C D E F) by (conclude_def Par ).
(* Goal: @Par Ax0 A B C D *)
assert (nCol G H A) by (conclude_def TS ).
(* Goal: @Par Ax0 A B C D *)
assert (neq A G) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq G A) by (conclude lemma_inequalitysymmetric).
(* Goal: @Par Ax0 A B C D *)
assert (neq G H) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (nCol A G H) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (CongA A G H G H F) by (conclude (proposition_29 A B E F P G H)).
(* Goal: @Par Ax0 A B C D *)
assert (eq A A) by (conclude cn_equalityreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (Out G A A) by (conclude lemma_ray4).
(* Goal: @Par Ax0 A B C D *)
assert (Out G H K) by (conclude lemma_ray4).
(* Goal: @Par Ax0 A B C D *)
assert (CongA A G H A G H) by (conclude lemma_equalanglesreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (CongA A G H A G K) by (conclude lemma_equalangleshelper).
(* Goal: @Par Ax0 A B C D *)
assert (CongA A G K A G H) by (conclude lemma_equalanglessymmetric).
(* Goal: @Par Ax0 A B C D *)
assert (CongA A G K G H F) by (conclude lemma_equalanglestransitive).
(* Goal: @Par Ax0 A B C D *)
assert (BetS C N F) by (conclude axiom_betweennesssymmetry).
(* Goal: @Par Ax0 A B C D *)
assert (eq H H) by (conclude cn_equalityreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (nCol F H K) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col E H F) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (Col F H E) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col F H H) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq E H) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (nCol E H K) by (conclude lemma_NChelper).
(* Goal: @Par Ax0 A B C D *)
assert (Col E H F) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (Col E H H) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq H F) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq F H) by (conclude lemma_inequalitysymmetric).
(* Goal: @Par Ax0 A B C D *)
assert (nCol F H K) by (conclude lemma_NChelper).
(* Goal: @Par Ax0 A B C D *)
assert (nCol H K F) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (eq H H) by (conclude cn_equalityreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (Col H K H) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (Col K H N) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col C K D) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (Col E H F) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq C K) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq C D) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq H F) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq E F) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (BetS K N H) by (conclude lemma_collinearbetween).
(* Goal: @Par Ax0 A B C D *)
assert (neq N H) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq H N) by (conclude lemma_inequalitysymmetric).
(* Goal: @Par Ax0 A B C D *)
assert (nCol H N F) by (conclude lemma_NChelper).
(* Goal: @Par Ax0 A B C D *)
assert (nCol F N H) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (BetS F N C) by (conclude axiom_betweennesssymmetry).
(* Goal: @Par Ax0 A B C D *)
assert (Col F N C) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (eq N N) by (conclude cn_equalityreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (Col F N N) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq C N) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (nCol C N H) by (conclude lemma_NChelper).
(* Goal: @Par Ax0 A B C D *)
assert (nCol H N C) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (BetS H N K) by (conclude axiom_betweennesssymmetry).
(* Goal: @Par Ax0 A B C D *)
assert (Col H N K) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (Col H N H) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq H K) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (nCol H K C) by (conclude lemma_NChelper).
(* Goal: @Par Ax0 A B C D *)
assert (nCol H K E) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (OS E C H K) by (conclude_def OS ).
(* Goal: @Par Ax0 A B C D *)
assert (eq K K) by (conclude cn_equalityreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (Col H K K) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (TS C H K D) by (conclude_def TS ).
(* Goal: @Par Ax0 A B C D *)
assert (TS E H K D) by (conclude lemma_planeseparation).
(* Goal: @Par Ax0 A B C D *)
assert (CongA G H F H K D) by (conclude proposition_29).
(* Goal: @Par Ax0 A B C D *)
assert (nCol C K H) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col C K D) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (eq K K) by (conclude cn_equalityreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (Col C K K) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq K D) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (neq D K) by (conclude lemma_inequalitysymmetric).
(* Goal: @Par Ax0 A B C D *)
assert (nCol D K H) by (conclude lemma_NChelper).
(* Goal: @Par Ax0 A B C D *)
assert (nCol H K D) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (CongA H K D H K D) by (conclude lemma_equalanglesreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (eq D D) by (conclude cn_equalityreflexive).
(* Goal: @Par Ax0 A B C D *)
assert (Out K D D) by (conclude lemma_ray4).
(* Goal: @Par Ax0 A B C D *)
assert (BetS K H G) by (conclude axiom_betweennesssymmetry).
(* Goal: @Par Ax0 A B C D *)
assert (neq K H) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (Out K H G) by (conclude lemma_ray4).
(* Goal: @Par Ax0 A B C D *)
assert (CongA H K D G K D) by (conclude lemma_equalangleshelper).
(* Goal: @Par Ax0 A B C D *)
assert (CongA G H F G K D) by (conclude lemma_equalanglestransitive).
(* Goal: @Par Ax0 A B C D *)
assert (CongA A G K G K D) by (conclude lemma_equalanglestransitive).
(* Goal: @Par Ax0 A B C D *)
assert (Col G H K) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq G H) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (Col H M K) by (conclude lemma_collinear4).
(* Goal: @Par Ax0 A B C D *)
assert (Col H K M) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col H K G) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (neq H K) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (Col K M G) by (conclude lemma_collinear4).
(* Goal: @Par Ax0 A B C D *)
assert (Col G K M) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col H K G) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col K N G) by (conclude lemma_collinear4).
(* Goal: @Par Ax0 A B C D *)
assert (Col G K N) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (nCol A G K) by (conclude lemma_equalanglesNC).
(* Goal: @Par Ax0 A B C D *)
assert (nCol G K A) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (nCol H K C) by (forward_using lemma_NCorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col H K G) by (forward_using lemma_collinearorder).
(* Goal: @Par Ax0 A B C D *)
assert (Col H K K) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (neq G K) by (forward_using lemma_betweennotequal).
(* Goal: @Par Ax0 A B C D *)
assert (nCol G K C) by (conclude lemma_NChelper).
(* Goal: @Par Ax0 A B C D *)
assert (OS A C G K) by (conclude_def OS ).
(* Goal: @Par Ax0 A B C D *)
assert (Col G K K) by (conclude_def Col ).
(* Goal: @Par Ax0 A B C D *)
assert (TS C G K D) by (conclude_def TS ).
(* Goal: @Par Ax0 A B C D *)
assert (TS A G K D) by (conclude lemma_planeseparation).
(* Goal: @Par Ax0 A B C D *)
assert (Par A B C D) by (conclude proposition_27).
(* Goal: @Par Ax0 A B C D *)
close.
Qed.

End Euclid.


