(************************************************************************)
(*         *   The Coq Proof Assistant / The Coq Development Team       *)
(*  v      *   INRIA, CNRS and contributors - Copyright 1999-2018       *)
(* <O___,, *       (see CREDITS file for the list of authors)           *)
(*   \VV/  **************************************************************)
(*    //   *    This file is distributed under the terms of the         *)
(*         *     GNU Lesser General Public License Version 2.1          *)
(*         *     (see LICENSE file for the text of the license)         *)
(************************************************************************)
(** Properties of subtraction between natural numbers.  This file is mostly OBSOLETE now, see module [PeanoNat.Nat] instead.  [minus] is now an alias for [Nat.sub], which is defined in [Init/Nat.v] as: << Fixpoint sub (n m:nat) : nat := match n, m with | S k, S l => k - l | _, _ => n end where "n - m" := (sub n m) : nat_scope. >> *)
Local Open Scope nat_scope.
(** * 0 is right neutral *)
(** * Permutation with successor *)
Register pred_of_minus as num.nat.pred_of_minus.
(** * Diagonal *)
Notation minus_diag := Nat.sub_diag (only parsing). (* n - n = 0 *)
Notation minus_n_n := minus_diag_reverse.
(** * Simplification *)
(** * Relation with plus *)
(** * Relation with order *)
Notation minus_le_compat_r :=
Nat.sub_le_mono_r (only parsing). (* n <= m -> n - p <= m - p. *)
Notation minus_le_compat_l :=
Nat.sub_le_mono_l (only parsing). (* n <= m -> p - m <= p - n. *)
Notation le_minus := Nat.le_sub_l (only parsing). (* n - m <= n *)
Notation lt_minus := Nat.sub_lt (only parsing). (* m <= n -> 0 < m -> n-m < n *)

Theorem not_le_minus_0 n m : ~ m <= n -> n - m = 0.