Z3/SMTLIB2对“独特”的支持`
我已经使用(ML)z3绑定有一段时间了,还有API函数Z3/SMTLIB2对“独特”的支持`,z3,smt,Z3,Smt,我已经使用(ML)z3绑定有一段时间了,还有API函数 val mk_distinct : context -> ast array -> ast 多年来一直忠心耿耿地服务。我现在正在尝试切换 到SMTLIB2接口,但我发现distinct命令 不支持。例如,查询: (declare-fun x () Int) (declare-fun y () Int) (distinct x y) (assert (= x y)) (check-sat) 结果是: unsupported ;
val mk_distinct : context -> ast array -> ast
多年来一直忠心耿耿地服务。我现在正在尝试切换
到SMTLIB2接口,但我发现distinct
命令
不支持
。例如,查询:
(declare-fun x () Int)
(declare-fun y () Int)
(distinct x y)
(assert (= x y))
(check-sat)
结果是:
unsupported
; distinct
sat
在网上演示。有解决办法吗
谢谢
Ranjit。您应该使用(断言(不同的xy))
而不是(不同的xy)
。
下面是更新示例的链接:太棒了!我假设这是SMTLIB2兼容的btw?谢谢是的,这是标准的一部分。如果你回到这里,你应该将答案标记为已接受。