【发布时间】:2021-03-17 15:29:34
【问题描述】:
现在我知道了,可以通过依赖类型来表达量词。所以我为此写了一个简单的实现“for all (a, b: N): exists (c: N): c = a + b”:
f : (a : Nat) -> (b : Nat) -> (c : Nat ** c = a + b)
f a b = (a + b ** Refl)
它有效。
现在我想知道,我可以表达这个“for all (a, b: N): exists (c: N): c > a and c
【问题讨论】:
标签: math types idris dependent-type quantifiers