(* Contribution to the Coq Library   V6.3 (July 1999)                    *)
Definition leZ (x y : Z) :=
match x return Prop with
| OZ =>
match y return Prop with
| OZ => True
| pos n => True
| neg n => False
end
| pos n =>
match y return Prop with
| OZ => False
| pos m => n <= m
| neg m => False
end
| neg n =>
match y return Prop with
| OZ => True
| pos m => True
| neg m => m <= n
end
end.
intros; elim x; simpl in |- *.
exact I.
intro; simpl in |- *.
exact I.
intro; simpl in |- *.
exact I.
Qed.
intro x; elim x.
unfold absZ in |- *; reflexivity.
unfold absZ in |- *; reflexivity.
intros; elim H.
Qed.
intros x y; elim x.
elim y.
reflexivity.
intros; elim H0.
intros; elim H.
intro n; elim y.
intros; elim H.
simpl in |- *; intros; elim (le_antisym n n0 H H0); reflexivity.
intros; elim H.
intro n; elim y.
intros; elim H0.
intros; elim H0.
simpl in |- *; intros; elim (le_antisym n0 n H H0); reflexivity.
Qed.
Definition ltZ (x y : Z) := leZ (succZ x) y.
Definition lt_absZ (x y : Z) := ltZ (absZ x) (absZ y).
simple induction x.
reflexivity.
unfold lt_absZ in |- *; unfold absZ in |- *; unfold ltZ in |- *;
unfold leZ in |- *; intros.
elim (le_Sn_O n H).
unfold lt_absZ in |- *; unfold absZ in |- *; unfold ltZ in |- *;
unfold leZ in |- *; intros.
elim (le_Sn_O n H).
Qed.
intros; elim n.
simpl in |- *; exact I.
simpl in |- *; intros; exact I.
Qed.
intro x; elim x.
simpl in |- *; intros; exact I.
simpl in |- *; intros; exact I.
intros; elim H.
Qed.

Lemma le_opp_OZ :
forall x y : Z, x = oppZ y -> leZ OZ x -> leZ OZ y -> x = OZ.