equal
deleted
inserted
replaced
1 (* Title: HOL/ex/Numeral.thy |
1 (* Title: HOL/ex/Numeral.thy |
2 ID: $Id$ |
|
3 Author: Florian Haftmann |
2 Author: Florian Haftmann |
4 |
3 |
5 An experimental alternative numeral representation. |
4 An experimental alternative numeral representation. |
6 *) |
5 *) |
7 |
6 |
247 |
246 |
248 subsection {* Binary numerals *} |
247 subsection {* Binary numerals *} |
249 |
248 |
250 text {* |
249 text {* |
251 We embed binary representations into a generic algebraic |
250 We embed binary representations into a generic algebraic |
252 structure using @{text of_num} |
251 structure using @{text of_num}. |
253 *} |
252 *} |
254 |
253 |
255 ML {* |
254 ML {* |
256 structure DigSimps = |
255 structure DigSimps = |
257 NamedThmsFun(val name = "numeral"; val description = "Simplification rules for numerals") |
256 NamedThmsFun(val name = "numeral"; val description = "Simplification rules for numerals") |
889 hide (open) const sub dup |
888 hide (open) const sub dup |
890 |
889 |
891 |
890 |
892 subsection {* Numeral equations as default simplification rules *} |
891 subsection {* Numeral equations as default simplification rules *} |
893 |
892 |
894 text {* TODO. Be more precise here with respect to subsumed facts. *} |
893 text {* TODO. Be more precise here with respect to subsumed facts. Or use named theorems anyway. *} |
895 declare (in semiring_numeral) numeral [simp] |
894 declare (in semiring_numeral) numeral [simp] |
896 declare (in semiring_1) numeral [simp] |
895 declare (in semiring_1) numeral [simp] |
897 declare (in semiring_char_0) numeral [simp] |
896 declare (in semiring_char_0) numeral [simp] |
898 declare (in ring_1) numeral [simp] |
897 declare (in ring_1) numeral [simp] |
899 thm numeral |
898 thm numeral |