Make automatic termination proof use different size function

前端 未结 1 443
星月不相逢
星月不相逢 2021-01-13 16:01

I have written a custom size function size2 for my datatype. Using this function I can manually prove the termination of my function:

terminatio         


        
相关标签:
1条回答
  • 2021-01-13 16:13

    A function f can be registered as a measure function for the termination prover by declaring the lemma is_measure f with the attribute measure_function. In your case, this looks as follows.

    lemma is_measure_size2 [measure_function]: "is_measure size2" ..
    

    Then, lexicographic_order, which fun uses, and size_change try size2, too.

    0 讨论(0)
提交回复
热议问题