equal
deleted
inserted
replaced
128 "(m::nat) < 0 \<longleftrightarrow> False" |
128 "(m::nat) < 0 \<longleftrightarrow> False" |
129 "0 < nat_of_num l \<longleftrightarrow> True" |
129 "0 < nat_of_num l \<longleftrightarrow> True" |
130 "nat_of_num k < nat_of_num l \<longleftrightarrow> k < l" |
130 "nat_of_num k < nat_of_num l \<longleftrightarrow> k < l" |
131 by (simp_all add: nat_of_num_numeral) |
131 by (simp_all add: nat_of_num_numeral) |
132 |
132 |
|
133 lemma [code, code del]: |
|
134 "divmod_nat = divmod_nat" .. |
|
135 |
|
136 lemma divmod_nat_code [code]: |
|
137 "divmod_nat (nat_of_num k) (nat_of_num l) = divmod k l" |
|
138 "divmod_nat m 0 = (0, m)" |
|
139 "divmod_nat 0 n = (0, 0)" |
|
140 by (simp_all add: prod_eq_iff nat_of_num_numeral del: div_nat_numeral mod_nat_numeral) |
|
141 |
133 |
142 |
134 subsection {* Conversions *} |
143 subsection {* Conversions *} |
135 |
144 |
136 lemma [code, code del]: |
145 lemma [code, code del]: |
137 "of_nat = of_nat" .. |
146 "of_nat = of_nat" .. |