(***************************************************************************)
(* 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 pythagoras_difference_lemmas.
Require Export euclidean_constructions_2.
Require Export construction_lemmas_2.
Require Export ratios_elimination_lemmas.
Ltac construct_grid O U V H :=
elim grid_existence;let H:= fresh in (
intros O H; elim H; clear H;intros U H;elim H;clear H;intro V;intros H;decompose [and] H).

Lemma degen_py_elim : forall O U V, perp O U O V ->
O ** U <> 0 -> O ** V <> 0 ->
forall A B,  (* ~ Col A O V -> ~ Col B O U -> *)
Py A B A = 2*2*2*(
(S O V A-S O V B) * (S O V A-S O V B) / (O**V * O**V) +
(S O U A-S O U B) * (S O U A-S O U B) / (O**U * O**U)).