AC: only allow one counting node per branch

This commit is contained in:
Tiago Gomes 2012-11-06 23:56:52 +00:00
parent 829f2248ee
commit b599b45bc6

View File

@ -526,6 +526,13 @@ LiftedCircuit::tryAtomCounting (
CircuitNode** follow,
Clauses& clauses)
{
for (size_t i = 0; i < clauses.size(); i++) {
if (clauses[i].nrPositiveCountedLogVars() > 0
|| clauses[i].nrNegativeCountedLogVars() > 0) {
// only allow one atom counting node per branch
return false;
}
}
for (size_t i = 0; i < clauses.size(); i++) {
Literals literals = clauses[i].literals();
for (size_t j = 0; j < literals.size(); j++) {