如何从 Coq.Numbers.NatInt.NZDiv 导入定理?

How to import theorems from Coq.Numbers.NatInt.NZDiv?

this 文档 link 中有关于除法的有用定理。我尝试在 CoqIDE 8.9.0 中使用 Require Import 导入它,但是当导入成功时,以下代码失败 The reference div_lt_upper_bound was not found in the current environment.

Require Import Coq.Numbers.NatInt.NZDiv.
Check div_lt_upper_bound.

我尝试下载该文件的源代码并通过 Load 手动导入它,但随后我收到以下消息,没有进一步的解释(第一行为红色):

Application of a functor with too few arguments.
Interactive Module Type DivMod started
div is declared
modulo is declared
Module Type DivMod is defined
Interactive Module Type DivModNotation started
Module Type DivModNotation is defined
Module Type DivMod' is defined
Interactive Module Type NZDivSpec started
div_mod is declared
mod_bound_pos is declared
Module Type NZDivSpec is defined
Module Type NZDiv is defined

如何正确加载这些定理?为什么之前的方法都不行?

快速回答是您正在查看 Module Type(参见 Print NZDivProp.)。

实际用法很简单,e。 g.

Require Import Arith.
Check Nat.div_lt_upper_bound.
(*
     Nat.div_lt_upper_bound
          : forall a b q : nat, b <> 0 -> a < b * q -> a / b < q
*)