(* Copyright (C) 2005-2008 Sebastien Briais *)
(* http://lamp.epfl.ch/~sbriais/ *)
(* This library is free software; you can redistribute it and/or modify *)
(* it under the terms of the GNU Lesser General Public License as *)
(* published by the Free Software Foundation; either version 2.1 of the *)
(* License, or (at your option) any later version. *)
(* This library is distributed in the hope that it will be useful, but *)
(* WITHOUT ANY WARRANTY; without even the implied warranty of *)
(* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU *)
(* Lesser General Public License for more details. *)
(* You should have received a copy of the GNU Lesser General Public *)
(* License along with this library; if not, write to the Free Software *)
(* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *)
(* 02110-1301 USA *)
Require Export Arith.
Require Export ArithRing.
Require Export Omega.
Unset Standard Proposition Elimination Names.
intros.
rewrite mult_comm.
induction m;simpl;auto with arith.
elim H0;trivial.
Qed.
intros.
induction n.
tauto.
simpl in H.
right.
assert (m <= O);try omega.
rewrite <- H.
auto with arith.
Qed.
intros.
rewrite mult_comm.
induction m.
inversion H0.
simpl.
assert (O < m*n);try omega.
inversion H0;try omega.
assert (1 <= n);try omega.
assert (m > 1);try omega.
generalize (IHm H4);omega.
Qed.
intros n m.
case n.
left;trivial.
intros.
right.
destruct m.
rewrite mult_comm in H.
discriminate.
destruct m;trivial.
assert ((S n0)<(S n0)*(S (S m))).
apply mult_lemma3;intros;auto with arith.
rewrite <- H in H0.
elim (lt_irrefl (S n0) H0).
Qed.

Lemma mult_lemma5 : forall (n m:nat),((n * m) =1)->(n=1)/\(m=1).