【发布时间】:2021-02-16 09:56:15
【问题描述】:
在 Coq 中,可以如下归纳定义自然数:
Inductive nat :=
| zero : nat
| succ : nat -> nat.
我想知道是否可以以类似的方式归纳定义 整数?我可以做类似的事情
Inductive int :=
| zero : int
| succ : int -> int
| pred : int -> int.
但是我想在int 的定义中断言succ(pred x) = x 和pred(succ x) = x,我不知道该怎么做。
【问题讨论】: