arith.ML
changeset 45 3d5b2b874e14
parent 40 ac7b7003f177
child 54 5ea12dfd9393
equal deleted inserted replaced
44:64eda8afe2b4 45:3d5b2b874e14
   123 val wf_less_trans = wf_pred_nat RS wf_trancl RSN (2, def_wfrec RS trans);
   123 val wf_less_trans = wf_pred_nat RS wf_trancl RSN (2, def_wfrec RS trans);
   124 
   124 
   125 goalw Nat.thy [less_def] "<m,n> : pred_nat^+ = (m<n)";
   125 goalw Nat.thy [less_def] "<m,n> : pred_nat^+ = (m<n)";
   126 by (rtac refl 1);
   126 by (rtac refl 1);
   127 val less_eq = result();
   127 val less_eq = result();
   128 
       
   129 (*
       
   130 val div_simps = [div_termination, cut_apply, less_eq];
       
   131 val div_ss = nat_ss addsimps div_simps;
       
   132 val div_ss = nat_ss addsimps div_simps;
       
   133 *)
       
   134 
   128 
   135 goal Arith.thy "!!m. m<n ==> m mod n = m";
   129 goal Arith.thy "!!m. m<n ==> m mod n = m";
   136 by (rtac (mod_def RS wf_less_trans) 1);
   130 by (rtac (mod_def RS wf_less_trans) 1);
   137 by(asm_simp_tac HOL_ss 1);
   131 by(asm_simp_tac HOL_ss 1);
   138 val mod_less = result();
   132 val mod_less = result();