X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fmatita%2Flibrary%2Fnat%2Flt_arith.ma;h=683ec262773cbe38541ba1499b6cf1eeb3775440;hb=6b61a9e6698a7c1936adf217b599e34e65a5e4c9;hp=623f30295922c7d6ff5fe5d23369b960f5e7c2dc;hpb=6db38e3d8e4083765f2fce40c7845c9827b9afd0;p=helm.git diff --git a/helm/software/matita/library/nat/lt_arith.ma b/helm/software/matita/library/nat/lt_arith.ma index 623f30295..683ec2627 100644 --- a/helm/software/matita/library/nat/lt_arith.ma +++ b/helm/software/matita/library/nat/lt_arith.ma @@ -12,8 +12,6 @@ (* *) (**************************************************************************) -set "baseuri" "cic:/matita/nat/lt_arith". - include "nat/div_and_mod.ma". (* plus *) @@ -118,6 +116,17 @@ apply (nat_case1 a) ] qed. +lemma lt_times_to_lt_O: \forall i,n,m:nat. i < n*m \to O < m. +intros. +elim (le_to_or_lt_eq O ? (le_O_n m)) + [assumption + |apply False_ind. + rewrite < H1 in H. + rewrite < times_n_O in H. + apply (not_le_Sn_O ? H) + ] +qed. + (* times *) theorem monotonic_lt_times_r: \forall n:nat.monotonic nat lt (\lambda m.(S n)*m). @@ -239,26 +248,7 @@ apply (nat_case n) ] qed. -theorem le_times_to_le_div: \forall a,b,c:nat. -O \lt b \to (b*c) \le a \to c \le (a /b). -intros. -apply lt_S_to_le. -apply (lt_times_n_to_lt b) - [assumption - |rewrite > sym_times. - apply (le_to_lt_to_lt ? a) - [assumption - |simplify. - rewrite > sym_plus. - rewrite > (div_mod a b) in ⊢ (? % ?) - [apply lt_plus_r. - apply lt_mod_m_m. - assumption - |assumption - ] - ] - ] -qed. + theorem nat_compare_times_l : \forall n,p,q:nat. nat_compare p q = nat_compare ((S n) * p) ((S n) * q).