30 #ifndef _cvc3__core_theorem_producer_h_
31 #define _cvc3__core_theorem_producer_h_
Theorem IffToIte(const Expr &e)
==> IFF(a,b) == ITE(a, b, !b)
Data structure of expressions in CVC3.
Theorem rewriteIteToOr(const Expr &e)
==> ITE(a, TRUE, b) IFF OR(a, b)
This theory handles the built-in logical connectives plus equality. It also handles the registration ...
Theorem rewriteNotIte(const Expr &e)
==> NOT ITE(a,b,c) IFF ITE(a,NOT b,NOT c)
Theorem iffOrDistrib(const Expr &iff)
((a|b)<=>(a|c))<=>(a|(b<=>c)); takes ((a|b)<=>(a|c)) as 'iff'
Theorem OrToIte(const Expr &e)
==> Or(e) == ITE(e[1], TRUE, e[0])
Theorem rewriteIteCond(const Expr &e)
==> ITE(a, b(a), c(a)) IFF ITE(a, b(TRUE), c(FALSE))
Theorem rewriteIteToAnd(const Expr &e)
==> ITE(a, b, FALSE) IFF AND(a, b)
Theorem rewriteIteElse(const Expr &e, const Theorem &elseThm)
!a |- c == d ==> ITE(a, b, c) == ITE(a, b, d)
Theorem ImpToIte(const Expr &e)
==> IMPLIES(a,b) == ITE(a, b, TRUE)
Theorem rewriteNotAnd(const Expr &e)
==> NOT (AND e1 ... en) IFF (OR !e1 ... !en), takes (AND ...)
Theorem rewriteIteToImp(const Expr &e)
==> ITE(a, b, TRUE) IFF IMPLIES(a, b)
Theorem rewriteIteToNot(const Expr &e)
==> ITE(e, FALSE, TRUE) IFF NOT(e)
Theorem rewriteDistinct(const Expr &e)
==> DISTINCT(e1,...,en) IFF AND 1 <= i < j <= n (e[i] /= e[j])
TheoryCore * d_core
pointer to theory core
virtual ~CoreTheoremProducer()
Theorem rewriteAndSubterms(const Expr &e, int idx)
(a & b) <=> a & b[a/true]; takes the index of a
Theorem dummyTheorem(const Expr &e)
Temporary cheat for building theorems.
Theorem rewriteIteBool(const Expr &c, const Expr &e1, const Expr &e2)
==> ITE(c, e1, e2) <=> (c => e1) AND (!c => e2)
Theorem rewriteLetDecl(const Expr &e)
Replace LETDECL with its definition.
Theorem rewriteIteThen(const Expr &e, const Theorem &thenThm)
a |- b == d ==> ITE(a, b, c) == ITE(a, d, c)
Theorem rewriteIteToIff(const Expr &e)
==> ITE(a, b, !b) IFF IFF(a, b)
CoreTheoremProducer(TheoremManager *tm, TheoryCore *core)
Theorem rewriteImplies(const Expr &e)
==> IMPLIES(e1,e2) IFF OR(!e1, e2)
Theorem rewriteOrSubterms(const Expr &e, int idx)
(a | b) <=> a | b[a/false]; takes the index of a
Theorem NotToIte(const Expr ¬_e)
==> NOT(e) == ITE(e, FALSE, TRUE)
Theorem iffAndDistrib(const Expr &iff)
((a&b)<=>(a&c))<=>(!a|(b<=>c)); takes ((a&b)<=>(a&c)) as 'iff'
Theorem andDistributivityRule(const Expr &e)
|= (A | B1) & (A | B2) & ... & (A | bn) <=> A | (B1 & B2 & ...& Bn)
Theorem rewriteNotIff(const Expr &e)
==> NOT IFF(e1,e2) IFF IFF(e1,NOT e2)
Theorem orDistributivityRule(const Expr &e)
|= (A & B1) | (A & B2) | ... | (A & bn) <=> A & (B1 | B2 | ...| Bn)
Proof rules used by theory_core.
Theorem AndToIte(const Expr &e)
==> And(e) == ITE(e[1], e[0], FALSE)
Theorem rewriteNotOr(const Expr &e)
==> NOT (OR e1 ... en) IFF (AND !e1 ... !en), takes (OR ...)
Theorem ifLiftUnaryRule(const Expr &e)
|- op(ITE(cond,a,b)) =/<=> ITE(cond,op(a),op(b))
Theorem typePred(const Expr &e)
e: T ==> |- typePred_T(e) [deriving the type predicate of e]