equal
deleted
inserted
replaced
3032 \label{ssec:size} *} |
3032 \label{ssec:size} *} |
3033 |
3033 |
3034 text {* |
3034 text {* |
3035 For each datatype, the \hthm{size} plugin generates a generic size |
3035 For each datatype, the \hthm{size} plugin generates a generic size |
3036 function @{text "t.size_t"} as well as a specific instance |
3036 function @{text "t.size_t"} as well as a specific instance |
3037 @{text "size \<Colon> t \<Rightarrow> bool"} belonging to the @{text size} type |
3037 @{text "size \<Colon> t \<Rightarrow> nat"} belonging to the @{text size} type |
3038 class. The \keyw{fun} command relies on @{const size} to prove termination of |
3038 class. The \keyw{fun} command relies on @{const size} to prove termination of |
3039 recursive functions on datatypes. |
3039 recursive functions on datatypes. |
3040 |
3040 |
3041 The plugin derives the following properties: |
3041 The plugin derives the following properties: |
3042 |
3042 |
3056 \item[@{text "t."}\hthm{size_gen_o_map}\rm:] ~ \\ |
3056 \item[@{text "t."}\hthm{size_gen_o_map}\rm:] ~ \\ |
3057 @{thm list.size_gen_o_map[no_vars]} |
3057 @{thm list.size_gen_o_map[no_vars]} |
3058 |
3058 |
3059 \item[@{text "t."}\hthm{size_neq}\rm:] ~ \\ |
3059 \item[@{text "t."}\hthm{size_neq}\rm:] ~ \\ |
3060 This property is missing for @{typ "'a list"}. If the @{term size} function |
3060 This property is missing for @{typ "'a list"}. If the @{term size} function |
3061 always evaluate to a non-zero value, this theorem have the form |
3061 always evaluates to a non-zero value, this theorem has the form |
3062 @{prop "\<not> size x = 0"}. |
3062 @{prop "\<not> size x = 0"}. |
3063 |
3063 |
3064 \end{description} |
3064 \end{description} |
3065 \end{indentblock} |
3065 \end{indentblock} |
3066 *} |
3066 *} |