src/ZF/Integ/Bin.thy
changeset 14511 73493236e97f
parent 13612 55d32e76ef4e
child 16417 9bc16273c2d4
equal deleted inserted replaced
14510:73ea1234bb23 14511:73493236e97f
   528 
   528 
   529 lemma int_of_eq_0_imp_natify_eq_0: "$# n = #0 ==> natify(n) = 0"
   529 lemma int_of_eq_0_imp_natify_eq_0: "$# n = #0 ==> natify(n) = 0"
   530 by (rule not_znegative_imp_zero, auto)
   530 by (rule not_znegative_imp_zero, auto)
   531 
   531 
   532 lemma nat_of_zminus_int_of: "nat_of($- $# n) = 0"
   532 lemma nat_of_zminus_int_of: "nat_of($- $# n) = 0"
   533 apply (unfold nat_of_def raw_nat_of_def)
   533 by (simp add: nat_of_def int_of_def raw_nat_of zminus image_intrel_int)
   534 apply (auto dest!: not_znegative_imp_zero natify_int_of_eq
       
   535             iff del: int_of_eq)
       
   536 apply (rule the_equality, auto)
       
   537 apply (blast intro: int_of_eq_0_imp_natify_eq_0 sym)
       
   538 done
       
   539 
   534 
   540 lemma int_of_nat_of: "#0 $<= z ==> $# nat_of(z) = intify(z)"
   535 lemma int_of_nat_of: "#0 $<= z ==> $# nat_of(z) = intify(z)"
   541 apply (rule not_zneg_nat_of_intify)
   536 apply (rule not_zneg_nat_of_intify)
   542 apply (simp add: znegative_iff_zless_0 not_zless_iff_zle)
   537 apply (simp add: znegative_iff_zless_0 not_zless_iff_zle)
   543 done
   538 done