(* Julien Narboux *)
(* Formalization of *)
(* Tarski's axiomatic *)
Require Export  Ch03_between_properties.
Proof with Tarski.
intros.
unfold IFSC in H.
intuition.
cases_equality A C.
treat_equalities...
assert (exists E, Bet A C E /\ C <> E)...
DecompExAnd H6 E.
assert (exists E', Bet A' C' E' /\ Cong C' E' C E)...
DecompExAnd H6 E'.
assert (Cong E D E' D').
eapply five_segments_with_def.
assert (OFSC A C E D A' C' E' D').
unfold OFSC.
intuition.
apply H6.
assumption.
assert (OFSC E C B D E' C' B' D').
unfold OFSC.
intuition;esTarski.
esTarski.
Qed.
Proof with Tarski.
intros.
assert (IFSC A B C A A' B' C' A').
unfold IFSC;intuition.
apply cong_commutativity.
eapply l4_2.
apply H3.
Qed.
Hint Resolve l4_2 l4_3 : Tarski.
(** A generalization of the Cong predicate for three points. *)
Definition Cong_3 := fun A1 A2 A3 B1 B2 B3 =>
Cong A1 A2 B1 B2 /\ Cong A1 A3 B1 B3 /\ Cong A2 A3 B2 B3.

Lemma l4_5 : forall A B C A' C',
Bet A B C -> Cong A C A' C' ->
exists B', Bet A' B' C' /\ Cong_3 A B C A' B' C'.