From ff70395fd3dcde9f68eda1c6a8bd70e6491f7458 Mon Sep 17 00:00:00 2001 From: Tim King Date: Wed, 19 May 2010 21:20:54 +0000 Subject: Significant revision to theory/arith. The new draft has a lot of small bug fixes and organizational changes. The theory is now enabled to perform checking in the TheoryEngine. This draft can now solve 2 new regression tests test/regress/regress0/ineq_slack.smt and test/regress/regress0/ineq_basic.smt. There is also a small bug fix inside src/expr/attribute.h. --- src/theory/arith/theory_arith.h | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) (limited to 'src/theory/arith/theory_arith.h') diff --git a/src/theory/arith/theory_arith.h b/src/theory/arith/theory_arith.h index 82bb47eb4..ecdebd720 100644 --- a/src/theory/arith/theory_arith.h +++ b/src/theory/arith/theory_arith.h @@ -21,10 +21,12 @@ #include "theory/theory.h" #include "context/context.h" #include "context/cdlist.h" +#include "expr/node.h" #include "theory/arith/delta_rational.h" #include "theory/arith/tableau.h" #include "theory/arith/arith_rewriter.h" +#include "theory/arith/partial_model.h" namespace CVC4 { namespace theory { @@ -33,16 +35,19 @@ namespace arith { class TheoryArith : public Theory { private: ArithConstants d_constants; + ArithPartialModel d_partialModel; context::CDList d_diseq; + context::CDList d_preprocessed; + //TODO This is currently needed to save preprocessed nodes that may not + //currently have an outisde reference. Get rid of when preprocessing is occuring + //correctly. + Tableau d_tableau; ArithRewriter d_rewriter; public: - TheoryArith(context::Context* c, OutputChannel& out) : - Theory(c, out), - d_constants(NodeManager::currentNM()), d_diseq(c), d_rewriter(&d_constants) - {} + TheoryArith(context::Context* c, OutputChannel& out); Node rewrite(TNode n); @@ -53,11 +58,12 @@ public: void explain(TNode n, Effort e) { Unimplemented(); } private: - void AssertLower(TNode n); - void AssertUpper(TNode n); + void AssertLower(TNode n, TNode orig); + void AssertUpper(TNode n, TNode orig); void update(TNode x_i, DeltaRational& v); void pivotAndUpdate(TNode x_i, TNode x_j, DeltaRational& v); - TNode updateInconsistentVars(); + + Node updateInconsistentVars(); TNode selectSlackBelow(TNode x_i); TNode selectSlackAbove(TNode x_i); @@ -66,6 +72,9 @@ private: Node generateConflictAbove(TNode conflictVar); Node generateConflictBelow(TNode conflictVar); + //TODO get rid of this! + Node simulatePreprocessing(TNode n); + }; }/* CVC4::theory::arith namespace */ -- cgit v1.2.3