在Coq中是否与BOOL和Prop有很强的关系?
有没有办法把道具转换成布尔?我知道在Coq中是否与BOOL和Prop有很强的关系?,coq,Coq,有没有办法把道具转换成布尔?我知道对于所有ab:nat,a在Prop中的谓词和bool中的谓词之间存在关系意味着所讨论的属性是可判定的。基本上,您有一个函数来决定属性是true还是false 并非所有命题都是如此(除非你假设了一些包含它的原则),但对 Inductive reflect (P : Prop) : bool -> Set := | ReflectT : P -> reflect P true | ReflectF : ~ P -> reflect P false
对于所有ab:nat,a在Prop
中的谓词和bool
中的谓词之间存在关系意味着所讨论的属性是可判定的。基本上,您有一个函数来决定属性是true
还是false
并非所有命题都是如此(除非你假设了一些包含它的原则),但对
Inductive reflect (P : Prop) : bool -> Set :=
| ReflectT : P -> reflect P true
| ReflectF : ~ P -> reflect P false.
Nat.ltb_spec0: forall x y : nat, reflect (x < y) (x <? y)