(************************************************************************) (* v * The Coq Proof Assistant / The Coq Development Team *) (* n == m. Proof. intros n m p; nzinduct p. now nzsimpl. intro p. nzsimpl. now rewrite succ_inj_wd. Qed. Theorem add_cancel_r : forall n m p, n + p == m + p <-> n == m. Proof. intros n m p. rewrite (add_comm n p), (add_comm m p). apply add_cancel_l. Qed. Theorem add_shuffle1 : forall n m p q, (n + m) + (p + q) == (n + p) + (m + q). Proof. intros n m p q. rewrite <- (add_assoc n m), <- (add_assoc n p), add_cancel_l. rewrite 2 add_assoc, add_cancel_r. now apply add_comm. Qed. Theorem add_shuffle2 : forall n m p q, (n + m) + (p + q) == (n + q) + (m + p). Proof. intros n m p q. rewrite <- (add_assoc n m), <- (add_assoc n q), add_cancel_l. rewrite add_assoc. now apply add_comm. Qed. Theorem sub_1_r : forall n, n - 1 == P n. Proof. intro n; now nzsimpl. Qed. End NZAddPropFunct.