(***************************************************************************)
(* Formalization of the Chou, Gao and Zhang's decision procedure.          *)
(* Julien Narboux (Julien@narboux.fr)                                      *)
(* LIX/INRIA FUTURS 2004-2006                                              *)
(* University of Strasbourg 2008                                           *)
(***************************************************************************)
Require Export basic_geometric_facts.
Proof with Geometry.
intros.
assert (D <> Y).
unfold not;intro;subst D...
unfold not;intro.
assert (C ** Y / D ** Y = S C A B / S D A B)...
assert (S C A B = S D A B).
unfold parallel in H6.
unfold S4 in H6.
assert (S C A B = - S A C B)...
rewrite H8.
RewriteVar (S A C B) H6.
ring_simplify.
Geometry.
rewrite H8 in H7.
assert (C ** Y = D ** Y).
RewriteVar (C ** Y) H7.
field...
Geometry.
assert (C = D).
assert (C ** D + D ** Y = C ** Y)...
rewrite <- H10 in H9.
assert (C ** D = 0)...
RewriteVar (C ** D) H9...
Geometry.
Qed.
Hint Resolve col_par_1 col_par_2 col_par_3 col_par_4 : Geom.
Proof with Geometry.
intros.
cut (Col C D B).
Geometry.
assert (parallel C D A B).
Geometry.
eapply par_col_col_1;eauto...
Qed.

Lemma par_col_col_4 : forall A B C D,
parallel A B C D ->
Col B C D ->
Col A C D.