aboutsummaryrefslogtreecommitdiffhomepage
path: root/theories
diff options
context:
space:
mode:
authorGravatar Hugo Herbelin <Hugo.Herbelin@inria.fr>2017-03-03 10:27:30 +0100
committerGravatar Hugo Herbelin <Hugo.Herbelin@inria.fr>2017-03-03 10:45:03 +0100
commit27d92355d38af5ee93c7343a62671701e72c1096 (patch)
tree9e813c3be24378b2c266d309c5fb910a7ddc7a99 /theories
parenta61494c8c430477da8a4b3367a8ac5d492bf83c1 (diff)
Completing basic lemmas about <= and < in BinInt.Z.Pos2Z.
Diffstat (limited to 'theories')
-rw-r--r--theories/ZArith/BinInt.v15
1 files changed, 15 insertions, 0 deletions
diff --git a/theories/ZArith/BinInt.v b/theories/ZArith/BinInt.v
index d09337484..1e3ab6687 100644
--- a/theories/ZArith/BinInt.v
+++ b/theories/ZArith/BinInt.v
@@ -1396,6 +1396,21 @@ Proof. easy. Qed.
Lemma neg_le_pos p q : Zneg p <= Zpos q.
Proof. easy. Qed.
+Lemma neg_lt_pos p q : Zneg p < Zpos q.
+Proof. easy. Qed.
+
+Lemma neg_le_neg p q : (q <= p)%positive -> Zneg p <= Zneg q.
+Proof. intros; unfold Z.le; simpl. now rewrite <- Pos.compare_antisym. Qed.
+
+Lemma neg_lt_neg p q : (q < p)%positive -> Zneg p < Zneg q.
+Proof. intros; unfold Z.lt; simpl. now rewrite <- Pos.compare_antisym. Qed.
+
+Lemma pos_le_pos p q : (p <= q)%positive -> Zpos p <= Zpos q.
+Proof. easy. Qed.
+
+Lemma pos_lt_pos p q : (p < q)%positive -> Zpos p < Zpos q.
+Proof. easy. Qed.
+
Lemma neg_xO p : Z.neg p~0 = 2 * Z.neg p.
Proof. reflexivity. Qed.