| 1 |
\DOC prove_NWORD_MOD |
| 2 |
|
| 3 |
\TYPE {prove_NWORD_MOD : int -> thm} |
| 4 |
|
| 5 |
\LIBRARY wordn |
| 6 |
|
| 7 |
\SYNOPSIS |
| 8 |
Proves a theorem stating the periodicity of the function {NWORDn}. |
| 9 |
|
| 10 |
\DESCRIBE |
| 11 |
{prove_NWORD_MOD n} proves a theorem about the num-to-word conversion |
| 12 |
{NWORDn} which takes the following form: |
| 13 |
{ |
| 14 |
|- !m. NWORDn m = NWORDn (m MOD e) |
| 15 |
} |
| 16 |
\noindent where {e} is a constant number whose value equals to {2 EXP n}. |
| 17 |
|
| 18 |
\FAILURE |
| 19 |
Fails if the type {:wordn} or the conversion function {NWORDn} |
| 20 |
has not been defined. |
| 21 |
|
| 22 |
\EXAMPLE |
| 23 |
The following HOL session illustrates the use of this function: |
| 24 |
{ |
| 25 |
# let word3_NWORD_MOD = prove_NWORD_MOD 3;; |
| 26 |
word3_NWORD_MOD = |- !m. NWORD3 m = NWORD3(m MOD 8) |
| 27 |
} |
| 28 |
|
| 29 |
\SEEALSO |
| 30 |
{define_wordn_type}, {define_word_val}, {prove_word_val}. |
| 31 |
|
| 32 |
\ENDDOC |