summaryrefslogtreecommitdiff
path: root/src/theory/theory.cpp
diff options
context:
space:
mode:
authorKshitij Bansal <kshitij@cs.nyu.edu>2015-11-03 04:47:30 -0500
committerKshitij Bansal <kshitij@cs.nyu.edu>2016-04-09 14:35:28 -0400
commit2039eab2d76cf5f4cfe44680f5325f44a4fc5a99 (patch)
tree05ac95009f3aa77a2fa7d41501aa1179d5b73b66 /src/theory/theory.cpp
parent67623ee1e6d62b36cb598c28ad9b871b6957a9dd (diff)
cardinality operation for finite sets (based on my thesis / ijcar16 paper)
Some further cleanup/fixes pending This is squash of 39 commits (kbansal/card branch + cleanup): * add card operator * local reasoning * towards graph building * first implementation * close cardinality terms * model building * more * more * more * Add aggressive sets rewriting. * Recursively aggressive rewrite sets. * Fix * incomplete card2 implementation * ... * Avoid using auto in sets. * fix merge * more * ... * more * ... * Fixed for loops * Slight modification to computeRelevantTerms * more * .. * more * ... * mv empty set lemma generation to later point * more options/reordering * debug related * more trace * ... * fix merge_nodes, models * rm warnigns * fix compile errors * warning * bug fixes/cleanup * mroe fixes * cleanup * ...
Diffstat (limited to 'src/theory/theory.cpp')
-rw-r--r--src/theory/theory.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/theory/theory.cpp b/src/theory/theory.cpp
index e05363bf2..7e2b6df55 100644
--- a/src/theory/theory.cpp
+++ b/src/theory/theory.cpp
@@ -231,7 +231,7 @@ void Theory::collectTerms(TNode n, set<Node>& termSet) const
}
-void Theory::computeRelevantTerms(set<Node>& termSet) const
+void Theory::computeRelevantTerms(set<Node>& termSet, bool includeShared) const
{
// Collect all terms appearing in assertions
context::CDList<Assertion>::const_iterator assert_it = facts_begin(), assert_it_end = facts_end();
@@ -239,6 +239,8 @@ void Theory::computeRelevantTerms(set<Node>& termSet) const
collectTerms(*assert_it, termSet);
}
+ if (!includeShared) return;
+
// Add terms that are shared terms
context::CDList<TNode>::const_iterator shared_it = shared_terms_begin(), shared_it_end = shared_terms_end();
for (; shared_it != shared_it_end; ++shared_it) {
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback