Isabelle在任何语言环境之外使用语言环境或上下文

Isabelle在任何语言环境之外使用语言环境或上下文,isabelle,Isabelle,我定义了locale并证明了几个定理。现在我需要在这个区域/上下文之外使用它们。我怎样才能做到? 我能通过语言环境的假设扩展假设得到定理吗?(就像在Coq中一样。) 我需要得到定理“a”∈A==>A∈上述定义的thm中的“A”。(我不需要这个定理,它只是一个通过扩展假设集获得定理的最简单示例。(mylocale中的thm没有任何假设))区域设置上下文中的每个定义和定理都会生成一个全局版本。您可以使用locale\u name.constant\u name或locale\u name.Therm

我定义了locale并证明了几个定理。现在我需要在这个区域/上下文之外使用它们。我怎样才能做到? 我能通过语言环境的假设扩展假设得到定理吗?(就像在Coq中一样。)


我需要得到定理“a”∈A==>A∈上述定义的thm中的“A”。(我不需要这个定理,它只是一个通过扩展假设集获得定理的最简单示例。(mylocale中的thm没有任何假设))

区域设置上下文中的每个定义和定理都会生成一个全局版本。您可以使用
locale\u name.constant\u name
locale\u name.Thermore\u name
访问此全局版本(通用于locale参数并使用locale假设进行扩展)。在您的示例中,
mylocale.thm
提供您想要的内容

如果需要几个定理而不概括区域设置参数,则可以在固定参数并假定假设的未修改上下文中解释区域设置。下面是一个例子:

 locale l = fixes a :: 'a assumes "a ~= undefined" begin
 definition foo :: 'a where "foo = a"
 lemma lem: "a = foo" by(simp add: foo_def)
 end

 thm l.lem (* a is generalized to ?a *)

 consts bar :: nat

 context assumes *: "bar ~= undefined" begin
 interpretation bar: l bar by(fact bar)
 thm lem (* a is instantiated with bar *)
 end

区域设置上下文中的每个定义和定理都会生成一个全局版本。您可以使用
locale\u name.constant\u name
locale\u name.Thermore\u name
访问此全局版本(通用于locale参数并使用locale假设进行扩展)。在您的示例中,
mylocale.thm
提供您想要的内容

如果需要几个定理而不概括区域设置参数,则可以在固定参数并假定假设的未修改上下文中解释区域设置。下面是一个例子:

 locale l = fixes a :: 'a assumes "a ~= undefined" begin
 definition foo :: 'a where "foo = a"
 lemma lem: "a = foo" by(simp add: foo_def)
 end

 thm l.lem (* a is generalized to ?a *)

 consts bar :: nat

 context assumes *: "bar ~= undefined" begin
 interpretation bar: l bar by(fact bar)
 thm lem (* a is instantiated with bar *)
 end