Some proofs of validity using Z3 SMT 2.0 online -
lemma: forall x : r, x <> 0 -> (x / x) = 1.
proof:
(declare-const x real) (push) (assert (or (> x 0) (< x 0))) (assert (not (= (/ x x) 1))) (check-sat)
and output :
unsat
qed.
lemma: forall x y : r, x <> 0, y <> 0 -> (x / x + y / y) = 2.
proof:
(declare-const x real) (declare-const y real) (push) (assert (or (> x 0) (< x 0))) (assert (or (> y 0) (< y 0))) (assert (not (= (+ (/ x x) (/ y y)) 2))) (check-sat)
and output is:
unsat
qed.
lemma: forall x y : r, x <> 0, y <> 0 -> (x / x + x / y) = ((x + y) / y).
proof:
(declare-const x real) (declare-const y real) (push) (assert (or (> x 0) (< x 0))) (assert (or (> y 0) (< y 0))) (assert (not (= (+ (/ x x) (/ x y)) (/ (+ x y) y)))) (check-sat)
and output is:
unsat
qed.
these lemmas proved using coq + maple at
http://coq.inria.fr/v8.2pl1/contribs/maplemode.examples.html
and using z3py online at
some proofs of validity using z3py online , strategy proposed nikolaj bjorner
please let me know if proofs z3 smt 2.0 correct , if know more direct form prove them using z3 smt 2.0. many thanks.
there nothing wrong encodings. may consider following encoding closer lemmas trying prove (also available online here):
(assert (not (forall ((x real)) (=> (not (= x 0)) (= (/ x x) 1))))) (check-sat) (reset) (assert (not (forall ((x real) (y real)) (=> (and (not (= x 0)) (not (= y 0))) (= (+ (/ x x) (/ y y)) 2))))) (check-sat) (reset) (assert (not (forall ((x real) (y real)) (=> (and (not (= x 0)) (not (= y 0))) (= (+ (/ x x) (/ x y)) (/ (+ x y) y)))))) (check-sat)
Comments
Post a Comment