繁体   English   中英

z3错误地说UNSAT

[英]z3 incorrectly saying UNSAT

对于以下问题,存在解决方案,但z3说是UNSAT。

(set-logic QF_UFNRA)
(declare-fun a () Real)
(declare-fun b () Real)
(declare-fun c () Real)
(declare-fun d () Real)
(declare-fun e () Real)
(declare-fun f () Real)
(declare-fun g () Real)
(declare-fun h () Real)
(assert (and (<= a 1.0) (> a 0.0)))
(assert (and (<= b 1.0) (> b 0.0)))
(assert (and (<= c 1.0) (> c 0.0)))
(assert (and (<= d 1.0) (> d 0.0)))
(assert (and (<= e 1.0) (>= e 0.0)))
(assert (and (<= f 1.0) (>= f 0.0)))
(assert (and (<= g 1.0) (>= g 0.0)))
(assert (and (<= h 1.0) (>= h 0.0)))
(assert (= (* (+ a b) (+ a c)) a))
(assert (= (* (+ a b) (+ b d)) b))
(assert (= (* (+ a c) (+ c d)) c))
(assert (= (* (+ b d) (+ c d)) d))
(assert (= (+ a b c d e f g h) 1.0))
(check-sat)

有效的解决方案:

a = 1/12, b = 1/4, c = 1/6, d = 1/2, e = f = g = h = 0 

我不知道为什么z3说不满意。

z3版本是z3-4.3.0-x64。

我不知道在rise4fun( http://rise4fun.com/z3 )上的z3是什么版本。 我刚刚测试过,它说的是SAT。 它返回您给的模型。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM