(** ** Some decidability results about orders. *)

(* Specifications: *)
Lemma Q_dec : forall x y, {x<y} + {y<x} + {x==y}.
Lemma Qopp_lt_compat: forall p q : Q, p < q -> - q < - p.
#[global]
Hint Resolve Qopp_le_compat Qopp_lt_compat : qarith.
Lemma Qle_minus_iff : forall p q, p <= q <-> 0 <= q+-p.
Lemma Qlt_minus_iff : forall p q, p < q <-> 0 < q+-p.
Lemma Qplus_le_compat :
forall x y z t, x<=y -> z<=t -> x+z <= y+t.
Lemma Qplus_lt_le_compat :
forall x y z t, x<y -> z<=t -> x+z < y+t.
Lemma Qplus_le_l (x y z: Q): x + z <= y + z <-> x <= y.
Lemma Qplus_le_r (x y z: Q): z + x <= z + y <-> x <= y.
Lemma Qplus_lt_l (x y z: Q): x + z < y + z <-> x < y.
Lemma Qplus_lt_r (x y z: Q): z + x < z + y <-> x < y.
Lemma Qplus_lt_compat : forall x y z t : Q,
x < y -> z < t -> x + z < y + t.