在Isabelle/HOL中公理化"undefined"的原因是什么?

What is the reason to axiomatize "undefined" in Isabelle/HOL?

在Isabelle/HOL中可以找到如下公理化

axiomatization The :: "('a ⇒ bool) ⇒ 'a"
axiomatization undefined :: 'a

有没有不能使用的原因

definition "undefined ≡ The (λx. False)"

或者这只是一个历史文物?目前的方式似乎导致了“不同”的不确定性概念。当我按照

定义某些内容时,我偶然发现了这一点
definition "of_interest y ≡ (THE x. foobar x y)"

并想证明(事后看来是愚蠢的)完整性检查

lemma "(∄x. foobar x y) ⟹ of_interest y = undefined"

这在当前状态下显然是行不通的,但应该通过上面定义的undefined。

通过使用 axiomatization 机制,您清楚地声明您不能对 undefined :: 'a 进行任何假设,但它是 'a 类型的任意但未知的值。相反,通过使用您的定义,您现在对 undefined 有了更多了解,即它是 The 映射到 λx. False 的值(这同样适用于 Eps (λx. True)和类似的定义)。例如,根据您的定义,您可以证明 The (λx. False) = undefined,而您无法使用 axiomatization.

证明