containedNegatively;
+
+ public VariableCbs(int i, Solver solver) {
+ super(i, solver);
+ containedPositively = new ArrayList<>();
+ containedNegatively = new ArrayList<>();
+ }
+
+ @Override
+ public Solver getSolver() {
+ throw new NullPointerException("getSolver not needed.");
+ }
+
+ @Override
+ public void setTrue() {
+ setAssignment(1);
+
+ // increase unsat literals for negative clauses
+ containedNegatively.forEach(CounterBasedClause::incrementUnsatisfied);
+
+ // increase sat literals for positive clauses
+ containedPositively.forEach(CounterBasedClause::incrementSatisfied);
+ }
+
+ @Override
+ public void setFalse() {
+ assert getAssignment() == -1;
+ setAssignment(0);
+
+ containedPositively.forEach(CounterBasedClause::incrementUnsatisfied);
+ containedNegatively.forEach(CounterBasedClause::incrementSatisfied);
+ }
+
+ @Override
+ public void undoAssignment() {
+ assert getAssignment() == 1 || getAssignment() == 0;
+
+ // Case 1
+ if (getAssignment() == 1) {
+ containedPositively.forEach(CounterBasedClause::decrementSatisfied);
+ containedNegatively.forEach(CounterBasedClause::decrementUnsatisfied);
+ }
+
+ // Case 2
+ if (getAssignment() == 0) {
+ containedNegatively.forEach(CounterBasedClause::decrementSatisfied);
+ containedPositively.forEach(CounterBasedClause::decrementUnsatisfied);
+ }
+
+ setAssignment(-1);
+ }
+
+
+ @Override
+ public void removeConnections(Integer l, Clause cl) {
+ CounterBasedClause cb = (CounterBasedClause) cl;
+ if(l < 0){
+ containedNegatively.remove(cb);
+ }
+ else{
+ containedPositively.remove(cb);
+ }
+ }
+
+ @Override
+ public void connectToClausePositive(@NotNull CounterBasedClause cl) {
+ containedPositively.add(cl);
+ }
+
+ @Override
+ public void connectToClauseNegative(@NotNull CounterBasedClause cl) {
+ containedNegatively.add(cl);
+ }
+}
diff --git a/Formula/src/factory/DataStrategyFactory.java b/Formula/src/factory/DataStrategyFactory.java
new file mode 100644
index 0000000..43f82c2
--- /dev/null
+++ b/Formula/src/factory/DataStrategyFactory.java
@@ -0,0 +1,29 @@
+package factory;
+
+import counterbased.SetOfClausesCbs;
+import formula.SetOfClauses;
+import mixed.SetOfClausesMixed;
+import specificationCore.Solver;
+import wl.SetOfClausesW;
+
+/**
+ * Data strategy factory.
+ *
+ * Created by Albert Schimpf on 04.10.2015.
+ */
+public class DataStrategyFactory {
+
+ public static SetOfClauses getDataStrategy(Solver solver, ESetOfClauses dataStructure) {
+ switch (dataStructure) {
+ case DataCB:
+ return new SetOfClausesCbs(solver);
+ case Data2WL:
+ return new SetOfClausesW(solver);
+ case DataMixed:
+ return new SetOfClausesMixed(solver);
+ default:
+ throw new IllegalArgumentException(
+ "Invalid data structure selected. " + dataStructure);
+ }
+ }
+}
diff --git a/Formula/src/factory/ESetOfClauses.java b/Formula/src/factory/ESetOfClauses.java
new file mode 100644
index 0000000..1e3f4e5
--- /dev/null
+++ b/Formula/src/factory/ESetOfClauses.java
@@ -0,0 +1,8 @@
+package factory;
+
+/**
+ * Created by tp on 17.12.15.
+ */
+public enum ESetOfClauses {
+ DataCB, Data2WL, DataMixed
+}
diff --git a/Formula/src/interfaces/CounterBasedClause.java b/Formula/src/interfaces/CounterBasedClause.java
new file mode 100644
index 0000000..04a637f
--- /dev/null
+++ b/Formula/src/interfaces/CounterBasedClause.java
@@ -0,0 +1,13 @@
+package interfaces;
+
+import formula.Clause;
+
+public interface CounterBasedClause extends Clause {
+ void incrementSatisfied();
+
+ void incrementUnsatisfied();
+
+ void decrementSatisfied();
+
+ void decrementUnsatisfied();
+}
diff --git a/Formula/src/interfaces/CounterBasedVariable.java b/Formula/src/interfaces/CounterBasedVariable.java
new file mode 100644
index 0000000..44f0211
--- /dev/null
+++ b/Formula/src/interfaces/CounterBasedVariable.java
@@ -0,0 +1,12 @@
+package interfaces;
+
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import formula.Variable;
+
+public interface CounterBasedVariable extends Variable{
+ void removeConnections(Integer l, Clause cl);
+
+ void connectToClausePositive(@NotNull CounterBasedClause cl);
+ void connectToClauseNegative(@NotNull CounterBasedClause cl);
+}
diff --git a/Formula/src/interfaces/WatchedLiteralsClause.java b/Formula/src/interfaces/WatchedLiteralsClause.java
new file mode 100644
index 0000000..3d44d60
--- /dev/null
+++ b/Formula/src/interfaces/WatchedLiteralsClause.java
@@ -0,0 +1,19 @@
+package interfaces;
+
+
+import formula.Clause;
+
+/**
+ * Created by tp on 17.12.15.
+ */
+public interface WatchedLiteralsClause extends Clause{
+ //TODO abstract initial watch selection to a heuristic
+ void connectInitialWachtes();
+
+ //TODO abstract watch selection to a heuristic
+ boolean searchNewWatch(Integer watch);
+
+ void updateStatus();
+
+ void removeWatchesFromVariables();
+}
diff --git a/Formula/src/interfaces/WatchedLiteralsVariable.java b/Formula/src/interfaces/WatchedLiteralsVariable.java
new file mode 100644
index 0000000..2d81dab
--- /dev/null
+++ b/Formula/src/interfaces/WatchedLiteralsVariable.java
@@ -0,0 +1,12 @@
+package interfaces;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Variable;
+import wl.ClauseWL;
+
+public interface WatchedLiteralsVariable extends Variable {
+ void connectToClause(@NotNull WatchedLiteralsClause clauseWL, Integer lit);
+ void removeWatch(@NotNull WatchedLiteralsClause clauseWL, Integer lit);
+ void connectToClauseL(WatchedLiteralsClause clauseWL, Integer lit);
+ void update();
+}
diff --git a/Formula/src/mixed/ClauseMixed.java b/Formula/src/mixed/ClauseMixed.java
new file mode 100644
index 0000000..b04a843
--- /dev/null
+++ b/Formula/src/mixed/ClauseMixed.java
@@ -0,0 +1,139 @@
+package mixed;
+
+
+import abstractImplementation.ClauseAbs;
+import counterbased.ClauseCbs;
+import formula.Clause;
+import interfaces.CounterBasedClause;
+import interfaces.WatchedLiteralsClause;
+import org.w3c.dom.css.Counter;
+import specificationCore.Solver;
+import wl.ClauseWL;
+
+import java.util.List;
+
+/**
+ *
+ * Created by tp on 16.12.15.
+ */
+public class ClauseMixed extends ClauseAbs implements CounterBasedClause, WatchedLiteralsClause {
+ private final Clause cl;
+
+ /**
+ * Default constructor for all 2WL clauses.
+ *
+ * Clauses have to operate on the formula {@code F} and have to have access
+ * to the trail {@code M}.
+ *
+ * @param solver
+ * reference to access formula {@code F} and trail {@code M}
+ */
+ public ClauseMixed(Solver solver, boolean big) {
+ super(solver);
+
+ if(big){
+ cl = new ClauseWL(solver);
+ }
+ else{
+ cl = new ClauseCbs(solver);
+ }
+ }
+
+ @Override
+ public boolean isConflicting() {
+ return cl.isConflicting();
+ }
+
+ @Override
+ public boolean isUnit() {
+ return cl.isUnit();
+ }
+
+ @Override
+ public Integer getUnitLiteral() {
+ return cl.getUnitLiteral();
+ }
+
+ @Override
+ public void addLiteral(Integer lit) {
+ cl.addLiteral(lit);
+ }
+
+ @Override
+ public void assertConflictingState() {
+ cl.assertConflictingState();
+ }
+
+ @Override
+ public void incrementSatisfied() {
+ ((ClauseCbs) cl).incrementSatisfied();
+ }
+
+ @Override
+ public void incrementUnsatisfied() {
+ ((ClauseCbs) cl).incrementUnsatisfied();
+ }
+
+ @Override
+ public void decrementSatisfied() {
+ ((ClauseCbs) cl).decrementSatisfied();
+ }
+
+ @Override
+ public void decrementUnsatisfied() {
+ ((ClauseCbs) cl).decrementUnsatisfied();
+ }
+
+ @Override
+ public void connectInitialWachtes() {
+ ((ClauseWL) cl).connectInitialWachtes();
+ }
+
+ @Override
+ public boolean searchNewWatch(Integer watch) {
+ return ((ClauseWL) cl).searchNewWatch(watch);
+ }
+
+ @Override
+ public void updateStatus() {
+ ((ClauseWL) cl).updateStatus();
+ }
+
+ @Override
+ public void removeWatchesFromVariables() {
+ ((ClauseWL) cl).removeWatchesFromVariables();
+ }
+
+ @Override
+ public void setLiterals(int literals){
+ ((ClauseAbs) cl).setLiterals(literals);
+ }
+
+ @Override
+ public int size(){
+ return ((ClauseAbs) cl).size();
+ }
+
+ @Override
+ public void setId(int i){
+ id = i;
+ ((ClauseAbs) cl).setId(i);
+ }
+
+ @Override
+ public int getId(){
+ return ((ClauseAbs) cl).getId();
+ }
+
+ @Override
+ public List getLiterals(){
+ return state.F().getLiterals(((ClauseAbs) cl).getId());
+ }
+
+ public boolean isBig(){
+ if(cl instanceof CounterBasedClause){
+ return false;
+ }
+ return true;
+ }
+}
diff --git a/Formula/src/mixed/SetOfClausesMixed.java b/Formula/src/mixed/SetOfClausesMixed.java
new file mode 100644
index 0000000..6c74daa
--- /dev/null
+++ b/Formula/src/mixed/SetOfClausesMixed.java
@@ -0,0 +1,130 @@
+package mixed;
+
+import abstractImplementation.SetOfClausesAbs;
+import counterbased.ClauseCbs;
+import counterbased.VariableCbs;
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+
+import java.util.List;
+
+import static java.lang.Math.abs;
+
+public class SetOfClausesMixed extends SetOfClausesAbs {
+ private static int BIG = 10;
+
+ public SetOfClausesMixed(@NotNull Solver solver) {
+ super(solver);
+ }
+
+ @Override
+ public void addClause(@NotNull List cl) {
+ Clause n;
+ if(cl.size() < BIG){
+ n = addClSmall(cl);
+ }else{
+ n = addClBig(cl);
+ }
+
+ if (n.isUnit()) foundUnitClause(n);
+ }
+
+ @Override
+ public Clause addLearnedClause(@NotNull List cl) {
+ Clause n;
+ if(cl.size() < BIG){
+ n = addClSmall(cl);
+ }else{
+ n = addClBig(cl);
+ }
+
+ n.assertConflictingState();
+
+ return n;
+ }
+
+ private Clause addClBig(List cl) {
+ // only for instancing the initial formula
+ ClauseMixed n = new ClauseMixed(solver,true);
+
+ n.setId(clauses.size());
+ n.setLiterals(cl.size());
+ initialClauses.add(n);
+ clauses.add(cl);
+
+ n.connectInitialWachtes();
+
+ return n;
+ }
+
+ private Clause addClSmall(@NotNull List cl) {
+ // only for instancing the initial formula
+ ClauseMixed n = new ClauseMixed(solver,false);
+ for (int l : cl) {
+ VariableMixed var = (VariableMixed) getVariables()[abs(l)];
+
+ if (l < 0) {
+ var.connectToClauseNegative(n);
+ } else {
+ var.connectToClausePositive(n);
+ }
+
+ }
+
+ n.setId(clauses.size());
+ n.setLiterals(cl.size());
+ initialClauses.add(n);
+ clauses.add(cl);
+
+ return n;
+ }
+
+
+
+
+ @Override
+ public void forgetLearnedClause(@NotNull Clause cl) {
+ cl.removeConnectionToVariables();
+
+ learnedClauses.remove(cl);
+ clauses.set(((ClauseCbs) cl).getId(), null);
+ }
+
+ @Override
+ public void removeClauseConnection(Clause cl) {
+ for (Integer lit : cl.getLiterals()) {
+ variables[abs(lit)].removeConnections(lit, cl);
+ }
+ }
+
+
+ @Override
+ public void variableCount(int variables) {
+ instanceVariableArray(variables + 1);
+ for (int i = 1; i < this.getVariables().length; i++) {
+ VariableMixed temp = new VariableMixed(i, solver);
+ this.getVariables()[i] = temp;
+ }
+ }
+
+ private void instanceVariableArray(Integer length) {
+ variables = new VariableMixed[length];
+ freeVariables = variables.length - 1;
+ }
+
+// public String toString(){
+// int small = 0;
+// int big = 0;
+// for (Clause cl : initialClauses) {
+// if(((ClauseMixed) cl).isBig()){
+// big++;
+// }
+// else{
+// small++;
+// }
+// }
+//
+// return "small: "+small+ " || big: "+big;
+// }
+}
diff --git a/Formula/src/mixed/VariableMixed.java b/Formula/src/mixed/VariableMixed.java
new file mode 100644
index 0000000..c9aaafa
--- /dev/null
+++ b/Formula/src/mixed/VariableMixed.java
@@ -0,0 +1,171 @@
+package mixed;
+
+
+import abstractImplementation.VariableAbs;
+import formula.Clause;
+import interfaces.CounterBasedClause;
+import interfaces.CounterBasedVariable;
+import interfaces.WatchedLiteralsClause;
+import interfaces.WatchedLiteralsVariable;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.stream.Collectors;
+
+/**
+ * Created by tp on 07.12.15.
+ */
+public class VariableMixed extends VariableAbs implements WatchedLiteralsVariable, CounterBasedVariable {
+ //non-lazy VarCB stuff
+ private final ArrayList containedPositively;
+ private final ArrayList containedNegatively;
+
+ //VarWL stuff
+ private final ArrayList ClausePositiveWatched;
+ private final ArrayList ClauseNegativeWatched;
+ private ArrayList toAddPositive = new ArrayList<>();
+ private ArrayList toAddNegative = new ArrayList<>();
+
+ public VariableMixed(int i, Solver solver) {
+ super(i, solver);
+ containedPositively = new ArrayList<>();
+ containedNegatively = new ArrayList<>();
+ ClausePositiveWatched = new ArrayList<>();
+ ClauseNegativeWatched = new ArrayList<>();
+ }
+
+ @Override
+ public Solver getSolver() {
+ throw new NullPointerException("getSolver not needed.");
+ }
+
+ @Override
+ public void setTrue() {
+ setAssignment(1);
+
+ // increase unsat literals for negative clauses
+ containedNegatively.forEach(CounterBasedClause::incrementUnsatisfied);
+
+ // increase sat literals for positive clauses
+ containedPositively.forEach(CounterBasedClause::incrementSatisfied);
+
+ //VARWL STUFF
+ for (Iterator it = ClauseNegativeWatched.iterator(); it
+ .hasNext();) {
+ WatchedLiteralsClause cl = it.next();
+ if (cl.searchNewWatch(-getIndex())) {
+ it.remove();
+ }
+ }
+
+ ClauseNegativeWatched.addAll(toAddNegative.stream().collect(Collectors.toList()));
+ ClausePositiveWatched.addAll(toAddPositive.stream().collect(Collectors.toList()));
+ toAddNegative.clear();
+ toAddPositive.clear();
+ }
+
+ @Override
+ public void setFalse() {
+ setAssignment(0);
+
+ containedPositively.forEach(CounterBasedClause::incrementUnsatisfied);
+ containedNegatively.forEach(CounterBasedClause::incrementSatisfied);
+
+ //varWL stuff
+ for (Iterator it = ClausePositiveWatched.iterator(); it
+ .hasNext();) {
+ WatchedLiteralsClause cl = it.next();
+ if (cl.searchNewWatch(getIndex())) {
+ it.remove();
+ }
+ }
+
+ ClauseNegativeWatched.addAll(toAddNegative.stream().collect(Collectors.toList()));
+ ClausePositiveWatched.addAll(toAddPositive.stream().collect(Collectors.toList()));
+ toAddNegative.clear();
+ toAddPositive.clear();
+ }
+
+ @Override
+ public void undoAssignment() {
+ // Case 1
+ if (getAssignment() == 1) {
+ containedPositively.forEach(CounterBasedClause::decrementSatisfied);
+ containedNegatively.forEach(CounterBasedClause::decrementUnsatisfied);
+ }
+
+ // Case 2
+ if (getAssignment() == 0) {
+ containedNegatively.forEach(CounterBasedClause::decrementSatisfied);
+ containedPositively.forEach(CounterBasedClause::decrementUnsatisfied);
+ }
+
+ setAssignment(-1);
+
+ //VARWL STUFF
+ //do nothing
+ }
+
+ @Override
+ public void removeConnections(Integer l, Clause cl) {
+ CounterBasedClause cb = (CounterBasedClause) cl;
+ if(l < 0){
+ containedNegatively.remove(cb);
+ }
+ else{
+ containedPositively.remove(cb);
+ }
+ }
+
+
+ @Override
+ public void connectToClausePositive(@NotNull CounterBasedClause cl) {
+ containedPositively.add(cl);
+ }
+
+ @Override
+ public void connectToClauseNegative(@NotNull CounterBasedClause cl) {
+ containedNegatively.add(cl);
+ }
+
+ @Override
+ public void connectToClause(@NotNull WatchedLiteralsClause cl, Integer lit) {
+ if(lit < 0){
+ ClauseNegativeWatched.add(cl);
+ }
+ else{
+ ClausePositiveWatched.add(cl);
+ }
+ }
+
+ @Override
+ public void removeWatch(@NotNull WatchedLiteralsClause clauseWL, Integer lit) {
+ if(lit < 0){
+ ClauseNegativeWatched.remove(clauseWL);
+ }
+ else{
+ ClausePositiveWatched.remove(clauseWL);
+ }
+ }
+
+ @Override
+ public void connectToClauseL(WatchedLiteralsClause clauseW, Integer toLit) {
+ if(toLit < 0){
+ toAddNegative.add(clauseW);
+ }
+ else{
+ toAddPositive.add(clauseW);
+ }
+ }
+
+ @Override
+ public void update() {
+ ClauseNegativeWatched.addAll(toAddNegative.stream().collect(Collectors.toList()));
+ ClausePositiveWatched.addAll(toAddPositive.stream().collect(Collectors.toList()));
+ toAddNegative.clear();
+ toAddPositive.clear();
+ }
+}
diff --git a/Formula/src/wl/ClauseWL.java b/Formula/src/wl/ClauseWL.java
new file mode 100644
index 0000000..490e6d9
--- /dev/null
+++ b/Formula/src/wl/ClauseWL.java
@@ -0,0 +1,287 @@
+package wl;
+
+import abstractImplementation.ClauseAbs;
+import formula.SetOfClauses;
+import interfaces.WatchedLiteralsClause;
+import interfaces.WatchedLiteralsVariable;
+import specificationCore.Solver;
+import specificationCore.Trail;
+
+import java.util.List;
+
+import static java.lang.Math.abs;
+
+/**
+ * 2016/02/15.
+ */
+public class ClauseWL extends ClauseAbs implements WatchedLiteralsClause {
+ //Watches
+ private Integer moving = null;
+ private int movingIndex = -1;
+
+ private Integer fixed = null;
+ private int fixedIndex = -1;
+
+ public ClauseWL(Solver solver) {
+ super(solver);
+ }
+
+
+ @Override
+ public void removeWatchesFromVariables() {
+ if (size() == 1) {
+ // Remove only watch
+ ((WatchedLiteralsVariable) state.F().getVariable(moving)).removeWatch(this,moving);
+ } else {
+ ((WatchedLiteralsVariable) state.F().getVariable(moving)).removeWatch(this,moving);
+ ((WatchedLiteralsVariable) state.F().getVariable(fixed)).removeWatch(this,fixed);
+ }
+ }
+
+ @Override
+ public void connectInitialWachtes() {
+ List lits = getLiterals();
+
+ //TODO random selection, heuristic
+ if(size() == 1){
+ moving = fixed = lits.get(0);
+ movingIndex = fixedIndex = 0;
+ }
+ else{
+ moving = lits.get(0);
+ movingIndex = 0;
+ fixed = lits.get(1);
+ fixedIndex = 1;
+ }
+
+ //connect variables
+
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(moving))).connectToClause(this,moving);
+ if(size()>1){
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(fixed))).connectToClause(this,fixed);
+ }
+ }
+
+
+
+ @Override
+ public boolean searchNewWatch(Integer watch) {
+ if(size() == 1){
+ state.F().foundConflictClause(this);
+ return false;
+ }
+ if(size() == 2){
+ if(isConflicting()) state.F().foundConflictClause(this);
+ if(isUnit()) state.F().foundUnitClause(this);
+ return false;
+ }
+
+ if(watch.equals(fixed)) flipSearch();
+
+ //search for new watch
+ for (int i = 0; i < getLiterals().size(); i++) {
+ Integer lit = getLiterals().get(i);
+ //ignore watches
+ if(lit.equals(fixed)) continue;
+ if(lit.equals(moving)) continue;
+
+ //case 1:literal is free
+ if(state.F().isVariableUndefined(abs(lit)) ||
+ (state.M().inTrail(lit))
+ ){
+ int prevVar = abs(moving);
+
+ moving = lit;
+ movingIndex = i;
+
+ // Add moving to a queue to avoid concurrent modification
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(moving))).connectToClauseL(this,moving);
+ if(prevVar != abs(moving)) ((WatchedLiteralsVariable) state.F().getVariable(abs(moving))).update();
+
+// if(isConflicting()) throw new IllegalStateException("2WL conflicting");
+// if(isUnit()) throw new IllegalStateException("2WL unit");
+
+ //signal watch change
+ return true;
+ }
+ }
+
+
+
+ if(isConflicting()) {
+ state.F().foundConflictClause(this);
+ }
+ if(isUnit()) {
+ state.F().foundUnitClause(this);
+ }
+ return false;
+ }
+
+ private void flipSearch() {
+ Integer t = moving;
+ Integer ind = movingIndex;
+ moving = fixed;
+ movingIndex = fixedIndex;
+ fixed = t;
+ fixedIndex = ind;
+ }
+
+
+// @Override
+// public boolean isConflicting() {
+// //not conflicting as long as moving is not false in trail
+// return state.M().inTrail(-moving);
+// }
+//
+// @Override
+// public boolean isUnit() {
+// //last unassigned literal is always moving
+// return state.F().isVariableUndefined(abs(moving));
+// }
+
+ @Override
+ public boolean isUnit() {
+ // If one watch is conflicting and the other free, clause is unit
+ if ((state.M().inTrail(-moving))
+ && (state.F().isVariableUndefined(abs(fixed)))) {
+ return true;
+ }
+ if ((state.M().inTrail(-fixed))
+ && (state.F().isVariableUndefined(abs(moving)))) {
+ return true;
+ }
+ // If moving == fixed (clause size 1) and undefined, clause is unit
+ return (size() == 1)
+ && (state.F().isVariableUndefined(abs(moving)));
+ }
+
+ @Override
+ public boolean isConflicting() {
+ // If both watches are conflicting in M, clause is conflicting
+ if ((state.M().inTrail(-moving)) && (state.M().inTrail(-fixed))) {
+ return true;
+ }
+
+ // Otherwise, clause is not conflicting
+ return false;
+ }
+
+ @Override
+ public Integer getUnitLiteral() {
+ if(state.F().isVariableUndefined(moving)) return moving;
+ if(state.F().isVariableUndefined(fixed)) return fixed;
+ throw new IllegalStateException("Not unit");
+// return fixed;
+ }
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ @Override
+ public void addLiteral(Integer lit) {
+
+ }
+
+
+
+
+
+
+
+
+
+ @Override
+ public void assertConflictingState() {
+ List lits = getLiterals();
+ if(size() == 1){
+ moving = fixed = lits.get(0);
+ movingIndex = fixedIndex = 0;
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(moving))).connectToClause(this,moving);
+ return;
+ }
+
+ if(size() == 2){
+ moving = lits.get(0);
+ fixed = lits.get(1);
+ movingIndex = 0;
+ fixedIndex = 1;
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(moving))).connectToClause(this,moving);
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(fixed))).connectToClause(this,fixed);
+ return;
+ }
+
+ // Size > 2: status may be affected
+ // Find the 2 literals which are last assigned in trail
+ int l1 = 0;
+ int l2 = 1;
+
+ // ensure bigger status
+ if (state.M().isAssertedBefore(-lits.get(l2), -lits.get(l1))) {
+ l2 = 0;
+ l1 = 1;
+ }
+
+ for (int i = 2; i < lits.size(); i++) {
+ // if new literal later than l2: set new literal as l2, l1 as l2
+ if (state.M().isAssertedBefore(-lits.get(l2), -lits.get(i)
+ )) {
+ l1 = l2;
+ l2 = i;
+ } else {
+ // new literal later than l1, but not l2: set new l1
+ if (state.M().isAssertedBefore(-lits.get(l1), -lits.get(i))) {
+ l1 = i;
+ }
+ // New literal before l1, l2: do nothing
+ }
+ }
+
+ // set watches and indexes
+ moving = lits.get(l1);
+ movingIndex = l1;
+ fixed = lits.get(l2);
+ fixedIndex = l2;
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(moving))).connectToClause(this,moving);
+ ((WatchedLiteralsVariable) state.F().getVariable(abs(fixed))).connectToClause(this,fixed);
+ }
+
+
+ @Override
+ public void updateStatus() {
+ throw new NullPointerException("NYI");
+ }
+
+
+
+
+
+ public String toString() {
+ String ret = "";
+ List lits = getLiterals();
+ for (int i = 0; i < lits.size(); i++) {
+ if (i == movingIndex) {
+ ret += " [" + lits.get(i) + "]";
+ } else {
+ if (i == fixedIndex) {
+ ret += " {" + lits.get(i) + "}";
+ } else {
+ ret += " " + lits.get(i);
+ }
+ }
+ }
+ return ret;
+ }
+}
diff --git a/Formula/src/wl/SetOfClausesW.java b/Formula/src/wl/SetOfClausesW.java
new file mode 100644
index 0000000..0a8c106
--- /dev/null
+++ b/Formula/src/wl/SetOfClausesW.java
@@ -0,0 +1,80 @@
+package wl;
+
+import abstractImplementation.ClauseAbs;
+import abstractImplementation.SetOfClausesAbs;
+import formula.Clause;
+import interfaces.WatchedLiteralsClause;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+
+import java.util.List;
+
+import static java.lang.Math.abs;
+
+
+/**
+ * 2016/02/01.
+ */
+public class SetOfClausesW extends SetOfClausesAbs {
+ public SetOfClausesW(@NotNull Solver solver) {
+ super(solver);
+ }
+
+ @Override
+ public void addClause(@NotNull List cl) {
+ Clause n = addCl(cl);
+ if (n.isUnit()) foundUnitClause(n);
+ }
+
+ @Override
+ public Clause addLearnedClause(List cl) {
+ Clause n = addCl(cl);
+ n.assertConflictingState();
+
+ return n;
+ }
+
+ private Clause addCl(@NotNull List cl) {
+ // only for instancing the initial formula
+ WatchedLiteralsClause n = new ClauseWL(solver);
+
+ ((ClauseAbs) n).setId(clauses.size());
+ ((ClauseAbs) n).setLiterals(cl.size());
+ initialClauses.add(n);
+ clauses.add(cl);
+
+ n.connectInitialWachtes();
+
+ return n;
+ }
+
+
+ @Override
+ public void forgetLearnedClause(Clause cl) {
+ cl.removeConnectionToVariables();
+
+ learnedClauses.remove(cl);
+ clauses.set(((ClauseWL) cl).getId(), null);
+ }
+
+ @Override
+ public void removeClauseConnection(Clause cl) {
+ for (Integer lit : cl.getLiterals()) {
+ variables[abs(lit)].removeConnections(lit, cl);
+ }
+ }
+
+ private void instanceVariableArray(Integer length) {
+ variables = new VariableW[length];
+ freeVariables = variables.length - 1;
+ }
+
+ @Override
+ public void variableCount(int variables) {
+ instanceVariableArray(variables + 1);
+ for (int i = 1; i < this.getVariables().length; i++) {
+ VariableW temp = new VariableW(i, solver);
+ this.getVariables()[i] = temp;
+ }
+ }
+}
diff --git a/Formula/src/wl/VariableW.java b/Formula/src/wl/VariableW.java
new file mode 100644
index 0000000..6dc8dcd
--- /dev/null
+++ b/Formula/src/wl/VariableW.java
@@ -0,0 +1,137 @@
+package wl;
+
+import abstractImplementation.VariableAbs;
+import interfaces.WatchedLiteralsClause;
+import interfaces.WatchedLiteralsVariable;
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import specificationCore.Solver;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.stream.Collectors;
+
+/**
+ * 2016/02/01.
+ */
+public class VariableW extends VariableAbs implements WatchedLiteralsVariable {
+ private final ArrayList ClausePositiveWatched;
+ private final ArrayList ClauseNegativeWatched;
+
+ private ArrayList toAddPositive = new ArrayList<>();
+ private ArrayList toAddNegative = new ArrayList<>();
+
+ public VariableW(int i, Solver solver) {
+ super(i, solver);
+ ClausePositiveWatched = new ArrayList<>();
+ ClauseNegativeWatched = new ArrayList<>();
+ }
+
+ @Override
+ public Solver getSolver() {
+ throw new NullPointerException("NYI");
+ }
+
+ @Override
+ public void setTrue() {
+ assert getAssignment() == -1;
+ setAssignment(1);
+
+
+ for (Iterator it = ClauseNegativeWatched.iterator(); it
+ .hasNext();) {
+ WatchedLiteralsClause cl = it.next();
+ if (cl.searchNewWatch(-getIndex())) {
+ it.remove();
+ }
+ }
+
+ ClauseNegativeWatched.addAll(toAddNegative.stream().collect(Collectors.toList()));
+ ClausePositiveWatched.addAll(toAddPositive.stream().collect(Collectors.toList()));
+ toAddNegative.clear();
+ toAddPositive.clear();
+ }
+
+ @Override
+ public void setFalse() {
+ assert getAssignment() == -1;
+ setAssignment(0);
+
+ for (Iterator it = ClausePositiveWatched.iterator(); it
+ .hasNext();) {
+ WatchedLiteralsClause cl = it.next();
+ if (cl.searchNewWatch(getIndex())) {
+ it.remove();
+ }
+ }
+
+
+ ClauseNegativeWatched.addAll(toAddNegative.stream().collect(Collectors.toList()));
+ ClausePositiveWatched.addAll(toAddPositive.stream().collect(Collectors.toList()));
+ toAddNegative.clear();
+ toAddPositive.clear();
+ }
+
+ @Override
+ public void undoAssignment() {
+ // No clause has to be visited when backtracking
+ assert getAssignment() == 1 || getAssignment() == 0;
+ setAssignment(-1);
+ }
+
+ @Override
+ public void removeConnections(Integer lit, Clause contained) {
+ throw new NullPointerException("NYI");
+ }
+
+ @Override
+ public void connectToClause(@NotNull WatchedLiteralsClause cl, Integer lit) {
+ if(lit < 0){
+ ClauseNegativeWatched.add(cl);
+ }
+ else{
+ ClausePositiveWatched.add(cl);
+ }
+ }
+
+
+ @Override
+ public void removeWatch(@NotNull WatchedLiteralsClause clauseWL, Integer lit) {
+ if(lit < 0){
+ ClauseNegativeWatched.remove(clauseWL);
+ }
+ else{
+ ClausePositiveWatched.remove(clauseWL);
+ }
+ }
+
+
+ public void connectToClauseL(WatchedLiteralsClause clauseW, Integer toLit) {
+ if(toLit < 0){
+ toAddNegative.add(clauseW);
+ }
+ else{
+ toAddPositive.add(clauseW);
+ }
+
+ }
+
+ public int isConnectedTo(WatchedLiteralsClause clauseWL) {
+ int c = 0;
+ for (WatchedLiteralsClause cl : ClausePositiveWatched) {
+ if(cl == clauseWL) c++;
+ }
+ for (WatchedLiteralsClause cl : ClauseNegativeWatched) {
+ if(cl == clauseWL) c++;
+ }
+
+ return c;
+ }
+
+ public void update() {
+ ClauseNegativeWatched.addAll(toAddNegative.stream().collect(Collectors.toList()));
+ ClausePositiveWatched.addAll(toAddPositive.stream().collect(Collectors.toList()));
+ toAddNegative.clear();
+ toAddPositive.clear();
+ }
+}
diff --git a/Heuristics/Heuristics.iml b/Heuristics/Heuristics.iml
new file mode 100644
index 0000000..b6a3561
--- /dev/null
+++ b/Heuristics/Heuristics.iml
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Heuristics/src/factory/EDecide.java b/Heuristics/src/factory/EDecide.java
new file mode 100644
index 0000000..5519c50
--- /dev/null
+++ b/Heuristics/src/factory/EDecide.java
@@ -0,0 +1,8 @@
+package factory;
+
+/**
+ * Created by tp on 17.12.15.
+ */
+public enum EDecide {
+ MiniSAT, SLIS, RandomLit
+}
diff --git a/Heuristics/src/factory/EForget.java b/Heuristics/src/factory/EForget.java
new file mode 100644
index 0000000..b522892
--- /dev/null
+++ b/Heuristics/src/factory/EForget.java
@@ -0,0 +1,8 @@
+package factory;
+
+/**
+ * Created by tp on 17.12.15.
+ */
+public enum EForget {
+ ForgetNever, ForgetSimple, ForgetRandomLarge, ForgetRandomShort, ForgetSize
+}
diff --git a/Heuristics/src/factory/ELearn.java b/Heuristics/src/factory/ELearn.java
new file mode 100644
index 0000000..f917231
--- /dev/null
+++ b/Heuristics/src/factory/ELearn.java
@@ -0,0 +1,8 @@
+package factory;
+
+/**
+ * Created by tp on 17.12.15.
+ */
+public enum ELearn {
+ LearnNever, LearnSimple
+}
diff --git a/Heuristics/src/factory/ERestart.java b/Heuristics/src/factory/ERestart.java
new file mode 100644
index 0000000..ddec81e
--- /dev/null
+++ b/Heuristics/src/factory/ERestart.java
@@ -0,0 +1,10 @@
+package factory;
+
+/**
+ * Created by tp on 17.12.15.
+ */
+public enum ERestart {
+ RestartNever,
+ RestartFixed,
+ RestartGeometric;
+}
diff --git a/Heuristics/src/factory/HeuristicFactory.java b/Heuristics/src/factory/HeuristicFactory.java
new file mode 100644
index 0000000..91e8ae9
--- /dev/null
+++ b/Heuristics/src/factory/HeuristicFactory.java
@@ -0,0 +1,90 @@
+package factory;
+
+import heuristicDecide.*;
+import heuristicForget.*;
+import heuristicLearn.LearnNever;
+import heuristicLearn.LearnSimple;
+import heuristicRestart.RestartConflictCountingFixed;
+import heuristicRestart.RestartConflictCountingGeometric;
+import heuristicRestart.RestartNever;
+import specificationCore.Solver;
+import specificationHeuristics.*;
+
+/**
+ * Heuristic factory.
+ * Created by Albert Schimpf on 04.10.2015.
+ */
+public class HeuristicFactory {
+ private HeuristicFactory() {
+ }
+
+ public static ForgetStrategy getForgetHeuristic(Solver solver, EForget forgetHeuristic) {
+ switch (forgetHeuristic) {
+ case ForgetNever:
+ return new ForgetNever(solver);
+ case ForgetSimple:
+ return new ForgetSimple(solver);
+ case ForgetRandomShort:
+ return new ForgetRandomShort(solver);
+ case ForgetRandomLarge:
+ return new ForgetRandomLarge(solver);
+ case ForgetSize:
+ return new ForgetSize(solver);
+ default:
+ throw new IllegalArgumentException(
+ "Invalid forget strategy selected. " + forgetHeuristic);
+ }
+ }
+
+
+ public static LearnStrategy getLearnHeuristic(Solver solver,ELearn learnHeuristic) {
+ switch (learnHeuristic) {
+ case LearnNever:
+ return new LearnNever(solver);
+ case LearnSimple:
+ return new LearnSimple(solver);
+
+ default:
+ throw new IllegalArgumentException(
+ "Invalid learn strategy selected. " + learnHeuristic);
+ }
+ }
+
+ public static RestartStrategy getRestartHeuristic(Solver solver,ERestart restartHeuristic) {
+ switch (restartHeuristic) {
+ case RestartNever:
+ return new RestartNever(solver);
+ case RestartGeometric:
+ return new RestartConflictCountingGeometric(solver);
+ case RestartFixed:
+ return new RestartConflictCountingFixed(solver);
+ default:
+ throw new IllegalArgumentException(
+ "Invalid restart strategy selected. " + restartHeuristic);
+ }
+ }
+
+ public static LiteralSelectionStrategy getLiteralSelectionHeuristic(Solver solver,EDecide literalHeuristic) {
+ switch (literalHeuristic) {
+ case RandomLit:
+ return new RandomLit(solver);
+
+ case SLIS:
+ VariableSelectionStrategy slis = new SLISVar(solver);
+ PolaritySelectionStrategy poll = new PolarityCachingPol(solver);
+ return new VariablePolarityLit(solver, slis,
+ poll);
+
+ case MiniSAT:
+ VariableSelectionStrategy mini = new MSATeffective(solver);
+ PolaritySelectionStrategy pol = new PolarityCachingPol(solver);
+ return new VariablePolarityLit(solver, mini,
+ pol);
+
+
+ default:
+ throw new IllegalArgumentException(
+ "Invalid decide strategy selected. " + literalHeuristic);
+ }
+ }
+}
diff --git a/Heuristics/src/heuristicDecide/MSATeffective.java b/Heuristics/src/heuristicDecide/MSATeffective.java
new file mode 100644
index 0000000..1b0efea
--- /dev/null
+++ b/Heuristics/src/heuristicDecide/MSATeffective.java
@@ -0,0 +1,150 @@
+package heuristicDecide;
+
+
+import formula.Clause;
+import heaps.Heap;
+import org.jetbrains.annotations.NotNull;
+import formula.SetOfClauses;
+import formula.Variable;
+import scores.ActivitiesVariable;
+import scores.Activity;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.VariableSelectionStrategy;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import static java.lang.Math.abs;
+
+/**
+ * 2016/02/02.
+ */
+public class MSATeffective implements SolverListener,VariableSelectionStrategy {
+ private final SetOfClauses F;
+ public Activity activities;
+ private Heap activityHeap;
+
+ private List toBump = new ArrayList<>();
+
+ public MSATeffective(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ solver.addObserver(this);
+ }
+
+ @Override
+ public Variable getVariable() {
+ Integer var = activityHeap.pop();
+
+ //shift index from heap
+ boolean undef = F.isVariableUndefined(var+1);
+ while(!undef){
+ var = activityHeap.pop();
+
+ //shift index from heap
+ undef = F.isVariableUndefined(var+1);
+ }
+ //shift index from heap
+ return F.getVariable(var+1);
+ }
+
+ @Override
+ public void onConflict(Clause cl) {
+ activities.decayAll();
+ bumpVarsInClause(cl.getLiterals());
+ }
+
+ @Override
+ public void onExplain(List ante, Integer resLit, List resolved) {
+ bumpVarsInClause(resolved);
+ }
+
+ @Override
+ public void onBacktrack(Integer l) {
+ //activityHeap.print();
+
+ //shift index back
+ if(!activityHeap.contains(abs(l)-1)){
+ activityHeap.push(abs(l)-1);
+ }
+
+
+ //activityHeap.print();
+ }
+
+
+ private void bumpVariableActivity(int var) {
+ //shift index back
+ activities.bump(var-1);
+
+ if(activityHeap.contains(var-1)){
+ activityHeap.increase(var-1);
+ }
+ }
+
+ private void bumpVarsInClause(List cl) {
+ for (Integer lit : cl) {
+ bumpVariableActivity(abs(lit));
+ }
+ }
+
+
+
+ public void onSetOfClausesLoaded() {
+ // Initialize variable array
+ Variable[] vars = F.getVariables();
+ int size = vars.length - 1;
+
+ // Initialize activity class by default constructor
+ activities = new ActivitiesVariable(size);
+
+ // Initialize priority queue with custom activity comparator
+// activityHeap = new VariableHeapInt(activities,size);
+ activityHeap = Heap.getImpl(size, activities);
+
+ for (Integer i = 0; i < size; i++) {
+ activityHeap.push(abs(i));
+ }
+
+ bumpVarsInClause(toBump);
+
+ //activityHeap.print();
+ }
+
+ @Override
+ public void onDecide(Integer ld) {
+
+ }
+
+ @Override
+ public void onUnitPropagate(List cl, Integer lu) {
+
+ }
+
+ @Override
+ public void onLearn(Clause cl) {
+
+ }
+
+ @Override
+ public void onForget(Clause cl) {
+
+ }
+
+ @Override
+ public void onLearnInitial(List cl) {
+ toBump.addAll(cl);
+ }
+
+ @Override
+ public void onRestart() {
+
+ }
+
+ @Override
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+
+ }
+
+
+}
diff --git a/Heuristics/src/heuristicDecide/PolarityCachingPol.java b/Heuristics/src/heuristicDecide/PolarityCachingPol.java
new file mode 100644
index 0000000..de3250e
--- /dev/null
+++ b/Heuristics/src/heuristicDecide/PolarityCachingPol.java
@@ -0,0 +1,170 @@
+package heuristicDecide;
+
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import formula.SetOfClauses;
+import specificationCore.*;
+import specificationHeuristics.PolaritySelectionStrategy;
+
+import java.util.List;
+
+import static java.lang.Math.abs;
+
+/**
+ * Polarity selection heuristic based on caching.
+ *
+ * Returns the polarity of a given variable based on previous used polarity.
+ * Initially random or either false or true for every variable.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class PolarityCachingPol implements PolaritySelectionStrategy,
+ SolverListener {
+ /**
+ * Array to cache the polarity of all variables.
+ */
+ private Boolean[] literalCache;
+ /**
+ * Saved formula reference.
+ */
+ private final SetOfClauses F;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * Adds itself to the observers to respond to some rules.
+ *
+ * @param solver
+ * the main module reference.
+ */
+ public PolarityCachingPol(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ solver.addObserver(this);
+ }
+
+ /**
+ * Returns a literal with cached polarity.
+ *
+ * @param varIndex
+ * variable to get the polarity
+ */
+ @Override
+ public Integer getPolarity(Integer varIndex) {
+ if(literalCache[varIndex]){
+ return varIndex;
+ }
+ else{
+ return -varIndex;
+ }
+ }
+
+ /**
+ * Cache the polarity of given literal on decide.
+ */
+ @Override
+ public void onDecide(@NotNull Integer l) {
+ if(l > 0){
+ literalCache[abs(l)] = true;
+ } else{
+ literalCache[abs(l)] = false;
+ }
+ }
+
+
+
+ /**
+ * Cache the polarity of given literal on unit propagation.
+ */
+ @Override
+ public void onUnitPropagate(@NotNull List cl,
+ @NotNull Integer l) {
+ if(l > 0){
+ literalCache[abs(l)] = true;
+ } else{
+ literalCache[abs(l)] = false;
+ }
+ }
+
+ /**
+ * Instance variable array when formula is fully loaded.
+ */
+ @Override
+ public void onSetOfClausesLoaded() {
+ literalCache = new Boolean[F.getVariables().length];
+ for (Integer i = 0; i < literalCache.length; i++) {
+ literalCache[i] = true;
+ }
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ @Override
+ public void onConflict(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ @Override
+ public void onExplain(List ante, Integer resLit,
+ List resolvente) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ @Override
+ public void onLearn(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ @Override
+ public void onForget(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ @Override
+ public void onLearnInitial(List cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ @Override
+ public void onBacktrack(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ @Override
+ public void onRestart() {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ @Override
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ }
+
+}
diff --git a/Heuristics/src/heuristicDecide/RandomLit.java b/Heuristics/src/heuristicDecide/RandomLit.java
new file mode 100644
index 0000000..eea4b77
--- /dev/null
+++ b/Heuristics/src/heuristicDecide/RandomLit.java
@@ -0,0 +1,70 @@
+package heuristicDecide;
+
+import org.jetbrains.annotations.NotNull;
+import formula.SetOfClauses;
+import formula.Variable;
+import specificationCore.Solver;
+import specificationHeuristics.LiteralSelectionStrategy;
+
+import java.util.List;
+import java.util.Random;
+
+
+/**
+ * A random literal selection heuristic. Returns a free variable at random with
+ * random polarity.
+ *
+ * If used sparsely, this heuristic can speed up the solving process (i.e. used
+ * as decoration 5% of the time).
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class RandomLit implements LiteralSelectionStrategy {
+ private final SetOfClauses F;
+
+ /**
+ * The heuristic has to operate on the formula {@code F}.
+ *
+ * @param solver
+ * reference to access formula {@code F}
+ */
+ public RandomLit(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ }
+
+ /**
+ * Returns a free random variable with random polarity.
+ *
+ * @return Free literal
+ */
+ @Override
+ public Integer getLiteral() {
+ List vars = F.getUnassignedVariablesList();
+
+ Random rand = new Random();
+ int randomNum = rand.nextInt(vars.size());
+ Variable var = vars.get(randomNum);
+
+ int randomBool = rand.nextInt(2);
+ int result;
+ if (randomBool == 1) {
+ result = var.getIndex();
+ } else {
+ result = -var.getIndex();
+ }
+
+ return result;
+
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+}
diff --git a/Heuristics/src/heuristicDecide/SLISVar.java b/Heuristics/src/heuristicDecide/SLISVar.java
new file mode 100644
index 0000000..ef4098d
--- /dev/null
+++ b/Heuristics/src/heuristicDecide/SLISVar.java
@@ -0,0 +1,137 @@
+package heuristicDecide;
+
+
+import formula.Clause;
+import heaps.Heap;
+import org.jetbrains.annotations.NotNull;
+import formula.SetOfClauses;
+import formula.Variable;
+import scores.ActivitiesVariable;
+import scores.Activity;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.VariableSelectionStrategy;
+import heaps.VariableHeapIntList;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import static java.lang.Math.abs;
+
+/**
+ * 2016/02/02.
+ */
+public class SLISVar implements SolverListener,VariableSelectionStrategy {
+ private final SetOfClauses F;
+ public Activity activities;
+ private Heap activityHeap;
+
+ private List toBump = new ArrayList<>();
+
+ public SLISVar(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ solver.addObserver(this);
+ }
+
+ @Override
+ public Variable getVariable() {
+ Integer var = activityHeap.pop();
+
+ //shift index from heap
+ boolean undef = F.isVariableUndefined(var+1);
+ while(!undef){
+ var = activityHeap.pop();
+ //shift index from heap
+ undef = F.isVariableUndefined(var+1);
+ }
+ //shift index from heap
+ return F.getVariable(var+1);
+ }
+
+ @Override
+ public void onConflict(Clause cl) {
+ }
+
+ @Override
+ public void onExplain(List ante, Integer resLit, List resolved) {
+ }
+
+ @Override
+ public void onBacktrack(Integer l) {
+ //shift index back
+ if(!activityHeap.contains(abs(l)-1))
+ activityHeap.push(abs(l)-1);
+ }
+
+
+ private void bumpVariableActivity(int var) {
+ //shift index back
+ activities.bump(var-1);
+
+ if(activityHeap.contains(var-1)){
+ activityHeap.increase(var-1);
+ }
+ }
+
+ private void bumpVarsInClause(List cl) {
+ for (Integer lit : cl) {
+ bumpVariableActivity(abs(lit));
+ }
+ }
+
+
+
+ @Override
+ public void onSetOfClausesLoaded() {
+ // Initialize variable array
+ Variable[] vars = F.getVariables();
+
+ // Initialize activity class by default constructor
+ activities = new ActivitiesVariable(10,1.0,vars.length);
+
+ // Initialize priority queue with custom activity comparator
+ activityHeap = new VariableHeapIntList(activities,vars.length);
+
+ for (Integer i = 0; i < F.getFreeVariablesCount(); i++) {
+ activityHeap.push(abs(i));
+ }
+
+ bumpVarsInClause(toBump);
+ }
+
+ @Override
+ public void onDecide(Integer ld) {
+
+ }
+
+ @Override
+ public void onUnitPropagate(List cl, Integer lu) {
+
+ }
+
+ @Override
+ public void onLearn(Clause cl) {
+
+ }
+
+ @Override
+ public void onForget(Clause cl) {
+
+ }
+
+ @Override
+ public void onLearnInitial(List cl) {
+ toBump.addAll(cl);
+ }
+
+ @Override
+ public void onRestart() {
+
+ }
+
+ @Override
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ }
+
+
+}
diff --git a/Heuristics/src/heuristicDecide/VariablePolarityLit.java b/Heuristics/src/heuristicDecide/VariablePolarityLit.java
new file mode 100644
index 0000000..d6bca49
--- /dev/null
+++ b/Heuristics/src/heuristicDecide/VariablePolarityLit.java
@@ -0,0 +1,90 @@
+package heuristicDecide;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Variable;
+import specificationCore.Solver;
+import specificationHeuristics.LiteralSelectionStrategy;
+import specificationHeuristics.PolaritySelectionStrategy;
+import specificationHeuristics.VariableSelectionStrategy;
+
+import java.util.Random;
+
+/**
+ * A strategy to select a variable and the polarity of it separately. Returns a
+ * random decision literal at 5% chance.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class VariablePolarityLit implements LiteralSelectionStrategy {
+ /**
+ * The variable selection heuristic.
+ */
+ private final VariableSelectionStrategy varStrategy;
+ /**
+ * The polarity selection heuristic.
+ */
+ private final PolaritySelectionStrategy polStrategy;
+ /**
+ * A random selection heuristic used as decoration.
+ */
+ private final RandomLit randStrategy;
+ /**
+ * A random seed.
+ */
+ private final Random seed = new Random();
+
+ /**
+ * Default constructor which saves the main module reference, the variable
+ * selection heuristic and the polarity selection heuristic.
+ *
+ * @param solver
+ * the main module reference.
+ * @param varS
+ * variable selection heuristic
+ * @param varP
+ * polarity selection heuristic
+ */
+ public VariablePolarityLit(@NotNull Solver solver, @NotNull VariableSelectionStrategy varS,
+ @NotNull PolaritySelectionStrategy varP) {
+ varStrategy = varS;
+ polStrategy = varP;
+
+ randStrategy = new RandomLit(solver);
+ }
+
+ /**
+ * Returns the literal with the variable index from the variable selection
+ * heuristic and the polarity of the polarity selection heuristic.
+ *
+ * @return free literal
+ */
+ @Override
+ public Integer getLiteral() {
+ float chance = seed.nextFloat();
+ int lit;
+
+ // Return a random literal 5% of the time
+ if (chance <= 0.001f) {
+ lit = randStrategy.getLiteral();
+ } else {
+ Variable var = varStrategy.getVariable();
+ assert var != null : "Null variable given";
+ lit = polStrategy.getPolarity(var.getIndex());
+ }
+
+ return lit;
+ }
+
+ public VariableSelectionStrategy getVarStrategy() {
+ return this.varStrategy;
+ }
+
+ public PolaritySelectionStrategy getPolStrategy() {
+ return this.polStrategy;
+ }
+
+ public String toString(){
+ return getPolStrategy().toString()+ " || "+ getVarStrategy().toString();
+ }
+}
diff --git a/Heuristics/src/heuristicForget/ForgetNever.java b/Heuristics/src/heuristicForget/ForgetNever.java
new file mode 100644
index 0000000..cae6d82
--- /dev/null
+++ b/Heuristics/src/heuristicForget/ForgetNever.java
@@ -0,0 +1,38 @@
+package heuristicForget;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import specificationCore.Solver;
+import specificationHeuristics.ForgetStrategy;
+
+import java.util.ArrayList;
+
+/**
+ * Forget strategy with a default response to never forget clauses.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class ForgetNever implements ForgetStrategy {
+ public ForgetNever(@NotNull Solver solver) {}
+
+ @Override
+ public boolean shouldForget() {
+ return false;
+ }
+
+ @Override
+ public ArrayList forgetClauses() {
+ throw new NullPointerException("Function call forbidden.");
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString(){
+ return getClass().getName();
+ }
+}
diff --git a/Heuristics/src/heuristicForget/ForgetRandomLarge.java b/Heuristics/src/heuristicForget/ForgetRandomLarge.java
new file mode 100644
index 0000000..982a23f
--- /dev/null
+++ b/Heuristics/src/heuristicForget/ForgetRandomLarge.java
@@ -0,0 +1,170 @@
+package heuristicForget;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import formula.SetOfClauses;
+import specificationCore.*;
+import specificationHeuristics.ForgetStrategy;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Random;
+
+
+/**
+ * Implementation of a simple forget heuristic based on learned clause count and
+ * random forget chance, only for large clauses.
+ *
+ * After every 100 clauses learned, this strategy tells the solver to forget
+ * each learned clause with a chance of 50%, if the clause is a big clause.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class ForgetRandomLarge implements ForgetStrategy, SolverListener {
+ public static Integer THRESHOLD;
+ /**
+ * Counter to keep track of learned clauses.
+ */
+ Integer learnClauseCount = 0;
+ /**
+ * Random seed.
+ */
+ private final Random r;
+ /**
+ * Saved formula reference.
+ */
+ private final SetOfClauses F;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * Adds itself as a observer to respond to learned clauses.
+ *
+ * @param solver
+ * the main module reference.
+ */
+ public ForgetRandomLarge(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ solver.addObserver(this);
+ r = new Random();
+ }
+
+ /**
+ * Solver should forget some learned big clauses after every 100 clauses
+ * learned.
+ *
+ * @return {@code true}, if solver should forget some big clauses;
+ * {@code false} otherwise
+ */
+ @Override
+ public boolean shouldForget() {
+ return learnClauseCount > THRESHOLD;
+ }
+
+ /**
+ * Removes every learned big clause with a chance of 50%.
+ *
+ * @return removed clauses
+ */
+ @Override
+ public ArrayList forgetClauses() {
+ learnClauseCount = 0;
+
+ List cl = F.getLearnedClauses();
+ ArrayList forgot = new ArrayList<>();
+ for (Clause c : cl) {
+ float chance = r.nextFloat();
+ if (c.getLiterals().size() > 20) {
+ if (chance <= 0.50f) {
+ forgot.add(c);
+ }
+ }
+ }
+ forgot.forEach(F::forgetLearnedClause);
+
+ return forgot;
+ }
+
+ /**
+ * On clause learn increase counter.
+ * @param cl
+ */
+ @Override
+ public void onLearn(Clause cl) {
+ learnClauseCount++;
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onRestart() {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ public void onConflict(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onUnitPropagate(List cl, Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onExplain(List ante, Integer resLit,
+ List resolvente) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ public void onForget(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onLearnInitial(List cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onSetOfClausesLoaded() {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBacktrack(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onDecide(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+}
diff --git a/Heuristics/src/heuristicForget/ForgetRandomShort.java b/Heuristics/src/heuristicForget/ForgetRandomShort.java
new file mode 100644
index 0000000..728d3bb
--- /dev/null
+++ b/Heuristics/src/heuristicForget/ForgetRandomShort.java
@@ -0,0 +1,169 @@
+package heuristicForget;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import formula.SetOfClauses;
+import specificationCore.*;
+import specificationHeuristics.ForgetStrategy;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Random;
+
+/**
+ * Implementation of a simple forget heuristic based on learned clause count and
+ * random forget chance, only for large clauses.
+ *
+ * After every 100 clauses learned, this strategy tells the solver to forget
+ * each learned clause with a chance of 50%, if the clause is a small clause.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class ForgetRandomShort implements ForgetStrategy,SolverListener {
+ public static Integer THRESHOLD;
+ /**
+ * Counter to keep track of learned clauses.
+ */
+ private int learnClauseCount = 0;
+ /**
+ * Random seed.
+ */
+ private final Random r;
+ /**
+ * Saved formula reference;
+ */
+ private final SetOfClauses F;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * Adds itself as a observer to respond to learned clauses.
+ *
+ * @param solver
+ * the main module reference.
+ */
+ public ForgetRandomShort(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ solver.addObserver(this);
+ r = new Random();
+ }
+
+ /**
+ * Solver should forget some learned small clauses after every 100 clauses
+ * learned.
+ *
+ * @return {@code true}, if solver should forget some big clauses;
+ * {@code false} otherwise
+ */
+ @Override
+ public boolean shouldForget() {
+ return learnClauseCount > THRESHOLD;
+ }
+
+ /**
+ * Removes every learned small clause with a chance of 50%.
+ *
+ * @return removed clauses
+ */
+ @Override
+ public ArrayList forgetClauses() {
+ learnClauseCount = 0;
+
+ List cl = F.getLearnedClauses();
+ ArrayList forgot = new ArrayList<>();
+ for (Clause c : cl) {
+ float chance = r.nextFloat();
+ if (c.getLiterals().size() <= 20) {
+ if (chance <= 0.50f) {
+ forgot.add(c);
+ }
+ }
+ }
+ forgot.forEach(F::forgetLearnedClause);
+
+ return forgot;
+ }
+
+ /**
+ * On clause learn increase counter.
+ * @param cl
+ */
+ @Override
+ public void onLearn(Clause cl) {
+ learnClauseCount++;
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onRestart() {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ public void onConflict(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onUnitPropagate(List cl, Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onExplain(List ante, Integer resLit,
+ List resolvente) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ public void onForget(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onLearnInitial(List cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onSetOfClausesLoaded() {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBacktrack(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onDecide(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString(){
+ return getClass().getName();
+ }
+}
diff --git a/Heuristics/src/heuristicForget/ForgetSimple.java b/Heuristics/src/heuristicForget/ForgetSimple.java
new file mode 100644
index 0000000..d084888
--- /dev/null
+++ b/Heuristics/src/heuristicForget/ForgetSimple.java
@@ -0,0 +1,160 @@
+package heuristicForget;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import formula.SetOfClauses;
+import specificationCore.*;
+import specificationHeuristics.ForgetStrategy;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Random;
+
+/**
+ * Implementation of a simple forget heuristic based on learned clause count and
+ * random forget chance.
+ *
+ * After every 200 clauses learned, this strategy tells the solver to forget
+ * each learned clause with a chance of 25%.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class ForgetSimple implements ForgetStrategy, SolverListener {
+ public static int THRESHOLD = 1000;
+ /**
+ * Counter to keep track of learned clauses.
+ */
+ private int learnClauseCount;
+
+ /**
+ * Random seed.
+ */
+ private final Random r;
+
+ /**
+ * Saved formula reference.
+ */
+ private final SetOfClauses F;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * Adds itself as a observer to respond to learned clauses.
+ *
+ * @param solver
+ * the main module reference.
+ */
+ public ForgetSimple(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ solver.addObserver(this);
+ learnClauseCount = 0;
+ r = new Random();
+ }
+
+ /**
+ * Solver should forget some learned clauses after every 200 clauses
+ * learned.
+ *
+ * @return {@code true}, if solver should forget some clauses; {@code false}
+ * otherwise
+ */
+ @Override
+ public boolean shouldForget() {
+ return learnClauseCount > THRESHOLD;
+ }
+
+ /**
+ * Removes every learned clause with a chance of 25%.
+ *
+ * @return removed clauses
+ */
+ @Override
+ public ArrayList forgetClauses() {
+ learnClauseCount = 0;
+
+ List cl = F.getLearnedClauses();
+ ArrayList forgot = new ArrayList<>();
+ for (Clause c : cl) {
+ float chance = r.nextFloat();
+ if (chance <= 0.33f) {
+ forgot.add(c);
+ }
+ }
+ forgot.forEach(F::forgetLearnedClause);
+
+ return forgot;
+ }
+
+ /**
+ * On clause learn increase counter.
+ * @param cl
+ */
+ @Override
+ public void onLearn(Clause cl) {
+ learnClauseCount++;
+ }
+
+ /**
+ * Restart response not needed in this heuristic.
+ */
+ public void onRestart() {
+ }
+
+ /**
+ * Conflict response not needed in this heuristic.
+ * @param cl
+ */
+ public void onConflict(Clause cl) {
+ }
+
+ /**
+ * Unit response not needed in this heuristic.
+ */
+ public void onUnitPropagate(List cl, Integer l) {
+ }
+
+ /**
+ * Explain response not needed in this heuristic.
+ */
+ public void onExplain(List ante, Integer resLit,
+ List resolvente) {
+ }
+
+ /**
+ * Forget response not needed in this heuristic.
+ * @param cl
+ */
+ public void onForget(Clause cl) {
+ }
+
+ /**
+ * Initial learn response not needed in this heuristic.
+ */
+ public void onLearnInitial(List cl) {
+ }
+
+ /**
+ * Formula loaded response not needed in this heuristic.
+ */
+ public void onSetOfClausesLoaded() {
+ }
+
+ /**
+ * Backtrack response not needed in this heuristic.
+ */
+ public void onBacktrack(Integer l) {
+ }
+
+ /**
+ * Decide response not needed in this heuristic.
+ */
+ public void onDecide(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBackjump(Integer current, Integer bl, Integer uip) {}
+
+}
diff --git a/Heuristics/src/heuristicForget/ForgetSize.java b/Heuristics/src/heuristicForget/ForgetSize.java
new file mode 100644
index 0000000..a7481e9
--- /dev/null
+++ b/Heuristics/src/heuristicForget/ForgetSize.java
@@ -0,0 +1,149 @@
+package heuristicForget;
+
+import formula.Clause;
+import formula.SetOfClauses;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.ForgetStrategy;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Random;
+
+public class ForgetSize implements ForgetStrategy, SolverListener {
+ public static int PERCENT = 100;
+
+ private int learnClauseCount;
+
+ /**
+ * Random seed.
+ */
+ private final Random r;
+
+ /**
+ * Saved formula reference.
+ */
+ private final SetOfClauses F;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * Adds itself as a observer to respond to learned clauses.
+ *
+ * @param solver
+ * the main module reference.
+ */
+ public ForgetSize(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ solver.addObserver(this);
+ learnClauseCount = 0;
+ r = new Random();
+ }
+
+ /**
+ * Solver should forget some learned clauses after every 200 clauses
+ * learned.
+ *
+ * @return {@code true}, if solver should forget some clauses; {@code false}
+ * otherwise
+ */
+ @Override
+ public boolean shouldForget() {
+ return learnClauseCount > ((PERCENT/100.)*(F.getInitialClauses().size()));
+ }
+
+ /**
+ * Removes every learned clause with a chance of 25%.
+ *
+ * @return removed clauses
+ */
+ @Override
+ public ArrayList forgetClauses() {
+ learnClauseCount = 0;
+
+ List cl = F.getLearnedClauses();
+ ArrayList forgot = new ArrayList<>();
+ for (Clause c : cl) {
+ float chance = r.nextFloat();
+ if (chance <= 0.33f) {
+ forgot.add(c);
+ }
+ }
+ forgot.forEach(F::forgetLearnedClause);
+
+ return forgot;
+ }
+
+ /**
+ * On clause learn increase counter.
+ * @param cl
+ */
+ @Override
+ public void onLearn(Clause cl) {
+ learnClauseCount++;
+ }
+
+ /**
+ * Restart response not needed in this heuristic.
+ */
+ public void onRestart() {
+ }
+
+ /**
+ * Conflict response not needed in this heuristic.
+ * @param cl
+ */
+ public void onConflict(Clause cl) {
+ }
+
+ /**
+ * Unit response not needed in this heuristic.
+ */
+ public void onUnitPropagate(List cl, Integer l) {
+ }
+
+ /**
+ * Explain response not needed in this heuristic.
+ */
+ public void onExplain(List ante, Integer resLit,
+ List resolvente) {
+ }
+
+ /**
+ * Forget response not needed in this heuristic.
+ * @param cl
+ */
+ public void onForget(Clause cl) {
+ }
+
+ /**
+ * Initial learn response not needed in this heuristic.
+ */
+ public void onLearnInitial(List cl) {
+ }
+
+ /**
+ * Formula loaded response not needed in this heuristic.
+ */
+ public void onSetOfClausesLoaded() {
+ }
+
+ /**
+ * Backtrack response not needed in this heuristic.
+ */
+ public void onBacktrack(Integer l) {
+ }
+
+ /**
+ * Decide response not needed in this heuristic.
+ */
+ public void onDecide(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBackjump(Integer current, Integer bl, Integer uip) {}
+
+}
diff --git a/Heuristics/src/heuristicLearn/LearnNever.java b/Heuristics/src/heuristicLearn/LearnNever.java
new file mode 100644
index 0000000..28a43a6
--- /dev/null
+++ b/Heuristics/src/heuristicLearn/LearnNever.java
@@ -0,0 +1,37 @@
+package heuristicLearn;
+
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+import specificationHeuristics.LearnStrategy;
+
+/**
+ * Learn strategy with a default response to never learn new clauses.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class LearnNever implements LearnStrategy {
+ public LearnNever(@NotNull Solver solver) {
+ }
+
+ @Override
+ public boolean shouldLearn() {
+ return false;
+ }
+
+ @Override
+ public Clause learnClause() {
+ throw new NullPointerException("Function call forbidden.");
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+}
diff --git a/Heuristics/src/heuristicLearn/LearnSimple.java b/Heuristics/src/heuristicLearn/LearnSimple.java
new file mode 100644
index 0000000..3038c4f
--- /dev/null
+++ b/Heuristics/src/heuristicLearn/LearnSimple.java
@@ -0,0 +1,57 @@
+package heuristicLearn;
+
+
+import formula.Clause;
+import formula.SetOfClauses;
+import specificationCore.Solver;
+import specificationCore.State;
+import specificationHeuristics.LearnStrategy;
+
+/**
+ * Implementation of a simple learn heuristic. Learns every (resolved) clause
+ * after a conflict.
+ *
+ * @author Albert Schimpf
+ */
+public class LearnSimple implements LearnStrategy { /**
+ * Saved solver reference.
+ */
+ private final State state;
+
+ public LearnSimple(Solver solver) {
+ this.state = solver.getState();
+ }
+
+ @Override
+ public boolean shouldLearn() {
+ return state.C() != null;
+
+ //proven to be not needed
+// // If clause is already in learned clauses, learn can not be applied
+// if (F.getLearnedClauses().indexOf(state.getC()) != -1) {
+// return false;
+// }
+//
+// // If clause is already in initial clauses, learn can not be applied
+// return F.getInitialClauses().indexOf(state.getC()) == -1;
+
+ }
+
+ @Override
+ public Clause learnClause() {
+ Clause c = state.F().addLearnedClause(state.C());
+
+ return c;
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+
+}
\ No newline at end of file
diff --git a/Heuristics/src/heuristicRestart/RestartConflictCountingFixed.java b/Heuristics/src/heuristicRestart/RestartConflictCountingFixed.java
new file mode 100644
index 0000000..b1d6a1a
--- /dev/null
+++ b/Heuristics/src/heuristicRestart/RestartConflictCountingFixed.java
@@ -0,0 +1,177 @@
+package heuristicRestart;
+
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.RestartStrategy;
+
+import java.util.List;
+
+/**
+ * Restart heuristic based on a fixed restart poInteger after a certain conflict
+ * threshold has been reached.
+ *
+ * Options:
+ *
+ * - 0: Berkmin (550 conflicts)
+ *
- 1: Chaff (700 conflicts)
+ *
- 2: Eureka (2000 conflicts)
+ *
- 3: Siege (16000 conflicts)
+ *
+ *
+ * Aggressive restarts should only be used in conjunction with clause learning.
+ *
+ * @author Albert Schimpf
+ */
+public class RestartConflictCountingFixed implements RestartStrategy,
+ SolverListener {
+ //can be set by param class when parsing program arguments
+ public static Integer NEXTRESTART = 500;
+
+ /**
+ * Counter to keep track of conflicts.
+ */
+ private Integer conflictCount;
+ /**
+ * Counter to keep track of when to restart.
+ */
+ private Integer conflictsForNextRestart;
+ /**
+ * Factor to increase the threshold, when it is reached.
+ */
+ private Integer conflictsForNextRestartConst;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * Adds itself as a observer to respond to certain rules.
+ *
+ * Calculates the number of conflicts for the first restart.
+ *
+ * @param solver
+ * the main module reference.
+ */
+ public RestartConflictCountingFixed(@NotNull Solver solver) {
+ solver.addObserver(this);
+ conflictCount = 0;
+ conflictsForNextRestart = 0;
+ conflictsForNextRestartConst = 0;
+ calculateConflictForFirstRestart();
+ }
+
+ /**
+ * If conflicts reach the conflict threshold, tell the solver to restart.
+ *
+ * @return {@code true}, if threshold is reached; {@code false} otherwise
+ */
+ @Override
+ public boolean shouldRestart() {
+ return conflictCount >= conflictsForNextRestart;
+ }
+
+ /**
+ * On restart reset conflict count, and increase threshold by given
+ * constant.
+ */
+ @Override
+ public void onRestart() {
+ conflictCount = 0;
+ calculateConflictsForNextRestart();
+ }
+
+ /**
+ * Calculates the threshold for the first restart based on which fixed
+ * heuristic is given.
+ */
+ private void calculateConflictForFirstRestart() {
+ conflictsForNextRestartConst = 0;
+ // Berkmin: 550 // Zchaff: 700
+ // Eureka: 2000 // Siege: 20000
+ conflictsForNextRestart = NEXTRESTART;
+ }
+
+ /**
+ * Increases the current threshold by {@code conflictsForNextRestartConst}
+ * constant.
+ */
+ private void calculateConflictsForNextRestart() {
+ conflictsForNextRestart += conflictsForNextRestartConst;
+ }
+
+ /**
+ * Increase conflict counter on conflict
+ * @param cl
+ */
+ @Override
+ public void onConflict(Clause cl) {
+ conflictCount++;
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+
+ /**
+ * Response not needed in this heuristic
+ */
+ public void onUnitPropagate(List cl, Integer l) {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ */
+ public void onExplain(List ante, Integer resLit,
+ List resolvente) {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ * @param cl
+ */
+ public void onLearn(Clause cl) {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ * @param cl
+ */
+ public void onForget(Clause cl) {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ */
+ public void onLearnInitial(List cl) {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ */
+ public void onSetOfClausesLoaded() {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ */
+ public void onBacktrack(Integer l) {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ */
+ public void onDecide(Integer l) {
+ }
+
+ /**
+ * Response not needed in this heuristic
+ */
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ }
+}
diff --git a/Heuristics/src/heuristicRestart/RestartConflictCountingGeometric.java b/Heuristics/src/heuristicRestart/RestartConflictCountingGeometric.java
new file mode 100644
index 0000000..eced3fe
--- /dev/null
+++ b/Heuristics/src/heuristicRestart/RestartConflictCountingGeometric.java
@@ -0,0 +1,166 @@
+package heuristicRestart;
+
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.RestartStrategy;
+
+import java.util.List;
+
+/**
+ * Restart heuristic based on MiniSAT restart.
+ *
+ * After an initial count of conflict, this strategy tells the solver to
+ * restart, and multiplying the restart threshold by a given factor.
+ *
+ * @author Albert Schimpf
+ */
+public class RestartConflictCountingGeometric implements RestartStrategy,
+ SolverListener {
+
+ public static double NEXTRESTARTCONST = 1.5;
+ public static Integer NEXTRESTART = 150;
+ /**
+ * Counter to keep track of conflicts.
+ */
+ private Integer conflictCount;
+ /**
+ * Counter to keep track of when to restart.
+ */
+ private float conflictsForNextRestart;
+ /**
+ * Factor to multiply the threshold, when it is reached.
+ */
+ private float conflictsForNextRestartConst;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * Adds itself as a observer to respond to certain rules.
+ *
+ * Calculates the number of conflicts for the first restart.
+ *
+ * @param solver
+ * the main module reference.
+ */
+ public RestartConflictCountingGeometric(@NotNull Solver solver) {
+ solver.addObserver(this);
+ conflictCount = 0;
+ conflictsForNextRestart = 0;
+ calculateConflictForFirstRestart();
+ }
+
+ /**
+ * If conflicts reach the conflict threshold, tell the solver to restart.
+ *
+ * @return {@code true}, if threshold is reached; {@code false} otherwise
+ */
+ @Override
+ public boolean shouldRestart() {
+ return conflictCount >= conflictsForNextRestart;
+ }
+
+ /**
+ * On restart reset conflict count, and increase threshold.
+ */
+ @Override
+ public void onRestart() {
+ conflictCount = 0;
+ calculateConflictsForNextRestart();
+ }
+
+ /**
+ * Calculates the threshold for the first restart based on which geometric
+ * heuristic is given.
+ */
+ private void calculateConflictForFirstRestart() {
+ conflictsForNextRestartConst = (float) NEXTRESTARTCONST;
+ conflictsForNextRestart = NEXTRESTART;
+ }
+
+ /**
+ * Multiplies the current threshold with
+ * {@code conflictsForNextRestartConst} factor.
+ */
+ private void calculateConflictsForNextRestart() {
+ conflictsForNextRestart *= conflictsForNextRestartConst;
+ }
+
+ /**
+ * Increase conflict counter on conflict.
+ * @param cl
+ */
+ public void onConflict(Clause cl) {
+ conflictCount++;
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onUnitPropagate(List cl, Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onExplain(List ante, Integer resLit,
+ List resolvente) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ public void onLearn(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ * @param cl
+ */
+ public void onForget(Clause cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onLearnInitial(List cl) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onSetOfClausesLoaded() {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBacktrack(Integer l) {
+ }
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onDecide(Integer l) {
+ }
+
+
+ /**
+ * Not needed in this heuristic.
+ */
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+
+}
diff --git a/Heuristics/src/heuristicRestart/RestartNever.java b/Heuristics/src/heuristicRestart/RestartNever.java
new file mode 100644
index 0000000..c23a74e
--- /dev/null
+++ b/Heuristics/src/heuristicRestart/RestartNever.java
@@ -0,0 +1,32 @@
+package heuristicRestart;
+
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+import specificationHeuristics.RestartStrategy;
+
+/**
+ * Restart strategy with a default response to never restart.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class RestartNever implements RestartStrategy {
+ public RestartNever(@NotNull Solver solver) {
+ }
+
+ @Override
+ public boolean shouldRestart() {
+ return false;
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+
+}
diff --git a/Logger/Logger.iml b/Logger/Logger.iml
new file mode 100644
index 0000000..709e7db
--- /dev/null
+++ b/Logger/Logger.iml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Logger/src/logger/SolverLogger.java b/Logger/src/logger/SolverLogger.java
new file mode 100644
index 0000000..5933393
--- /dev/null
+++ b/Logger/src/logger/SolverLogger.java
@@ -0,0 +1,221 @@
+package logger;
+
+import formula.Clause;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+
+import java.util.List;
+
+/**
+ * Logs all operations and counts them. Displays them at the end of the solving
+ * process in the console, if enabled in the main module.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class SolverLogger implements SolverListener {
+ /*
+ * Various counters
+ */
+ private Integer opCount = 0;
+ private Integer decideCount = 0;
+ private Integer unitCount = 0;
+ private Integer conflictCount = 0;
+ private Integer ignoredDl = 0;
+ private Integer highestDl = 1;
+ private Integer resolutionCount = 0;
+ private Integer learnedCount = 0;
+ private Integer learnedLit = 0;
+ private Integer learnedBin = 0;
+ private Integer learnedTer = 0;
+ private Integer forgottenCount = 0;
+ private Integer restartCount = 0;
+ private Integer initialClauses = 0;
+ private Integer initialLit = 0;
+ private Integer initialBin = 0;
+ private Integer initialTer = 0;
+
+ private long start;
+
+ /*
+ * Save heuristic argument names
+ */
+ private final String highlevel;
+ private final String trail;
+ private final String set;
+ private final String forget;
+ private final String learn;
+ private final String restart;
+ private final String literal;
+
+ private long conv = 0;
+
+
+ /**
+ * Default constructor of a solver logger.
+ *
+ * @param solver parameter.Param solver reference.
+ */
+ public SolverLogger(Solver solver) {
+ solver.addObserver(this);
+ start = System.currentTimeMillis();
+
+ highlevel = solver.getHighlevelStrategy().toString();
+ trail = solver.getState().M().toString();
+ set = solver.getState().F().toString();
+ forget = solver.getHighlevelStrategy().getForgetStrategy().toString();
+ learn = solver.getHighlevelStrategy().getLearnStrategy().toString();
+ restart = solver.getHighlevelStrategy().getRestartStrategy().toString();
+ literal = solver.getHighlevelStrategy().getLiteralSelectionStrategy().toString();
+ }
+
+ @Override
+ public void onDecide(Integer ld) {
+ opCount++;
+ decideCount++;
+ }
+
+ @Override
+ public void onUnitPropagate(List cl, Integer lu) {
+ opCount++;
+ unitCount++;
+ }
+
+ @Override
+ public void onConflict(Clause cl) {
+ opCount++;
+ conflictCount++;
+ }
+
+ @Override
+ public void onBacktrack(Integer l) {
+ opCount++;
+ }
+
+ @Override
+ public void onExplain(List ante, Integer resLit,
+ List resolved) {
+ opCount++;
+ resolutionCount++;
+ }
+
+ @Override
+ public void onLearn(Clause cl) {
+ opCount++;
+ learnedCount++;
+
+ Integer size = cl.getLiterals().size();
+ if (size == 1) {
+ learnedLit++;
+ }
+ if (size == 2) {
+ learnedBin++;
+ }
+ if (size == 3) {
+ learnedTer++;
+ }
+ }
+
+ @Override
+ public void onForget(Clause cl) {
+ opCount++;
+ forgottenCount++;
+ }
+
+ @Override
+ public void onRestart() {
+ opCount++;
+ restartCount++;
+ }
+
+ @Override
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ opCount++;
+ assert (current - (bl + 1)) >= 0;
+ ignoredDl += (current - (bl + 1));
+ if (current - bl > highestDl) {
+ highestDl = current - bl;
+ }
+ }
+
+ @Override
+ public void onLearnInitial(List cl) {
+ initialClauses++;
+ if (cl.size() == 1) {
+ initialLit++;
+ }
+ if (cl.size() == 2) {
+ initialBin++;
+ }
+ if (cl.size() == 3) {
+ initialTer++;
+ }
+ }
+
+ @Override
+ public void onSetOfClausesLoaded() {
+ long stopTime = System.currentTimeMillis();
+
+ conv = stopTime - start;
+ }
+
+ /**
+ * Prints accumulated information after the instances satisfiability has
+ * been determined.
+ */
+ public void printFinishLog() {
+ System.out
+ .println("c START FINISH LOG --------------------------------------");
+
+ System.out.println("c Initial (literal) [binary] {ternary}: "
+ + initialClauses + " (" + initialLit + ")[" + initialBin + "]{"
+ + initialTer + "} "
+ + (initialClauses - initialLit - initialBin - initialTer));
+
+ System.out.println("c Operations: " + opCount);
+ System.out.println("c Decision: " + decideCount);
+ System.out.println("c Unit propagations: " + unitCount);
+ System.out.println("c Conflicts/Branches: " + conflictCount);
+ System.out.println("c Ignored decisionlevels: " + ignoredDl);
+ if (conflictCount != 0) {
+ System.out
+ .println("c Average (Highest) decision level jump: "
+ + Math.round(((float) (decideCount + ignoredDl) / (float) conflictCount))
+ + " (" + highestDl + ")");
+ } else {
+ System.out.println("c Average decision level jump: 0");
+ }
+
+ System.out.println("c Resolutions: " + resolutionCount);
+ System.out.println("c Learned (literal) [binary] {ternary}: "
+ + learnedCount + "(" + learnedLit + ")[" + learnedBin + "]{"
+ + learnedTer + "}");
+ System.out.println("c Forgotten clauses: " + forgottenCount);
+ System.out.println("c Restarts: " + restartCount);
+
+ long stopTime = System.currentTimeMillis();
+ long elapsedTime = stopTime - start;
+ assert elapsedTime >= 0;
+ System.out.println("c Time spent: " + elapsedTime + " ms"+
+ "("+conv+" ms + "+(elapsedTime-conv)+" ms)"
+ );
+
+ }
+
+ /**
+ * Prints initial information before the solving process has been started.
+ */
+ public void printInitialLog() {
+ System.out
+ .println("c START OPTIONS ------------------------------------");
+ System.out.println("c High-level strategy: " + highlevel);
+ System.out.println("c Trail structure: " + trail);
+ System.out.println("c Data structure: " + set);
+ System.out.println("c Decision heuristic: " + literal);
+
+ System.out.println("c Forget : " + forget);
+ System.out.println("c Learn : " + learn);
+ System.out.println("c Restart : " + restart);
+
+ }
+}
diff --git a/Logger/src/logger/TimeoutLogger.java b/Logger/src/logger/TimeoutLogger.java
new file mode 100644
index 0000000..c4899cf
--- /dev/null
+++ b/Logger/src/logger/TimeoutLogger.java
@@ -0,0 +1,126 @@
+package logger;
+
+
+import exceptions.SolverTimeoutException;
+import formula.Clause;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+
+import java.util.List;
+
+/**
+ * Logger, to throw a {@code runtimeException}, if given time threshold is
+ * reached.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class TimeoutLogger implements SolverListener {
+ /**
+ * Starting system time.
+ */
+ private long start;
+ /**
+ * Internal time threshold convert to milliseconds..
+ */
+ private long timeThreshold;
+
+ /**
+ * Default constructor to save given time threshold and add the logger to
+ * the observer list.
+ *
+ * @param solver
+ * parameter.Param module
+ * @param timeout
+ * Time threshold in seconds
+ */
+ public TimeoutLogger(Solver solver, long timeout) {
+ solver.addObserver(this);
+ start = System.currentTimeMillis();
+ timeThreshold = timeout * 1000;
+ }
+
+ /**
+ * Forces the solver to time out, if called by another thread.
+ */
+ public void forceTimeout() {
+ timeThreshold = 0;
+ }
+
+ /**
+ * Check on conflict, if time threshold is reached.
+ *
+ * @throws SolverTimeoutException
+ * if threshold is reached.
+ * @param cl
+ */
+ @Override
+ public void onConflict(Clause cl) {
+ long stopTime = System.currentTimeMillis();
+ long elapsedTime = stopTime - start;
+ if (elapsedTime > timeThreshold) {
+ throw new SolverTimeoutException(
+ "Solver timed out. Given time in seconds: " + timeThreshold
+ / 1000);
+ }
+ }
+
+ /**
+ * Check on explain, if time threshold is reached.
+ *
+ * @throws SolverTimeoutException
+ * if threshold is reached.
+ */
+ @Override
+ public void onExplain(List ante, Integer resLit,
+ List resolved) {
+
+ long stopTime = System.currentTimeMillis();
+ long elapsedTime = stopTime - start;
+ if (elapsedTime > timeThreshold) {
+ throw new SolverTimeoutException(
+ "Solver timed out. Given time in seconds: " + timeThreshold
+ / 1000);
+ }
+
+ }
+
+ /*
+ * Other responses not needed.
+ */
+ @Override
+ public void onDecide(Integer ld) {
+ }
+
+ @Override
+ public void onUnitPropagate(List cl, Integer lu) {
+ }
+
+ @Override
+ public void onBacktrack(Integer l) {
+ }
+
+ @Override
+ public void onLearn(Clause cl) {
+ }
+
+ @Override
+ public void onForget(Clause cl) {
+ }
+
+ @Override
+ public void onRestart() {
+ }
+
+ @Override
+ public void onBackjump(Integer current, Integer bl, Integer uip) {
+ }
+
+ @Override
+ public void onLearnInitial(List cl) {
+ }
+
+ @Override
+ public void onSetOfClausesLoaded() {
+ }
+}
diff --git a/ModularSATFramework.iml b/ModularSATFramework.iml
new file mode 100644
index 0000000..1fdc90c
--- /dev/null
+++ b/ModularSATFramework.iml
@@ -0,0 +1,40 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Preprocessing/Preprocessing.iml b/Preprocessing/Preprocessing.iml
new file mode 100644
index 0000000..709e7db
--- /dev/null
+++ b/Preprocessing/Preprocessing.iml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Preprocessing/src/dimacsConverter/StrictConverter.java b/Preprocessing/src/dimacsConverter/StrictConverter.java
new file mode 100644
index 0000000..6ef728b
--- /dev/null
+++ b/Preprocessing/src/dimacsConverter/StrictConverter.java
@@ -0,0 +1,88 @@
+package dimacsConverter;
+
+
+import exceptions.ConvertException;
+import specificationCore.ConverterObserver;
+
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileReader;
+import java.io.IOException;
+
+/**
+ * Class container for the static convert method.
+ */
+public class StrictConverter {
+ private StrictConverter() {
+ }
+
+ /**
+ * Reads a DIMACS file and converts it to be able to hand it to the internal data structure.
+ *
+ * Updates the observer accordingly.
+ *
+ * @param path to DIMACS file
+ * @throws ConvertException if an error occurs during file conversion.
+ * @throws IOException if an error occurs during file loading
+ */
+ public static void dimacsToSet(File path, ConverterObserver obs)
+ throws ConvertException, IOException {
+ if (path == null) {
+ throw new NullPointerException();
+ }
+ if (obs == null) {
+ throw new NullPointerException();
+ }
+ assert path.exists() && !path.isDirectory(): "Path error: "+path.toString();
+
+ //open file as BufferedReader, closes stream automatically after try block
+ try (BufferedReader reader = new BufferedReader(new FileReader(path))) {
+ convert(reader, obs);
+ }
+ }
+
+ private static void convert(BufferedReader bufferedReader, ConverterObserver obs)
+ throws IOException, ConvertException {
+ /*
+ * Example Implementation
+ */
+ String curLine;
+ curLine = bufferedReader.readLine();
+
+ //read lines
+ while (curLine != null) {
+ curLine = curLine.trim();
+ if (curLine.charAt(0) != 'c') {
+ if (curLine.charAt(0) == 'p') {
+ String[] splitted = curLine.split(" ");
+ obs.clauseCount(Integer.valueOf(splitted[3]));
+ obs.variableCount(Integer.valueOf(splitted[2]));
+ } else {
+ obs.startClause();
+
+ String[] splitted;
+ if (!curLine.contains("\t")) {
+ splitted = curLine.split(" ");
+ } else {
+ splitted = curLine.split("\\t");
+ }
+
+ for (String s : splitted) {
+ if (!s.equals("0")) {
+ if (s.charAt(0) == '-') {
+ int index = Integer.valueOf(s.substring(1));
+ obs.literal(index, true);
+ } else {
+ int index = Integer.valueOf(s);
+ obs.literal(index, false);
+ }
+ }
+ }
+
+ obs.endClause();
+ }
+ }
+ curLine = bufferedReader.readLine();
+ }
+ }
+}
diff --git a/Specification/Specification.iml b/Specification/Specification.iml
new file mode 100644
index 0000000..c90834f
--- /dev/null
+++ b/Specification/Specification.iml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Specification/src/exceptions/ConvertException.java b/Specification/src/exceptions/ConvertException.java
new file mode 100644
index 0000000..0622355
--- /dev/null
+++ b/Specification/src/exceptions/ConvertException.java
@@ -0,0 +1,13 @@
+package exceptions;
+
+/**
+ * Checked exception, which gets thrown, if an error occurs during internal file conversion from a DIMACS file.
+ */
+public class ConvertException extends Exception{
+
+ public ConvertException(String string) {
+ super(string);
+ }
+
+ private static final long serialVersionUID = 1L;
+}
diff --git a/Specification/src/exceptions/SolverTimeoutException.java b/Specification/src/exceptions/SolverTimeoutException.java
new file mode 100644
index 0000000..e15c9d5
--- /dev/null
+++ b/Specification/src/exceptions/SolverTimeoutException.java
@@ -0,0 +1,13 @@
+package exceptions;
+
+/**
+ * Unchecked exception, which will be thrown, if a given time threshold is reached.
+ */
+public class SolverTimeoutException extends RuntimeException{
+
+ public SolverTimeoutException(String string) {
+ super(string);
+ }
+
+ private static final long serialVersionUID = 1L;
+}
diff --git a/Specification/src/formula/Clause.java b/Specification/src/formula/Clause.java
new file mode 100644
index 0000000..ba79286
--- /dev/null
+++ b/Specification/src/formula/Clause.java
@@ -0,0 +1,17 @@
+package formula;
+
+
+import java.util.List;
+
+
+public interface Clause {
+ boolean isConflicting();
+ boolean isUnit();
+
+ Integer getUnitLiteral();
+ List getLiterals();
+
+ void addLiteral(Integer lit);
+ void removeConnectionToVariables();
+ void assertConflictingState();
+}
diff --git a/Specification/src/formula/SetOfClauses.java b/Specification/src/formula/SetOfClauses.java
new file mode 100644
index 0000000..a442004
--- /dev/null
+++ b/Specification/src/formula/SetOfClauses.java
@@ -0,0 +1,89 @@
+package formula;
+
+import specificationCore.ConverterObserver;
+import specificationCore.Solver;
+
+import java.util.*;
+
+import static java.lang.Math.abs;
+
+
+public interface SetOfClauses extends ConverterObserver {
+
+ Clause getUnitClause();
+ Clause getConflictingClause();
+ Variable getVariable(Integer lit);
+
+ void undoAssignment(Integer varIndex);
+ void setVariableTrue(Integer varIndex);
+ void setVariableFalse(Integer varIndex);
+
+ boolean isVariableUndefined(Integer varIndex);
+ boolean isVariableTrue(Integer varIndex);
+ boolean isVariableFalse(Integer varIndex);
+
+ List getUnassignedVariablesList();
+
+ void addClause(List cl);
+ Clause addLearnedClause(List cl);
+ void forgetLearnedClause(Clause cl);
+ void removeClauseConnection(Clause cl);
+
+ /*
+ * Mandatory Getters
+ */
+
+ Variable[] getVariables();
+
+ Solver getSolver();
+
+ List getInitialClauses();
+ List getLearnedClauses();
+
+ List getLiterals(int clauseId);
+
+ //store unit clauses lazily
+ void foundUnitClause(Clause cl);
+ void foundConflictClause(Clause cl);
+ void resetConflicts();
+
+ boolean foundConflict();
+
+ void decreaseFreeVariable();
+ void increaseFreeVariable();
+ Integer getFreeVariablesCount();
+
+ static List generalResolve(List cl, List ante, Integer res){
+// System.out.println("B/efore "+cl+ " "+ante);
+
+ // Instance new list for resolved clause
+ List resolventLits = new ArrayList<>();
+
+ // Go through all literals of this clause and filter
+ // If not resolved variable and not already contained
+
+ // If negated lit, add new negated lit; else add new positive
+ // lit
+ cl.stream().filter(l -> !(abs(l) == (res))).forEach(resolventLits::add);
+
+ // Go through all literals of antecedent and filter
+ // If not resolved variable and not already contained
+ // If negated lit, add new negated lit; else add new positive
+ // lit
+// resolventLits.addAll(ante.stream().filter(lit -> abs(lit) != res).collect(Collectors.toList()));
+ ante.stream().filter(l ->
+ !(abs(l) == (res)) &&
+ !resolventLits.contains(l)).forEach(resolventLits::add);
+
+ if (resolventLits.size() == 0) {
+ throw new NullPointerException("Resolved empty clause. ");
+ }
+
+
+ // Return resolved literals
+ return resolventLits;
+ }
+
+
+
+}
diff --git a/Specification/src/formula/Variable.java b/Specification/src/formula/Variable.java
new file mode 100644
index 0000000..097d73e
--- /dev/null
+++ b/Specification/src/formula/Variable.java
@@ -0,0 +1,27 @@
+package formula;
+
+import specificationCore.Solver;
+
+import java.util.List;
+
+public interface Variable {
+ Solver getSolver();
+
+ Integer getIndex();
+ Integer getAssignment();
+
+ void setTrue();
+ void setFalse();
+ void undoAssignment();
+
+ int getDl();
+ void setDl(int i);
+
+ int getOrder();
+ void setOrder(int i);
+
+ List getReason();
+ void setReason(List ante);
+
+ void removeConnections(Integer lit, Clause contained);
+}
\ No newline at end of file
diff --git a/Specification/src/rules/CoreRules.java b/Specification/src/rules/CoreRules.java
new file mode 100644
index 0000000..c68522c
--- /dev/null
+++ b/Specification/src/rules/CoreRules.java
@@ -0,0 +1,262 @@
+package rules;
+
+import formula.Clause;
+import specificationCore.HighlevelStrategy;
+import specificationHeuristics.ForgetStrategy;
+import specificationHeuristics.LearnStrategy;
+import specificationHeuristics.LiteralSelectionStrategy;
+import specificationHeuristics.RestartStrategy;
+
+/**
+ * Specification of all supported rules of the state transition system
+ *
+ * Rules can be implemented directly by a {@link HighlevelStrategy high-level
+ * strategy}, or in an external {@link RuleSystem Rule System}, which can
+ * be extended by the actual high-level strategy.
+ *
+ * Rules may check guards with other conditions, which have to imply the
+ * specification guard (i.e. stronger or equally strong pre-conditions).
+ *
+ * @author Albert Schimpf
+ */
+public interface CoreRules {
+ /*
+ * GUARDS BASIC
+ */
+
+ /**
+ * Checks, if there are free variables to assign.
+ *
+ * @return {@code false}, if no variables are free; {@code true} otherwise.
+ */
+ boolean decideGuard();
+
+ /**
+ * Checks, if there is a unit clause in the current formula {@code F} with
+ * current assignments in trail {@code M}.
+ *
+ * The data structure that implements the formula {@code F} should support
+ * fast unit detection, because unit propagation takes up most of the
+ * solving process.
+ *
+ * For efficiency reasons, the clause should be saved internally for further application.
+ *
+ *
+ * @return {@code true}, if there is such a clause; {@code false}
+ * otherwise.
+ */
+ Clause unitGuard();
+
+ /**
+ * Checks, if there is a conflict clause in the current formula {@code F}
+ * with current assignments in trail {@code M}.
+ *
+ * @return {@code true}, if there is such a clause; {@code false}
+ * otherwise.
+ */
+ boolean conflictGuard();
+
+ /**
+ * Checks, if there is a saved conflict and if the current decision level is
+ * greater than 0 (i.e. there is at least 1 decision literal left). If both
+ * conditions are fulfilled, backtrack can be applied.
+ *
+ * @return {@code true}, if backtrack can be applied;{@code false} otherwise
+ */
+ boolean backtrackGuard();
+
+ /*
+ * GUARDS ADVANCED
+ */
+
+ /**
+ * Checks, if resolution can be applied on conflict clause {@code C}.
+ *
+ * Resolution can only be applied, if
+ *
+ * - at least 2 literals are in current decision level
+ *
- at least 1 literal of conflict clause {@code C} is unit literal in
+ * current decision level with an antecedent
+ *
+ */
+ boolean explainUIPGuard();
+
+ /**
+ * Checks, if there is only one literal (UIP) in current conflict clause
+ * {@code C} left.
+ *
+ */
+ Integer backjumpGuard();
+
+ /**
+ * Checks, if a conflict {@code C} is detected. If learning is disabled,
+ * returns always {@code false}.
+ *
+ * Conflicts can always be added negated to a formula, because the formula
+ * entails the conflict clause.
+ *
+ * @return {@code true}, if conflict detected and learning enabled;
+ * {@code false} otherwise
+ */
+ boolean learnGuard();
+
+ /**
+ * Checks, if there is at least one learned clause to forget. If forget is
+ * disabled, returns always {@code false}.
+ *
+ * @return {@code true}, if at least one learned clause and forget enabled;
+ * {@code false} otherwise
+ */
+ boolean forgetGuard();
+
+ /**
+ * Checks, if restart can be applied. If restart is disabled, returns always
+ * {@code false}.
+ *
+ * In theory, a restart can occur at any poInteger in the solving process. This
+ * should be limited by a restart heuristic, to ensure that the solver
+ * terminates.
+ *
+ * Aggressive restarts are generally used for conflict-driven clause
+ * learning strategies, and loose restarts for chronological backtracking.
+ *
+ * @return {@code true}, if restart can be applied and restart enabled;
+ * {@code false} otherwise
+ */
+ boolean restartGuard();
+
+ /*
+ * APPLICATION BASIC
+ */
+
+ /**
+ * The application of the decide rule. Should only be used after a
+ * {@code decideGuard()} check.
+ *
+ *
+ * Selects a literal and adds it to the trail {@code M} as a decision
+ * literal, increasing the current decision level.
+ *
+ * Selection can be done directly, or via the {@code getLiteral()} function
+ * of {@link LiteralSelectionStrategy literal
+ * selection strategy}.
+ *
+ * A good decide heuristic is one of the things that contribute much to the
+ * solver's efficiency and should be a focus of the solver.
+ *
+ * It should be noted that, while a unit literal has an antecedent clause,
+ * a decision literal has not. The antecedent of a decision literal is
+ * always {@code null}.
+ */
+ void applyDecide();
+
+ void applyUnit(Clause cl);
+
+ /**
+ * The application of the conflict rule. Should only be used after a
+ * {@code conflictGuard()} check.
+ *
+ *
+ * Saves the conflict clause for later access, to enable other rules which
+ * need a detected conflict clause.
+ */
+ void applyConflict();
+
+ /**
+ * The application of the backtrack rule. Should only be used after a
+ * {@code backtrackGuard()} check.
+ *
+ *
+ * Deletes the currently saved conflict clause and undoes all assignments of
+ * the current level. After that, the negated recent
+ * {@code decision literal} is added to trail {@code M}.
+ */
+ void applyBacktrack();
+
+ /*
+ * APPLICATION ADVANCED
+ */
+
+ /**
+ * The exhaustive application of the explain rule. Should only be used after
+ * a {@code explainUIPGuard()} check.
+ *
+ * Applies resolution on the conflict clause {@code C} until only one
+ * literal of conflict clause {@code C} is left in current decision level.
+ *
+ * @return first UIP of current decision level
+ */
+ Integer applyExplainUIP();
+
+ /**
+ * The application of the backjump rule. Should only be used after a
+ * {@code backjumpGuard()} check.
+ *
+ * Backjumps to the second most recent decision level of {@code C}, adding
+ * the negation of the UIP to the trail, with {@code C} being the antecedent
+ * of the UIP. Deletes {@code C} afterwards.
+ *
+ * It should be noted that backjump only works in conjunction with
+ * resolution (conflict-directed backjumping), because it is not guaranteed
+ * that a conflict clause has one UIP right after a conflict is detected.
+ *
+ * @param UIP of current decision level
+ */
+ void applyBackjump(Integer UIP);
+
+ /**
+ * The application of the learn rule. Should only be used after a
+ * {@code learnGuard()} check.
+ *
+ * Adds the current conflict clause {@code C} negated to the formula.
+ *
+ * Excessive use of learn can slow down the solver. Size should be
+ * controlled by a forget heuristic.
+ */
+ void applyLearn();
+
+ /**
+ * The application of the forget rule. Should only be used after a
+ * {@code forgetGuard()} check.
+ *
+ * Forgets some learned clauses according to a forget heuristic.
+ */
+ void applyForget();
+
+ /**
+ * The application of the restart rule. Should only be used after a
+ * {@code restartGuard()} check.
+ *
+ * Restarts the solving process. Learned clauses are kept, and the trail
+ * {@code M} is reseted.
+ */
+ void applyRestart();
+
+ /**
+ * Returns the currently used forget heuristic.
+ *
+ * @return forget heuristic
+ */
+ ForgetStrategy getForgetStrategy();
+
+ /**
+ * Returns the currently used learn heuristic.
+ *
+ * @return learn heuristic
+ */
+ LearnStrategy getLearnStrategy();
+
+ /**
+ * Returns the currently used decide heuristic.
+ *
+ * @return decide heuristic
+ */
+ LiteralSelectionStrategy getLiteralSelectionStrategy();
+
+ /**
+ * Returns the currently used restart heuristic.
+ *
+ * @return restart heuristic
+ */
+ RestartStrategy getRestartStrategy();
+}
diff --git a/Specification/src/specificationCore/ConverterObserver.java b/Specification/src/specificationCore/ConverterObserver.java
new file mode 100644
index 0000000..d8c6afb
--- /dev/null
+++ b/Specification/src/specificationCore/ConverterObserver.java
@@ -0,0 +1,40 @@
+package specificationCore;
+
+/**
+ * Observer interface to observe the conversion process.
+ *
+ * Created by Albert Schimpf on 10.09.2015.
+ */
+public interface ConverterObserver {
+ /**
+ * Clause count of the Formula.
+ *
+ * @param clauses
+ */
+ void clauseCount(int clauses);
+
+ /**
+ * Variable count of the Formula.
+ *
+ * @param variables
+ */
+ void variableCount(int variables);
+
+ /**
+ * Indicates the start of a new Clause.
+ */
+ void startClause();
+
+ /**
+ * Closes the last open Clause.
+ */
+ void endClause();
+
+ /**
+ * Indicates a new Literal in last open Clause.
+ *
+ * @param index of Literal
+ * @param negated status of Literal
+ */
+ void literal(int index, boolean negated);
+}
diff --git a/Specification/src/specificationCore/HighlevelStrategy.java b/Specification/src/specificationCore/HighlevelStrategy.java
new file mode 100644
index 0000000..dca104b
--- /dev/null
+++ b/Specification/src/specificationCore/HighlevelStrategy.java
@@ -0,0 +1,52 @@
+package specificationCore;
+
+import specificationHeuristics.ForgetStrategy;
+import specificationHeuristics.LearnStrategy;
+import specificationHeuristics.LiteralSelectionStrategy;
+import specificationHeuristics.RestartStrategy;
+
+/**
+ * Specifications for a high-level strategy.
+ *
+ * Every strategy has to save the reference to the main module, as they operate
+ * on the formula {@code F} and the trail {@code M}.
+ *
+ * @author Albert Schimpf
+ */
+public interface HighlevelStrategy {
+ /**
+ * The abstract function which needs to be implemented by an actual
+ * strategy.
+ *
+ * @return true if formula {@code F} is satisfied, false if not.
+ */
+ boolean applyStrategy();
+
+ /**
+ * Returns the currently used forget heuristic.
+ *
+ * @return forget heuristic
+ */
+ ForgetStrategy getForgetStrategy();
+
+ /**
+ * Returns the currently used learn heuristic.
+ *
+ * @return learn heuristic
+ */
+ LearnStrategy getLearnStrategy();
+
+ /**
+ * Returns the currently used decide heuristic.
+ *
+ * @return decide heuristic
+ */
+ LiteralSelectionStrategy getLiteralSelectionStrategy();
+
+ /**
+ * Returns the currently used restart heuristic.
+ *
+ * @return restart heuristic
+ */
+ RestartStrategy getRestartStrategy();
+}
diff --git a/Specification/src/specificationCore/Solver.java b/Specification/src/specificationCore/Solver.java
new file mode 100644
index 0000000..2287bc3
--- /dev/null
+++ b/Specification/src/specificationCore/Solver.java
@@ -0,0 +1,26 @@
+package specificationCore;
+
+import exceptions.ConvertException;
+import exceptions.SolverTimeoutException;
+
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * Solver main interface.
+ *
+ * Manages state, observers and the main high-level function.
+ *
+ * Created by Albert Schimpf on 15.09.2015.
+ */
+public interface Solver {
+ List getObs();
+
+ State getState();
+
+ void addObserver(SolverListener obs);
+
+ HighlevelStrategy getHighlevelStrategy();
+
+ boolean checkCurrentInstance() throws ConvertException, SolverTimeoutException, IOException;
+}
diff --git a/Specification/src/specificationCore/SolverListener.java b/Specification/src/specificationCore/SolverListener.java
new file mode 100644
index 0000000..bc0abf9
--- /dev/null
+++ b/Specification/src/specificationCore/SolverListener.java
@@ -0,0 +1,125 @@
+package specificationCore;
+
+import formula.Clause;
+
+import java.util.List;
+
+/**
+ * Observer interface for listener of the solving process.
+ *
+ * If a satellite component (heuristic, proof logger, GUI etc.) needs to be
+ * updated during the solving process, it needs to implement this interface and
+ * add itself to the observers with the method addObserver.
+ *
+ * To use an implemented custom rule, a dedicated {@code onCustomRule} update
+ * with desired parameters has to be specified. A custom rule can easily
+ * interrupt/disrupt the solving process or distort the solution, if the rule is
+ * not proven beforehand and used in an incorrect strategy.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public interface SolverListener {
+ /**
+ * Notifies the observer that the decision literal {@code ld} was added to
+ * the trail {@code M}.
+ *
+ * @param ld
+ * : decision literal
+ */
+ void onDecide(Integer ld);
+
+ /**
+ * Notifies the observer that the unit literal {@code lu} was added to the
+ * trail {@code M}, with {@code cl} being its antecedent.
+ *
+ * @param lu
+ * : unit literal
+ * @param cl
+ * : antecedent of unit literal
+ */
+ void onUnitPropagate(List cl, Integer lu);
+
+ /**
+ * Notifies the observer that the clause {@code cl} is currently
+ * conflicting.
+ *
+ * @param cl
+ * : conflicting clause
+ */
+ void onConflict(Clause cl);
+
+ /**
+ * Notifies the observer that the solver backtracked one literal, of which
+ * corresponding variable is now undefined again.
+ *
+ * @param l
+ * backtracked literal
+ */
+ void onBacktrack(Integer l);
+
+ /**
+ * Notifies the observer that a resolution step was done, with literal
+ * {@code resLit} being resolved from the conflict clause {@code C} with the
+ * antecedent of {@code resLit}. {@code resolved} being the concluded
+ * clause.
+ *
+ * @param ante
+ * : antecedent of the resolved literal
+ * @param resLit
+ * : the literal to resolve
+ * @param resolved
+ * : the resolved clause
+ */
+ void onExplain(List ante, Integer resLit,
+ List resolved);
+
+ /**
+ * Notifies the observer that the clause {@code cl} was added to the formula
+ * {@code F} as a learned clause.
+ *
+ * @param cl
+ * : learned clause
+ */
+ void onLearn(Clause cl);
+
+ /**
+ * Notifies the observer that the (learned) clause {@code cl} was removed
+ * from formula {@code F}.
+ *
+ * @param cl
+ * : learned clause
+ */
+ void onForget(Clause cl);
+
+ /**
+ * Notifies the observer that the clause {@code cl} was added to the formula
+ * {@code F} as an initial clause.
+ *
+ * @param cl
+ * : initial clause
+ */
+ void onLearnInitial(List cl);
+
+ /**
+ * Notifies the observer that the solver has restarted the solving process.
+ */
+ void onRestart();
+
+ /**
+ * Notifies the observer that the converting process has finished and the
+ * formula {@code F} is fully constructed.
+ */
+ void onSetOfClausesLoaded();
+
+ /**
+ * Notifies the observer that the solver backjumped from current level to
+ * given decision level and given flipped literal.
+ *
+ * @param uip added to decision trail after backjumping
+ * @param bl backjump level
+ * @param current decision level
+ */
+ void onBackjump(Integer current, Integer bl, Integer uip);
+
+}
diff --git a/Specification/src/specificationCore/State.java b/Specification/src/specificationCore/State.java
new file mode 100644
index 0000000..51d460f
--- /dev/null
+++ b/Specification/src/specificationCore/State.java
@@ -0,0 +1,19 @@
+package specificationCore;
+
+import formula.SetOfClauses;
+
+import java.util.List;
+
+/**
+ * State container class for the solver state.
+ *
+ * Created by Albert Schimpf on 01.10.2015.
+ */
+public interface State {
+ void setInitialF(SetOfClauses F);
+ SetOfClauses F();
+ void setInitialM(Trail M);
+ Trail M();
+ List C();
+ void setC(List clause);
+}
diff --git a/Specification/src/specificationCore/Trail.java b/Specification/src/specificationCore/Trail.java
new file mode 100644
index 0000000..f4ee31d
--- /dev/null
+++ b/Specification/src/specificationCore/Trail.java
@@ -0,0 +1,203 @@
+package specificationCore;
+
+import formula.SetOfClauses;
+
+import java.util.List;
+
+/**
+ * A main component in the state transition system to keep track of the assigned
+ * literals and decision levels during the solving process.
+ *
+ * More specifically, the trail has to keep track of the following:
+ *
+ * - Assigned literals
+ *
- Order of assigned literals
+ *
- Antecedents of unit literals
+ *
- Decision level tracking (checkpoints)
+ *
- Ability to backtrack to any given level below the current one
+ *
+ *
+ * All functions should be implemented as efficiently as possible, as to not
+ * become the bottleneck of the solving process.
+ *
+ * @author Albert Schimpf
+ */
+public interface Trail {
+ /**
+ * Checks if literal {@code lit} is in the current trail.
+ *
+ * This function should cost at most O(1).
+ *
+ * @param lit : literal to be checked
+ * @return true if {@code lit} is in trail; false otherwise
+ */
+ boolean inTrail(Integer lit);
+
+ /**
+ * Adds literal {@code lit} as a decision literal in the current trail.
+ * Increases current decision level by 1.
+ *
+ * The antecedent of a decision literal is always {@code null}.
+ *
+ * @param lit : decision literal to be added
+ * @see SetOfClauses#setVariableFalse(int)
+ * F.setVariableFalse
+ * @see SetOfClauses#setVariableTrue(int)
+ * F.setVariableTrue
+ */
+ void addDecisionLiteral(Integer lit);
+
+ /**
+ * Adds literal {@code lit} as a unit literal with it's antecedent {@code cl}
+ * in the current trail. Does not increase current decision level.
+ *
+ * @param lit : unit literal to be added
+ * @param cl : antecedent of lit
+ * @see SetOfClauses#setVariableFalse(int)
+ * F.setVariableFalse
+ * @see SetOfClauses#setVariableTrue(int)
+ * F.setVariableTrue
+ */
+ void addUnitLiteral(Integer lit, List cl);
+
+ /**
+ * Undoes all assignments of the current decision level and adds the
+ * negation of the current decision literal after undoing the assignments.
+ * Decreases current decision level by 1.
+ *
+ * Backtrack at decision level 0 is not possible and should throw a
+ * {@code Exception}.
+ *
+ * @see SetOfClauses#undoAssignment(int)
+ * F.undoVariableAssignment
+ * @see SetOfClauses#setVariableFalse(int)
+ * F.setVariableFalse
+ * @see SetOfClauses#setVariableTrue(int)
+ * F.setVariableTrue
+ */
+ void backtrack();
+
+ /**
+ * Undoes all assignments until given decision level is reached and adds the
+ * given literal {@code d} after undoing the assignments.
+ *
+ * The decision level parameter is exclusive: assignments on level {@code i}
+ * will not be undone.
+ *
+ * Backjumping below level 0, to the current level, or above current level
+ * is not allowed and should throw an {@code IllegalArgumentException}.
+ *
+ * @param i : level to backjump to (exclusive)
+ * @param d : literal which will be added to the trail after backjump
+ * @throws IllegalArgumentException if backjump level is not allowed
+ * @see SetOfClauses#undoAssignment(int)
+ * F.undoVariableAssignment
+ * @see SetOfClauses#setVariableFalse(int)
+ * F.setVariableFalse
+ * @see SetOfClauses#setVariableTrue(int)
+ * F.setVariableTrue
+ */
+ void backjumpToLevel(Integer i, Integer d);
+
+ /**
+ * Returns the most recent decision literal, {@code null} if there is none.
+ *
+ * Per definition, there is only one decision literal per decision level.
+ *
+ * @return recent decision literal
+ */
+ Integer getCurrentDecisionLiteral();
+
+ /**
+ * Returns current decision level. Decision levels of literals not in trail
+ * are not consistent.
+ *
+ * @return current decision level
+ */
+ Integer getCurrentDecisionLevel();
+
+ /**
+ * Returns the second biggest decision level of the literals of a given
+ * clause.
+ *
+ * Two literals with the same decision level are filtered beforehand. If
+ * there is only one decision level among the literals in given clause, -1
+ * is returned.
+ *
+ * Is not checked, but all literals of given clause should be in the trail.
+ *
+ * @param cl ClauseAbs
+ * @return Second recent decision level of clause, -1 if there is no second
+ * recent
+ */
+ Integer getSecondRecentDecisionLevel(List cl);
+
+ /**
+ * Resets the trail completely, undoing all assignments, inclusive decision
+ * level 0 (i.e. unit assignments).
+ *
+ * @see SetOfClauses#undoAssignment(int)
+ * F.undoVariableAssignment
+ */
+ void reset();
+
+ /**
+ * Returns the decision level of given literal {@code lit}. Returns -1, if
+ * literal is not in trail.
+ *
+ * @param lit : literal
+ * @return decision level of literal
+ */
+ Integer getDecisionLevel(Integer lit);
+
+ /**
+ * Prints the current assignment to the console. Should only be used after
+ * satisfaction of a formula.
+ *
+ * Format: v( literal)* 0
+ *
+ * Negation is printed as '-' in front of the literal. Example model:
+ *
+ * v 1 -2 3 -5 4 0
+ */
+ void createModel();
+
+ /**
+ * Checks, if a literal is asserted before another literal.
+ *
+ * Is not checked, but both literals should be in the trail.
+ *
+ * @param lit1 First literal
+ * @param lit2 Second BuilderLiteral
+ * @return {@code true}, if lit1 is asserted before lit2; {@code false}
+ * otherwise
+ */
+ boolean isAssertedBefore(Integer lit1, Integer lit2);
+
+ /**
+ * Returns the antecedent of the given literal, {@code null} if literal does
+ * not have one.
+ *
+ * Not checked, but literal should be in the trail.
+ *
+ * @param lit : literal
+ * @return antecedent of (unit) literal
+ */
+ List getReason(Integer lit);
+
+ /**
+ * Returns a list with all current literals sorted from end of the trail to
+ * the end of the last decision level.
+ *
+ * @return literals in current decision level sorted from end to a
+ * checkpoint
+ */
+ List getCurrentDecisionLevelLiteralsFromEnd();
+
+ /**
+ * Returns a refutation proof, if clause is determined to be unsatisfiable.
+ */
+ void createRefutation();
+
+
+}
diff --git a/Specification/src/specificationHeuristics/ForgetStrategy.java b/Specification/src/specificationHeuristics/ForgetStrategy.java
new file mode 100644
index 0000000..28171e7
--- /dev/null
+++ b/Specification/src/specificationHeuristics/ForgetStrategy.java
@@ -0,0 +1,40 @@
+package specificationHeuristics;
+
+
+import formula.Clause;
+
+import java.util.List;
+
+/**
+ * Specification for all forget strategies.
+ *
+ * A forget strategy has to implement a check, if the solver should forget some
+ * clauses and an actual forget method.
+ *
+ * Heuristics may need to get information from the formula {@code F} or the
+ * trail {@code M}.
+ *
+ * If the heuristic needs to be updated after certain rule application, it needs
+ * to add itself as a observer with the addObserver method in its
+ * constructor.
+ *
+ * @author Albert Schimpf
+ */
+public interface ForgetStrategy {
+ /**
+ * Checks, if the solver should forget some learned clauses according to a
+ * heuristic.
+ *
+ * @return {@code true}, if some learned clauses should be removed;
+ * {@code false} otherwise
+ */
+ boolean shouldForget();
+
+ /**
+ * Forgets some learned clauses according to a selection heuristic. Returns
+ * all clauses which were removed from the formula.
+ *
+ * @return removed clauses
+ */
+ List forgetClauses();
+}
diff --git a/Specification/src/specificationHeuristics/LearnStrategy.java b/Specification/src/specificationHeuristics/LearnStrategy.java
new file mode 100644
index 0000000..375686c
--- /dev/null
+++ b/Specification/src/specificationHeuristics/LearnStrategy.java
@@ -0,0 +1,36 @@
+package specificationHeuristics;
+
+import formula.Clause;
+
+/**
+ * Specification for all learn strategies.
+ *
+ * A learn strategy has to implement a check, if the solver should learn a
+ * clause.
+ *
+ * Heuristics may need to get information from the formula {@code F} or the
+ * trail {@code M}.
+ *
+ * If the heuristic needs to be updated after certain rule application, it needs
+ * to add itself as a observer with the addObserver method in its
+ * constructor.
+ *
+ * @author Albert Schimpf
+ */
+public interface LearnStrategy {
+ /**
+ * Checks, if the solver should learn some clause according to a heuristic.
+ *
+ * @return {@code true}, if clause should be learned; {@code false}
+ * otherwise
+ */
+ boolean shouldLearn();
+
+ /**
+ * Learns some clause according to the learn strategy. Returns the learned
+ * clause.
+ *
+ * @return learned clause
+ */
+ Clause learnClause();
+}
\ No newline at end of file
diff --git a/Specification/src/specificationHeuristics/LiteralSelectionStrategy.java b/Specification/src/specificationHeuristics/LiteralSelectionStrategy.java
new file mode 100644
index 0000000..9595002
--- /dev/null
+++ b/Specification/src/specificationHeuristics/LiteralSelectionStrategy.java
@@ -0,0 +1,27 @@
+package specificationHeuristics;
+
+
+/**
+ * General literal selection strategy, which every literal selection heuristic
+ * must implement.
+ *
+ * Is used in the main module to get the next decision literal.
+ *
+ * Selection heuristics may need to get information from the formula {@code F} or the
+ * trail {@code M}.
+ *
+ * If the heuristic needs to be updated after certain rule application, it needs
+ * to add itself as a observer with the addObserver method in its
+ * constructor.
+ *
+ * @author Albert Schimpf
+ */
+public interface LiteralSelectionStrategy {
+ /**
+ * Method body to select a free literal in F according to the implemented
+ * heuristic. Should never return a {@code null} object.
+ *
+ * @return free literal
+ */
+ Integer getLiteral();
+}
\ No newline at end of file
diff --git a/Specification/src/specificationHeuristics/PolaritySelectionStrategy.java b/Specification/src/specificationHeuristics/PolaritySelectionStrategy.java
new file mode 100644
index 0000000..373365d
--- /dev/null
+++ b/Specification/src/specificationHeuristics/PolaritySelectionStrategy.java
@@ -0,0 +1,25 @@
+package specificationHeuristics;
+
+
+/**
+ * General polarity selection strategy, which every polarity selection heuristic
+ * must implement.
+ *
+ * Used to decide the polarity of a given variable according to a heuristic.
+ *
+ * Should be used in a literal selection strategy, which uses separate variable
+ * and polarity heuristics.
+ *
+ * @author Albert Schimpf
+ * @see LiteralSelectionStrategy
+ */
+public interface PolaritySelectionStrategy {
+ /**
+ * Method body to select a polarity of a variable according to the
+ * implemented heuristic. Returns a new BuilderLiteral with said polarity.
+ *
+ * @param varIndex Index of given VariableAbs
+ * @return literal with selected polarity
+ */
+ Integer getPolarity(Integer varIndex);
+}
\ No newline at end of file
diff --git a/Specification/src/specificationHeuristics/RestartStrategy.java b/Specification/src/specificationHeuristics/RestartStrategy.java
new file mode 100644
index 0000000..40c0cab
--- /dev/null
+++ b/Specification/src/specificationHeuristics/RestartStrategy.java
@@ -0,0 +1,25 @@
+package specificationHeuristics;
+
+/**
+ * Specification for all restart strategies.
+ *
+ * A restart strategy has to implement a check, if the solver should restart at
+ * some point in the process.
+ *
+ * Restart heuristics may need to get information from the formula {@code F} or
+ * the trail {@code M}.
+ *
+ * If the heuristic needs to be updated after certain rule application, it needs
+ * to add itself as a observer with the addObserver method in its
+ * constructor.
+ *
+ * @author Albert Schimpf
+ */
+public interface RestartStrategy {
+ /**
+ * Checks, if the solver should restart according to a restart heuristic.
+ *
+ * @return {@code true}, solver should restart; {@code false} otherwise
+ */
+ boolean shouldRestart();
+}
diff --git a/Specification/src/specificationHeuristics/VariableSelectionStrategy.java b/Specification/src/specificationHeuristics/VariableSelectionStrategy.java
new file mode 100644
index 0000000..2cd576e
--- /dev/null
+++ b/Specification/src/specificationHeuristics/VariableSelectionStrategy.java
@@ -0,0 +1,24 @@
+package specificationHeuristics;
+
+
+import formula.Variable;
+
+/**
+ * General variable selection strategy, which every variable selection heuristic
+ * must implement.
+ *
+ * Is used in a literal selection strategy, to decide the variable of the
+ * literal to return.
+ *
+ * @author Albert Schimpf
+ * @see LiteralSelectionStrategy
+ */
+public interface VariableSelectionStrategy {
+ /**
+ * Method body to select a free variable in F according to the implemented
+ * heuristic.
+ *
+ * @return selected variable
+ */
+ Variable getVariable();
+}
diff --git a/Trail/Trail.iml b/Trail/Trail.iml
new file mode 100644
index 0000000..8c85319
--- /dev/null
+++ b/Trail/Trail.iml
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Trail/src/arraylist/TrailArrayList.java b/Trail/src/arraylist/TrailArrayList.java
new file mode 100644
index 0000000..2e7d598
--- /dev/null
+++ b/Trail/src/arraylist/TrailArrayList.java
@@ -0,0 +1,374 @@
+package arraylist;
+
+import org.jetbrains.annotations.NotNull;
+import formula.SetOfClauses;
+import formula.Variable;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationCore.Trail;
+
+import java.util.*;
+import java.util.stream.Collectors;
+
+import static java.lang.Math.abs;
+import static java.util.Collections.max;
+
+/**
+ * 2016/02/01.
+ */
+public class TrailArrayList implements Trail {
+ private final SetOfClauses F;
+ private final Solver solver;
+
+
+ private Stack previousDlLits = new Stack<>();
+ private TLiteral currentDlLit = null;
+ private int currentDl = 0;
+ private int currentOrder = 0;
+
+ List sequence;
+
+ public int firstLevel = 0;
+
+ public TrailArrayList(@NotNull Solver solver) {
+ this.F = solver.getState().F();
+ this.solver = solver;
+ sequence = new ArrayList<>();
+ }
+
+
+ private void assertLiteral(@NotNull TLiteral l) {
+ if(currentDl == 0){
+ firstLevel++;
+ }
+
+
+ Variable var = F.getVariable(l.lit);
+ //case decide
+ if (l.decision) {
+ //set decision literal references
+ previousDlLits.push(currentDlLit);
+ currentDlLit = l;
+ //increase level
+ currentDl++;
+ //reset order
+ currentOrder = 0;
+
+ }
+
+ //set dl, order, increase order and add to tail literals
+ var.setDl(currentDl);
+ var.setOrder(currentOrder);
+ currentOrder++;
+
+ //add to main sequence
+ sequence.add(l);
+
+ // Assign variable in F
+ if (l.lit < 0) {
+ F.setVariableFalse(l.lit);
+ } else {
+ F.setVariableTrue(l.lit);
+ }
+ }
+
+
+ //takes care of current DL
+ private void backtrackLastLiteral() {
+ if(currentDl == 0){
+ firstLevel--;
+ }
+
+ TLiteral bLit = sequence.remove(sequence.size()-1);
+// if(abs(bLit.lit) == 8){
+// System.out.println("[Backtrack] "+bLit.lit);
+// }
+// if(abs(bLit.lit) == 11){
+// System.out.println("[Backtrack] "+bLit.lit);
+// }
+// if(abs(bLit.lit) == 39){
+// System.out.println("[Backtrack] "+bLit.lit);
+// }
+
+
+ //set variable attributes
+ Variable var = F.getVariable(bLit.lit);
+ var.setDl(-1);
+ var.setOrder(-1);
+ var.setReason(null);
+
+ //case decision
+ if(bLit.decision){
+ //set decision literal references
+ currentDlLit = previousDlLits.pop();
+ //decrease level
+ currentDl--;
+ //decrease order
+ if(sequence.size() != 0){
+ TLiteral bLit2 = sequence.get(sequence.size()-1);
+ currentOrder = F.getVariable(bLit2.lit).getOrder()+1;
+ } else{
+ currentOrder = 0;
+ }
+
+ } else{
+ //decrease order
+ currentOrder--;
+ }
+
+ //undo assignment
+ var.undoAssignment();
+
+ // Update all observer that literal l has been backtracked
+ for (SolverListener ob : solver.getObs()) {
+ ob.onBacktrack(bLit.lit);
+ }
+ }
+
+
+ @Override
+ public void createRefutation() {
+ //TODO
+ }
+
+ @Override
+ public void createModel() {
+ String ret = "v ";
+ for (TLiteral l : sequence) {
+ ret += (l.lit) + " ";
+ }
+ System.out.println(ret + "0");
+ }
+
+
+ @Override
+ public List getCurrentDecisionLevelLiteralsFromEnd() {
+ // TODO more efficient storage of current decision level literals?
+ List res = new ArrayList<>();
+ Integer i = sequence.size() - 1;
+
+ if (i == -1) {
+ return res;
+ }
+
+ TLiteral l = sequence.get(i);
+ while (!l.decision) {
+ res.add(l.lit);
+ i--;
+ if (i == -1) {
+ return res;
+ }
+ l = sequence.get(i);
+ }
+
+ res.add(l.lit);
+
+ return res;
+ }
+
+ @Override
+ public void backjumpToLevel(@NotNull Integer i,@NotNull Integer flip) {
+ if (i == currentDl) {
+ throw new IllegalArgumentException("Decision parameter is the same as current level");
+ }
+ if (i < 0) {
+ throw new IllegalArgumentException("Illegal backjump level. " + i);
+ }
+// if (!inTrail(-flip)) {
+// throw new IllegalArgumentException("Integer not false in trail: " + flip);
+// }
+
+
+ // Backtrack one decision level until given level is reached
+ while (!getCurrentDecisionLevel().equals(i)) {
+ backtrackLastLiteral();
+ }
+ F.resetConflicts();
+ addUnitLiteral(flip, solver.getState().C());
+ }
+
+ @Override
+ public void backtrack() {
+ // Use general backjump for backtrack
+ Integer flip = getCurrentDecisionLiteral();
+
+ backjumpToLevel(getCurrentDecisionLevel() - 1, -flip);
+ }
+
+
+ @Override
+ public void reset() {
+ while (currentDl > 0) {
+ backtrackLastLiteral();
+ }
+ }
+
+ //Old: complex
+ //New: O(cl.size + O(getSecondMostRecentLevel) + hashset.remove*collections.max)
+ @Override
+ public Integer getSecondRecentDecisionLevel(@NotNull List cl) {
+ //filter duplicates
+ Set filtered = new HashSet<>(cl.size());
+ filtered.addAll(cl.stream().map(lit -> F.getVariable(lit).getDl()).collect(Collectors.toList()));
+
+ if (filtered.size() == 1) {
+ return -1;
+ } else {
+ filtered.remove(max(filtered));
+ return max(filtered);
+ }
+ }
+
+
+ //Old: O(n)
+ //O(1)
+ @Override
+ public List getReason(@NotNull Integer lit) {
+ return F.getVariable(lit).getReason();
+ }
+
+
+ //Old: O(2*n)
+ //New: O(1)
+ @Override
+ public boolean isAssertedBefore(@NotNull Integer lit,@NotNull Integer target) {
+ //both have to be in trail //TODO doc
+
+ int dlLit = F.getVariable(lit).getDl();
+ int dlTarget = F.getVariable(target).getDl();
+
+ if (dlLit < dlTarget) {
+ return true;
+ } else if (dlLit > dlTarget) {
+ return false;
+ } else {
+ return F.getVariable(lit).getOrder() < F.getVariable(target).getOrder();
+ }
+
+ }
+
+ //O(assertLiteral)
+ @Override
+ public void addDecisionLiteral(@NotNull Integer lit) {
+ TLiteral decideLit = new TLiteral(lit, true);
+ Variable var = F.getVariable(lit);
+ var.setDl(currentDl + 1);
+ var.setOrder(currentOrder);
+// var.setReason(null);
+ assertLiteral(decideLit);
+ }
+
+ //O(assertLiteral)
+ @Override
+ public void addUnitLiteral(@NotNull Integer lit,@NotNull List ante) {
+ // set reason of literal to the clause
+ TLiteral unitLit = new TLiteral(lit, false);
+ Variable var = F.getVariable(lit);
+ var.setDl(currentDl);
+ var.setOrder(currentOrder);
+ var.setReason(ante);
+// assert ((VariableAbs) var).getAnteIndex() != -1;
+ //((VariableAbs) var).setAnteIndex(); //FIXME not here
+ // call function to assert literal as a unit literal
+ assertLiteral(unitLit);
+ }
+
+ //Old: O(#CurrentDlLiteral)
+ //New: O(1)
+ @Override
+ public Integer getCurrentDecisionLiteral() {
+ //FIXME nullpointer
+ return currentDlLit.lit;
+ }
+
+ //O(1)
+ @Override
+ public Integer getCurrentDecisionLevel() {
+ return currentDl;
+ }
+
+ @Override
+ public Integer getDecisionLevel(@NotNull Integer lit) {
+ assert inTrail(lit);
+ //not checked FIXME check if in trail
+ return F.getVariable(lit).getDl();
+ }
+
+ //O(1)
+ //3 array get calls on F
+ @Override
+ public boolean inTrail(@NotNull Integer l) {
+ // // Instead of traversing the trail,
+ // // check if variable is undefined in F
+// System.out.print("Checking "+l+"... ");
+ Integer index = abs(l);
+ boolean neg = l < 0;
+
+ if (F.isVariableUndefined(index)) {
+// System.out.println(" false because undef!");
+ return false;
+ }
+
+ // If variable is false and ld is negated, then ld is in trail
+ if ((F.isVariableFalse(index)) && neg) {
+// System.out.println(" true because var false!!");
+ return true;
+ }
+
+ // If variable is true and ld is not negated, then ld is in trail
+ if ((F.isVariableTrue(index)) && !neg) {
+// System.out.println(" true because var true!");
+ return true;
+ }
+
+// System.out.println(" other! ... varFalse("+F.isVariableFalse(index)+") varTrue("+F.isVariableTrue(index)+") "+neg);
+ // For other cases return false
+ return false;
+ }
+
+
+
+//
+// @Override
+// public String toString() {
+// String s = "[ ";
+//
+// for (TLiteral literal : sequence) {
+// if(literal.decision) s+= "X ";
+// s+=literal.lit+" ";
+// }
+//
+// return s + " ]";
+// }
+}
+
+class TLiteral {
+ public final Integer lit;
+ public final boolean decision; //unit or decision literal
+
+ public TLiteral(@NotNull Integer lit, boolean decision) {
+ this.lit = lit;
+ this.decision = decision;
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+
+ TLiteral literal = (TLiteral) o;
+
+ return lit.equals(literal.lit);
+
+ }
+
+ @Override
+ public int hashCode() {
+ return lit.hashCode();
+ }
+
+// @Override
+// public String toString() {
+// return lit + "";
+// }
+}
\ No newline at end of file
diff --git a/Trail/src/factory/ETrail.java b/Trail/src/factory/ETrail.java
new file mode 100644
index 0000000..515542d
--- /dev/null
+++ b/Trail/src/factory/ETrail.java
@@ -0,0 +1,8 @@
+package factory;
+
+/**
+ * Created by tp on 17.12.15.
+ */
+public enum ETrail {
+ TrailEfficient
+}
diff --git a/Trail/src/factory/TrailFactory.java b/Trail/src/factory/TrailFactory.java
new file mode 100644
index 0000000..9cc7b5e
--- /dev/null
+++ b/Trail/src/factory/TrailFactory.java
@@ -0,0 +1,21 @@
+package factory;
+
+import specificationCore.Solver;
+import specificationCore.Trail;
+import arraylist.TrailArrayList;
+
+public class TrailFactory {
+ private TrailFactory(){}
+
+ public static Trail getTrail(Solver solver, ETrail trail) {
+ switch (trail) {
+// case TrailSimple:
+// return new TrailSimple(solver);
+ case TrailEfficient:
+ return new TrailArrayList(solver);
+ default:
+ throw new IllegalArgumentException("Invalid trail selected. "
+ + trail);
+ }
+ }
+}
diff --git a/TransitionSystem/TransitionSystem.iml b/TransitionSystem/TransitionSystem.iml
new file mode 100644
index 0000000..3fcb7a0
--- /dev/null
+++ b/TransitionSystem/TransitionSystem.iml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/TransitionSystem/src/factory/EHighlevel.java b/TransitionSystem/src/factory/EHighlevel.java
new file mode 100644
index 0000000..0c75f4e
--- /dev/null
+++ b/TransitionSystem/src/factory/EHighlevel.java
@@ -0,0 +1,5 @@
+package factory;
+
+public enum EHighlevel {
+ Chaff,DPLLSimple
+}
\ No newline at end of file
diff --git a/TransitionSystem/src/factory/HighlevelStrategyFactory.java b/TransitionSystem/src/factory/HighlevelStrategyFactory.java
new file mode 100644
index 0000000..fc5c221
--- /dev/null
+++ b/TransitionSystem/src/factory/HighlevelStrategyFactory.java
@@ -0,0 +1,30 @@
+package factory;
+
+import highlevelStrategy.Chaff;
+import highlevelStrategy.DPLLSimple;
+import specificationCore.HighlevelStrategy;
+import specificationCore.Solver;
+
+/**
+ * Highlevel strategy factory.
+ * Created by Albert Schimpf on 04.10.2015.
+ */
+public class HighlevelStrategyFactory {
+
+ private HighlevelStrategyFactory(){}
+
+ public static HighlevelStrategy getHighlevelStrategy(Solver solver, EHighlevel coreStrategy, EDecide literalHeuristic, ERestart restartHeuristic, ELearn learnHeuristic, EForget forgetHeuristic) {
+ switch (coreStrategy) {
+ case Chaff:
+ return new Chaff(solver, literalHeuristic,
+ restartHeuristic, learnHeuristic, forgetHeuristic);
+ case DPLLSimple:
+ return new DPLLSimple(solver, literalHeuristic,
+ restartHeuristic, learnHeuristic, forgetHeuristic);
+
+ default:
+ throw new IllegalArgumentException(
+ "Invalid high-level strategy selected." + coreStrategy);
+ }
+ }
+}
\ No newline at end of file
diff --git a/TransitionSystem/src/highlevelStrategy/Chaff.java b/TransitionSystem/src/highlevelStrategy/Chaff.java
new file mode 100644
index 0000000..20aab81
--- /dev/null
+++ b/TransitionSystem/src/highlevelStrategy/Chaff.java
@@ -0,0 +1,125 @@
+package highlevelStrategy;
+
+import factory.EDecide;
+import factory.EForget;
+import factory.ELearn;
+import factory.ERestart;
+import formula.Clause;
+import formula.SetOfClauses;
+import org.jetbrains.annotations.NotNull;
+import ruleSystem.RuleSystem;
+import specificationCore.*;
+
+/**
+ * Implementation of the strategy of the Chaff solver.
+ *
+ * Extension of the classic DPLL algorithm with clause learning/forgetting (if
+ * enabled), restarts (if enabled) and non-chronological backtracking.
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class Chaff extends RuleSystem implements HighlevelStrategy {
+ /**
+ * Saved trail reference.
+ */
+ public boolean condition = true;
+
+ /**
+ * The strategy has to operate on the formula {@code F} and has to have
+ * access to the trail {@code M}.
+ *
+ * @param solver
+ * reference to access formula {@code F} and trail {@code M}
+ * @param literalHeuristic
+ * given decide heuristic
+ * @param forgetHeuristic
+ * given forget heuristic
+ * @param learnHeuristic
+ * given learn heuristic
+ * @param restartHeuristic
+ * given restart heuristic
+ */
+ public Chaff(@NotNull Solver solver, @NotNull EDecide literalHeuristic,
+ @NotNull ERestart restartHeuristic, @NotNull ELearn learnHeuristic,
+ @NotNull EForget forgetHeuristic) {
+ super(solver, literalHeuristic, restartHeuristic, learnHeuristic,
+ forgetHeuristic);
+ }
+
+ /**
+ * Actual iterative implementation of the chaff strategy.
+ */
+ public boolean applyStrategy() {
+ while (condition) {
+ BCP();
+
+ if (conflictGuard()) {
+ applyConflict();
+
+ if (getSolver().getState().M().getCurrentDecisionLevel() == 0) {
+ return false;
+ } else {
+
+
+ Integer UIP = null;
+ if (explainUIPGuard()) {
+ UIP = applyExplainUIP();
+ if (learnGuard()) {
+ applyLearn();
+ }
+ }
+
+
+
+ if(UIP == null){
+ UIP = backjumpGuard();
+ }
+
+ applyBackjump(UIP);
+ }
+
+ } else {
+ if (forgetGuard()) {
+ applyForget();
+ }
+ if (restartGuard()) {
+ applyRestart();
+ }
+ if (decideGuard()) {
+ applyDecide();
+ } else {
+ return true;
+ }
+ }
+ }
+
+ throw new NullPointerException("Interupted Strategy");
+ }
+
+ /**
+ * Exhaustive application of unit rule, also called Boolean Constraint
+ * Propagation.
+ */
+ private void BCP() {
+ Clause unit = unitGuard();
+ while (unit != null) {
+ if(getSolver().getState().F().foundConflict()){
+ break;
+ }
+ applyUnit(unit);
+ unit = unitGuard();
+ }
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+
+}
diff --git a/TransitionSystem/src/highlevelStrategy/DPLLSimple.java b/TransitionSystem/src/highlevelStrategy/DPLLSimple.java
new file mode 100644
index 0000000..20b03cb
--- /dev/null
+++ b/TransitionSystem/src/highlevelStrategy/DPLLSimple.java
@@ -0,0 +1,122 @@
+package highlevelStrategy;
+
+import abstractImplementation.SetOfClausesAbs;
+import factory.EDecide;
+import factory.EForget;
+import factory.ELearn;
+import factory.ERestart;
+import formula.Clause;
+import formula.SetOfClauses;
+import org.jetbrains.annotations.NotNull;
+import ruleSystem.RuleSystem;
+import specificationCore.HighlevelStrategy;
+import specificationCore.Solver;
+import specificationCore.Trail;
+import wl.SetOfClausesW;
+
+
+/**
+ * Implementation of the classic Davis-Putnam-Logemann-Loveland strategy.
+ *
+ *
+ * {@code (((Conflict; Backtrack) || UnitPropag)* ; [Decide])* }
+ *
+ *
+ * This strategy consists of 2 main phases using only the minimum amount of
+ * rules: conflict, unit propagation, decide and backtrack (chronological
+ * backtracking).
+ *
+ * Phase 1: Unit propagation until either a conflict clause is found, or no unit
+ * clauses remain. If a conflict was found, backtrack one decision level. If no
+ * unit clauses remain and no clause is conflicting, go to phase 2.
+ *
+ * Phase 2: Assert a decision literal. Go to phase 1.
+ *
+ *
+ * Repeat phases 1 and 2 until either the formula is satisfiable or conflicting
+ * at decision level 0 (i.e. no backtracking possible).
+ *
+ *
+ * Implementation uses external defined rules, extending the {@link RuleSystem
+ * Rule System}.
+ *
+ * @see HighlevelStrategy
+ * @author Albert Schimpf
+ *
+ */
+public class DPLLSimple extends RuleSystem implements HighlevelStrategy {
+ /**
+ * The strategy has to operate on the formula {@code F} and has to have
+ * access to the trail {@code M}.
+ *
+ * @param solver
+ * reference to access formula {@code F} and trail {@code M}
+ * @param literalHeuristic given decide heuristic
+ * @param forgetHeuristic given forget heuristic
+ * @param learnHeuristic given learn heuristic
+ * @param restartHeuristic given restart heuristic
+ */
+ public DPLLSimple(@NotNull Solver solver,
+ @NotNull EDecide literalHeuristic, @NotNull ERestart restartHeuristic,
+ @NotNull ELearn learnHeuristic, @NotNull EForget forgetHeuristic) {
+ super(solver, literalHeuristic, restartHeuristic, learnHeuristic,
+ forgetHeuristic);
+ }
+
+ /**
+ * Actual implementation of the Classic DPLL strategy.
+ *
+ * {@code (((Conflict; Backtrack) || UnitPropag)* ; [Decide])* }
+ *
+ * No clause learning and forgetting; Optional restarts if enabled.
+ *
+ * @return true if formula {@code F} is satisfiable, false if not.
+ */
+ @Override
+ public boolean applyStrategy() {
+ while (true) {
+// System.out.println(M);
+ BCP();
+
+ if (conflictGuard()) {
+ applyConflict();
+
+ if (getSolver().getState().M().getCurrentDecisionLevel() == 0) {
+ return false;
+ } else {
+
+ assert backtrackGuard();
+ applyBacktrack();
+ }
+
+ } else {
+ if (decideGuard()) {
+ applyDecide();
+ } else {
+ return true;
+ }
+ }
+ }
+ }
+
+ private void BCP() {
+ Clause unit = unitGuard();
+ while (unit != null) {
+ if(getSolver().getState().F().foundConflict()){
+ break;
+ }
+ applyUnit(unit);
+ unit = unitGuard();
+ }
+ }
+
+ /**
+ * Returns the name of the strategy without the hash-code.
+ *
+ * @return name of strategy
+ */
+ @Override
+ public String toString() {
+ return getClass().getName();
+ }
+}
diff --git a/TransitionSystem/src/ruleSystem/RuleSystem.java b/TransitionSystem/src/ruleSystem/RuleSystem.java
new file mode 100644
index 0000000..05e588a
--- /dev/null
+++ b/TransitionSystem/src/ruleSystem/RuleSystem.java
@@ -0,0 +1,307 @@
+package ruleSystem;
+
+
+import factory.*;
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import rules.*;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.ForgetStrategy;
+import specificationHeuristics.LearnStrategy;
+import specificationHeuristics.LiteralSelectionStrategy;
+import specificationHeuristics.RestartStrategy;
+
+
+/**
+ * A rule system which can be extended by an actual high-level strategy, if the
+ * strategy does not want to implement the rules directly.
+ *
+ * All currently supported rules are implemented in this module.
+ *
+ * @author Albert Schimpf
+ * @see CoreRules Core Rules
+ */
+public abstract class RuleSystem implements CoreRules {
+ /**
+ * parameter.Param module reference.
+ */
+ private final @NotNull Solver solver;
+
+ /*
+ * External Rules - Basic
+ */
+ /**
+ * External decide rule.
+ *
+ * @see RuleDecide Decide
+ */
+ private final RDecide rDecide;
+ /**
+ * External unit rule.
+ *
+ * @see RuleUnit Unit
+ */
+ private final RUnit rUnit;
+ /**
+ * External conflict rule.
+ *
+ * @see RuleConflict Conflict
+ */
+ private final RConflict rConflict;
+ /**
+ * External backtrack rule.
+ *
+ * @see RuleBacktrack Backtrack
+ */
+ private final RBacktrack rBacktrack;
+
+ /*
+ * External Rules - Advanced
+ */
+ /**
+ * External backjump rule.
+ *
+ * @see RuleBackjump Backjump
+ */
+ private final RBackjump rBackjump;
+ /**
+ * External explain rule.
+ *
+ * @see RuleExplain Explain
+ */
+ private final RExplainEfficient rExplain;
+ /**
+ * External forget rule.
+ *
+ * @see RuleForget Forget
+ */
+ private final RForget rForget;
+ /**
+ * External learn rule.
+ *
+ * @see RuleLearn Learn
+ */
+ private final RLearn rLearn;
+ /**
+ * External restart rule.
+ *
+ * @see RuleRestart Restart
+ */
+ private final RRestart rRestart;
+
+ /*
+ * Strategies
+ */
+ /**
+ * Returns a decision literal via a given selected heuristic every time a
+ * decide rule is applied.
+ *
+ * @see LiteralSelectionStrategy
+ */
+ private final @NotNull LiteralSelectionStrategy literalSelectionStrategy;
+ /**
+ * Indicates, whether the solver should restart or not via a given restart
+ * heuristic.
+ *
+ * @see RestartStrategy
+ */
+ private final @NotNull RestartStrategy restartStrategy;
+ /**
+ * Indicates, when to learn clauses.
+ *
+ * @see LearnStrategy
+ */
+ private final @NotNull LearnStrategy learnStrategy;
+ /**
+ * Indicates, what learned clauses the solver should forget via a given
+ * forget heuristic
+ *
+ * @see ForgetStrategy
+ */
+ private final @NotNull ForgetStrategy forgetStrategy;
+
+ public RuleSystem(@NotNull Solver solver,
+ @NotNull EDecide literalHeuristic, @NotNull ERestart restartHeuristic,
+ @NotNull ELearn learnHeuristic, @NotNull EForget forgetHeuristic) {
+ this.solver = solver;
+
+ /*
+ * Instance heuristics
+ */
+
+ forgetStrategy = HeuristicFactory.getForgetHeuristic(solver,forgetHeuristic);
+
+ learnStrategy = HeuristicFactory.getLearnHeuristic(solver, learnHeuristic);
+
+ restartStrategy = HeuristicFactory.getRestartHeuristic(solver, restartHeuristic);
+
+ literalSelectionStrategy = HeuristicFactory.getLiteralSelectionHeuristic(solver,literalHeuristic);
+
+ /*
+ * External Rules - Basic
+ */
+ rDecide = new RDecide(solver, this);
+ rUnit = new RUnit(solver, this);
+ rConflict = new RConflict(solver, this);
+ rBacktrack = new RBacktrack(solver, this);
+
+ /*
+ * External Rules - Advanced
+ */
+ rBackjump = new RBackjump(solver, this);
+ rExplain = new RExplainEfficient(solver, this);
+ rForget = new RForget(solver, this);
+ rLearn = new RLearn(solver, this);
+ rRestart = new RRestart(solver, this);
+
+ }
+
+ /*
+ * RULE GUARDS BASIC
+ */
+ @Override
+ public boolean decideGuard() {
+ // Get guard of external decide rule
+ return rDecide.guard();
+ }
+
+ @Override
+ public Clause unitGuard() {
+ // Get guard of external unit rule
+ return rUnit.guard();
+ }
+
+ @Override
+ public boolean conflictGuard() {
+ // Get guard of external conflict rule
+ return rConflict.guard();
+ }
+
+ @Override
+ public boolean backtrackGuard() {
+ // Get guard of external backtrack rule
+ return rBacktrack.guard();
+ }
+
+ /*
+ * RULE GUARDS ADVANCED
+ */
+ @Override
+ public Integer backjumpGuard() {
+ // Get guard of external backjump rule
+ return rBackjump.guard();
+ }
+
+ @Override
+ public boolean learnGuard() {
+ // Get guard of external learn rule
+ return rLearn.guard();
+ }
+
+ @Override
+ public boolean forgetGuard() {
+ // Get guard of external forget rule
+ return rForget.guard();
+ }
+
+ @Override
+ public boolean restartGuard() {
+ // Get guard of external restart rule
+ return rRestart.guard();
+ }
+
+ @Override
+ public boolean explainUIPGuard() {
+ return rExplain.guard();
+ }
+
+ /*
+ * RULE APPLICATIONS BASIC
+ */
+ @Override
+ public void applyDecide() {
+ // Apply external decide rule and get decision literal
+ rDecide.apply();
+ }
+
+ @Override
+ public void applyUnit(Clause cl) {
+ // Apply external unit rule and get unit literal
+ rUnit.apply(cl);
+ }
+
+ @Override
+ public void applyConflict() {
+ // Apply external conflict rule
+ rConflict.apply();
+ }
+
+ @Override
+ public void applyBacktrack() {
+ // Apply external backtrack rule
+ rBacktrack.apply();
+
+ // Solver are updated in trail while backtracking
+ }
+
+ /*
+ * RULE APPLICATIONS ADVANCED
+ */
+ @Override
+ public void applyBackjump(Integer UIP) {
+ rBackjump.apply(UIP);
+ }
+
+ @Override
+ public void applyLearn() {
+ // Apply external learn rule and get learned clause
+ rLearn.apply();
+ }
+
+ @Override
+ public void applyForget() {
+ // Apply external forget rule and get forgotten clause
+ rForget.apply();
+ }
+
+ @Override
+ public void applyRestart() {
+ // Apply external restart rule
+ rRestart.apply();
+
+ // Inform observer
+ getSolver().getObs().forEach(SolverListener::onRestart);
+ }
+
+ @Override
+ public Integer applyExplainUIP() {
+ return rExplain.apply();
+ // Observers are notified in rule
+ }
+
+ @NotNull
+ public Solver getSolver() {
+ return solver;
+ }
+
+ @NotNull
+ public LiteralSelectionStrategy getLiteralSelectionStrategy() {
+ return literalSelectionStrategy;
+ }
+
+ @NotNull
+ public RestartStrategy getRestartStrategy() {
+ return restartStrategy;
+ }
+
+ @NotNull
+ public LearnStrategy getLearnStrategy() {
+ return learnStrategy;
+ }
+
+ @NotNull
+ public ForgetStrategy getForgetStrategy() {
+ return forgetStrategy;
+ }
+}
diff --git a/TransitionSystem/src/rules/RBackjump.java b/TransitionSystem/src/rules/RBackjump.java
new file mode 100644
index 0000000..f334872
--- /dev/null
+++ b/TransitionSystem/src/rules/RBackjump.java
@@ -0,0 +1,71 @@
+package rules;
+
+import ruleSystem.RuleSystem;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationCore.State;
+import specificationCore.Trail;
+
+import java.util.ArrayList;
+import java.util.List;
+import java.util.stream.Collectors;
+
+/**
+ * 2016/02/14.
+ */
+public class RBackjump {
+ private final Trail M;
+ private final Solver solver;
+ private final State state;
+
+ public RBackjump(Solver solver, CoreRules ruleSystem) {
+ M = solver.getState().M();
+ this.solver = solver;
+ this.state = solver.getState();
+ }
+
+ public Integer guard() {
+ // Check basic conditions
+ if (solver.getState().C() == null) {
+ return null;
+ }
+ if (M.getCurrentDecisionLevel() == 0) {
+ return null;
+ }
+
+ for (Integer lit : state.C()) {
+ if(M.getDecisionLevel(lit).equals(M.getCurrentDecisionLevel())){
+ return lit;
+ }
+ }
+
+ return null;
+ }
+
+ public void apply(Integer UIP) {
+ // Save current level for observer update
+ int current = M.getCurrentDecisionLevel();
+
+ // Get second recent decision level of conflict clause
+ List lneg = new ArrayList<>(state.C().size());
+ lneg.addAll(state.C().stream().map(l -> -l).collect(Collectors.toList()));
+
+ int bl = M.getSecondRecentDecisionLevel(lneg);
+
+ // If no SRDL:jump only one level back, and add negation of UIP to trail
+ if (bl == -1) {
+ M.backjumpToLevel(M.getCurrentDecisionLevel() - 1, UIP);
+
+ state.setC(null);
+ return;
+ }
+
+ M.backjumpToLevel(bl, UIP);
+ state.setC(null);
+
+ // Update observer
+ for (SolverListener o : solver.getObs()) {
+ o.onBackjump(current, bl, UIP);
+ }
+ }
+}
diff --git a/TransitionSystem/src/rules/RBacktrack.java b/TransitionSystem/src/rules/RBacktrack.java
new file mode 100644
index 0000000..f7496e2
--- /dev/null
+++ b/TransitionSystem/src/rules/RBacktrack.java
@@ -0,0 +1,36 @@
+package rules;
+
+
+import ruleSystem.RuleSystem;
+import specificationCore.Solver;
+import specificationCore.State;
+import specificationCore.Trail;
+
+public class RBacktrack {
+ private final Trail M;
+ private final State state;
+
+ public RBacktrack(Solver solver, CoreRules ruleSystem) {
+ M = solver.getState().M();
+ this.state = solver.getState();
+ }
+
+ public boolean guard() {
+ // If no conflict, backtrack is not applicable
+ if (state.C() == null) {
+ return false;
+ }
+ // If decision level == 0, there is no decision literal to backtrack
+ if (M.getCurrentDecisionLevel() == 0) {
+ return false;
+ }
+
+ // Else backtrack is applicable
+ return true;
+ }
+
+ public void apply() {
+ M.backtrack();
+ state.setC(null);
+ }
+}
diff --git a/TransitionSystem/src/rules/RConflict.java b/TransitionSystem/src/rules/RConflict.java
new file mode 100644
index 0000000..f4fa788
--- /dev/null
+++ b/TransitionSystem/src/rules/RConflict.java
@@ -0,0 +1,62 @@
+package rules;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import formula.SetOfClauses;
+import ruleSystem.RuleSystem;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationCore.State;
+
+/**
+ * Implementation of the conflict rule.
+ *
+ * For detailed specifications see
+ * {@link CoreRules#conflictGuard conflict guard} and
+ * {@link CoreRules#applyConflict apply conflict}.
+ *
+ * @author Albert Schimpf
+ * @see Rule
+ */
+public class RConflict{
+ private final SetOfClauses F;
+ private final State state;
+ private final Solver solver;
+
+ /**
+ * Default constructor which saves the main module reference.
+ * @param solver
+ * the main module reference.
+ * @param ruleSystem
+ */
+ public RConflict(@NotNull Solver solver, CoreRules ruleSystem) {
+ F = solver.getState().F();
+ this.state = solver.getState();
+ this.solver = solver;
+ }
+
+ public boolean guard() {
+ // If a conflict was already found, conflict can not be applied anymore
+ if (state.C() != null) {
+ return false;
+ }
+
+ return F.foundConflict();
+ }
+
+ public void apply() {
+ //noinspection AssertWithSideEffects
+
+ // Save reference for other rules
+ Clause conflictClause = F.getConflictingClause();
+ state.setC(conflictClause.getLiterals());
+
+
+ // Inform observer on conflict clause
+ for (SolverListener ob : solver.getObs()) {
+ ob.onConflict(conflictClause);
+ }
+ }
+
+
+}
diff --git a/TransitionSystem/src/rules/RDecide.java b/TransitionSystem/src/rules/RDecide.java
new file mode 100644
index 0000000..df7617a
--- /dev/null
+++ b/TransitionSystem/src/rules/RDecide.java
@@ -0,0 +1,47 @@
+package rules;
+
+import org.jetbrains.annotations.NotNull;
+import formula.SetOfClauses;
+import ruleSystem.RuleSystem;
+import specificationCore.*;
+import specificationHeuristics.LiteralSelectionStrategy;
+
+import static java.lang.Math.abs;
+
+
+
+public class RDecide {
+ private final SetOfClauses F;
+ private final Trail M;
+ private final Solver solver;
+ private LiteralSelectionStrategy heuristic;
+
+ public RDecide(@NotNull Solver solver, CoreRules ruleSystem) {
+ F = solver.getState().F();
+ M = solver.getState().M();
+ this.solver = solver;
+ heuristic = ruleSystem.getLiteralSelectionStrategy();
+ }
+
+ public boolean guard() {
+ // Get unassigned literal count from the formula F
+ return F.getFreeVariablesCount() > 0;
+ }
+
+ public void apply() {
+ assert guard();
+
+ // Use the selection strategy to get the decision level
+ int ld =heuristic.getLiteral();
+
+ // Add as a decision literal to the trail
+ M.addDecisionLiteral(ld);
+
+ // Inform observer on decide application
+ for (SolverListener ob : solver.getObs()) {
+ ob.onDecide(ld);
+ }
+ // Return decision literal
+// return ld;
+ }
+}
diff --git a/TransitionSystem/src/rules/RExplain.java b/TransitionSystem/src/rules/RExplain.java
new file mode 100644
index 0000000..9f9a8a2
--- /dev/null
+++ b/TransitionSystem/src/rules/RExplain.java
@@ -0,0 +1,50 @@
+package rules;
+
+import formula.SetOfClauses;
+import formula.Variable;
+import org.jetbrains.annotations.NotNull;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationCore.State;
+import specificationCore.Trail;
+
+import java.util.ArrayList;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.stream.Collectors;
+
+public class RExplain {
+ private final SetOfClauses F;
+ private final Trail M;
+ private final State state;
+
+ public RExplain(@NotNull Solver solver, @NotNull CoreRules ruleSystem) {
+ F = solver.getState().F();
+ M = solver.getState().M();
+ this.state = solver.getState();
+ }
+
+ public Integer guard() {
+ // C should not be empty
+ if (state.C() == null) {
+ return null;
+ }
+
+ List lits = new ArrayList<>();
+
+ int cdl = M.getCurrentDecisionLevel();
+ lits.addAll(state.C().stream().filter(lit -> (M.getDecisionLevel(lit) == cdl) && (M.getReason(lit) != null)).collect(Collectors.toList()));
+
+ int max = -1;
+ for (Integer p : lits) {
+ if (F.getVariable(p).getOrder() > max)
+ max = p;
+ }
+
+ return max;
+ }
+
+ public void apply(Integer resolve) {
+ SetOfClauses.generalResolve(state.C(),M.getReason(resolve),Math.abs(resolve));
+ }
+}
diff --git a/TransitionSystem/src/rules/RExplainEfficient.java b/TransitionSystem/src/rules/RExplainEfficient.java
new file mode 100644
index 0000000..5696176
--- /dev/null
+++ b/TransitionSystem/src/rules/RExplainEfficient.java
@@ -0,0 +1,140 @@
+package rules;
+
+import formula.SetOfClauses;
+import formula.Variable;
+import org.jetbrains.annotations.NotNull;
+import ruleSystem.RuleSystem;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationCore.State;
+import specificationCore.Trail;
+
+import java.util.LinkedList;
+import java.util.List;
+
+
+public class RExplainEfficient {
+ private final SetOfClauses F;
+ private final Trail M;
+ private final State state;
+ private final Solver solver;
+
+ private Integer UIP;
+ private List orderedLits;
+
+ public RExplainEfficient(@NotNull Solver solver, CoreRules ruleSystem) {
+ F = solver.getState().F();
+ M = solver.getState().M();
+ this.state = solver.getState();
+ this.solver = solver;
+ }
+
+ public boolean guard() {
+ orderedLits = new LinkedList<>();
+
+ // C should not be empty
+ if (state.C() == null) {
+ return false;
+ }
+
+ // Create ordered list of literals to be resolved in a backwards process
+ List toBeResolved = M
+ .getCurrentDecisionLevelLiteralsFromEnd();
+
+ assert toBeResolved.size() > 0;
+
+ // If there are no literals or only one (UIP), resolution is not needed
+ // (first UIP is decision literal)
+ if (toBeResolved.size() < 2) {
+ return false;
+ }
+
+
+
+ // Count literals in C
+ int anteCount = 0;
+ int litCount = 0;
+ for (Integer l : toBeResolved) {
+ if (state.C().contains(-l)) {
+ litCount++;
+ if (M.getReason(l) != null) {
+ orderedLits.add(l);
+ anteCount++;
+ }
+ }
+ }
+
+ // There should be at least 2 literals of C in current level
+ if (litCount > 1) {
+ // And 1 unit literal
+ if (anteCount > 0) {
+ return true;
+ }
+ }
+
+ // Otherwise, resolution not applicable
+ return false;
+ }
+
+ public Integer apply() {
+ UIP = null;
+
+ while(!orderedLits.isEmpty()){
+// System.out.println("CURRENT CONFLICT" +state.C());
+// System.out.println("List to be resolved: "+orderedLits);
+ Integer lit = orderedLits.remove(0);
+
+
+ // FirstUIP: Check, if only one literal is left in current decision
+ // level
+ int firstUIPCount = 0;
+ Integer firstUIP = null;
+ for (Integer cLit : state.C()) {
+ if (F.getVariable(cLit).getDl() == M.getCurrentDecisionLevel()) {
+ firstUIP = cLit;
+ firstUIPCount++;
+ }
+ }
+
+ // One literal in decision level, first UIP
+ if (firstUIPCount == 1) {
+// assert M.inTrail(firstUIP);
+ UIP = firstUIP;
+ return UIP;
+ }
+
+ // If literal has no antecedent, do nothing
+ List ante = M.getReason(lit);
+ if (null != ante) {
+ // Apply one resolve step
+ state.setC(applyExplain(ante, F.getVariable(lit)));
+// System.out.print("Produced ");
+
+ state.C().stream().filter(i -> F.getVariable(i).getDl() == M.getCurrentDecisionLevel()).filter(i -> !i.equals(lit) && !orderedLits.contains(i)).forEach(i -> orderedLits.add(i));
+
+// System.out.println();
+
+
+ // Update listener on resolution step
+ for (SolverListener l : solver.getObs()) {
+ l.onExplain(ante, lit, state.C());
+ }
+ }
+
+ // Iterate and search for next literal
+ }
+
+ return UIP;
+ }
+
+
+
+
+
+ private List applyExplain(@NotNull List ante,
+ @NotNull Variable var) {
+// System.out.println("RESOLVING "+var.getIndex() +" with "+ante);
+ return SetOfClauses.generalResolve(state.C(),ante,var.getIndex());
+ }
+
+}
diff --git a/TransitionSystem/src/rules/RForget.java b/TransitionSystem/src/rules/RForget.java
new file mode 100644
index 0000000..9067eb4
--- /dev/null
+++ b/TransitionSystem/src/rules/RForget.java
@@ -0,0 +1,42 @@
+package rules;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import formula.SetOfClauses;
+import ruleSystem.RuleSystem;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.ForgetStrategy;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public class RForget {
+ private final SetOfClauses F;
+ private final ForgetStrategy forgetStrategy;
+ private final Solver solver;
+
+ public RForget(@NotNull Solver solver, CoreRules ruleSystem) {
+ F = solver.getState().F();
+ this.solver = solver;
+ forgetStrategy = ruleSystem.getForgetStrategy();
+ }
+
+
+ public boolean guard() {
+ return F.getLearnedClauses().size() != 0 && forgetStrategy.shouldForget();
+ }
+
+ public void apply() {
+ assert guard();
+
+ List cF = forgetStrategy.forgetClauses();
+
+ // Inform observer on forgotten clauses
+ for (Clause c : cF) {
+ for (SolverListener ob : solver.getObs()) {
+ ob.onForget(c);
+ }
+ }
+ }
+}
diff --git a/TransitionSystem/src/rules/RLearn.java b/TransitionSystem/src/rules/RLearn.java
new file mode 100644
index 0000000..74aa380
--- /dev/null
+++ b/TransitionSystem/src/rules/RLearn.java
@@ -0,0 +1,35 @@
+package rules;
+
+import formula.Clause;
+import org.jetbrains.annotations.NotNull;
+import ruleSystem.RuleSystem;
+import specificationCore.Solver;
+import specificationCore.SolverListener;
+import specificationHeuristics.LearnStrategy;
+
+import java.util.List;
+
+public class RLearn {
+ private final LearnStrategy learnStrategy;
+ private final Solver solver;
+
+ public RLearn(@NotNull Solver solver, CoreRules ruleSystem) {
+ learnStrategy = ruleSystem.getLearnStrategy();
+ this.solver = solver;
+ }
+
+ public boolean guard() {
+ return learnStrategy.shouldLearn();
+ }
+
+ public void apply() {
+ assert guard();
+
+ Clause cF = learnStrategy.learnClause();
+
+ // Inform observer on learned clause
+ for (SolverListener ob : solver.getObs()) {
+ ob.onLearn(cF);
+ }
+ }
+}
diff --git a/TransitionSystem/src/rules/RRestart.java b/TransitionSystem/src/rules/RRestart.java
new file mode 100644
index 0000000..9f16ca8
--- /dev/null
+++ b/TransitionSystem/src/rules/RRestart.java
@@ -0,0 +1,43 @@
+package rules;
+
+import org.jetbrains.annotations.NotNull;
+import ruleSystem.RuleSystem;
+import specificationCore.Solver;
+import specificationCore.Trail;
+import specificationHeuristics.RestartStrategy;
+
+public class RRestart{
+ private final Trail M;
+ private final RestartStrategy restartStrategy;
+
+ /**
+ * Default constructor which saves the main module reference.
+ *
+ * @param solver
+ * the main module reference.
+ * @param ruleSystem
+ * rule system, which uses this rule
+ */
+ public RRestart(@NotNull Solver solver, @NotNull CoreRules ruleSystem) {
+ M = solver.getState().M();
+ restartStrategy = ruleSystem.getRestartStrategy();
+ }
+
+ /**
+ * Checks, if the solver should restart according to a restart heuristic.
+ *
+ * @return {@code true}, solver should restart; {@code false} otherwise
+ */
+ public boolean guard() {
+ return restartStrategy.shouldRestart();
+ }
+
+ /**
+ * Resets the trail, restarting the solving process.
+ */
+ public void apply() {
+ assert guard();
+
+ M.reset();
+ }
+}
diff --git a/TransitionSystem/src/rules/RUnit.java b/TransitionSystem/src/rules/RUnit.java
new file mode 100644
index 0000000..b3f182b
--- /dev/null
+++ b/TransitionSystem/src/rules/RUnit.java
@@ -0,0 +1,39 @@
+package rules;
+
+import org.jetbrains.annotations.NotNull;
+import formula.Clause;
+import formula.SetOfClauses;
+import ruleSystem.RuleSystem;
+import specificationCore.*;
+
+import static java.lang.Math.abs;
+
+public class RUnit {
+ private final SetOfClauses F;
+ private final Trail M;
+ private final Solver solver;
+
+ public RUnit(@NotNull Solver solver, CoreRules ruleSystem) {
+ F = solver.getState().F();
+ M = solver.getState().M();
+ this.solver = solver;
+ }
+
+ public Clause guard() {
+ return F.getUnitClause();
+ }
+
+ public void apply(Clause cl) {
+ // Get the unit literal from data structure
+ Integer lu = cl.getUnitLiteral();
+ // add unit literal with antecedent to trail
+ M.addUnitLiteral(lu, cl.getLiterals());
+
+ assert lu != null : "Returned null unit literal";
+
+ // Inform observer on unit application
+ for (SolverListener ob : solver.getObs()) {
+ ob.onUnitPropagate(cl.getLiterals(), lu);
+ }
+ }
+}
diff --git a/example-output.txt b/example-output.txt
new file mode 100644
index 0000000..2889c69
--- /dev/null
+++ b/example-output.txt
@@ -0,0 +1,24 @@
+c Loaded DIMACS instance: aim-50-1_6-yes1-2.cnf
+c START OPTIONS ------------------------------------
+c High-level strategy: highlevelStrategy.Chaff
+c Trail structure: arraylist.TrailArrayList@103dbd3
+c Data structure: mixed.SetOfClausesMixed
+c Decision heuristic: heuristicDecide.PolarityCachingPol || heuristicDecide.MSATeffective@167cf4d
+c Forget : heuristicForget.ForgetNever
+c Learn : heuristicLearn.LearnSimple
+c Restart : heuristicRestart.RestartConflictCountingGeometric
+c START FINISH LOG --------------------------------------
+c Initial (literal) [binary] {ternary}: 80 (0)[0]{80} 0
+c Operations: 1521
+c Decision: 41
+c Unit propagations: 336
+c Conflicts/Branches: 21
+c Ignored decisionlevels: 15
+c Average (Highest) decision level jump: 3 (8)
+c Resolutions: 738
+c Learned (literal) [binary] {ternary}: 19(1)[2]{2}
+c Forgotten clauses: 0
+c Restarts: 0
+c Time spent: 96 ms(49 ms + 47 ms)
+s SATISFIABLE
+v 38 -43 -24 -21 34 39 36 12 -15 31 6 42 33 -18 4 -17 -16 19 -20 -49 -47 26 25 14 44 3 -1 41 23 40 -22 8 -5 30 29 -13 -37 -32 46 10 27 50 48 11 -45 -28 7 35 2 9 0
diff --git a/src/de/unikl/CoreDPLL.java b/src/de/unikl/CoreDPLL.java
new file mode 100644
index 0000000..f0ea2f9
--- /dev/null
+++ b/src/de/unikl/CoreDPLL.java
@@ -0,0 +1,310 @@
+package de.unikl;
+
+import dimacsConverter.StrictConverter;
+import exceptions.ConvertException;
+import exceptions.SolverTimeoutException;
+import factory.*;
+import logger.SolverLogger;
+import logger.TimeoutLogger;
+import org.jetbrains.annotations.NotNull;
+import rules.*;
+import specificationCore.*;
+import specificationHeuristics.LiteralSelectionStrategy;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.LinkedList;
+import java.util.List;
+
+/**
+ * parameter.Param component connecting all different modules together to form a solver.
+ *
+ *
+ * Necessary minimum modules for correct solver behavior are:
+ *
+ * - {@link Trail Trail} implementation
+ *
- {@link SetOfClauses Formula} full
+ * implementation or formula based on {@link SetOfClauses Abstract formula}
+ *
- Complete and correct strategy (i.e.
+ * {@link highlevelStrategy.ExtendedDPLL Classic DPLL}) extending a
+ * corresponding {@link CoreRules rule system} or implementing
+ * the rules itself.
+ *
+ *
+ * Additions to the core solver can include:
+ *
+ * - More strategy with new rule system (i.e. {@link highlevelStrategy.Chaff
+ * Conflict-driven non-chronological backtracking})
+ *
- Efficient data structures (i.e.
+ * {@link SetOfClausesWL 2 Watched Literals})
+ *
- Heuristics for rule application (i.e. good decide heuristics)
+ *
- Restarts
+ *
- ClauseAbs learning and forgetting
+ *
+ *
+ * @author Albert Schimpf
+ *
+ */
+public class CoreDPLL implements Solver {
+ private final File path;
+ protected State state;
+
+ /*
+ * Observers & Loggers
+ */
+ private final List obs;
+ private final SolverLogger solverLogger;
+ private final TimeoutLogger timeoutLogger;
+
+ /*
+ * Strategies
+ */
+ private HighlevelStrategy highlevelStrategy;
+
+ /*
+ * Constructor
+ */
+ /**
+ * Default constructor for the solver, which initializes strategies given.
+ *
+ * @param path
+ * to instance
+ * @param logProcess
+ * on/off
+ * @param coreStrategy
+ * High-level strategy
+ * @param dataStructure
+ * Data structure
+ * @param literalHeuristic
+ * Decide heuristic
+ * @param forgetHeuristic
+ * Forget heuristic
+ * @param learnHeuristic
+ * Learn heuristic
+ * @param restartHeuristic
+ * Restart heuristic
+ * @param trail
+ * data structure for trail interface
+ * @param preprocess
+ * Preprocess strategy
+ * @param timeout
+ * timeout in seconds
+ *
+ */
+ public CoreDPLL(@NotNull File path, boolean logProcess,
+ @NotNull EHighlevel coreStrategy, @NotNull ESetOfClauses dataStructure,
+ @NotNull EDecide literalHeuristic, @NotNull ERestart restartHeuristic,
+ @NotNull ELearn learnHeuristic, @NotNull EForget forgetHeuristic,
+ @NotNull String preprocess, @NotNull ETrail trail, long timeout) {
+ obs = new LinkedList<>();
+ state = new StateImpl();
+
+ this.path = path;
+
+ timeoutLogger = new TimeoutLogger(this, timeout);
+
+ // Instance high-level strategy, trail, and select data structure and
+ // preprocessing strategy; pass heuristic parameters to strategies
+ selectPreprocessStrategy(preprocess);
+ selectDataStrategy(dataStructure);
+ selectTrailStrategy(trail);
+
+
+
+ instanceStrategy(coreStrategy, literalHeuristic, restartHeuristic,
+ learnHeuristic, forgetHeuristic);
+
+ if (logProcess) {
+ // Instance logger to gather additional information if enabled
+ solverLogger = new SolverLogger(this);
+ } else {
+ solverLogger = null;
+ }
+ }
+
+ public CoreDPLL(File path){
+ this(path,true,EHighlevel.Chaff,ESetOfClauses.DataCB,
+ EDecide.MiniSAT,ERestart.RestartGeometric,
+ ELearn.LearnSimple,EForget.ForgetNever,"NPP",
+ ETrail.TrailEfficient,1000);
+ }
+
+
+
+ /*
+ * HIGHLEVEL STRATEGY
+ */
+
+ /**
+ * Instances given high-level strategy.
+ *
+ * @param coreStrategy
+ * High-level strategy
+ * @param literalHeuristic
+ * Decide heuristic
+ * @param forgetHeuristic
+ * Forget heuristic
+ * @param learnHeuristic
+ * Learn heuristic
+ * @param restartHeuristic
+ * Restart heuristic
+ *
+ */
+ private void instanceStrategy(EHighlevel coreStrategy, EDecide literalHeuristic,
+ ERestart restartHeuristic, ELearn learnHeuristic,
+ EForget forgetHeuristic) {
+ highlevelStrategy = HighlevelStrategyFactory.getHighlevelStrategy(this, coreStrategy,literalHeuristic,restartHeuristic,learnHeuristic,forgetHeuristic);
+ }
+
+ /**
+ * Instances given data structure strategy.
+ *
+ * @param dataStructure
+ * Data structure
+ *
+ */
+ private void selectDataStrategy(ESetOfClauses dataStructure) {
+ state.setInitialF(DataStrategyFactory.getDataStrategy(this,dataStructure));
+ }
+
+ /**
+ * Instances given trail strategy.
+ *
+ * @param trail
+ * data structure for trail interface
+
+ */
+ private void selectTrailStrategy(ETrail trail) {
+ state.setInitialM(TrailFactory.getTrail(this,trail));
+ }
+
+ /**
+ * Instance given preprocess strategy.
+ *
+ * @param preprocess
+ * Preprocess strategy
+ *
+ */
+ private void selectPreprocessStrategy(String preprocess) {
+ switch (preprocess) {
+ case "NPP":
+ break;
+ default:
+ throw new IllegalArgumentException(
+ "Invalid preprocess strategy selected. " + preprocess);
+ }
+ }
+
+ /*
+ * PUBLIC METHODS
+ */
+
+ /**
+ * Loads given DIMACS file and checks the internal formula after solver has
+ * been built.
+ *
+ * Prints additional information, if logging is enabled.
+ *
+ * Prints lines to console according to specified format in the
+ * {@code application.parameter.Param} module.
+ *
+ * Throws an {@code ConvertException}, if the file does not fulfill the
+ * DIMACS format requirements.
+ *
+ * @return true, if instance is satisfiable; false otherwise
+ * @throws ConvertException
+ * if an error occurs during internal formula conversion
+ * @throws SolverTimeoutException
+ * if the solver times out or is forced to time out (unchecked).
+ */
+ public boolean checkCurrentInstance() throws ConvertException, SolverTimeoutException, IOException {
+ // TODO preprocess
+// state.getF().DimacsToSet(path);
+
+ StrictConverter.dimacsToSet(path, state.F());
+// StrictConverter.dimacsToSet();
+
+
+ // Update observer on conversion finish
+ getObs().forEach(SolverListener::onSetOfClausesLoaded);
+
+ if (solverLogger != null) {
+ // Print initial logging information if enabled
+ System.out.println("c Loaded DIMACS instance: " + path.getName());
+ solverLogger.printInitialLog();
+ }
+
+ // Get satisfiability
+// assert (F != null) && (M != null);
+ boolean sat = this.getHighlevelStrategy().applyStrategy();
+
+ if (solverLogger != null) {
+ // Additional information is only printed if enabled
+ solverLogger.printFinishLog();
+ }
+
+ if (sat) {
+ // If satisfiable, generate model
+ System.out.println("s SATISFIABLE");
+ state.M().createModel();
+ } else {
+ // Else generate refutation
+ System.out.println("s UNSATISFIABLE");
+ state.M().createRefutation();
+ }
+
+ // Return satisfiability to the caller
+ return sat;
+ }
+
+ /**
+ * Public method, to enable a forced solver timeout.
+ */
+ @SuppressWarnings("unused")
+ public void forceTimeout() {
+ timeoutLogger.forceTimeout();
+ }
+
+ @Override
+ public State getState() {
+ return state;
+ }
+
+ /**
+ * Adds given listener to the observer list.
+ *
+ * @param ob
+ * solver observer
+ */
+ public void addObserver(@NotNull SolverListener ob) {
+ getObs().add(ob);
+ }
+
+// /**
+// * Removes given listener from the observer list, if contained. Does
+// * nothing, if given object is not contained in the list.
+// *
+// * @param observer
+// * to be removed
+// */
+// public void removeObserver(@NotNull SolverListener observer) {
+// if (getObs().contains(this))
+// getObs().remove(observer);
+// }
+
+ public List getObs() {
+ return this.obs;
+ }
+
+// public SolverLogger getSolverLogger() {
+// return this.solverLogger;
+// }
+//
+// public TimeoutLogger getTimeoutLogger() {
+// return this.timeoutLogger;
+// }
+
+ public HighlevelStrategy getHighlevelStrategy() {
+ return this.highlevelStrategy;
+ }
+}
diff --git a/src/de/unikl/Main.java b/src/de/unikl/Main.java
new file mode 100644
index 0000000..0d9fb99
--- /dev/null
+++ b/src/de/unikl/Main.java
@@ -0,0 +1,277 @@
+package de.unikl;
+
+import exceptions.ConvertException;
+import exceptions.SolverTimeoutException;
+import factory.*;
+import heuristicForget.ForgetSimple;
+import heuristicForget.ForgetSize;
+import heuristicRestart.RestartConflictCountingFixed;
+import highlevelStrategy.DPLLSimple;
+import specificationCore.Solver;
+
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+
+import static factory.EForget.*;
+import static factory.EHighlevel.*;
+
+
+/**
+ * parameter.Param black-box application for using this SAT solver framework. Solver
+ * expects the file path as the first argument, other parameters can be
+ * specified in any order. If no parameters are given, help will be printed to
+ * the console.
+ *
+ * If finished, the solver prints a line to console depending if the formula is
+ * satisfied or not. Possible lines:
+ *
+ * - "s SATISFIABLE"
+ *
- "s UNSATISFIABLE"
+ *
+ *
+ * If satisfied, the solver additionally prints the variable assignments to
+ * console according to this {@link trail.TrailSimple#createModel() format}. If
+ * unsatisfiable, the solver generates a refutation proof.
+ *
+ * If logging is enabled, the solver prints additional comment lines with
+ * information above those two lines and times out after a certain amount of
+ * seconds, throwing a runtime Exception.
+ *
+ *
+ * - The file path. Either relative to current location or an absolute path.
+ *
+ *
- Write log to console (true/false).
+ *
+ *
- High-level strategy selection. Available options:
+ *
+ * - "Chaff" : {@link highlevelStrategy.Chaff Chaff}
+ *
- "DPLLExtended": {@link highlevelStrategy.ExtendedDPLL Simple DPLL} with
+ * additional rules
+ *
- "DPLLSimple": {@link DPLLSimple Simple DPLL}
+ *
+ *
+ * - Trail structure selection. Available options:
+ *
+ * - "TrailSimple" : {@link trail.TrailSimple Simple Trail}
+ *
+ *
+ * - Data-structure selection. Available options:
+ *
+ * - "Data2WL" : { 2-Watched Literals}
+ *
- "DataCB" : { Counter-Based}
+ *
+ *
+ *
+ * - Decide Heuristic. Available options:
+ *
+ * - "MiniSAT": {@link MiniSATVar Conflict prioritizing
+ * variable selection} with {@link heuristics.heuristicDecide.PolarityCachingPol Polarity
+ * Caching}
+ *
- "SLIS" : {@link heuristics.heuristicDecide.SLISLit Static Largest Individual Sum}
+ *
- "RandomLit": {@link heuristics.heuristicDecide.RandomLit Random BuilderLiteral Selection}
+ *
+ *
+ * - Learn heuristic. Available options:
+ *
+ * - "LearnNever" : {@link heuristics.heuristicLearn.LearnNever ClauseAbs Learning} off
+ *
- "LearnSimple" : {@link heuristics.heuristicLearn.LearnSimple ClauseAbs Learning} on
+ *
+ *
+ * - Forget heuristic. Available options:
+ *
+ * - "ForgetNever": {@link heuristics.heuristicForget.ForgetNever Forget} disabled
+ *
- "ForgetSimple": {@link heuristics.heuristicForget.ForgetSimple Forget} 25% learned
+ * clauses
+ *
- "ForgetRandomLarge": {@link heuristics.heuristicForget.ForgetRandomLarge Forget} 50%
+ * learned large clauses
+ *
- "ForgetRandomShort": {@link heuristics.heuristicForget.ForgetRandomShort Forget} 50%
+ * learned small clauses
+ *
+ *
+ *
+ * - Restart heuristic. Available options:
+ *
+ * - "RestartNever": {@link heuristics.heuristicRestart.RestartNever Restarts} disabled
+ *
- "RFixed" + i ( {@link heuristics.heuristicRestart.RestartConflictCountingFixed
+ * Fixed}):
+ *
+ * - 0: Berkmin (550 conflicts)
+ *
- 1: Chaff (700 conflicts)
+ *
- 2: Eureka (2000 conflicts)
+ *
- 3: Siege (16000 conflicts)
+ *
+ * - "RGeometric" + i (
+ * {@link heuristics.heuristicRestart.RestartConflictCountingGeometric Geometric}):
+ *
+ * - 0: MiniSAT (Base 100, factor 1.5) (Default)
+ *
+ *
+ * - Preprocessing. Available options:
+ *
+ * - "NPP": Preprocess disabled
+ *
+ *
+ *
+ *
+ * - Timeout. Terminates the solving process after given amount of seconds.
+ * Input as an Integer. Default: 10000 seconds.
+ *
+ *
+ */
+public class Main {
+ /**
+ * parameter.Param method to check a given DIMACS instance. Returns satisfiable (with a
+ * model in a separate file), or unsatisfiable (with a resolution proof in a
+ * separate file).
+ *
+ * First parameter should always be the path to the DIMACS instance. Other
+ * parameters are optional.
+ *
+ * @param args
+ * as specified in {@link Param}
+ * @throws FileNotFoundException
+ * if file does not exist.
+ * @throws IOException
+ * if stream to the DIMACS file cannot be written to or closed.
+ * @throws ConvertException
+ * if an error occurs during file conversion
+ * @throws IllegalArgumentException
+ * if file is a directory.
+ * @throws SolverTimeoutException
+ * if solver times out and logging is enabled
+ *
+ */
+ public static void main(String... args) throws IOException,
+ ConvertException, SolverTimeoutException {
+ if (args.length == 0) {
+ printHelp();
+ return;
+ }
+
+ File selected = new File(args[0]);
+
+ if (!selected.exists()) {
+ throw new FileNotFoundException("File does not exist: " + selected);
+ }
+ if (!selected.isFile()) {
+ throw new IllegalArgumentException("Must not be a directory: "
+ + selected);
+ }
+
+
+
+
+ // Set options (default)
+ boolean logging = true;
+ EHighlevel coreStrategy = Chaff;
+ ESetOfClauses dataStructure = ESetOfClauses.DataCB;
+ EDecide literalHeuristic = EDecide.MiniSAT;
+ ERestart restartHeuristic = ERestart.RestartGeometric;
+ EForget forgetHeuristic = ForgetNever;
+ ELearn learnHeuristic = ELearn.LearnSimple;
+ ETrail trail = ETrail.TrailEfficient;
+ String preprocess = "NPP";
+ long time = 1000;
+
+ // Fetch parameters
+ for (String s : args) {
+ if (s.equals(args[0])) {
+ continue;
+ }
+ try {
+ time = Integer.parseInt(s);
+ continue;
+ } catch (NumberFormatException ignored) {}
+
+ if(s.equals("true")){
+ logging = true;
+ }
+ else if(s.equals("false")){
+ logging = false;
+ }
+ else if(s.equals("Chaff")){
+ coreStrategy = Chaff;
+ }
+ else if(s.equals("DPLLSimple")){
+ coreStrategy = DPLLSimple;
+ }
+ else if(s.equals("DataCB")){
+ dataStructure = ESetOfClauses.DataCB;
+ }
+ else if(s.equals("Data2WL")){
+ dataStructure = ESetOfClauses.Data2WL;
+ }
+ else if(s.equals("DataMixed")){
+ dataStructure = ESetOfClauses.DataMixed;
+ }
+ else if(s.equals("MiniSAT")){
+ literalHeuristic = EDecide.MiniSAT;
+ }
+ else if(s.equals("SLIS")){
+ literalHeuristic = EDecide.SLIS;
+ }
+ else if(s.equals("RandomLit")){
+ literalHeuristic = EDecide.RandomLit;
+ }
+ else if(s.equals("ForgetNever")){
+ forgetHeuristic = ForgetNever;
+ }
+ else if(s.startsWith("ForgetSimple")){
+ forgetHeuristic = ForgetSimple;
+ heuristicForget.ForgetSimple.THRESHOLD = Integer.valueOf(s.substring(12));
+ }
+ else if(s.startsWith("ForgetRandomShort")){
+ forgetHeuristic = ForgetRandomShort;
+ heuristicForget.ForgetRandomShort.THRESHOLD = Integer.valueOf(s.substring(17));
+ }
+ else if(s.startsWith("ForgetRandomLarge")){
+ forgetHeuristic = ForgetRandomLarge;
+ heuristicForget.ForgetRandomLarge.THRESHOLD = Integer.valueOf(s.substring(17));
+ }
+ else if(s.startsWith("ForgetSize")){
+ forgetHeuristic = ForgetSize;
+ heuristicForget.ForgetSize.PERCENT = Integer.valueOf(s.substring(10));
+ }
+ else if(s.equals("LearnNever")){
+ learnHeuristic = ELearn.LearnNever;
+ }
+ else if(s.equals("LearnSimple")){
+ learnHeuristic = ELearn.LearnSimple;
+ }
+ //FIXME Trail
+ else if(s.equals("RestartNever")){
+ restartHeuristic = ERestart.RestartNever;
+ }
+ else if(s.startsWith("RestartGeometric")){
+ restartHeuristic = ERestart.RestartGeometric;
+ //FIXME arguments
+ }
+ else if(s.startsWith("RestartFixed")){
+ restartHeuristic = ERestart.RestartFixed;
+ RestartConflictCountingFixed.NEXTRESTART = Integer.valueOf(s.substring(12));
+ //FIXME arguments
+ }
+ //FIXME preprocessing
+ else{
+ throw new IllegalArgumentException("Argument not valid: "+s);
+ }
+
+ }
+
+ // Instance parameter.Param module
+ Solver dl = new CoreDPLL(selected, logging, coreStrategy,
+ dataStructure, literalHeuristic, restartHeuristic,
+ learnHeuristic,
+ forgetHeuristic, preprocess, trail, time);
+
+
+ // Return satisfiability
+ dl.checkCurrentInstance();
+ }
+
+ private static void printHelp() {
+ // TODO
+ System.out.println("Console help not implemented yet.");
+ }
+}
diff --git a/src/de/unikl/Param.java b/src/de/unikl/Param.java
new file mode 100644
index 0000000..6b1da7c
--- /dev/null
+++ b/src/de/unikl/Param.java
@@ -0,0 +1,501 @@
+package de.unikl;
+
+import exceptions.ConvertException;
+import exceptions.SolverTimeoutException;
+import factory.*;
+import highlevelStrategy.DPLLSimple;
+import specificationCore.Solver;
+
+import java.io.File;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+
+import static factory.EHighlevel.Chaff;
+import static factory.EHighlevel.DPLLSimple;
+
+
+/**
+ * parameter.Param black-box application for using this SAT solver framework. Solver
+ * expects the file path as the first argument, other parameters can be
+ * specified in any order. If no parameters are given, help will be printed to
+ * the console.
+ *
+ * If finished, the solver prints a line to console depending if the formula is
+ * satisfied or not. Possible lines:
+ *
+ * - "s SATISFIABLE"
+ *
- "s UNSATISFIABLE"
+ *
+ *
+ * If satisfied, the solver additionally prints the variable assignments to
+ * console according to this {@link trail.TrailSimple#createModel() format}. If
+ * unsatisfiable, the solver generates a refutation proof.
+ *
+ * If logging is enabled, the solver prints additional comment lines with
+ * information above those two lines and times out after a certain amount of
+ * seconds, throwing a runtime Exception.
+ *
+ *
+ * - The file path. Either relative to current location or an absolute path.
+ *
+ *
- Write log to console (true/false).
+ *
+ *
- High-level strategy selection. Available options:
+ *
+ * - "Chaff" : {@link highlevelStrategy.Chaff Chaff}
+ *
- "DPLLExtended": {@link highlevelStrategy.ExtendedDPLL Simple DPLL} with
+ * additional rules
+ *
- "DPLLSimple": {@link DPLLSimple Simple DPLL}
+ *
+ *
+ * - Trail structure selection. Available options:
+ *
+ * - "TrailSimple" : {@link trail.TrailSimple Simple Trail}
+ *
+ *
+ * - Data-structure selection. Available options:
+ *
+ * - "Data2WL" : { 2-Watched Literals}
+ *
- "DataCB" : { Counter-Based}
+ *
+ *
+ *
+ * - Decide Heuristic. Available options:
+ *
+ * - "MiniSAT": {@link MiniSATVar Conflict prioritizing
+ * variable selection} with {@link heuristics.heuristicDecide.PolarityCachingPol Polarity
+ * Caching}
+ *
- "SLIS" : {@link heuristics.heuristicDecide.SLISLit Static Largest Individual Sum}
+ *
- "RandomLit": {@link heuristics.heuristicDecide.RandomLit Random BuilderLiteral Selection}
+ *
+ *
+ * - Learn heuristic. Available options:
+ *
+ * - "LearnNever" : {@link heuristics.heuristicLearn.LearnNever ClauseAbs Learning} off
+ *
- "LearnSimple" : {@link heuristics.heuristicLearn.LearnSimple ClauseAbs Learning} on
+ *
+ *
+ * - Forget heuristic. Available options:
+ *
+ * - "ForgetNever": {@link heuristics.heuristicForget.ForgetNever Forget} disabled
+ *
- "ForgetSimple": {@link heuristics.heuristicForget.ForgetSimple Forget} 25% learned
+ * clauses
+ *
- "ForgetRandomLarge": {@link heuristics.heuristicForget.ForgetRandomLarge Forget} 50%
+ * learned large clauses
+ *
- "ForgetRandomShort": {@link heuristics.heuristicForget.ForgetRandomShort Forget} 50%
+ * learned small clauses
+ *
+ *
+ *
+ * - Restart heuristic. Available options:
+ *
+ * - "RestartNever": {@link heuristics.heuristicRestart.RestartNever Restarts} disabled
+ *
- "RFixed" + i ( {@link heuristics.heuristicRestart.RestartConflictCountingFixed
+ * Fixed}):
+ *
+ * - 0: Berkmin (550 conflicts)
+ *
- 1: Chaff (700 conflicts)
+ *
- 2: Eureka (2000 conflicts)
+ *
- 3: Siege (16000 conflicts)
+ *
+ * - "RGeometric" + i (
+ * {@link heuristics.heuristicRestart.RestartConflictCountingGeometric Geometric}):
+ *
+ * - 0: MiniSAT (Base 100, factor 1.5) (Default)
+ *
+ *
+ * - Preprocessing. Available options:
+ *
+ * - "NPP": Preprocess disabled
+ *
+ *
+ *
+ *
+ * - Timeout. Terminates the solving process after given amount of seconds.
+ * Input as an Integer. Default: 10000 seconds.
+ *
+ *
+ */
+public class Param {
+ /**
+ * parameter.Param method to check a given DIMACS instance. Returns satisfiable (with a
+ * model in a separate file), or unsatisfiable (with a resolution proof in a
+ * separate file).
+ *
+ * First parameter should always be the path to the DIMACS instance. Other
+ * parameters are optional.
+ *
+ * @param args
+ * as specified in {@link Param}
+ * @throws FileNotFoundException
+ * if file does not exist.
+ * @throws IOException
+ * if stream to the DIMACS file cannot be written to or closed.
+ * @throws ConvertException
+ * if an error occurs during file conversion
+ * @throws IllegalArgumentException
+ * if file is a directory.
+ * @throws SolverTimeoutException
+ * if solver times out and logging is enabled
+ *
+ */
+ public static void main(String... args) throws IOException,
+ ConvertException, SolverTimeoutException {
+ if (args.length == 0) {
+ printHelp();
+ return;
+ }
+
+ File selected = new File(args[0]);
+
+ if (!selected.exists()) {
+ throw new FileNotFoundException("File does not exist: " + selected);
+ }
+ if (!selected.isFile()) {
+ throw new IllegalArgumentException("Must not be a directory: "
+ + selected);
+ }
+
+
+
+
+ // Set options (default)
+ boolean logging = true;
+ EHighlevel coreStrategy = Chaff;
+ ESetOfClauses dataStructure = ESetOfClauses.DataCB;
+ EDecide literalHeuristic = EDecide.MiniSAT;
+ ERestart restartHeuristic = ERestart.RestartGeometric;
+ EForget forgetHeuristic = EForget.ForgetNever;
+ ELearn learnHeuristic = ELearn.LearnSimple;
+ ETrail trail = ETrail.TrailEfficient;
+ String preprocess = "NPP";
+ long time = 1000;
+
+ // Fetch parameters
+ for (String s : args) {
+ if (s.equals(args[0])) {
+ continue;
+ }
+ try {
+ time = Integer.parseInt(s);
+ continue;
+ } catch (NumberFormatException ignored) {}
+
+ switch (s) {
+ /*
+ * Logging parameters
+ */
+ case "true":
+ // Activate logging to file
+ logging = true;
+ break;
+ case "false":
+ // Deactivate logging to file
+ logging = false;
+ break;
+
+ /*
+ * High-level strategy parameters
+ */
+ //CASE
+ case "Chaff":
+ coreStrategy = Chaff;
+ break;
+ case "DPLLExtended":
+ //coreStrategy = DPLLExtended;
+ break;
+ case "DPLLSimple":
+ coreStrategy = DPLLSimple;
+ break;
+
+ /*
+ * Data structure parameters
+ */
+ case "DataCB":
+ //dataStructure = ESetOfClauses.DataCB;
+ break;
+ case "Data2WL":
+ //dataStructure = ESetOfClauses.Data2WL;
+ break;
+// case "DataMixed":
+// dataStructure = ESetOfClauses.DataMixed;
+// break;
+
+ /*
+ * BuilderLiteral selection heuristic parameters
+ */
+ case "MiniSAT":
+ //literalHeuristic = EDecide.MiniSAT;
+ break;
+ case "SLIS":
+ //literalHeuristic = EDecide.SLIS;
+ break;
+ case "RandomLit":
+ //literalHeuristic = EDecide.RandomLit;
+ break;
+ /*
+ * Forget heuristic parameters
+ */
+ case "ForgetNever":
+ //forgetHeuristic = ForgetNever;
+ break;
+ case "ForgetSimple":
+ //forgetHeuristic = ForgetSimple;
+ break;
+ case "ForgetRandomShort":
+ //forgetHeuristic = ForgetRandomShort;
+ break;
+ case "ForgetRandomLarge":
+ //forgetHeuristic = ForgetRandomLarge;
+ break;
+
+ /*
+ * Learn heuristic parameters
+ */
+ case "LearnNever":
+ //learnHeuristic = ELearn.LearnNever;
+ break;
+ case "LearnSimple":
+ //learnHeuristic = ELearn.LearnSimple;
+ break;
+
+ /*
+ * Trail parameters
+ */
+// case "TrailSimple":
+// trail = ETrail.TrailSimple;
+// break;
+ case "TrailEfficient":
+ //trail = ETrail.TrailEfficient;
+ break;
+
+ /*
+ * Restart heuristic parameters
+ */
+ case "RestartNever":
+ //restartHeuristic = ERestart.RestartNever;
+ break;
+ case "RestartGeometric1":
+ //restartHeuristic = ERestart.RestartGeometric;
+ break;
+ case "RestartFixed1":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 500;
+ break;
+ case "RestartFixed2":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 700;
+ break;
+ case "RestartFixed3":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 2000;
+ break;
+ case "RestartFixed4":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 20000;
+ break;
+
+ /*
+ * Prepocess parameters
+ */
+ case "NPP":
+ preprocess = s;
+ break;
+
+ default:
+ throw new IllegalArgumentException("Illegal argument given: "
+ + s);
+ }
+ }
+
+ // Instance parameter.Param module
+ Solver dl = new CoreDPLL(selected, logging, coreStrategy,
+ dataStructure, literalHeuristic, restartHeuristic,
+ learnHeuristic,
+ forgetHeuristic, preprocess, trail, time);
+
+
+ // Return satisfiability
+ dl.checkCurrentInstance();
+ }
+
+ public boolean check(String... args) throws IOException,
+ ConvertException, SolverTimeoutException {
+ File selected = new File(args[0]);
+
+ if (!selected.exists()) {
+ throw new FileNotFoundException("File does not exist: " + selected);
+ }
+ if (!selected.isFile()) {
+ throw new IllegalArgumentException("Must not be a directory: "
+ + selected);
+ }
+
+
+
+
+ // Set options (default)
+ boolean logging = true;
+ EHighlevel coreStrategy = Chaff;
+ ESetOfClauses dataStructure = ESetOfClauses.DataCB;
+ EDecide literalHeuristic = EDecide.MiniSAT;
+ ERestart restartHeuristic = ERestart.RestartGeometric;
+ EForget forgetHeuristic = EForget.ForgetNever;
+ ELearn learnHeuristic = ELearn.LearnSimple;
+ ETrail trail = ETrail.TrailEfficient;
+ String preprocess = "NPP";
+ long time = 1000;
+
+ // Fetch parameters
+ for (String s : args) {
+ if (s.equals(args[0])) {
+ continue;
+ }
+ try {
+ time = Integer.parseInt(s);
+ continue;
+ } catch (NumberFormatException ignored) {}
+
+ switch (s) {
+ /*
+ * Logging parameters
+ */
+ case "true":
+ // Activate logging to file
+ logging = true;
+ break;
+ case "false":
+ // Deactivate logging to file
+ logging = false;
+ break;
+
+ /*
+ * High-level strategy parameters
+ */
+ //CASE
+ case "Chaff":
+ coreStrategy = Chaff;
+ break;
+ case "DPLLExtended":
+ //coreStrategy = DPLLExtended;
+ break;
+ case "DPLLSimple":
+ coreStrategy = DPLLSimple;
+ break;
+
+ /*
+ * Data structure parameters
+ */
+ case "DataCB":
+ //dataStructure = ESetOfClauses.DataCB;
+ break;
+ case "Data2WL":
+ //dataStructure = ESetOfClauses.Data2WL;
+ break;
+// case "DataMixed":
+// dataStructure = ESetOfClauses.DataMixed;
+// break;
+
+ /*
+ * BuilderLiteral selection heuristic parameters
+ */
+ case "MiniSAT":
+ //literalHeuristic = EDecide.MiniSAT;
+ break;
+ case "SLIS":
+ //literalHeuristic = EDecide.SLIS;
+ break;
+ case "RandomLit":
+ //literalHeuristic = EDecide.RandomLit;
+ break;
+ /*
+ * Forget heuristic parameters
+ */
+ case "ForgetNever":
+ //forgetHeuristic = ForgetNever;
+ break;
+ case "ForgetSimple":
+ //forgetHeuristic = ForgetSimple;
+ break;
+ case "ForgetRandomShort":
+ //forgetHeuristic = ForgetRandomShort;
+ break;
+ case "ForgetRandomLarge":
+ //forgetHeuristic = ForgetRandomLarge;
+ break;
+
+ /*
+ * Learn heuristic parameters
+ */
+ case "LearnNever":
+ //learnHeuristic = ELearn.LearnNever;
+ break;
+ case "LearnSimple":
+ //learnHeuristic = ELearn.LearnSimple;
+ break;
+
+ /*
+ * Trail parameters
+ */
+// case "TrailSimple":
+// trail = ETrail.TrailSimple;
+// break;
+ case "TrailEfficient":
+ //trail = ETrail.TrailEfficient;
+ break;
+
+ /*
+ * Restart heuristic parameters
+ */
+ case "RestartNever":
+ //restartHeuristic = ERestart.RestartNever;
+ break;
+ case "RestartGeometric1":
+ //restartHeuristic = ERestart.RestartGeometric;
+ break;
+ case "RestartFixed1":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 500;
+ break;
+ case "RestartFixed2":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 700;
+ break;
+ case "RestartFixed3":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 2000;
+ break;
+ case "RestartFixed4":
+ //restartHeuristic = ERestart.RestartFixed;
+ //RestartConflictCountingFixed.NEXTRESTART = 20000;
+ break;
+
+ /*
+ * Prepocess parameters
+ */
+ case "NPP":
+ preprocess = s;
+ break;
+
+ default:
+ throw new IllegalArgumentException("Illegal argument given: "
+ + s);
+ }
+ }
+
+ // Instance parameter.Param module
+ Solver dl = new CoreDPLL(selected, logging, coreStrategy,
+ dataStructure, literalHeuristic, restartHeuristic,
+ learnHeuristic,
+ forgetHeuristic, preprocess, trail, time);
+
+
+ // Return satisfiability
+ return dl.checkCurrentInstance();
+ }
+
+ private static void printHelp() {
+ // TODO
+ System.out.println("Console help not implemented yet.");
+ }
+}
diff --git a/src/de/unikl/StateImpl.java b/src/de/unikl/StateImpl.java
new file mode 100644
index 0000000..b24d4ea
--- /dev/null
+++ b/src/de/unikl/StateImpl.java
@@ -0,0 +1,46 @@
+package de.unikl;
+
+import formula.SetOfClauses;
+import specificationCore.State;
+import specificationCore.Trail;
+
+import java.util.List;
+
+/**
+ * Created by nas on 05.02.16.
+ */
+public class StateImpl implements State{
+ public SetOfClauses F;
+ public Trail M;
+ public List C;
+
+ @Override
+ public void setInitialF(SetOfClauses F) {
+ this.F = F;
+ }
+
+ @Override
+ public SetOfClauses F() {
+ return F;
+ }
+
+ @Override
+ public void setInitialM(Trail M) {
+ this.M = M;
+ }
+
+ @Override
+ public Trail M() {
+ return M;
+ }
+
+ @Override
+ public List C() {
+ return C;
+ }
+
+ @Override
+ public void setC(List clause) {
+ this.C = clause;
+ }
+}
diff --git a/src/de/unikl/diagrams/core/12.3.2016/diagram.png b/src/de/unikl/diagrams/core/12.3.2016/diagram.png
new file mode 100644
index 0000000..8a84d51
Binary files /dev/null and b/src/de/unikl/diagrams/core/12.3.2016/diagram.png differ
diff --git a/src/de/unikl/diagrams/core/CoreModule.uml b/src/de/unikl/diagrams/core/CoreModule.uml
new file mode 100644
index 0000000..f66bcb2
--- /dev/null
+++ b/src/de/unikl/diagrams/core/CoreModule.uml
@@ -0,0 +1,106 @@
+
+
+ JAVA
+ heuristicForget.ForgetNever
+
+ specificationHeuristics.LearnStrategy
+ rules.CoreRules
+ specificationHeuristics.ForgetStrategy
+ specificationCore.State
+ specificationHeuristics.LiteralSelectionStrategy
+ specificationCore.Solver
+ de.unikl.CoreDPLL
+ de.unikl.StateImpl
+ specificationCore.HighlevelStrategy
+ formula.Clause
+ specificationCore.SolverListener
+ specificationHeuristics.VariableSelectionStrategy
+ formula.SetOfClauses
+ specificationHeuristics.PolaritySelectionStrategy
+ specificationCore.Trail
+ specificationHeuristics.RestartStrategy
+ de.unikl.Param
+ formula.Variable
+ specificationCore.ConverterObserver
+
+
+
+ de.unikl.StateImpl
+ Conflict is saved as \na List of Literals
+
+
+
+
+
+
+
+
+ specificationCore.HighlevelStrategy
+ Uses Strategies to \noperate on the State
+
+
+
+
+
+
+ specificationCore.SolverListener
+ Manages Observers
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ private
+
+
diff --git a/src/de/unikl/diagrams/formula/12.3.2016/CounterBased.png b/src/de/unikl/diagrams/formula/12.3.2016/CounterBased.png
new file mode 100644
index 0000000..6bb7487
Binary files /dev/null and b/src/de/unikl/diagrams/formula/12.3.2016/CounterBased.png differ
diff --git a/src/de/unikl/diagrams/formula/12.3.2016/FormulaGeneral.png b/src/de/unikl/diagrams/formula/12.3.2016/FormulaGeneral.png
new file mode 100644
index 0000000..6bd4f2d
Binary files /dev/null and b/src/de/unikl/diagrams/formula/12.3.2016/FormulaGeneral.png differ
diff --git a/src/de/unikl/diagrams/formula/12.3.2016/Mixed.png b/src/de/unikl/diagrams/formula/12.3.2016/Mixed.png
new file mode 100644
index 0000000..8d761c7
Binary files /dev/null and b/src/de/unikl/diagrams/formula/12.3.2016/Mixed.png differ
diff --git a/src/de/unikl/diagrams/formula/12.3.2016/WatchedLiterals.png b/src/de/unikl/diagrams/formula/12.3.2016/WatchedLiterals.png
new file mode 100644
index 0000000..c3e0d8b
Binary files /dev/null and b/src/de/unikl/diagrams/formula/12.3.2016/WatchedLiterals.png differ
diff --git a/src/de/unikl/diagrams/formula/13.3.2016/Counterbased.png b/src/de/unikl/diagrams/formula/13.3.2016/Counterbased.png
new file mode 100644
index 0000000..74bab09
Binary files /dev/null and b/src/de/unikl/diagrams/formula/13.3.2016/Counterbased.png differ
diff --git a/src/de/unikl/diagrams/formula/13.3.2016/Formula.png b/src/de/unikl/diagrams/formula/13.3.2016/Formula.png
new file mode 100644
index 0000000..7edf67e
Binary files /dev/null and b/src/de/unikl/diagrams/formula/13.3.2016/Formula.png differ
diff --git a/src/de/unikl/diagrams/formula/13.3.2016/Mixed.png b/src/de/unikl/diagrams/formula/13.3.2016/Mixed.png
new file mode 100644
index 0000000..7da620e
Binary files /dev/null and b/src/de/unikl/diagrams/formula/13.3.2016/Mixed.png differ
diff --git a/src/de/unikl/diagrams/formula/13.3.2016/WatchedLiterals.png b/src/de/unikl/diagrams/formula/13.3.2016/WatchedLiterals.png
new file mode 100644
index 0000000..1c0f0b7
Binary files /dev/null and b/src/de/unikl/diagrams/formula/13.3.2016/WatchedLiterals.png differ
diff --git a/src/de/unikl/diagrams/formula/FormulaCounterbasedDependencies.uml b/src/de/unikl/diagrams/formula/FormulaCounterbasedDependencies.uml
new file mode 100644
index 0000000..e84ab63
--- /dev/null
+++ b/src/de/unikl/diagrams/formula/FormulaCounterbasedDependencies.uml
@@ -0,0 +1,163 @@
+
+
+ JAVA
+ abstractImplementation
+
+ factory
+ rules.CoreRules
+ specificationCore.State
+ specificationCore.Solver
+ counterbased.VariableCbs
+ specificationHeuristics
+ interfaces.CounterBasedClause
+ specificationCore.HighlevelStrategy
+ abstractImplementation.SetOfClausesAbs
+ formula.Clause
+ specificationCore.SolverListener
+ interfaces.CounterBasedVariable
+ formula.SetOfClauses
+ specificationCore.Trail
+ counterbased.ClauseCbs
+ counterbased.SetOfClausesCbs
+ abstractImplementation.ClauseAbs
+ abstractImplementation.VariableAbs
+ formula.Variable
+ specificationCore.ConverterObserver
+
+
+
+ specificationCore.Solver
+ Clause learn observer\nnotification
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ public
+
+
diff --git a/src/de/unikl/diagrams/formula/FormulaGeneral.uml b/src/de/unikl/diagrams/formula/FormulaGeneral.uml
new file mode 100644
index 0000000..3b7c951
--- /dev/null
+++ b/src/de/unikl/diagrams/formula/FormulaGeneral.uml
@@ -0,0 +1,231 @@
+
+
+ JAVA
+ abstractImplementation
+
+ factory
+ counterbased.VariableCbs
+ wl.SetOfClausesW
+ mixed.ClauseMixed
+ interfaces.WatchedLiteralsClause
+ interfaces.CounterBasedClause
+ abstractImplementation.SetOfClausesAbs
+ interfaces.WatchedLiteralsVariable
+ formula.Clause
+ mixed.SetOfClausesMixed
+ wl.VariableW
+ interfaces.CounterBasedVariable
+ wl.ClauseWL
+ formula.SetOfClauses
+ counterbased.ClauseCbs
+ counterbased.SetOfClausesCbs
+ abstractImplementation.ClauseAbs
+ abstractImplementation.VariableAbs
+ formula.Variable
+ mixed.VariableMixed
+
+
+
+ factory
+ Instances SetOfClauses
+
+
+
+
+
+
+ formula.SetOfClauses
+ Fetch Unit/Conflict Clauses,\nadd/forget Clauses,\nDIMACS converting\nprovides resolve method
+
+
+
+
+
+
+ abstractImplementation.SetOfClausesAbs
+ Provides:\nUnit/Conflict detection\nDIMACS converting\nSeparation of Clause Literals from Clause
+
+
+
+
+
+
+
+
+ formula.Clause
+ add Literal, State Detection (Conflict, Unit), \nfetch Unit Literal, Clause Connection
+
+
+
+
+
+
+ abstractImplementation.ClauseAbs
+ Provides Separation of Literals (moved to SetOfClauses), \nClause Connection
+
+
+
+
+
+
+
+
+ abstractImplementation.VariableAbs
+ Provides Index, Assignment (partially), \nDecision Level, Antecedent
+
+
+
+
+
+
+
+
+ formula.Variable
+ Index, Assignment, Decision Level, \nAntecedent, Clause Connection
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ public
+
+
diff --git a/src/de/unikl/diagrams/formula/FormulaMixedDependencies.uml b/src/de/unikl/diagrams/formula/FormulaMixedDependencies.uml
new file mode 100644
index 0000000..a6078d2
--- /dev/null
+++ b/src/de/unikl/diagrams/formula/FormulaMixedDependencies.uml
@@ -0,0 +1,249 @@
+
+
+ JAVA
+ abstractImplementation
+
+ factory
+ rules.CoreRules
+ specificationCore.State
+ specificationCore.Solver
+ specificationHeuristics
+ mixed.ClauseMixed
+ interfaces.WatchedLiteralsClause
+ interfaces.CounterBasedClause
+ specificationCore.HighlevelStrategy
+ abstractImplementation.SetOfClausesAbs
+ interfaces.WatchedLiteralsVariable
+ formula.Clause
+ mixed.SetOfClausesMixed
+ specificationCore.SolverListener
+ interfaces.CounterBasedVariable
+ wl.ClauseWL
+ formula.SetOfClauses
+ specificationCore.Trail
+ counterbased.ClauseCbs
+ abstractImplementation.ClauseAbs
+ abstractImplementation.VariableAbs
+ formula.Variable
+ mixed.VariableMixed
+ specificationCore.ConverterObserver
+
+
+
+ specificationCore.Solver
+ Clause learn observer\nnotification
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ public
+
+
diff --git a/src/de/unikl/diagrams/formula/FormulaWatchedLiteralsDependencies.uml b/src/de/unikl/diagrams/formula/FormulaWatchedLiteralsDependencies.uml
new file mode 100644
index 0000000..ff22118
--- /dev/null
+++ b/src/de/unikl/diagrams/formula/FormulaWatchedLiteralsDependencies.uml
@@ -0,0 +1,161 @@
+
+
+ JAVA
+ abstractImplementation
+
+ factory
+ rules.CoreRules
+ specificationCore.State
+ specificationCore.Solver
+ wl.SetOfClausesW
+ specificationHeuristics
+ interfaces.WatchedLiteralsClause
+ specificationCore.HighlevelStrategy
+ abstractImplementation.SetOfClausesAbs
+ interfaces.WatchedLiteralsVariable
+ formula.Clause
+ wl.VariableW
+ specificationCore.SolverListener
+ wl.ClauseWL
+ formula.SetOfClauses
+ specificationCore.Trail
+ abstractImplementation.ClauseAbs
+ abstractImplementation.VariableAbs
+ formula.Variable
+ specificationCore.ConverterObserver
+
+
+
+ specificationCore.Solver
+ Clause learn observer\nnotification
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ public
+
+
diff --git a/src/de/unikl/diagrams/heuristics/12.3.2016/Heuristics.png b/src/de/unikl/diagrams/heuristics/12.3.2016/Heuristics.png
new file mode 100644
index 0000000..4bae8e5
Binary files /dev/null and b/src/de/unikl/diagrams/heuristics/12.3.2016/Heuristics.png differ
diff --git a/src/de/unikl/diagrams/heuristics/HeuristicsDependencies.uml b/src/de/unikl/diagrams/heuristics/HeuristicsDependencies.uml
new file mode 100644
index 0000000..c8eef0a
--- /dev/null
+++ b/src/de/unikl/diagrams/heuristics/HeuristicsDependencies.uml
@@ -0,0 +1,140 @@
+
+
+ JAVA
+ heuristicForget.ForgetNever
+
+ heuristicForget
+ specificationHeuristics.LearnStrategy
+ factory
+ rules.CoreRules
+ specificationHeuristics.ForgetStrategy
+ specificationCore.State
+ specificationHeuristics.LiteralSelectionStrategy
+ specificationCore.Solver
+ heuristicDecide
+ specificationCore.HighlevelStrategy
+ formula.Clause
+ specificationCore.SolverListener
+ specificationHeuristics.VariableSelectionStrategy
+ heuristicLearn
+ formula.SetOfClauses
+ specificationHeuristics.PolaritySelectionStrategy
+ specificationCore.Trail
+ heuristicRestart
+ specificationHeuristics.RestartStrategy
+ formula.Variable
+ specificationCore.ConverterObserver
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ private
+
+
diff --git a/src/de/unikl/diagrams/trail/12.3.2016/Trail.png b/src/de/unikl/diagrams/trail/12.3.2016/Trail.png
new file mode 100644
index 0000000..b15fcdb
Binary files /dev/null and b/src/de/unikl/diagrams/trail/12.3.2016/Trail.png differ
diff --git a/src/de/unikl/diagrams/trail/Trail.uml b/src/de/unikl/diagrams/trail/Trail.uml
new file mode 100644
index 0000000..8e748f9
--- /dev/null
+++ b/src/de/unikl/diagrams/trail/Trail.uml
@@ -0,0 +1,56 @@
+
+
+ JAVA
+ heuristicForget.ForgetNever
+
+ factory
+ rules.CoreRules
+ specificationCore.State
+ specificationCore.Solver
+ specificationHeuristics
+ specificationCore.HighlevelStrategy
+ formula.Clause
+ specificationCore.SolverListener
+ formula.SetOfClauses
+ arraylist.TLiteral
+ specificationCore.Trail
+ arraylist.TrailArrayList
+ formula.Variable
+ specificationCore.ConverterObserver
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ private
+
+
diff --git a/src/de/unikl/diagrams/transistionSystem/12.3.2016/TransitionSystem.png b/src/de/unikl/diagrams/transistionSystem/12.3.2016/TransitionSystem.png
new file mode 100644
index 0000000..a08357f
Binary files /dev/null and b/src/de/unikl/diagrams/transistionSystem/12.3.2016/TransitionSystem.png differ
diff --git a/src/de/unikl/diagrams/transistionSystem/TransistionSystem.uml b/src/de/unikl/diagrams/transistionSystem/TransistionSystem.uml
new file mode 100644
index 0000000..8115482
--- /dev/null
+++ b/src/de/unikl/diagrams/transistionSystem/TransistionSystem.uml
@@ -0,0 +1,226 @@
+
+
+ JAVA
+ factory.HighlevelStrategyFactory
+
+ factory
+ rules.CoreRules
+ specificationCore.State
+ specificationCore.Solver
+ specificationHeuristics
+ ruleSystem.RuleSystem
+ rules.RLearn
+ specificationCore.HighlevelStrategy
+ formula.Clause
+ rules.RBackjump
+ rules.RUnit
+ rules.RRestart
+ specificationCore.SolverListener
+ rules.RBacktrack
+ formula.SetOfClauses
+ specificationCore.Trail
+ highlevelStrategy.DPLLSimple
+ rules.RDecide
+ rules.RConflict
+ highlevelStrategy.Chaff
+ formula.Variable
+ rules.RExplainEfficient
+ rules.RForget
+ specificationCore.ConverterObserver
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ All
+ private
+
+
diff --git a/test/de/unikl/HighlevelTests.java b/test/de/unikl/HighlevelTests.java
new file mode 100644
index 0000000..5c27a8e
--- /dev/null
+++ b/test/de/unikl/HighlevelTests.java
@@ -0,0 +1,170 @@
+package de.unikl;
+
+import exceptions.ConvertException;
+import exceptions.SolverTimeoutException;
+import factory.*;
+import org.junit.BeforeClass;
+import org.junit.Test;
+import specificationCore.Solver;
+
+import java.io.File;
+import java.io.IOException;
+import java.nio.file.Files;
+import java.nio.file.Paths;
+import java.text.DecimalFormat;
+import java.util.ArrayList;
+import java.util.List;
+
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
+
+
+/**
+ * Created by nas on 05.02.16.
+ */
+@SuppressWarnings("ALL")
+public class HighlevelTests {
+ static List satTests = new ArrayList<>();
+ static List unsatTests = new ArrayList<>();
+
+ @BeforeClass
+ public static void setUpBeforeClass() throws Exception {
+ Files.walk(Paths.get("test/resources/sat"))
+ .filter(Files::isRegularFile)
+ .forEach((f) -> satTests.add(f.toFile()));
+ Files.walk(Paths.get("test/resources/easySat"))
+ .filter(Files::isRegularFile)
+ .forEach((f) -> satTests.add(f.toFile()));
+
+ Files.walk(Paths.get("test/resources/unsat"))
+ .filter(Files::isRegularFile)
+ .forEach((f) -> unsatTests.add(f.toFile()));
+ Files.walk(Paths.get("test/resources/easyUnsat"))
+ .filter(Files::isRegularFile)
+ .forEach((f) -> unsatTests.add(f.toFile()));
+
+ if(Parameter.full){
+ Files.walk(Paths.get("test/resources/BenchmarkSat"))
+ .filter(Files::isRegularFile)
+ .forEach((f) -> satTests.add(f.toFile()));
+ Files.walk(Paths.get("test/resources/BenchmarkHardSat"))
+ .filter(Files::isRegularFile)
+ .forEach((f) -> satTests.add(f.toFile()));
+
+ Files.walk(Paths.get("test/resources/BenchmarkUnsat"))
+ .filter(Files::isRegularFile)
+ .forEach((f) -> unsatTests.add(f.toFile()));
+
+ }
+ }
+
+ @Test
+ public void T1() {
+ System.out.println(satTests.size());
+ System.out.println(unsatTests.size());
+ }
+
+
+
+ @Test
+ public void SatTests() throws ConvertException, IOException {
+ int i = 0;
+ int j = 0;
+
+ int max = generateMax();
+ for (EHighlevel hl : Parameter.HIGHLEVEL) {
+ for (ESetOfClauses s : Parameter.FORMULA) {
+ for (ETrail t : Parameter.TRAIL) {
+ for (EDecide d : Parameter.DECIDE) {
+ for (EForget f : Parameter.FORGET) {
+ for (ELearn l : Parameter.LEARN) {
+ for (ERestart r : ERestart.values()) {
+
+ for (File file : satTests) {
+
+ double prog = ((i * 1.0) / (max * 1.0)) * 100;
+ DecimalFormat df = new DecimalFormat("#.##");
+ System.out.print("[PROGRESS] " + df.format(prog) + "% || " + i + "/" + max + " [" + j + " t/o]");
+ System.out.println(" -- "+file.getName());
+
+ System.out.print("["+hl+"]");
+ System.out.print("["+s+"]");
+ System.out.print("["+t+"]");
+ System.out.print("["+d+"]");
+ System.out.println();
+ System.out.print("("+f+")");
+ System.out.print("("+l+")");
+ System.out.print("("+r+")");
+ System.out.println();
+
+ Solver dl = new CoreDPLL(file, Parameter.LOGGING, hl,
+ s, d, r,
+ l,
+ f, "NPP", t, Parameter.TIMEOUT);
+
+ // Return satisfiability
+ try {
+ assertTrue(dl.checkCurrentInstance());
+ } catch (SolverTimeoutException e) {
+ System.out.println("Timeout nr " + (j + 1));
+ j++;
+ }
+
+ i++;
+ }
+
+ for (File file : unsatTests) {
+ double prog = ((i * 1.0) / (max * 1.0)) * 100;
+ DecimalFormat df = new DecimalFormat("#.##");
+ System.out.print("[PROGRESS] " + df.format(prog) + "% || " + i + "/" + max + " [" + j + " t/o]");
+ System.out.println(" -- "+file.getName());
+
+ System.out.print("["+hl+"]");
+ System.out.print("["+s+"]");
+ System.out.print("["+t+"]");
+ System.out.print("["+d+"]");
+ System.out.println();
+ System.out.print("("+f+")");
+ System.out.print("("+l+")");
+ System.out.print("("+r+")");
+ System.out.println();
+
+ Solver dl = new CoreDPLL(file, Parameter.LOGGING, hl,
+ s, d, r,
+ l,
+ f, "NPP", t, Parameter.TIMEOUT);
+
+ // Return satisfiability
+ try {
+ boolean ass = dl.checkCurrentInstance();
+ assertFalse(ass);
+ } catch (SolverTimeoutException e) {
+ System.out.println("Timeout nr " + (j + 1));
+ j++;
+ }
+
+ i++;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+
+
+
+ private int generateMax() {
+ int i = (satTests.size() +unsatTests.size())*
+ Parameter.DECIDE.length*
+ Parameter.FORGET.length*
+ Parameter.HIGHLEVEL.length*
+ Parameter.LEARN.length*
+ ERestart.values().length*
+ ESetOfClauses.values().length;
+
+ return i;
+ }
+}
diff --git a/test/de/unikl/Parameter.java b/test/de/unikl/Parameter.java
new file mode 100644
index 0000000..60ad5d0
--- /dev/null
+++ b/test/de/unikl/Parameter.java
@@ -0,0 +1,33 @@
+package de.unikl;
+
+
+import factory.*;
+
+public class Parameter {
+
+
+
+ public static boolean LOGGING = false;
+ public static int TESTS = 100;
+ public static int HIGH = TESTS*10;
+ public static int MEDIUM = TESTS*5;
+ public static int LOW = TESTS*1;
+ public static int TIMEOUT = 4; //seconds
+
+ public static boolean full = true;
+
+ //scope of implemented highlevel strategies to test
+ public static final EHighlevel[] HIGHLEVEL = new EHighlevel[]{EHighlevel.Chaff,EHighlevel.DPLLSimple};
+ public static final EDecide[] DECIDE = new EDecide[]{EDecide.MiniSAT,EDecide.SLIS};
+ public static final EForget[] FORGET = new EForget[]{EForget.ForgetSimple,EForget.ForgetNever,EForget.ForgetRandomLarge, EForget.ForgetRandomShort};
+ public static final ELearn[] LEARN = new ELearn[]{ELearn.LearnSimple,ELearn.LearnNever};
+ public static final ESetOfClauses[] FORMULA = new ESetOfClauses[]{ESetOfClauses.DataMixed};
+ public static final ETrail[] TRAIL = ETrail.values();
+
+// public static final EHighlevel[] HIGHLEVEL = new EHighlevel[]{EHighlevel.Chaff};
+// public static final EDecide[] DECIDE = new EDecide[]{EDecide.MiniSAT};
+// public static final EForget[] FORGET = new EForget[]{EForget.ForgetSimple};
+// public static final ELearn[] LEARN = new ELearn[]{ELearn.LearnSimple};
+// public static final ESetOfClauses[] FORMULA = new ESetOfClauses[]{ESetOfClauses.Data2WL};
+// public static final ETrail[] TRAIL = ETrail.values();
+}
diff --git a/test/resources/BenchmarkHardSat/aim-200-6_0-yes1-2.cnf b/test/resources/BenchmarkHardSat/aim-200-6_0-yes1-2.cnf
new file mode 100644
index 0000000..4f30586
--- /dev/null
+++ b/test/resources/BenchmarkHardSat/aim-200-6_0-yes1-2.cnf
@@ -0,0 +1,1211 @@
+c FILE: aim-200-6_0-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 200 1200
+51 87 -120 0
+51 -120 134 0
+54 -120 134 0
+-54 106 -120 0
+-106 -120 134 0
+-120 -134 177 0
+113 -134 -177 0
+64 -134 -177 0
+-64 -134 -177 0
+-75 120 141 0
+-75 120 -141 0
+-29 120 162 0
+-29 75 120 0
+-1 29 120 0
+29 99 171 0
+75 99 -171 0
+74 75 168 0
+74 75 -168 0
+12 75 -99 0
+4 21 22 0
+1 4 -61 0
+-4 22 -61 0
+1 -12 -61 0
+-74 -99 183 0
+-74 -86 -99 0
+-86 -99 -183 0
+120 166 -179 0
+121 -166 -179 0
+68 86 -179 0
+-68 120 -121 0
+1 3 -12 0
+1 3 -82 0
+-3 44 193 0
+-3 44 -172 0
+-12 44 -193 0
+-12 -14 54 0
+-12 -44 54 0
+-8 -74 -99 0
+37 86 179 0
+-54 91 -131 0
+8 -54 -91 0
+8 -46 187 0
+-46 86 -187 0
+-37 61 -116 0
+-3 116 178 0
+8 -14 -37 0
+104 145 -178 0
+-104 116 145 0
+31 35 -54 0
+30 -31 -145 0
+-30 -145 196 0
+35 -145 196 0
+35 -145 -196 0
+-7 -35 -37 0
+7 116 -159 0
+7 -65 116 0
+14 94 179 0
+-94 179 198 0
+-35 155 -198 0
+14 -35 -179 0
+-127 155 -179 0
+14 84 116 0
+-47 -84 116 0
+-85 159 -178 0
+14 66 -84 0
+47 57 -145 0
+47 112 -116 0
+47 -116 -145 0
+85 -105 -155 0
+-58 -66 85 0
+58 -84 107 0
+58 107 -198 0
+-66 -84 98 0
+-57 85 -194 0
+47 106 112 0
+47 -112 137 0
+106 -137 194 0
+-106 107 196 0
+-106 -107 196 0
+58 105 110 0
+182 194 -196 0
+64 -98 -104 0
+-64 -98 -106 0
+-106 -157 -196 0
+157 168 188 0
+157 168 -182 0
+-78 104 -182 0
+-137 -182 194 0
+-110 -125 -168 0
+-128 157 -196 0
+66 125 189 0
+-66 -182 189 0
+-32 -66 189 0
+-115 137 157 0
+-11 19 137 0
+-11 157 -169 0
+-19 137 157 0
+143 157 -168 0
+11 43 78 0
+-11 43 -143 0
+36 67 115 0
+64 67 -189 0
+107 -189 -197 0
+-64 67 107 0
+67 -107 -189 0
+78 125 -156 0
+128 -129 -189 0
+34 125 -189 0
+-143 148 -199 0
+-43 -143 -148 0
+-20 -34 57 0
+-20 -34 -57 0
+20 32 -43 0
+20 35 -43 0
+20 35 -43 0
+20 -35 -92 0
+92 156 180 0
+-67 -180 198 0
+-149 -180 198 0
+-32 -180 -185 0
+81 92 -198 0
+-68 -81 185 0
+36 -81 141 0
+36 -81 -180 0
+20 68 -114 0
+47 92 -162 0
+68 92 -162 0
+-47 92 -162 0
+68 -180 183 0
+68 -118 190 0
+42 185 -190 0
+-42 -118 -190 0
+-11 168 185 0
+-11 -168 -198 0
+42 118 162 0
+18 146 162 0
+138 -146 -183 0
+-18 138 162 0
+-36 -38 162 0
+-38 -78 162 0
+-78 162 -174 0
+-38 -78 -150 0
+-36 144 175 0
+11 -144 175 0
+-36 172 -175 0
+-42 -139 162 0
+11 -15 -138 0
+33 -42 -165 0
+-33 -42 -165 0
+38 -42 -192 0
+11 15 44 0
+15 23 38 0
+23 102 -119 0
+23 38 -102 0
+139 187 192 0
+139 187 192 0
+-23 -124 139 0
+124 132 -172 0
+-23 120 -153 0
+133 139 -153 0
+-120 133 -153 0
+-23 139 -153 0
+-23 -133 -153 0
+15 -166 192 0
+-19 -166 192 0
+-19 -81 -166 0
+15 -19 -166 0
+-23 80 -132 0
+87 -164 192 0
+34 124 -164 0
+-34 -87 -164 0
+-80 124 -152 0
+73 153 164 0
+82 88 164 0
+88 -101 164 0
+-82 88 164 0
+-31 -88 183 0
+-31 -88 -183 0
+-31 -72 -88 0
+24 -132 164 0
+-16 138 166 0
+-24 138 166 0
+8 107 166 0
+8 -16 166 0
+-8 -138 166 0
+-30 31 36 0
+-30 31 -36 0
+16 -26 -30 0
+21 -24 31 0
+-40 42 -73 0
+42 -73 -130 0
+-73 143 196 0
+-42 88 -196 0
+-42 88 -143 0
+-40 -42 -73 0
+31 56 113 0
+31 56 -113 0
+30 41 -88 0
+-21 -56 -112 0
+-41 -51 -56 0
+30 40 45 0
+40 -45 193 0
+51 92 94 0
+94 112 -169 0
+51 94 112 0
+5 51 180 0
+5 44 -180 0
+5 -44 51 0
+-10 -41 -94 0
+10 -41 102 0
+62 -102 -193 0
+18 -62 -64 0
+-62 -64 112 0
+-5 64 -121 0
+51 64 -113 0
+113 -127 -193 0
+-5 -102 -151 0
+-102 -113 -151 0
+83 149 151 0
+83 113 151 0
+-83 93 151 0
+-63 -93 123 0
+-63 112 -123 0
+-93 -112 127 0
+-93 127 160 0
+136 151 -160 0
+39 113 121 0
+-91 -93 127 0
+-93 127 -129 0
+63 127 -167 0
+91 -93 -191 0
+91 151 176 0
+85 -90 167 0
+63 -85 167 0
+17 91 130 0
+91 130 -136 0
+-140 167 -176 0
+91 -126 -136 0
+-49 90 126 0
+85 -146 191 0
+-85 -146 -176 0
+49 -82 90 0
+126 169 191 0
+126 186 191 0
+186 191 199 0
+126 191 -199 0
+138 140 188 0
+69 138 -188 0
+6 69 140 0
+-6 69 140 0
+33 146 -186 0
+33 37 -186 0
+33 37 -186 0
+33 -37 -186 0
+-33 78 117 0
+57 -78 142 0
+24 117 -142 0
+24 -56 156 0
+24 -142 -156 0
+-142 146 151 0
+-33 110 -151 0
+-24 57 -142 0
+17 117 -186 0
+-33 -57 117 0
+49 -111 126 0
+-69 -117 -123 0
+126 146 -188 0
+146 -184 -186 0
+-69 -96 111 0
+-77 111 123 0
+-65 77 184 0
+84 96 172 0
+-84 172 184 0
+96 -141 -172 0
+18 77 123 0
+123 169 188 0
+-4 -18 184 0
+77 96 -142 0
+96 -163 184 0
+96 103 142 0
+89 96 142 0
+89 -103 -167 0
+89 -159 -167 0
+4 95 163 0
+-18 66 -169 0
+59 -66 -169 0
+-18 -25 -169 0
+70 114 163 0
+70 154 163 0
+25 -114 163 0
+-114 -154 163 0
+6 33 -95 0
+33 73 -95 0
+-6 -73 -95 0
+83 -89 -95 0
+-17 -89 -95 0
+-33 71 -95 0
+-59 -89 144 0
+-71 -144 175 0
+58 68 -97 0
+25 -58 -97 0
+-68 -97 -175 0
+17 87 95 0
+17 87 -95 0
+17 -144 -177 0
+17 97 -147 0
+-87 136 -144 0
+-87 -136 198 0
+-22 100 -136 0
+17 -22 -100 0
+-17 -22 -198 0
+-22 -25 -198 0
+97 -109 133 0
+-87 97 -109 0
+97 109 122 0
+22 97 135 0
+-37 97 135 0
+22 -122 173 0
+27 -60 109 0
+-60 109 -122 0
+28 -135 146 0
+16 22 -146 0
+-16 28 -146 0
+60 -149 -173 0
+60 -79 -135 0
+-55 61 149 0
+-28 -61 149 0
+60 -158 172 0
+60 -158 -173 0
+55 158 -195 0
+-53 55 -195 0
+55 -58 158 0
+65 165 175 0
+-135 -175 -197 0
+165 -174 -197 0
+48 -65 -135 0
+-65 -135 165 0
+-48 -65 194 0
+-48 -119 -197 0
+-135 -165 195 0
+-135 195 -197 0
+9 -28 149 0
+-9 79 -133 0
+55 79 174 0
+79 91 -190 0
+22 -91 133 0
+-22 -91 -190 0
+79 133 -157 0
+100 111 190 0
+100 -111 190 0
+53 55 -174 0
+53 90 -174 0
+53 55 -174 0
+53 55 -69 0
+170 -174 197 0
+-27 -100 190 0
+-108 -170 -174 0
+-9 27 -154 0
+-19 133 154 0
+-19 83 -133 0
+-19 -83 154 0
+19 -53 134 0
+27 -100 -200 0
+27 72 121 0
+-121 133 -170 0
+27 72 97 0
+27 72 -121 0
+27 -48 200 0
+45 154 -170 0
+19 108 -181 0
+-2 54 154 0
+-2 -72 154 0
+154 -171 200 0
+-18 154 -171 0
+-45 102 103 0
+-26 -45 -102 0
+-26 48 -103 0
+-45 88 -148 0
+2 -88 -148 0
+-101 148 178 0
+-101 -178 181 0
+48 71 103 0
+5 48 181 0
+48 -71 103 0
+26 -45 150 0
+101 -119 183 0
+101 -119 -183 0
+26 -103 -161 0
+76 -103 175 0
+76 -150 -175 0
+-61 -150 -175 0
+-103 -104 -175 0
+83 156 161 0
+-76 -156 161 0
+13 48 119 0
+13 119 -150 0
+50 -83 161 0
+-50 52 96 0
+-50 -83 -96 0
+52 -83 -96 0
+-6 -50 -150 0
+33 68 169 0
+47 -167 198 0
+13 23 35 0
+-52 153 196 0
+-81 -97 153 0
+-17 -31 -43 0
+37 153 195 0
+8 45 100 0
+50 -62 -127 0
+-31 -102 -193 0
+-1 -125 134 0
+-11 -163 -181 0
+-23 -60 74 0
+71 -73 155 0
+83 -185 193 0
+84 143 161 0
+-77 -154 189 0
+-29 -33 -196 0
+6 -69 95 0
+54 68 -147 0
+93 119 -164 0
+3 -87 193 0
+124 -139 158 0
+76 163 -195 0
+-101 122 136 0
+18 76 -138 0
+13 -45 194 0
+-37 66 89 0
+-20 -50 -96 0
+-9 64 -153 0
+21 -50 114 0
+32 -129 159 0
+-17 -169 -180 0
+80 -129 -194 0
+14 -119 -159 0
+-6 -57 133 0
+2 -86 -121 0
+-49 -189 195 0
+12 98 159 0
+24 31 -182 0
+6 -7 76 0
+13 -40 120 0
+73 -121 192 0
+-104 131 -161 0
+-4 -190 197 0
+19 -90 125 0
+-26 56 -179 0
+-15 186 -197 0
+-1 -21 108 0
+29 117 154 0
+130 152 181 0
+5 -95 -147 0
+74 112 178 0
+11 -67 -78 0
+29 128 -191 0
+-14 56 137 0
+4 -7 14 0
+39 84 150 0
+-40 -88 -122 0
+-37 -108 -195 0
+-19 -62 -137 0
+10 -85 188 0
+31 -52 66 0
+78 -98 183 0
+10 71 -111 0
+-4 -124 164 0
+52 -129 161 0
+-61 97 195 0
+21 -39 -46 0
+31 -83 95 0
+-25 103 197 0
+-65 -112 177 0
+-10 -109 162 0
+-47 110 -110 0
+-45 -117 175 0
+-22 -79 106 0
+4 -27 191 0
+13 -46 150 0
+74 -85 89 0
+87 157 178 0
+-29 -157 180 0
+2 150 -163 0
+-49 87 187 0
+73 -116 181 0
+-66 79 -101 0
+-96 -111 200 0
+82 -128 -177 0
+-58 -119 -155 0
+-26 -72 176 0
+-131 -172 200 0
+29 137 -179 0
+-6 9 -34 0
+13 25 -59 0
+-11 -163 188 0
+30 155 -195 0
+-25 -57 -74 0
+-93 -112 -152 0
+94 103 168 0
+-54 70 -106 0
+47 -61 -172 0
+-27 -29 173 0
+121 168 -176 0
+-125 -173 -175 0
+130 -176 -200 0
+-36 149 -179 0
+45 105 -130 0
+-15 145 -156 0
+-26 -40 77 0
+-22 -42 -176 0
+-76 121 -166 0
+-124 160 -192 0
+-27 -46 57 0
+17 -39 -123 0
+-8 50 -112 0
+28 143 165 0
+-123 -151 -160 0
+104 183 -185 0
+-35 -118 125 0
+-92 -123 198 0
+-89 96 -109 0
+-39 81 -137 0
+84 91 106 0
+55 -105 183 0
+-86 -152 -159 0
+-137 149 -189 0
+-39 -104 -152 0
+19 36 -108 0
+75 -159 -186 0
+-16 51 134 0
+40 -107 -142 0
+-24 172 196 0
+93 176 -191 0
+-6 -16 188 0
+-85 148 174 0
+81 146 180 0
+158 181 -191 0
+-83 -113 164 0
+-14 62 166 0
+18 108 -114 0
+5 -46 108 0
+2 -40 98 0
+50 190 -193 0
+78 -82 -186 0
+50 -133 193 0
+23 -74 -150 0
+6 170 196 0
+42 106 147 0
+-57 -148 0
+100 -131 -193 0
+51 -128 -179 0
+100 -115 -198 0
+12 -114 156 0
+14 87 -181 0
+85 175 200 0
+15 76 102 0
+138 152 179 0
+50 160 181 0
+-1 28 -104 0
+-31 -46 -70 0
+50 70 83 0
+59 106 -139 0
+82 125 169 0
+20 37 -37 0
+73 -119 -175 0
+-78 183 184 0
+-46 73 -140 0
+-2 9 14 0
+-108 125 -146 0
+-55 -56 -105 0
+48 189 -191 0
+23 -76 126 0
+85 -94 -156 0
+41 108 178 0
+-26 79 -139 0
+-79 84 -149 0
+-151 184 -189 0
+138 156 -158 0
+-49 78 -127 0
+-30 -86 200 0
+-8 -56 68 0
+-14 116 173 0
+-159 179 -185 0
+-38 94 -121 0
+-177 -188 -191 0
+32 52 -146 0
+-2 95 104 0
+-121 160 170 0
+16 -113 -143 0
+-11 186 192 0
+-108 169 -189 0
+-130 165 187 0
+-1 2 22 0
+-4 27 56 0
+24 -134 -172 0
+-66 -155 -159 0
+116 -130 143 0
+25 -146 -169 0
+108 -111 165 0
+-11 -73 -161 0
+84 -88 90 0
+11 -83 160 0
+-15 102 -192 0
+-1 62 121 0
+-12 -165 188 0
+-15 28 -60 0
+11 -118 164 0
+-100 153 -177 0
+-90 112 183 0
+44 117 174 0
+41 45 87 0
+7 -139 -168 0
+-2 94 -183 0
+17 -83 -119 0
+-12 -108 -130 0
+-79 173 -181 0
+-28 -55 -112 0
+-10 -105 -178 0
+62 -120 -130 0
+-22 -95 -118 0
+56 -62 174 0
+36 119 -140 0
+-19 -92 -143 0
+-21 99 191 0
+30 -85 182 0
+12 15 73 0
+9 60 82 0
+25 -84 -195 0
+-22 111 -129 0
+111 122 150 0
+88 -92 -94 0
+-4 96 200 0
+-13 -77 109 0
+67 122 195 0
+-7 -52 126 0
+65 67 -157 0
+-23 69 139 0
+-9 -110 174 0
+130 135 -156 0
+-75 -187 197 0
+12 -21 56 0
+122 -166 185 0
+37 166 186 0
+151 -173 -194 0
+86 130 -180 0
+3 -72 85 0
+27 62 95 0
+-35 39 -91 0
+70 78 181 0
+3 -33 -37 0
+-79 182 192 0
+-90 148 -154 0
+-71 -124 -199 0
+-63 117 -133 0
+-7 -105 186 0
+37 -124 176 0
+63 128 -192 0
+-92 155 -157 0
+-14 138 -188 0
+-73 113 130 0
+32 38 -200 0
+86 122 -154 0
+93 -124 -129 0
+-71 -171 -182 0
+-10 37 -41 0
+29 57 112 0
+11 59 132 0
+-68 134 179 0
+29 -86 -148 0
+2 -61 -98 0
+-53 -86 95 0
+-126 132 164 0
+-58 111 -133 0
+16 23 -48 0
+41 71 -134 0
+-75 -94 148 0
+-96 101 141 0
+32 84 158 0
+52 -56 128 0
+20 -125 -169 0
+-1 -68 198 0
+-41 132 -147 0
+103 -103 153 0
+-36 159 180 0
+38 -98 144 0
+60 -114 124 0
+-10 172 -178 0
+61 86 169 0
+-110 -124 170 0
+-6 -81 113 0
+-44 73 -135 0
+35 -51 -136 0
+-62 67 -180 0
+-2 -165 190 0
+-30 -115 -168 0
+-41 -62 -147 0
+84 139 150 0
+25 -106 -126 0
+22 -64 92 0
+-59 95 163 0
+-20 -96 -132 0
+-91 122 166 0
+21 61 73 0
+-49 -155 -164 0
+-23 -66 -96 0
+24 -158 -191 0
+-97 -193 194 0
+-110 -154 168 0
+-20 -119 -155 0
+-92 -169 -191 0
+-15 -69 -136 0
+23 38 143 0
+47 -49 -79 0
+-2 -40 62 0
+-13 110 198 0
+145 152 -177 0
+-78 177 -181 0
+80 -85 -196 0
+-71 88 -139 0
+-81 -100 136 0
+-64 150 163 0
+7 89 137 0
+-126 -171 -176 0
+2 26 -101 0
+-8 -47 185 0
+15 -44 187 0
+-4 15 45 0
+52 -123 -134 0
+32 -66 170 0
+3 5 -77 0
+-34 -39 -118 0
+-25 -102 187 0
+-77 -109 -194 0
+-6 64 -112 0
+-25 -135 -150 0
+34 -69 -123 0
+150 155 -175 0
+24 86 -143 0
+-153 179 187 0
+34 -103 199 0
+77 -129 182 0
+9 -98 -123 0
+-15 113 178 0
+28 -108 144 0
+-24 30 168 0
+-67 -128 -194 0
+-3 81 -118 0
+-91 140 -181 0
+-45 46 -141 0
+-27 143 -158 0
+11 -121 -138 0
+-55 -142 170 0
+41 -45 -124 0
+16 -32 -63 0
+-35 45 -82 0
+-154 -182 -192 0
+-5 101 130 0
+26 78 -185 0
+57 -143 195 0
+95 -128 -173 0
+39 -62 114 0
+-44 -130 -200 0
+-6 43 153 0
+-26 41 -133 0
+-49 -147 -194 0
+35 118 -195 0
+-76 -105 -137 0
+7 -90 -108 0
+6 -14 -199 0
+-3 74 108 0
+-99 -141 -164 0
+57 66 194 0
+72 -117 139 0
+76 116 122 0
+-59 -171 199 0
+7 -77 -116 0
+-46 64 -157 0
+7 72 -178 0
+8 42 -126 0
+-60 -110 -133 0
+74 136 -149 0
+-23 117 -155 0
+32 132 197 0
+-47 60 184 0
+-114 115 132 0
+118 128 -190 0
+-13 -100 -165 0
+-12 80 176 0
+-18 -33 -140 0
+-34 102 157 0
+-48 -70 -97 0
+-24 -55 121 0
+12 18 -143 0
+144 163 173 0
+-21 -115 -120 0
+36 63 -103 0
+-79 -96 113 0
+-114 137 -171 0
+62 156 -173 0
+12 -39 117 0
+-14 45 -199 0
+-111 -118 -184 0
+136 156 159 0
+-68 -155 184 0
+2 21 -136 0
+-77 -136 190 0
+48 94 -137 0
+-48 -165 181 0
+88 -130 144 0
+151 -171 -178 0
+115 -167 194 0
+-25 90 134 0
+-2 -12 -107 0
+80 114 -131 0
+59 -118 195 0
+-47 -117 -149 0
+25 -44 189 0
+121 167 193 0
+-63 -141 145 0
+-20 36 -149 0
+-21 -93 186 0
+-74 128 -167 0
+-27 -167 184 0
+-35 79 170 0
+-61 192 200 0
+-17 -90 114 0
+43 81 -168 0
+2 152 174 0
+-51 -80 -173 0
+45 80 179 0
+109 -110 189 0
+25 100 -170 0
+-94 110 -159 0
+-20 -89 98 0
+79 -131 -144 0
+-49 -158 -167 0
+-79 129 134 0
+-115 133 -138 0
+-50 61 -188 0
+-131 -171 -196 0
+-14 43 148 0
+90 -151 -199 0
+-69 -81 -148 0
+-44 -57 -166 0
+9 -84 -152 0
+21 66 -176 0
+-8 69 -153 0
+-51 62 173 0
+-44 52 125 0
+48 -69 -86 0
+54 111 -125 0
+3 -57 180 0
+-58 -69 -139 0
+69 -140 197 0
+-70 93 -156 0
+-52 130 193 0
+-85 129 146 0
+-21 -52 -55 0
+-54 -65 139 0
+-36 -99 155 0
+-27 50 131 0
+66 -81 -170 0
+14 21 -184 0
+-7 44 195 0
+-148 167 -178 0
+101 -137 -194 0
+-7 -44 56 0
+-76 -88 -151 0
+28 59 -76 0
+86 -90 -137 0
+-25 52 -173 0
+-130 -141 144 0
+67 -80 170 0
+-110 -147 -170 0
+20 -138 -192 0
+15 64 -165 0
+3 161 -163 0
+-56 -154 -188 0
+-16 -88 -113 0
+7 -36 -108 0
+-193 199 -199 0
+-3 94 -155 0
+59 99 -132 0
+25 -77 -196 0
+85 140 -156 0
+-98 123 -167 0
+-111 119 147 0
+12 -18 -194 0
+-86 188 -199 0
+12 43 -117 0
+-9 63 178 0
+-24 46 -177 0
+-55 109 -173 0
+-89 -113 -176 0
+-73 106 -144 0
+-38 86 -128 0
+19 -126 -168 0
+-82 -105 146 0
+143 -147 156 0
+8 37 -63 0
+61 62 -144 0
+-17 -109 -200 0
+4 -115 -190 0
+99 125 -125 0
+-114 124 -185 0
+-60 -115 156 0
+-91 -98 -141 0
+-98 127 -140 0
+-34 41 -140 0
+-141 -145 -151 0
+-16 -80 190 0
+76 80 132 0
+-47 76 -87 0
+49 -159 -176 0
+-7 -139 -172 0
+44 -80 185 0
+-38 -188 193 0
+-38 78 -145 0
+40 136 194 0
+-30 77 -131 0
+-39 43 -172 0
+-32 -76 136 0
+13 -132 -157 0
+60 -146 199 0
+1 70 181 0
+-10 -152 -174 0
+8 69 97 0
+-30 59 152 0
+-51 -84 174 0
+131 -163 165 0
+16 -71 -158 0
+16 108 -112 0
+54 -94 176 0
+101 -134 -164 0
+4 -29 108 0
+24 -36 190 0
+-50 65 -149 0
+-29 63 110 0
+61 -131 187 0
+42 49 132 0
+5 -33 173 0
+-91 111 -193 0
+10 -39 -90 0
+21 38 165 0
+-56 -116 -163 0
+-48 -110 160 0
+-76 100 105 0
+-99 -152 -163 0
+-35 -97 199 0
+18 -93 -168 0
+-40 -155 173 0
+172 -188 199 0
+140 147 -154 0
+114 115 198 0
+80 151 169 0
+39 -107 124 0
+77 -90 137 0
+-17 60 -116 0
+-53 105 -190 0
+-24 69 153 0
+-56 -111 -188 0
+-29 -47 200 0
+52 75 165 0
+49 135 159 0
+33 41 53 0
+-10 18 -100 0
+-7 -28 -74 0
+46 -52 -97 0
+4 -59 -197 0
+82 -111 -186 0
+-29 141 -194 0
+-5 -47 161 0
+126 -164 176 0
+90 102 -184 0
+-17 -20 70 0
+39 114 118 0
+119 148 -165 0
+-132 -139 158 0
+104 136 -166 0
+-8 81 159 0
+-70 72 161 0
+-51 71 -100 0
+144 -170 191 0
+9 -63 -109 0
+101 -192 199 0
+41 65 170 0
+-53 179 180 0
+-87 -105 174 0
+-60 -64 193 0
+-132 -185 -195 0
+-59 -117 144 0
+32 75 -200 0
+29 160 -172 0
+-100 124 -142 0
+-103 -107 172 0
+26 80 -158 0
+10 -152 167 0
+39 -142 188 0
+-53 -128 -132 0
+58 98 -184 0
+39 -41 -138 0
+10 -134 -192 0
+91 135 -191 0
+-21 92 -126 0
+-34 -141 -145 0
+-60 63 93 0
+39 -92 158 0
+4 13 -28 0
+59 104 135 0
+-117 -162 182 0
+-92 -138 152 0
+-117 -148 189 0
+-94 147 180 0
+-105 -125 132 0
+59 93 128 0
+-28 -38 -124 0
+-102 -133 142 0
+82 98 182 0
+-15 -20 -72 0
+-10 -54 90 0
+-51 55 -101 0
+149 -161 167 0
+50 -72 173 0
+30 -129 191 0
+-21 87 -87 0
+-26 -28 43 0
+10 79 175 0
+35 -82 -144 0
+127 -144 -181 0
+3 119 182 0
+1 -77 118 0
+75 89 186 0
+-8 109 -152 0
+-72 102 -149 0
+40 -64 -198 0
+-58 -136 161 0
+63 -107 178 0
+63 -89 93 0
+16 43 -187 0
+65 -126 -149 0
+98 140 -199 0
+-72 -94 155 0
+70 -148 185 0
+19 -80 -185 0
+42 109 148 0
+16 105 -190 0
+-31 118 124 0
+-48 -51 140 0
+110 127 199 0
+-1 -41 171 0
+-49 -99 159 0
+-52 -55 -163 0
+-72 98 111 0
+29 -78 -200 0
+131 -132 -164 0
+26 -30 -54 0
+-27 104 -131 0
+1 -31 -187 0
+-161 -182 -185 0
+-1 -59 145 0
+30 -68 -74 0
+-28 153 -192 0
+46 -75 185 0
+56 61 140 0
+106 -138 -183 0
+7 -76 -153 0
+-75 101 -160 0
+9 61 104 0
+-41 71 -178 0
+-82 -115 167 0
+34 -55 114 0
+-39 104 155 0
+40 -126 185 0
+10 49 89 0
+9 -150 -161 0
+22 -32 66 0
+150 -161 171 0
+-27 -87 118 0
+-89 -113 159 0
+40 -116 129 0
+10 121 169 0
+99 -170 171 0
+-59 89 141 0
+-2 -13 -174 0
+109 123 -181 0
+6 -43 -58 0
+135 177 -198 0
+-52 -89 -101 0
+-104 107 -200 0
+18 -162 171 0
+-54 129 135 0
+-68 147 -157 0
+105 -107 196 0
+-3 54 128 0
+-25 149 -161 0
+-3 101 107 0
+82 -128 -183 0
+19 54 148 0
+-43 65 -115 0
+-79 98 141 0
+-122 -140 -195 0
+-3 -34 99 0
+58 122 171 0
+-43 57 -170 0
+58 160 177 0
+-65 90 -182 0
+49 -161 -197 0
+26 32 171 0
+6 34 110 0
+-5 -13 -109 0
+83 176 182 0
+-28 34 -75 0
+-84 100 -160 0
+65 71 -80 0
+53 -107 -116 0
+-53 58 -157 0
+-9 99 123 0
+-9 77 -104 0
+-17 -32 197 0
+-43 -71 -140 0
+143 149 158 0
+-32 81 168 0
+-51 -67 -162 0
+-59 -71 175 0
+19 -53 186 0
+69 -71 105 0
+-18 147 189 0
+-32 72 197 0
+-18 -128 -184 0
+99 -125 176 0
+65 -75 -150 0
+6 72 197 0
+115 123 169 0
+49 -68 152 0
+26 -62 103 0
+20 127 178 0
+167 -187 -200 0
+-122 -127 128 0
+-104 145 180 0
+92 110 -187 0
+72 119 158 0
+-10 -60 -67 0
+-5 -8 -151 0
+34 46 147 0
+-106 107 147 0
+-58 119 129 0
+-13 -123 -184 0
+81 123 182 0
+-50 -147 -187 0
+-15 -106 -125 0
+-52 -183 -184 0
+-24 74 142 0
+28 -70 105 0
+-9 114 -181 0
+-32 -92 115 0
+129 -158 0
+38 118 -197 0
+49 83 -102 0
+-4 26 145 0
+1 40 135 0
+-101 115 152 0
+160 -160 0
+-50 70 -80 0
+-9 93 -162 0
+-13 30 67 0
+-4 53 118 0
+102 141 147 0
+38 81 -184 0
+-70 -75 -187 0
+46 105 -127 0
+-65 141 0
+-40 53 152 0
+-16 -117 -160 0
+58 71 77 0
+74 -160 -187 0
+-13 34 -127 0
+44 46 -53 0
+-67 -127 145 0
+-5 -113 115 0
+-13 23 -67 0
+-63 82 171 0
+46 174 177 0
+1 -74 172 0
+40 46 -127 0
+129 -162 171 0
+5 65 131 0
+53 82 115 0
+-5 -82 177 0
+-109 131 142 0
+-48 177 -183 0
+-97 131 177 0
+-5 -63 -70 0
+-16 131 142 0
+-38 -70 131 0
+36 142 0
+-70 -80 -156 0
+28 129 -160 0
+-67 103 0
+-122 -162 0
+42 -122 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkHardSat/ais8.cnf b/test/resources/BenchmarkHardSat/ais8.cnf
new file mode 100644
index 0000000..3475fc5
--- /dev/null
+++ b/test/resources/BenchmarkHardSat/ais8.cnf
@@ -0,0 +1,1523 @@
+c created by Generic SAT Encoder v1.0
+p cnf 113 1520
+1 2 3 4 5 6 7 8 0
+-1 -2 0
+-1 -3 0
+-1 -4 0
+-1 -5 0
+-1 -6 0
+-1 -7 0
+-1 -8 0
+-2 -3 0
+-2 -4 0
+-2 -5 0
+-2 -6 0
+-2 -7 0
+-2 -8 0
+-3 -4 0
+-3 -5 0
+-3 -6 0
+-3 -7 0
+-3 -8 0
+-4 -5 0
+-4 -6 0
+-4 -7 0
+-4 -8 0
+-5 -6 0
+-5 -7 0
+-5 -8 0
+-6 -7 0
+-6 -8 0
+-7 -8 0
+9 10 11 12 13 14 15 16 0
+-9 -10 0
+-9 -11 0
+-9 -12 0
+-9 -13 0
+-9 -14 0
+-9 -15 0
+-9 -16 0
+-10 -11 0
+-10 -12 0
+-10 -13 0
+-10 -14 0
+-10 -15 0
+-10 -16 0
+-11 -12 0
+-11 -13 0
+-11 -14 0
+-11 -15 0
+-11 -16 0
+-12 -13 0
+-12 -14 0
+-12 -15 0
+-12 -16 0
+-13 -14 0
+-13 -15 0
+-13 -16 0
+-14 -15 0
+-14 -16 0
+-15 -16 0
+17 18 19 20 21 22 23 24 0
+-17 -18 0
+-17 -19 0
+-17 -20 0
+-17 -21 0
+-17 -22 0
+-17 -23 0
+-17 -24 0
+-18 -19 0
+-18 -20 0
+-18 -21 0
+-18 -22 0
+-18 -23 0
+-18 -24 0
+-19 -20 0
+-19 -21 0
+-19 -22 0
+-19 -23 0
+-19 -24 0
+-20 -21 0
+-20 -22 0
+-20 -23 0
+-20 -24 0
+-21 -22 0
+-21 -23 0
+-21 -24 0
+-22 -23 0
+-22 -24 0
+-23 -24 0
+25 26 27 28 29 30 31 32 0
+-25 -26 0
+-25 -27 0
+-25 -28 0
+-25 -29 0
+-25 -30 0
+-25 -31 0
+-25 -32 0
+-26 -27 0
+-26 -28 0
+-26 -29 0
+-26 -30 0
+-26 -31 0
+-26 -32 0
+-27 -28 0
+-27 -29 0
+-27 -30 0
+-27 -31 0
+-27 -32 0
+-28 -29 0
+-28 -30 0
+-28 -31 0
+-28 -32 0
+-29 -30 0
+-29 -31 0
+-29 -32 0
+-30 -31 0
+-30 -32 0
+-31 -32 0
+33 34 35 36 37 38 39 40 0
+-33 -34 0
+-33 -35 0
+-33 -36 0
+-33 -37 0
+-33 -38 0
+-33 -39 0
+-33 -40 0
+-34 -35 0
+-34 -36 0
+-34 -37 0
+-34 -38 0
+-34 -39 0
+-34 -40 0
+-35 -36 0
+-35 -37 0
+-35 -38 0
+-35 -39 0
+-35 -40 0
+-36 -37 0
+-36 -38 0
+-36 -39 0
+-36 -40 0
+-37 -38 0
+-37 -39 0
+-37 -40 0
+-38 -39 0
+-38 -40 0
+-39 -40 0
+41 42 43 44 45 46 47 48 0
+-41 -42 0
+-41 -43 0
+-41 -44 0
+-41 -45 0
+-41 -46 0
+-41 -47 0
+-41 -48 0
+-42 -43 0
+-42 -44 0
+-42 -45 0
+-42 -46 0
+-42 -47 0
+-42 -48 0
+-43 -44 0
+-43 -45 0
+-43 -46 0
+-43 -47 0
+-43 -48 0
+-44 -45 0
+-44 -46 0
+-44 -47 0
+-44 -48 0
+-45 -46 0
+-45 -47 0
+-45 -48 0
+-46 -47 0
+-46 -48 0
+-47 -48 0
+49 50 51 52 53 54 55 56 0
+-49 -50 0
+-49 -51 0
+-49 -52 0
+-49 -53 0
+-49 -54 0
+-49 -55 0
+-49 -56 0
+-50 -51 0
+-50 -52 0
+-50 -53 0
+-50 -54 0
+-50 -55 0
+-50 -56 0
+-51 -52 0
+-51 -53 0
+-51 -54 0
+-51 -55 0
+-51 -56 0
+-52 -53 0
+-52 -54 0
+-52 -55 0
+-52 -56 0
+-53 -54 0
+-53 -55 0
+-53 -56 0
+-54 -55 0
+-54 -56 0
+-55 -56 0
+57 58 59 60 61 62 63 64 0
+-57 -58 0
+-57 -59 0
+-57 -60 0
+-57 -61 0
+-57 -62 0
+-57 -63 0
+-57 -64 0
+-58 -59 0
+-58 -60 0
+-58 -61 0
+-58 -62 0
+-58 -63 0
+-58 -64 0
+-59 -60 0
+-59 -61 0
+-59 -62 0
+-59 -63 0
+-59 -64 0
+-60 -61 0
+-60 -62 0
+-60 -63 0
+-60 -64 0
+-61 -62 0
+-61 -63 0
+-61 -64 0
+-62 -63 0
+-62 -64 0
+-63 -64 0
+65 66 67 68 69 70 71 0
+-65 -66 0
+-65 -67 0
+-65 -68 0
+-65 -69 0
+-65 -70 0
+-65 -71 0
+-66 -67 0
+-66 -68 0
+-66 -69 0
+-66 -70 0
+-66 -71 0
+-67 -68 0
+-67 -69 0
+-67 -70 0
+-67 -71 0
+-68 -69 0
+-68 -70 0
+-68 -71 0
+-69 -70 0
+-69 -71 0
+-70 -71 0
+72 73 74 75 76 77 78 0
+-72 -73 0
+-72 -74 0
+-72 -75 0
+-72 -76 0
+-72 -77 0
+-72 -78 0
+-73 -74 0
+-73 -75 0
+-73 -76 0
+-73 -77 0
+-73 -78 0
+-74 -75 0
+-74 -76 0
+-74 -77 0
+-74 -78 0
+-75 -76 0
+-75 -77 0
+-75 -78 0
+-76 -77 0
+-76 -78 0
+-77 -78 0
+79 80 81 82 83 84 85 0
+-79 -80 0
+-79 -81 0
+-79 -82 0
+-79 -83 0
+-79 -84 0
+-79 -85 0
+-80 -81 0
+-80 -82 0
+-80 -83 0
+-80 -84 0
+-80 -85 0
+-81 -82 0
+-81 -83 0
+-81 -84 0
+-81 -85 0
+-82 -83 0
+-82 -84 0
+-82 -85 0
+-83 -84 0
+-83 -85 0
+-84 -85 0
+86 87 88 89 90 91 92 0
+-86 -87 0
+-86 -88 0
+-86 -89 0
+-86 -90 0
+-86 -91 0
+-86 -92 0
+-87 -88 0
+-87 -89 0
+-87 -90 0
+-87 -91 0
+-87 -92 0
+-88 -89 0
+-88 -90 0
+-88 -91 0
+-88 -92 0
+-89 -90 0
+-89 -91 0
+-89 -92 0
+-90 -91 0
+-90 -92 0
+-91 -92 0
+93 94 95 96 97 98 99 0
+-93 -94 0
+-93 -95 0
+-93 -96 0
+-93 -97 0
+-93 -98 0
+-93 -99 0
+-94 -95 0
+-94 -96 0
+-94 -97 0
+-94 -98 0
+-94 -99 0
+-95 -96 0
+-95 -97 0
+-95 -98 0
+-95 -99 0
+-96 -97 0
+-96 -98 0
+-96 -99 0
+-97 -98 0
+-97 -99 0
+-98 -99 0
+100 101 102 103 104 105 106 0
+-100 -101 0
+-100 -102 0
+-100 -103 0
+-100 -104 0
+-100 -105 0
+-100 -106 0
+-101 -102 0
+-101 -103 0
+-101 -104 0
+-101 -105 0
+-101 -106 0
+-102 -103 0
+-102 -104 0
+-102 -105 0
+-102 -106 0
+-103 -104 0
+-103 -105 0
+-103 -106 0
+-104 -105 0
+-104 -106 0
+-105 -106 0
+107 108 109 110 111 112 113 0
+-107 -108 0
+-107 -109 0
+-107 -110 0
+-107 -111 0
+-107 -112 0
+-107 -113 0
+-108 -109 0
+-108 -110 0
+-108 -111 0
+-108 -112 0
+-108 -113 0
+-109 -110 0
+-109 -111 0
+-109 -112 0
+-109 -113 0
+-110 -111 0
+-110 -112 0
+-110 -113 0
+-111 -112 0
+-111 -113 0
+-112 -113 0
+-1 -9 0
+-2 -10 0
+-3 -11 0
+-4 -12 0
+-5 -13 0
+-6 -14 0
+-7 -15 0
+-8 -16 0
+-1 -17 0
+-2 -18 0
+-3 -19 0
+-4 -20 0
+-5 -21 0
+-6 -22 0
+-7 -23 0
+-8 -24 0
+-1 -25 0
+-2 -26 0
+-3 -27 0
+-4 -28 0
+-5 -29 0
+-6 -30 0
+-7 -31 0
+-8 -32 0
+-1 -33 0
+-2 -34 0
+-3 -35 0
+-4 -36 0
+-5 -37 0
+-6 -38 0
+-7 -39 0
+-8 -40 0
+-1 -41 0
+-2 -42 0
+-3 -43 0
+-4 -44 0
+-5 -45 0
+-6 -46 0
+-7 -47 0
+-8 -48 0
+-1 -49 0
+-2 -50 0
+-3 -51 0
+-4 -52 0
+-5 -53 0
+-6 -54 0
+-7 -55 0
+-8 -56 0
+-1 -57 0
+-2 -58 0
+-3 -59 0
+-4 -60 0
+-5 -61 0
+-6 -62 0
+-7 -63 0
+-8 -64 0
+-9 -1 0
+-10 -2 0
+-11 -3 0
+-12 -4 0
+-13 -5 0
+-14 -6 0
+-15 -7 0
+-16 -8 0
+-9 -17 0
+-10 -18 0
+-11 -19 0
+-12 -20 0
+-13 -21 0
+-14 -22 0
+-15 -23 0
+-16 -24 0
+-9 -25 0
+-10 -26 0
+-11 -27 0
+-12 -28 0
+-13 -29 0
+-14 -30 0
+-15 -31 0
+-16 -32 0
+-9 -33 0
+-10 -34 0
+-11 -35 0
+-12 -36 0
+-13 -37 0
+-14 -38 0
+-15 -39 0
+-16 -40 0
+-9 -41 0
+-10 -42 0
+-11 -43 0
+-12 -44 0
+-13 -45 0
+-14 -46 0
+-15 -47 0
+-16 -48 0
+-9 -49 0
+-10 -50 0
+-11 -51 0
+-12 -52 0
+-13 -53 0
+-14 -54 0
+-15 -55 0
+-16 -56 0
+-9 -57 0
+-10 -58 0
+-11 -59 0
+-12 -60 0
+-13 -61 0
+-14 -62 0
+-15 -63 0
+-16 -64 0
+-17 -1 0
+-18 -2 0
+-19 -3 0
+-20 -4 0
+-21 -5 0
+-22 -6 0
+-23 -7 0
+-24 -8 0
+-17 -9 0
+-18 -10 0
+-19 -11 0
+-20 -12 0
+-21 -13 0
+-22 -14 0
+-23 -15 0
+-24 -16 0
+-17 -25 0
+-18 -26 0
+-19 -27 0
+-20 -28 0
+-21 -29 0
+-22 -30 0
+-23 -31 0
+-24 -32 0
+-17 -33 0
+-18 -34 0
+-19 -35 0
+-20 -36 0
+-21 -37 0
+-22 -38 0
+-23 -39 0
+-24 -40 0
+-17 -41 0
+-18 -42 0
+-19 -43 0
+-20 -44 0
+-21 -45 0
+-22 -46 0
+-23 -47 0
+-24 -48 0
+-17 -49 0
+-18 -50 0
+-19 -51 0
+-20 -52 0
+-21 -53 0
+-22 -54 0
+-23 -55 0
+-24 -56 0
+-17 -57 0
+-18 -58 0
+-19 -59 0
+-20 -60 0
+-21 -61 0
+-22 -62 0
+-23 -63 0
+-24 -64 0
+-25 -1 0
+-26 -2 0
+-27 -3 0
+-28 -4 0
+-29 -5 0
+-30 -6 0
+-31 -7 0
+-32 -8 0
+-25 -9 0
+-26 -10 0
+-27 -11 0
+-28 -12 0
+-29 -13 0
+-30 -14 0
+-31 -15 0
+-32 -16 0
+-25 -17 0
+-26 -18 0
+-27 -19 0
+-28 -20 0
+-29 -21 0
+-30 -22 0
+-31 -23 0
+-32 -24 0
+-25 -33 0
+-26 -34 0
+-27 -35 0
+-28 -36 0
+-29 -37 0
+-30 -38 0
+-31 -39 0
+-32 -40 0
+-25 -41 0
+-26 -42 0
+-27 -43 0
+-28 -44 0
+-29 -45 0
+-30 -46 0
+-31 -47 0
+-32 -48 0
+-25 -49 0
+-26 -50 0
+-27 -51 0
+-28 -52 0
+-29 -53 0
+-30 -54 0
+-31 -55 0
+-32 -56 0
+-25 -57 0
+-26 -58 0
+-27 -59 0
+-28 -60 0
+-29 -61 0
+-30 -62 0
+-31 -63 0
+-32 -64 0
+-33 -1 0
+-34 -2 0
+-35 -3 0
+-36 -4 0
+-37 -5 0
+-38 -6 0
+-39 -7 0
+-40 -8 0
+-33 -9 0
+-34 -10 0
+-35 -11 0
+-36 -12 0
+-37 -13 0
+-38 -14 0
+-39 -15 0
+-40 -16 0
+-33 -17 0
+-34 -18 0
+-35 -19 0
+-36 -20 0
+-37 -21 0
+-38 -22 0
+-39 -23 0
+-40 -24 0
+-33 -25 0
+-34 -26 0
+-35 -27 0
+-36 -28 0
+-37 -29 0
+-38 -30 0
+-39 -31 0
+-40 -32 0
+-33 -41 0
+-34 -42 0
+-35 -43 0
+-36 -44 0
+-37 -45 0
+-38 -46 0
+-39 -47 0
+-40 -48 0
+-33 -49 0
+-34 -50 0
+-35 -51 0
+-36 -52 0
+-37 -53 0
+-38 -54 0
+-39 -55 0
+-40 -56 0
+-33 -57 0
+-34 -58 0
+-35 -59 0
+-36 -60 0
+-37 -61 0
+-38 -62 0
+-39 -63 0
+-40 -64 0
+-41 -1 0
+-42 -2 0
+-43 -3 0
+-44 -4 0
+-45 -5 0
+-46 -6 0
+-47 -7 0
+-48 -8 0
+-41 -9 0
+-42 -10 0
+-43 -11 0
+-44 -12 0
+-45 -13 0
+-46 -14 0
+-47 -15 0
+-48 -16 0
+-41 -17 0
+-42 -18 0
+-43 -19 0
+-44 -20 0
+-45 -21 0
+-46 -22 0
+-47 -23 0
+-48 -24 0
+-41 -25 0
+-42 -26 0
+-43 -27 0
+-44 -28 0
+-45 -29 0
+-46 -30 0
+-47 -31 0
+-48 -32 0
+-41 -33 0
+-42 -34 0
+-43 -35 0
+-44 -36 0
+-45 -37 0
+-46 -38 0
+-47 -39 0
+-48 -40 0
+-41 -49 0
+-42 -50 0
+-43 -51 0
+-44 -52 0
+-45 -53 0
+-46 -54 0
+-47 -55 0
+-48 -56 0
+-41 -57 0
+-42 -58 0
+-43 -59 0
+-44 -60 0
+-45 -61 0
+-46 -62 0
+-47 -63 0
+-48 -64 0
+-49 -1 0
+-50 -2 0
+-51 -3 0
+-52 -4 0
+-53 -5 0
+-54 -6 0
+-55 -7 0
+-56 -8 0
+-49 -9 0
+-50 -10 0
+-51 -11 0
+-52 -12 0
+-53 -13 0
+-54 -14 0
+-55 -15 0
+-56 -16 0
+-49 -17 0
+-50 -18 0
+-51 -19 0
+-52 -20 0
+-53 -21 0
+-54 -22 0
+-55 -23 0
+-56 -24 0
+-49 -25 0
+-50 -26 0
+-51 -27 0
+-52 -28 0
+-53 -29 0
+-54 -30 0
+-55 -31 0
+-56 -32 0
+-49 -33 0
+-50 -34 0
+-51 -35 0
+-52 -36 0
+-53 -37 0
+-54 -38 0
+-55 -39 0
+-56 -40 0
+-49 -41 0
+-50 -42 0
+-51 -43 0
+-52 -44 0
+-53 -45 0
+-54 -46 0
+-55 -47 0
+-56 -48 0
+-49 -57 0
+-50 -58 0
+-51 -59 0
+-52 -60 0
+-53 -61 0
+-54 -62 0
+-55 -63 0
+-56 -64 0
+-57 -1 0
+-58 -2 0
+-59 -3 0
+-60 -4 0
+-61 -5 0
+-62 -6 0
+-63 -7 0
+-64 -8 0
+-57 -9 0
+-58 -10 0
+-59 -11 0
+-60 -12 0
+-61 -13 0
+-62 -14 0
+-63 -15 0
+-64 -16 0
+-57 -17 0
+-58 -18 0
+-59 -19 0
+-60 -20 0
+-61 -21 0
+-62 -22 0
+-63 -23 0
+-64 -24 0
+-57 -25 0
+-58 -26 0
+-59 -27 0
+-60 -28 0
+-61 -29 0
+-62 -30 0
+-63 -31 0
+-64 -32 0
+-57 -33 0
+-58 -34 0
+-59 -35 0
+-60 -36 0
+-61 -37 0
+-62 -38 0
+-63 -39 0
+-64 -40 0
+-57 -41 0
+-58 -42 0
+-59 -43 0
+-60 -44 0
+-61 -45 0
+-62 -46 0
+-63 -47 0
+-64 -48 0
+-57 -49 0
+-58 -50 0
+-59 -51 0
+-60 -52 0
+-61 -53 0
+-62 -54 0
+-63 -55 0
+-64 -56 0
+-65 -72 0
+-66 -73 0
+-67 -74 0
+-68 -75 0
+-69 -76 0
+-70 -77 0
+-71 -78 0
+-65 -79 0
+-66 -80 0
+-67 -81 0
+-68 -82 0
+-69 -83 0
+-70 -84 0
+-71 -85 0
+-65 -86 0
+-66 -87 0
+-67 -88 0
+-68 -89 0
+-69 -90 0
+-70 -91 0
+-71 -92 0
+-65 -93 0
+-66 -94 0
+-67 -95 0
+-68 -96 0
+-69 -97 0
+-70 -98 0
+-71 -99 0
+-65 -100 0
+-66 -101 0
+-67 -102 0
+-68 -103 0
+-69 -104 0
+-70 -105 0
+-71 -106 0
+-65 -107 0
+-66 -108 0
+-67 -109 0
+-68 -110 0
+-69 -111 0
+-70 -112 0
+-71 -113 0
+-72 -65 0
+-73 -66 0
+-74 -67 0
+-75 -68 0
+-76 -69 0
+-77 -70 0
+-78 -71 0
+-72 -79 0
+-73 -80 0
+-74 -81 0
+-75 -82 0
+-76 -83 0
+-77 -84 0
+-78 -85 0
+-72 -86 0
+-73 -87 0
+-74 -88 0
+-75 -89 0
+-76 -90 0
+-77 -91 0
+-78 -92 0
+-72 -93 0
+-73 -94 0
+-74 -95 0
+-75 -96 0
+-76 -97 0
+-77 -98 0
+-78 -99 0
+-72 -100 0
+-73 -101 0
+-74 -102 0
+-75 -103 0
+-76 -104 0
+-77 -105 0
+-78 -106 0
+-72 -107 0
+-73 -108 0
+-74 -109 0
+-75 -110 0
+-76 -111 0
+-77 -112 0
+-78 -113 0
+-79 -65 0
+-80 -66 0
+-81 -67 0
+-82 -68 0
+-83 -69 0
+-84 -70 0
+-85 -71 0
+-79 -72 0
+-80 -73 0
+-81 -74 0
+-82 -75 0
+-83 -76 0
+-84 -77 0
+-85 -78 0
+-79 -86 0
+-80 -87 0
+-81 -88 0
+-82 -89 0
+-83 -90 0
+-84 -91 0
+-85 -92 0
+-79 -93 0
+-80 -94 0
+-81 -95 0
+-82 -96 0
+-83 -97 0
+-84 -98 0
+-85 -99 0
+-79 -100 0
+-80 -101 0
+-81 -102 0
+-82 -103 0
+-83 -104 0
+-84 -105 0
+-85 -106 0
+-79 -107 0
+-80 -108 0
+-81 -109 0
+-82 -110 0
+-83 -111 0
+-84 -112 0
+-85 -113 0
+-86 -65 0
+-87 -66 0
+-88 -67 0
+-89 -68 0
+-90 -69 0
+-91 -70 0
+-92 -71 0
+-86 -72 0
+-87 -73 0
+-88 -74 0
+-89 -75 0
+-90 -76 0
+-91 -77 0
+-92 -78 0
+-86 -79 0
+-87 -80 0
+-88 -81 0
+-89 -82 0
+-90 -83 0
+-91 -84 0
+-92 -85 0
+-86 -93 0
+-87 -94 0
+-88 -95 0
+-89 -96 0
+-90 -97 0
+-91 -98 0
+-92 -99 0
+-86 -100 0
+-87 -101 0
+-88 -102 0
+-89 -103 0
+-90 -104 0
+-91 -105 0
+-92 -106 0
+-86 -107 0
+-87 -108 0
+-88 -109 0
+-89 -110 0
+-90 -111 0
+-91 -112 0
+-92 -113 0
+-93 -65 0
+-94 -66 0
+-95 -67 0
+-96 -68 0
+-97 -69 0
+-98 -70 0
+-99 -71 0
+-93 -72 0
+-94 -73 0
+-95 -74 0
+-96 -75 0
+-97 -76 0
+-98 -77 0
+-99 -78 0
+-93 -79 0
+-94 -80 0
+-95 -81 0
+-96 -82 0
+-97 -83 0
+-98 -84 0
+-99 -85 0
+-93 -86 0
+-94 -87 0
+-95 -88 0
+-96 -89 0
+-97 -90 0
+-98 -91 0
+-99 -92 0
+-93 -100 0
+-94 -101 0
+-95 -102 0
+-96 -103 0
+-97 -104 0
+-98 -105 0
+-99 -106 0
+-93 -107 0
+-94 -108 0
+-95 -109 0
+-96 -110 0
+-97 -111 0
+-98 -112 0
+-99 -113 0
+-100 -65 0
+-101 -66 0
+-102 -67 0
+-103 -68 0
+-104 -69 0
+-105 -70 0
+-106 -71 0
+-100 -72 0
+-101 -73 0
+-102 -74 0
+-103 -75 0
+-104 -76 0
+-105 -77 0
+-106 -78 0
+-100 -79 0
+-101 -80 0
+-102 -81 0
+-103 -82 0
+-104 -83 0
+-105 -84 0
+-106 -85 0
+-100 -86 0
+-101 -87 0
+-102 -88 0
+-103 -89 0
+-104 -90 0
+-105 -91 0
+-106 -92 0
+-100 -93 0
+-101 -94 0
+-102 -95 0
+-103 -96 0
+-104 -97 0
+-105 -98 0
+-106 -99 0
+-100 -107 0
+-101 -108 0
+-102 -109 0
+-103 -110 0
+-104 -111 0
+-105 -112 0
+-106 -113 0
+-107 -65 0
+-108 -66 0
+-109 -67 0
+-110 -68 0
+-111 -69 0
+-112 -70 0
+-113 -71 0
+-107 -72 0
+-108 -73 0
+-109 -74 0
+-110 -75 0
+-111 -76 0
+-112 -77 0
+-113 -78 0
+-107 -79 0
+-108 -80 0
+-109 -81 0
+-110 -82 0
+-111 -83 0
+-112 -84 0
+-113 -85 0
+-107 -86 0
+-108 -87 0
+-109 -88 0
+-110 -89 0
+-111 -90 0
+-112 -91 0
+-113 -92 0
+-107 -93 0
+-108 -94 0
+-109 -95 0
+-110 -96 0
+-111 -97 0
+-112 -98 0
+-113 -99 0
+-107 -100 0
+-108 -101 0
+-109 -102 0
+-110 -103 0
+-111 -104 0
+-112 -105 0
+-113 -106 0
+-1 -10 65 0
+-1 -11 66 0
+-1 -12 67 0
+-1 -13 68 0
+-1 -14 69 0
+-1 -15 70 0
+-1 -16 71 0
+-2 -11 65 0
+-2 -9 65 0
+-2 -12 66 0
+-2 -13 67 0
+-2 -14 68 0
+-2 -15 69 0
+-2 -16 70 0
+-3 -12 65 0
+-3 -10 65 0
+-3 -13 66 0
+-3 -9 66 0
+-3 -14 67 0
+-3 -15 68 0
+-3 -16 69 0
+-4 -13 65 0
+-4 -11 65 0
+-4 -14 66 0
+-4 -10 66 0
+-4 -15 67 0
+-4 -9 67 0
+-4 -16 68 0
+-5 -14 65 0
+-5 -12 65 0
+-5 -15 66 0
+-5 -11 66 0
+-5 -16 67 0
+-5 -10 67 0
+-5 -9 68 0
+-6 -15 65 0
+-6 -13 65 0
+-6 -16 66 0
+-6 -12 66 0
+-6 -11 67 0
+-6 -10 68 0
+-6 -9 69 0
+-7 -16 65 0
+-7 -14 65 0
+-7 -13 66 0
+-7 -12 67 0
+-7 -11 68 0
+-7 -10 69 0
+-7 -9 70 0
+-8 -15 65 0
+-8 -14 66 0
+-8 -13 67 0
+-8 -12 68 0
+-8 -11 69 0
+-8 -10 70 0
+-8 -9 71 0
+-9 -18 72 0
+-9 -19 73 0
+-9 -20 74 0
+-9 -21 75 0
+-9 -22 76 0
+-9 -23 77 0
+-9 -24 78 0
+-10 -19 72 0
+-10 -17 72 0
+-10 -20 73 0
+-10 -21 74 0
+-10 -22 75 0
+-10 -23 76 0
+-10 -24 77 0
+-11 -20 72 0
+-11 -18 72 0
+-11 -21 73 0
+-11 -17 73 0
+-11 -22 74 0
+-11 -23 75 0
+-11 -24 76 0
+-12 -21 72 0
+-12 -19 72 0
+-12 -22 73 0
+-12 -18 73 0
+-12 -23 74 0
+-12 -17 74 0
+-12 -24 75 0
+-13 -22 72 0
+-13 -20 72 0
+-13 -23 73 0
+-13 -19 73 0
+-13 -24 74 0
+-13 -18 74 0
+-13 -17 75 0
+-14 -23 72 0
+-14 -21 72 0
+-14 -24 73 0
+-14 -20 73 0
+-14 -19 74 0
+-14 -18 75 0
+-14 -17 76 0
+-15 -24 72 0
+-15 -22 72 0
+-15 -21 73 0
+-15 -20 74 0
+-15 -19 75 0
+-15 -18 76 0
+-15 -17 77 0
+-16 -23 72 0
+-16 -22 73 0
+-16 -21 74 0
+-16 -20 75 0
+-16 -19 76 0
+-16 -18 77 0
+-16 -17 78 0
+-17 -26 79 0
+-17 -27 80 0
+-17 -28 81 0
+-17 -29 82 0
+-17 -30 83 0
+-17 -31 84 0
+-17 -32 85 0
+-18 -27 79 0
+-18 -25 79 0
+-18 -28 80 0
+-18 -29 81 0
+-18 -30 82 0
+-18 -31 83 0
+-18 -32 84 0
+-19 -28 79 0
+-19 -26 79 0
+-19 -29 80 0
+-19 -25 80 0
+-19 -30 81 0
+-19 -31 82 0
+-19 -32 83 0
+-20 -29 79 0
+-20 -27 79 0
+-20 -30 80 0
+-20 -26 80 0
+-20 -31 81 0
+-20 -25 81 0
+-20 -32 82 0
+-21 -30 79 0
+-21 -28 79 0
+-21 -31 80 0
+-21 -27 80 0
+-21 -32 81 0
+-21 -26 81 0
+-21 -25 82 0
+-22 -31 79 0
+-22 -29 79 0
+-22 -32 80 0
+-22 -28 80 0
+-22 -27 81 0
+-22 -26 82 0
+-22 -25 83 0
+-23 -32 79 0
+-23 -30 79 0
+-23 -29 80 0
+-23 -28 81 0
+-23 -27 82 0
+-23 -26 83 0
+-23 -25 84 0
+-24 -31 79 0
+-24 -30 80 0
+-24 -29 81 0
+-24 -28 82 0
+-24 -27 83 0
+-24 -26 84 0
+-24 -25 85 0
+-25 -34 86 0
+-25 -35 87 0
+-25 -36 88 0
+-25 -37 89 0
+-25 -38 90 0
+-25 -39 91 0
+-25 -40 92 0
+-26 -35 86 0
+-26 -33 86 0
+-26 -36 87 0
+-26 -37 88 0
+-26 -38 89 0
+-26 -39 90 0
+-26 -40 91 0
+-27 -36 86 0
+-27 -34 86 0
+-27 -37 87 0
+-27 -33 87 0
+-27 -38 88 0
+-27 -39 89 0
+-27 -40 90 0
+-28 -37 86 0
+-28 -35 86 0
+-28 -38 87 0
+-28 -34 87 0
+-28 -39 88 0
+-28 -33 88 0
+-28 -40 89 0
+-29 -38 86 0
+-29 -36 86 0
+-29 -39 87 0
+-29 -35 87 0
+-29 -40 88 0
+-29 -34 88 0
+-29 -33 89 0
+-30 -39 86 0
+-30 -37 86 0
+-30 -40 87 0
+-30 -36 87 0
+-30 -35 88 0
+-30 -34 89 0
+-30 -33 90 0
+-31 -40 86 0
+-31 -38 86 0
+-31 -37 87 0
+-31 -36 88 0
+-31 -35 89 0
+-31 -34 90 0
+-31 -33 91 0
+-32 -39 86 0
+-32 -38 87 0
+-32 -37 88 0
+-32 -36 89 0
+-32 -35 90 0
+-32 -34 91 0
+-32 -33 92 0
+-33 -42 93 0
+-33 -43 94 0
+-33 -44 95 0
+-33 -45 96 0
+-33 -46 97 0
+-33 -47 98 0
+-33 -48 99 0
+-34 -43 93 0
+-34 -41 93 0
+-34 -44 94 0
+-34 -45 95 0
+-34 -46 96 0
+-34 -47 97 0
+-34 -48 98 0
+-35 -44 93 0
+-35 -42 93 0
+-35 -45 94 0
+-35 -41 94 0
+-35 -46 95 0
+-35 -47 96 0
+-35 -48 97 0
+-36 -45 93 0
+-36 -43 93 0
+-36 -46 94 0
+-36 -42 94 0
+-36 -47 95 0
+-36 -41 95 0
+-36 -48 96 0
+-37 -46 93 0
+-37 -44 93 0
+-37 -47 94 0
+-37 -43 94 0
+-37 -48 95 0
+-37 -42 95 0
+-37 -41 96 0
+-38 -47 93 0
+-38 -45 93 0
+-38 -48 94 0
+-38 -44 94 0
+-38 -43 95 0
+-38 -42 96 0
+-38 -41 97 0
+-39 -48 93 0
+-39 -46 93 0
+-39 -45 94 0
+-39 -44 95 0
+-39 -43 96 0
+-39 -42 97 0
+-39 -41 98 0
+-40 -47 93 0
+-40 -46 94 0
+-40 -45 95 0
+-40 -44 96 0
+-40 -43 97 0
+-40 -42 98 0
+-40 -41 99 0
+-41 -50 100 0
+-41 -51 101 0
+-41 -52 102 0
+-41 -53 103 0
+-41 -54 104 0
+-41 -55 105 0
+-41 -56 106 0
+-42 -51 100 0
+-42 -49 100 0
+-42 -52 101 0
+-42 -53 102 0
+-42 -54 103 0
+-42 -55 104 0
+-42 -56 105 0
+-43 -52 100 0
+-43 -50 100 0
+-43 -53 101 0
+-43 -49 101 0
+-43 -54 102 0
+-43 -55 103 0
+-43 -56 104 0
+-44 -53 100 0
+-44 -51 100 0
+-44 -54 101 0
+-44 -50 101 0
+-44 -55 102 0
+-44 -49 102 0
+-44 -56 103 0
+-45 -54 100 0
+-45 -52 100 0
+-45 -55 101 0
+-45 -51 101 0
+-45 -56 102 0
+-45 -50 102 0
+-45 -49 103 0
+-46 -55 100 0
+-46 -53 100 0
+-46 -56 101 0
+-46 -52 101 0
+-46 -51 102 0
+-46 -50 103 0
+-46 -49 104 0
+-47 -56 100 0
+-47 -54 100 0
+-47 -53 101 0
+-47 -52 102 0
+-47 -51 103 0
+-47 -50 104 0
+-47 -49 105 0
+-48 -55 100 0
+-48 -54 101 0
+-48 -53 102 0
+-48 -52 103 0
+-48 -51 104 0
+-48 -50 105 0
+-48 -49 106 0
+-49 -58 107 0
+-49 -59 108 0
+-49 -60 109 0
+-49 -61 110 0
+-49 -62 111 0
+-49 -63 112 0
+-49 -64 113 0
+-50 -59 107 0
+-50 -57 107 0
+-50 -60 108 0
+-50 -61 109 0
+-50 -62 110 0
+-50 -63 111 0
+-50 -64 112 0
+-51 -60 107 0
+-51 -58 107 0
+-51 -61 108 0
+-51 -57 108 0
+-51 -62 109 0
+-51 -63 110 0
+-51 -64 111 0
+-52 -61 107 0
+-52 -59 107 0
+-52 -62 108 0
+-52 -58 108 0
+-52 -63 109 0
+-52 -57 109 0
+-52 -64 110 0
+-53 -62 107 0
+-53 -60 107 0
+-53 -63 108 0
+-53 -59 108 0
+-53 -64 109 0
+-53 -58 109 0
+-53 -57 110 0
+-54 -63 107 0
+-54 -61 107 0
+-54 -64 108 0
+-54 -60 108 0
+-54 -59 109 0
+-54 -58 110 0
+-54 -57 111 0
+-55 -64 107 0
+-55 -62 107 0
+-55 -61 108 0
+-55 -60 109 0
+-55 -59 110 0
+-55 -58 111 0
+-55 -57 112 0
+-56 -63 107 0
+-56 -62 108 0
+-56 -61 109 0
+-56 -60 110 0
+-56 -59 111 0
+-56 -58 112 0
+-56 -57 113 0
+c end of file
diff --git a/test/resources/BenchmarkSat/aim-100-1_6-yes1-2.cnf b/test/resources/BenchmarkSat/aim-100-1_6-yes1-2.cnf
new file mode 100644
index 0000000..2637944
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-100-1_6-yes1-2.cnf
@@ -0,0 +1,171 @@
+c FILE: aim-100-1_6-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 100 160
+16 25 35 0
+16 25 -35 0
+-16 25 -48 0
+-25 -48 86 0
+-25 -48 -86 0
+32 48 53 0
+32 48 -53 0
+-32 48 -70 0
+-32 -49 70 0
+49 69 74 0
+69 70 -74 0
+49 -69 -94 0
+24 -69 94 0
+-24 83 94 0
+-20 -24 -83 0
+-24 81 -83 0
+-66 -81 -83 0
+3 66 -81 0
+-3 -41 66 0
+-3 -56 80 0
+41 -56 -80 0
+41 56 73 0
+56 -73 -97 0
+45 56 -73 0
+-45 -60 -73 0
+12 -45 -73 0
+-12 60 -75 0
+-12 75 95 0
+58 75 -95 0
+15 -58 -95 0
+5 -15 -58 0
+-5 11 -58 0
+-5 -11 -76 0
+-11 -29 76 0
+65 76 -99 0
+29 76 -99 0
+29 43 99 0
+-43 93 99 0
+23 -43 -93 0
+-23 -86 -93 0
+-23 -93 -98 0
+-67 -93 98 0
+8 67 98 0
+-8 -28 98 0
+-8 -16 98 0
+-8 28 -55 0
+28 55 100 0
+1 55 -100 0
+-1 -21 -100 0
+-1 21 -46 0
+21 46 -85 0
+21 71 85 0
+21 -22 -71 0
+22 40 -71 0
+46 51 67 0
+22 -46 51 0
+-40 51 60 0
+51 -60 -67 0
+-4 -40 -51 0
+4 -51 82 0
+4 26 -82 0
+-26 28 -62 0
+-28 -62 -82 0
+-26 -52 62 0
+52 57 62 0
+-57 62 -64 0
+-37 -57 64 0
+19 64 -77 0
+-19 37 -77 0
+13 37 77 0
+-13 -44 77 0
+-13 44 89 0
+-34 44 -89 0
+34 68 -89 0
+-9 34 -68 0
+50 -91 97 0
+9 50 -97 0
+9 -68 -91 0
+36 86 91 0
+36 -68 91 0
+6 -36 91 0
+6 -36 -49 0
+-6 -36 90 0
+-6 65 -90 0
+-31 -65 -90 0
+31 -65 -87 0
+25 -65 87 0
+14 31 87 0
+-14 18 -25 0
+-14 -18 -72 0
+-14 -18 -30 0
+-14 72 84 0
+-33 72 84 0
+-27 30 75 0
+30 -75 -84 0
+27 78 -84 0
+59 -78 -80 0
+-59 -80 -84 0
+24 79 80 0
+-78 79 80 0
+38 -78 -79 0
+-38 -79 88 0
+19 -38 -88 0
+-38 -88 -96 0
+-19 42 96 0
+-39 -42 94 0
+-39 -94 96 0
+-17 20 -42 0
+-17 -20 39 0
+-10 17 38 0
+-10 17 39 0
+10 17 74 0
+-7 10 -74 0
+7 12 41 0
+7 41 -92 0
+7 -41 -92 0
+-33 -74 92 0
+-2 33 54 0
+-2 -54 92 0
+2 33 50 0
+2 -50 -63 0
+27 47 63 0
+-50 -61 63 0
+-27 -61 63 0
+-50 -53 61 0
+53 54 61 0
+47 53 -54 0
+35 -47 -54 0
+-35 -47 59 0
+52 78 95 0
+23 26 89 0
+-29 45 -98 0
+-31 -66 -76 0
+-21 -30 -55 0
+-22 -52 -85 0
+20 -34 100 0
+45 -63 90 0
+-16 -52 -72 0
+3 -33 -44 0
+-9 15 26 0
+13 -70 85 0
+-37 -63 -75 0
+31 40 54 0
+-87 88 -96 0
+-15 -59 82 0
+3 23 93 0
+19 -31 -39 0
+-34 58 68 0
+1 15 -34 0
+14 43 71 0
+8 30 57 0
+-4 18 73 0
+5 18 88 0
+-7 11 83 0
+-64 68 81 0
+30 35 -37 0
+-9 12 97 0
+-4 42 93 0
+-7 -21 0
+-7 -10 81 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-100-2_0-yes1-4.cnf b/test/resources/BenchmarkSat/aim-100-2_0-yes1-4.cnf
new file mode 100644
index 0000000..3e5519e
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-100-2_0-yes1-4.cnf
@@ -0,0 +1,211 @@
+c FILE: aim-100-2_0-yes1-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 100 200
+1 35 64 0
+28 -64 69 0
+1 -28 -64 0
+-1 22 69 0
+-22 38 93 0
+38 69 -93 0
+-1 -22 -38 0
+19 35 -69 0
+-19 35 -69 0
+17 -35 72 0
+-17 72 78 0
+-17 -35 72 0
+-35 -72 -79 0
+-68 -72 79 0
+68 -72 -89 0
+-51 68 89 0
+-37 68 89 0
+-25 37 89 0
+25 32 37 0
+15 25 -32 0
+-15 -32 36 0
+-13 -15 -36 0
+-15 -34 -36 0
+13 -36 71 0
+13 45 -71 0
+-45 -71 99 0
+-45 -71 -90 0
+14 66 -99 0
+66 98 -99 0
+-45 66 -98 0
+-1 -66 -99 0
+45 90 97 0
+90 94 97 0
+-66 90 97 0
+-28 37 53 0
+-37 53 -66 0
+-53 84 -97 0
+-28 -53 -84 0
+1 -93 -97 0
+44 93 -97 0
+27 -44 93 0
+-27 -44 -98 0
+-26 -27 -44 0
+26 -27 -81 0
+14 26 92 0
+26 81 92 0
+42 81 -92 0
+42 81 -95 0
+3 -33 -92 0
+-3 -33 -42 0
+-42 -47 -92 0
+-42 70 76 0
+33 -70 76 0
+33 59 -76 0
+-56 -59 -76 0
+-21 -59 -76 0
+-22 56 -59 0
+21 -31 56 0
+15 21 -96 0
+21 22 -96 0
+-9 82 96 0
+-9 22 -82 0
+4 9 96 0
+-4 54 96 0
+-4 -54 -95 0
+-4 -39 -54 0
+-54 74 95 0
+-68 74 95 0
+60 -74 95 0
+33 58 -74 0
+-33 58 -60 0
+-3 58 -60 0
+-3 -58 -74 0
+-58 -60 -80 0
+3 52 -58 0
+3 -52 91 0
+5 55 -91 0
+-5 -52 55 0
+-14 -52 56 0
+-14 -56 -91 0
+-14 -56 -83 0
+13 -19 -55 0
+-13 -19 -91 0
+25 -55 -87 0
+-25 -55 -87 0
+14 19 -64 0
+19 51 63 0
+-51 63 64 0
+11 -63 64 0
+7 -11 40 0
+7 -40 -63 0
+-11 -63 -100 0
+-7 -11 75 0
+-7 -46 -75 0
+46 74 86 0
+46 -75 86 0
+-77 88 100 0
+-86 -88 100 0
+-75 -77 -100 0
+46 -67 -86 0
+-62 67 -86 0
+62 67 -88 0
+62 67 78 0
+-5 62 -78 0
+18 -78 88 0
+-18 24 79 0
+24 -78 -79 0
+-18 -24 -50 0
+-18 -24 43 0
+-24 -43 -69 0
+-30 -43 50 0
+-23 32 -43 0
+-23 -32 65 0
+9 -23 -65 0
+-9 30 -65 0
+23 30 -82 0
+23 49 100 0
+30 49 -100 0
+23 -49 -53 0
+-48 -49 53 0
+48 -49 -65 0
+-16 48 88 0
+-16 65 -88 0
+-40 48 65 0
+8 39 57 0
+16 -39 57 0
+-8 16 57 0
+16 -57 85 0
+-57 -83 -85 0
+2 -12 -85 0
+-2 -12 -57 0
+20 83 -85 0
+-20 34 -94 0
+-34 83 -94 0
+83 -93 -94 0
+12 -20 73 0
+-20 61 77 0
+61 -73 -77 0
+8 -61 82 0
+8 -73 -82 0
+-29 -61 -73 0
+-8 41 -61 0
+10 38 -41 0
+-8 10 -38 0
+-10 -41 -70 0
+-10 -38 -41 0
+-6 -10 70 0
+6 -17 70 0
+2 6 7 0
+2 -7 17 0
+-2 27 -84 0
+-2 17 -84 0
+-39 54 91 0
+77 85 -90 0
+15 -48 99 0
+42 -79 -96 0
+32 92 98 0
+-40 59 -62 0
+-21 86 94 0
+4 10 -98 0
+11 40 -89 0
+4 63 91 0
+27 -70 73 0
+12 60 75 0
+-25 47 61 0
+49 51 98 0
+31 34 43 0
+-6 29 47 0
+-13 39 -68 0
+77 -80 85 0
+-62 82 87 0
+5 -21 -34 0
+-31 71 80 0
+40 54 -67 0
+39 52 55 0
+9 36 76 0
+24 -30 -50 0
+5 -48 94 0
+34 -46 73 0
+75 78 87 0
+-12 -46 80 0
+11 44 -81 0
+-30 -67 84 0
+60 -80 -87 0
+18 -29 31 0
+-16 28 29 0
+41 51 -81 0
+28 -29 -47 0
+59 -90 99 0
+-47 -89 -95 0
+44 71 80 0
+52 -83 87 0
+-5 31 50 0
+-6 36 84 0
+20 29 43 0
+6 20 45 0
+18 -26 -51 0
+12 50 -50 0
+-31 47 79 0
+-26 -37 41 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-100-3_4-yes1-2.cnf b/test/resources/BenchmarkSat/aim-100-3_4-yes1-2.cnf
new file mode 100644
index 0000000..6d61846
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-100-3_4-yes1-2.cnf
@@ -0,0 +1,351 @@
+c FILE: aim-100-3_4-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 100 340
+11 21 92 0
+11 21 90 0
+11 23 -92 0
+11 -23 -92 0
+-11 21 65 0
+-11 55 -65 0
+14 -21 71 0
+-21 68 -71 0
+14 -21 -71 0
+-14 -21 55 0
+-14 55 -63 0
+49 -55 80 0
+49 60 -80 0
+49 -60 -80 0
+20 28 57 0
+-20 28 67 0
+9 -55 61 0
+9 -55 -61 0
+-49 -57 78 0
+-57 67 -78 0
+13 67 76 0
+-9 -13 67 0
+-9 -49 -76 0
+47 -55 -67 0
+13 42 -47 0
+13 -49 98 0
+13 22 -98 0
+13 -22 -49 0
+29 -67 -93 0
+-29 -67 -93 0
+-67 -81 -93 0
+36 -89 93 0
+22 -36 93 0
+-47 58 93 0
+22 33 -47 0
+22 -33 93 0
+22 -51 -60 0
+-13 -22 86 0
+2 -23 86 0
+-2 -22 86 0
+-22 -42 86 0
+-13 -47 -75 0
+75 -86 91 0
+9 -86 -91 0
+29 -86 93 0
+-29 75 86 0
+-29 -86 -90 0
+-4 -29 -90 0
+74 75 90 0
+-9 -77 90 0
+-7 -9 17 0
+-7 -17 -29 0
+-2 7 77 0
+7 -33 -74 0
+2 63 -74 0
+4 -74 -94 0
+4 -51 -74 0
+2 33 -72 0
+5 -33 -72 0
+-5 -63 -72 0
+7 -52 77 0
+43 77 -79 0
+-43 77 -79 0
+7 -52 -77 0
+7 -77 -87 0
+33 71 72 0
+15 33 72 0
+-63 72 -97 0
+52 68 -71 0
+21 52 -68 0
+-15 52 -57 0
+41 83 89 0
+57 77 83 0
+41 -77 83 0
+-41 83 97 0
+65 73 79 0
+-2 65 73 0
+73 -79 97 0
+-65 73 97 0
+-12 73 97 0
+-21 -79 -83 0
+-11 32 -73 0
+-11 -32 -73 0
+11 57 68 0
+-51 -69 94 0
+69 -83 95 0
+69 89 -95 0
+58 69 -89 0
+-58 69 -83 0
+-51 61 -83 0
+-51 -61 -83 0
+18 55 88 0
+18 -55 88 0
+-18 79 88 0
+-4 6 -88 0
+-4 6 -90 0
+-6 79 97 0
+-68 79 -97 0
+4 -31 -68 0
+24 38 51 0
+-24 31 51 0
+37 38 48 0
+31 37 -48 0
+-6 31 -37 0
+-38 51 -76 0
+30 76 81 0
+30 59 -81 0
+30 31 -59 0
+56 71 100 0
+56 -71 100 0
+-40 56 100 0
+1 6 51 0
+1 -6 51 0
+-1 56 -100 0
+-1 -96 -100 0
+-1 -34 -96 0
+46 -54 -100 0
+46 -54 -91 0
+35 51 -100 0
+-35 -54 60 0
+25 -56 60 0
+4 -25 60 0
+-56 57 63 0
+-4 -56 -57 0
+46 -56 -63 0
+-46 -56 60 0
+4 -30 -50 0
+-30 -38 -62 0
+50 76 -92 0
+-66 76 -92 0
+-42 -66 -92 0
+10 50 58 0
+50 58 -60 0
+9 -58 78 0
+-58 -78 81 0
+50 -58 81 0
+45 -48 -60 0
+26 -45 -48 0
+-26 -45 96 0
+-45 62 -96 0
+-62 -81 -96 0
+25 32 92 0
+25 -32 48 0
+48 62 71 0
+46 62 -71 0
+-25 92 100 0
+-25 58 92 0
+-46 -81 91 0
+-25 -46 -99 0
+20 41 -58 0
+-41 -61 99 0
+2 -61 99 0
+-2 -61 99 0
+13 -39 -46 0
+-13 -39 79 0
+-39 61 -79 0
+-13 -20 -39 0
+39 84 -91 0
+-59 61 -91 0
+39 78 99 0
+39 -40 78 0
+59 -84 100 0
+-18 71 -78 0
+-18 -78 -100 0
+29 -84 87 0
+-84 -87 89 0
+18 -84 89 0
+2 -31 -84 0
+-2 -31 89 0
+18 54 -89 0
+8 24 59 0
+8 -24 59 0
+-8 10 20 0
+-8 20 -89 0
+-5 -8 20 0
+10 -20 31 0
+-20 -31 99 0
+10 -20 -99 0
+-10 47 80 0
+-10 -47 80 0
+-37 -54 -80 0
+37 42 -80 0
+-42 69 -80 0
+68 -69 70 0
+-10 -69 70 0
+19 -69 -70 0
+15 -70 78 0
+15 -69 -78 0
+-15 26 -70 0
+37 68 -87 0
+37 -68 -87 0
+12 35 87 0
+-12 35 87 0
+-17 -26 91 0
+-17 -70 -91 0
+3 17 -19 0
+-3 -19 27 0
+-19 27 -52 0
+17 -19 -24 0
+49 -53 82 0
+49 -53 -82 0
+30 -49 87 0
+30 -53 -67 0
+29 -30 -35 0
+-30 -35 -53 0
+-12 17 -27 0
+-12 -17 -35 0
+-17 -23 -27 0
+-34 53 88 0
+12 -34 53 0
+-34 53 -88 0
+-11 12 -34 0
+24 42 77 0
+24 42 -77 0
+-27 42 -60 0
+24 53 -66 0
+34 41 66 0
+-41 53 95 0
+-41 -42 -53 0
+34 35 43 0
+34 43 48 0
+15 -35 43 0
+-15 34 -48 0
+50 66 88 0
+-50 66 88 0
+-22 -50 66 0
+5 28 81 0
+5 28 -88 0
+63 -88 95 0
+32 40 67 0
+-28 32 40 0
+-28 -32 40 0
+26 -28 -40 0
+-26 63 -95 0
+4 5 75 0
+5 -42 -75 0
+-4 -42 -88 0
+-43 -44 48 0
+-44 -48 -95 0
+3 -5 -95 0
+3 -5 -30 0
+3 -5 -46 0
+23 -43 52 0
+23 27 -43 0
+23 44 -52 0
+-3 19 -23 0
+-3 -19 -85 0
+-43 62 -85 0
+-3 -62 -85 0
+10 45 85 0
+-10 44 74 0
+-10 25 44 0
+-6 -10 -25 0
+-6 44 46 0
+27 -46 85 0
+-27 -45 85 0
+-3 -23 -45 0
+6 85 -96 0
+6 74 82 0
+45 -74 82 0
+52 -82 -94 0
+21 -52 -82 0
+45 -82 -94 0
+16 -82 85 0
+12 36 96 0
+-12 45 96 0
+28 39 96 0
+28 -39 96 0
+1 85 94 0
+1 41 -85 0
+1 -41 -85 0
+62 64 75 0
+-62 64 76 0
+-16 -63 64 0
+14 -75 81 0
+14 -68 -75 0
+-14 38 94 0
+33 36 -81 0
+38 59 95 0
+-33 -59 95 0
+-33 38 -95 0
+36 -38 -75 0
+-16 64 72 0
+-16 -72 83 0
+-16 -36 -72 0
+36 64 -76 0
+61 -76 94 0
+-36 -76 94 0
+-28 40 66 0
+40 47 -66 0
+-16 -47 -66 0
+15 -36 90 0
+-15 65 90 0
+57 -64 -90 0
+-36 -57 -90 0
+-64 92 -94 0
+-64 65 -94 0
+-1 -65 -98 0
+9 44 -65 0
+-9 14 -65 0
+26 54 59 0
+-26 27 54 0
+-27 -44 54 0
+-44 54 -59 0
+-1 -44 -54 0
+3 -14 -64 0
+-14 56 -64 0
+32 -65 98 0
+39 -62 -93 0
+17 55 70 0
+-15 82 84 0
+-37 80 98 0
+23 -73 98 0
+34 -37 82 0
+19 -70 -98 0
+-32 -38 91 0
+-8 74 0
+-26 43 84 0
+12 -24 63 0
+25 70 -97 0
+-32 -50 91 0
+70 72 80 0
+-24 87 91 0
+8 -40 -59 0
+-11 -73 -89 0
+-40 74 84 0
+-7 19 -97 0
+47 -50 -97 0
+-7 8 -38 0
+-28 -73 -99 0
+-19 29 98 0
+16 18 88 0
+16 -31 98 0
+47 -98 0
+-18 -99 0
+8 -86 -99 0
+19 26 35 0
+84 -87 -93 0
+16 74 -93 0
+-7 16 -37 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-100-6_0-yes1-4.cnf b/test/resources/BenchmarkSat/aim-100-6_0-yes1-4.cnf
new file mode 100644
index 0000000..a0e5ed9
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-100-6_0-yes1-4.cnf
@@ -0,0 +1,611 @@
+c FILE: aim-100-6_0-yes1-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 100 600
+27 43 -75 0
+25 27 -43 0
+25 -27 -43 0
+84 89 97 0
+10 84 -97 0
+10 -11 21 0
+-21 -25 89 0
+-10 -25 52 0
+-25 -52 74 0
+-25 -74 83 0
+-25 -83 84 0
+-2 -25 43 0
+-2 -43 89 0
+-25 -84 89 0
+20 -43 -89 0
+-20 -43 80 0
+-20 -80 -89 0
+-20 -43 -79 0
+-22 28 88 0
+28 72 -88 0
+19 -28 72 0
+6 79 88 0
+6 64 88 0
+-6 64 88 0
+40 64 88 0
+-88 93 98 0
+-88 93 -98 0
+64 -88 -93 0
+-22 -64 -72 0
+43 -64 -69 0
+-19 27 85 0
+54 56 85 0
+-19 -56 85 0
+-22 -27 -54 0
+-22 27 -85 0
+9 -27 -85 0
+9 -72 -85 0
+-27 43 -85 0
+-27 -40 -85 0
+22 29 -52 0
+-29 43 76 0
+-29 -52 55 0
+15 -29 -55 0
+-29 -55 -76 0
+-15 52 75 0
+-15 35 -75 0
+-35 69 -75 0
+-15 -69 79 0
+-15 -35 -79 0
+22 43 -90 0
+15 -51 63 0
+-51 -63 90 0
+51 53 -83 0
+51 -53 -83 0
+-13 15 83 0
+51 91 -97 0
+51 90 -91 0
+2 32 -47 0
+-47 81 -82 0
+52 -81 -82 0
+21 22 -47 0
+-2 -21 22 0
+24 32 -99 0
+-2 24 32 0
+-2 -24 -31 0
+-32 46 -47 0
+22 -46 -47 0
+83 84 -87 0
+-9 83 -87 0
+3 52 -87 0
+3 86 -87 0
+-84 -86 96 0
+3 -84 -96 0
+-3 -87 99 0
+1 -3 -99 0
+-1 77 -99 0
+-1 77 -83 0
+-1 -77 -99 0
+13 -71 97 0
+51 -57 90 0
+13 -17 71 0
+-17 52 71 0
+-17 -35 71 0
+-40 83 92 0
+-40 49 83 0
+13 -40 83 0
+13 -46 56 0
+13 -46 -86 0
+44 -46 87 0
+14 -44 -56 0
+-46 -56 87 0
+-46 -56 89 0
+13 -46 -89 0
+-12 71 87 0
+-11 47 85 0
+-11 57 -85 0
+20 -35 46 0
+11 -35 46 0
+-11 -35 57 0
+71 82 95 0
+-9 33 -95 0
+-9 -33 71 0
+-9 71 -82 0
+18 91 93 0
+18 87 -91 0
+18 87 -93 0
+18 63 99 0
+18 40 -63 0
+18 35 -99 0
+12 35 -74 0
+11 -58 97 0
+26 -58 -97 0
+11 46 -58 0
+11 -31 -97 0
+44 81 89 0
+44 92 97 0
+89 -92 97 0
+44 -81 -97 0
+12 40 -44 0
+-2 40 -44 0
+12 40 89 0
+46 70 -89 0
+11 73 98 0
+11 -73 98 0
+11 51 98 0
+-1 -51 98 0
+-23 55 -89 0
+-23 67 -89 0
+-23 -67 -89 0
+54 73 99 0
+-43 73 99 0
+-14 73 99 0
+31 37 97 0
+35 60 73 0
+35 -37 -60 0
+-31 35 54 0
+9 54 -97 0
+35 54 -97 0
+38 54 77 0
+9 38 -77 0
+9 -38 54 0
+4 -18 -70 0
+-18 56 79 0
+-4 -18 79 0
+-4 -18 -33 0
+-18 21 -56 0
+-18 21 -95 0
+-18 -21 79 0
+50 -70 -79 0
+-50 -79 -95 0
+-70 -79 86 0
+41 -89 -96 0
+-41 -89 -96 0
+23 58 76 0
+23 32 78 0
+32 -58 -78 0
+23 -32 -58 0
+31 -76 88 0
+31 88 95 0
+77 -88 95 0
+-76 -88 95 0
+31 -76 -94 0
+31 -40 -76 0
+26 -31 66 0
+-26 50 66 0
+-50 66 95 0
+34 -79 87 0
+-34 73 -79 0
+24 -66 73 0
+-24 -66 -87 0
+-31 58 80 0
+-58 -66 80 0
+59 -73 95 0
+-73 80 95 0
+59 -73 -80 0
+-39 -66 -80 0
+67 -80 96 0
+60 63 76 0
+-63 76 100 0
+26 60 75 0
+10 -26 75 0
+10 -75 76 0
+10 23 -60 0
+23 -53 -60 0
+10 -60 76 0
+52 -76 82 0
+10 -52 -67 0
+64 -67 82 0
+-10 64 -95 0
+-64 -67 72 0
+-10 -64 -67 0
+12 34 39 0
+-12 39 87 0
+19 -66 -87 0
+39 91 98 0
+39 -66 98 0
+49 -66 -98 0
+-19 -42 -49 0
+21 -34 76 0
+-21 -34 76 0
+5 33 -76 0
+11 -33 -76 0
+-11 -33 -42 0
+-42 46 -66 0
+39 -61 74 0
+39 -61 -74 0
+39 -42 -46 0
+39 -44 -67 0
+72 75 94 0
+-73 -84 -94 0
+72 -73 -84 0
+42 -73 -84 0
+73 -80 -82 0
+34 -73 -80 0
+19 39 -80 0
+-34 -39 -80 0
+-41 -80 -82 0
+7 -33 42 0
+-7 -33 -67 0
+32 -61 76 0
+-61 -76 83 0
+32 -61 -83 0
+-32 -59 -61 0
+25 61 -62 0
+33 -62 77 0
+33 -49 -62 0
+40 54 -62 0
+40 -54 -62 0
+33 -40 -77 0
+42 -48 82 0
+20 -42 82 0
+-20 28 82 0
+-20 -28 -48 0
+61 79 96 0
+61 -62 91 0
+-62 -79 96 0
+-62 71 -96 0
+61 -62 -71 0
+41 -77 -82 0
+33 -48 49 0
+-41 -48 -49 0
+-10 59 65 0
+-59 65 -82 0
+-10 -59 -90 0
+58 -65 86 0
+58 78 88 0
+-9 78 -88 0
+58 66 -78 0
+31 66 77 0
+31 -77 82 0
+31 66 -82 0
+-9 -10 84 0
+-10 -65 99 0
+28 42 -99 0
+-28 42 66 0
+-31 -42 66 0
+-10 59 -82 0
+-10 -59 -65 0
+61 67 100 0
+-20 67 100 0
+12 -67 100 0
+-12 58 -67 0
+12 61 100 0
+-58 61 100 0
+62 -90 99 0
+62 -90 100 0
+-13 -90 91 0
+-13 -90 100 0
+7 49 62 0
+-49 62 75 0
+7 62 -77 0
+-7 62 95 0
+57 62 -95 0
+-57 62 -95 0
+-42 45 61 0
+-42 -45 75 0
+3 61 84 0
+-3 38 -60 0
+33 -38 -60 0
+1 45 93 0
+55 -93 -94 0
+1 -55 -94 0
+1 15 -100 0
+15 -99 -100 0
+-15 18 81 0
+-15 18 -100 0
+1 -18 -100 0
+-1 16 -94 0
+-11 90 91 0
+16 -91 -100 0
+-16 17 89 0
+14 -16 17 0
+-17 90 -94 0
+-14 -16 90 0
+-90 -94 -100 0
+-3 21 44 0
+-3 21 62 0
+10 41 92 0
+-41 92 100 0
+10 92 -100 0
+7 92 -100 0
+-7 -38 60 0
+-21 31 56 0
+-21 -55 -56 0
+45 59 86 0
+58 -59 86 0
+16 -55 -58 0
+-16 25 -55 0
+-25 -55 86 0
+-31 -55 -86 0
+-14 -31 45 0
+-21 -45 -55 0
+47 -48 53 0
+47 -48 -53 0
+-48 50 -75 0
+-47 -75 -100 0
+-3 4 94 0
+-21 48 50 0
+-69 -92 94 0
+-69 74 94 0
+-41 74 -92 0
+66 75 -92 0
+-66 75 94 0
+-74 -75 -92 0
+29 48 60 0
+5 -29 48 0
+15 30 60 0
+-5 15 -56 0
+-15 48 -56 0
+14 23 56 0
+23 56 -68 0
+-23 -50 56 0
+-50 56 -68 0
+50 54 56 0
+-54 -68 91 0
+-68 70 -91 0
+47 49 -54 0
+49 -50 82 0
+12 -47 49 0
+-49 -54 -68 0
+36 45 -54 0
+-12 36 -45 0
+-36 -54 -68 0
+44 -77 -92 0
+-44 69 -92 0
+28 47 77 0
+28 -47 48 0
+18 30 -38 0
+-18 30 -38 0
+30 46 65 0
+-28 30 -65 0
+-28 77 98 0
+-28 -46 -98 0
+-28 30 -77 0
+30 48 93 0
+-28 30 -93 0
+26 30 48 0
+-9 -26 -28 0
+-30 59 -99 0
+-30 -59 -99 0
+-4 49 94 0
+-49 78 94 0
+-4 78 -94 0
+-16 45 84 0
+-30 -32 -45 0
+-16 59 70 0
+-16 -50 51 0
+-30 -50 -51 0
+-30 51 -84 0
+-30 -51 90 0
+-30 -59 -84 0
+-59 -84 -90 0
+38 44 46 0
+16 38 68 0
+38 43 -44 0
+-44 46 68 0
+5 68 79 0
+-5 68 79 0
+-5 68 -85 0
+4 38 68 0
+-4 38 68 0
+14 16 17 0
+9 14 -17 0
+14 16 69 0
+69 71 -95 0
+16 -71 -95 0
+16 -31 -71 0
+38 -78 93 0
+-38 -78 93 0
+-26 29 -30 0
+-13 -26 88 0
+-13 -26 -30 0
+-14 -26 -29 0
+-38 72 78 0
+-14 72 83 0
+-38 72 -83 0
+-32 -72 -93 0
+-32 -56 95 0
+-32 81 -95 0
+-32 -72 -81 0
+-2 -32 -81 0
+49 -78 -93 0
+45 -78 -93 0
+-39 -78 92 0
+45 -78 -92 0
+25 -45 -93 0
+-6 32 -49 0
+3 -20 26 0
+-3 -20 -49 0
+4 64 -72 0
+-4 64 -72 0
+6 45 -63 0
+6 -63 -72 0
+34 52 69 0
+20 34 69 0
+20 26 -69 0
+-12 26 42 0
+-12 20 22 0
+2 19 20 0
+2 20 -63 0
+2 -19 79 0
+2 -19 -26 0
+-2 -69 75 0
+6 -69 -75 0
+-22 23 94 0
+-22 -23 50 0
+3 -22 -50 0
+3 6 -23 0
+-3 6 -23 0
+20 -29 -69 0
+43 47 53 0
+6 -43 47 0
+-35 47 53 0
+6 34 -47 0
+22 33 34 0
+-33 34 -53 0
+27 48 -53 0
+-27 34 48 0
+-22 -48 -53 0
+32 -49 -85 0
+-45 57 78 0
+57 63 86 0
+-57 70 86 0
+65 -70 86 0
+4 -45 57 0
+19 -45 57 0
+-15 57 -86 0
+-57 63 65 0
+44 59 -86 0
+36 -44 63 0
+-36 -86 99 0
+-36 -44 -86 0
+-19 21 65 0
+-21 40 65 0
+-40 -59 65 0
+-20 -40 65 0
+25 26 50 0
+-26 -34 50 0
+-23 -34 50 0
+5 25 -50 0
+5 -34 69 0
+24 -34 -69 0
+5 -24 63 0
+-5 13 27 0
+-5 -13 27 0
+-5 24 70 0
+24 -34 -77 0
+37 47 -70 0
+13 37 -70 0
+13 24 -37 0
+-13 14 97 0
+-13 24 -97 0
+-13 -14 -70 0
+27 28 63 0
+-27 28 41 0
+28 -41 51 0
+-27 -51 63 0
+69 -81 85 0
+-57 69 85 0
+1 -81 85 0
+-1 -81 85 0
+-60 -81 85 0
+-5 -41 74 0
+-5 -33 57 0
+-33 -57 74 0
+-41 55 92 0
+-1 55 -74 0
+55 -74 -92 0
+-27 -41 -74 0
+4 22 68 0
+22 41 -68 0
+4 41 52 0
+-5 70 74 0
+-4 70 -74 0
+-8 70 -74 0
+-4 -48 70 0
+-8 41 -70 0
+-8 41 -75 0
+-8 24 -52 0
+9 -24 -52 0
+-8 -9 -52 0
+-8 -52 72 0
+-8 19 -72 0
+-8 -19 -72 0
+-8 -53 -87 0
+-2 8 -65 0
+37 -65 67 0
+8 37 -65 0
+35 41 53 0
+29 94 97 0
+29 -94 97 0
+5 53 93 0
+53 93 -97 0
+29 -35 -93 0
+-29 53 99 0
+-29 -35 53 0
+2 29 35 0
+2 -16 29 0
+2 29 -53 0
+1 9 23 0
+9 -23 -37 0
+1 4 19 0
+1 -19 98 0
+4 -19 -98 0
+-4 -9 -37 0
+12 -36 58 0
+-36 -37 -58 0
+-36 43 96 0
+5 -43 96 0
+-12 -36 96 0
+-12 -68 96 0
+-12 -36 -96 0
+-37 -39 82 0
+-39 64 78 0
+-24 78 87 0
+-39 -78 87 0
+-39 40 -64 0
+7 -63 -64 0
+-63 -64 77 0
+-7 -63 -64 0
+-36 -39 -40 0
+-37 -39 -87 0
+8 52 73 0
+8 14 -73 0
+8 14 -52 0
+-14 19 -88 0
+8 -14 -88 0
+-7 16 42 0
+-16 60 81 0
+42 60 -81 0
+-7 -42 60 0
+3 19 -60 0
+3 -37 -60 0
+-3 -7 68 0
+-7 -37 -68 0
+-1 7 -91 0
+8 90 -91 0
+-1 8 -90 0
+-22 74 -91 0
+8 15 -91 0
+-7 -15 -91 0
+-11 17 0
+-25 -61 74 0
+-79 81 -83 0
+-14 80 91 0
+36 -45 -71 0
+-38 -51 58 0
+15 37 -98 0
+5 26 67 0
+33 -65 -71 0
+59 -71 84 0
+-6 36 -85 0
+44 80 84 0
+-17 37 -98 0
+-57 -83 90 0
+17 -54 -61 0
+12 25 42 0
+17 -17 -61 0
+-6 25 67 0
+55 -71 -86 0
+-24 -51 -96 0
+-24 80 -86 0
+7 27 55 0
+-53 55 -83 0
+-6 7 36 0
+-51 -54 -64 0
+36 37 96 0
+11 67 92 0
+-6 80 0
+-11 -24 81 0
+-6 36 -57 0
+2 -70 -96 0
+17 21 -24 0
+17 37 -65 0
+7 -57 91 0
+-17 67 -96 0
+17 -17 80 0
+-6 36 -98 0
+81 -96 0
+-71 -98 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-200-1_6-yes1-3.cnf b/test/resources/BenchmarkSat/aim-200-1_6-yes1-3.cnf
new file mode 100644
index 0000000..77b380b
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-200-1_6-yes1-3.cnf
@@ -0,0 +1,331 @@
+c FILE: aim-200-1_6-yes1-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 200 320
+46 72 115 0
+-46 72 130 0
+-46 72 -130 0
+50 -72 115 0
+-50 -72 115 0
+92 -95 -115 0
+-92 -95 -115 0
+95 -115 -171 0
+95 133 171 0
+-52 -133 171 0
+-133 171 175 0
+171 -175 176 0
+-21 -175 -176 0
+21 63 111 0
+21 63 -111 0
+21 -63 103 0
+-63 -94 -103 0
+94 -103 -131 0
+94 -103 200 0
+28 -86 131 0
+-28 -86 131 0
+-87 131 -200 0
+87 -93 131 0
+53 87 93 0
+-42 -53 93 0
+42 -53 184 0
+42 90 -184 0
+-16 -90 -184 0
+16 -90 138 0
+-90 -138 187 0
+-101 -138 -187 0
+7 101 -187 0
+-7 -62 101 0
+-7 62 152 0
+-7 142 -152 0
+-49 -142 -152 0
+49 -142 -153 0
+49 153 -172 0
+153 -159 172 0
+123 159 172 0
+-123 172 -188 0
+-123 174 188 0
+67 -174 188 0
+-67 -89 -174 0
+-67 80 89 0
+-56 -67 -80 0
+56 -80 -116 0
+56 116 -186 0
+1 116 186 0
+-1 -14 186 0
+-1 71 113 0
+-71 113 186 0
+14 -113 -193 0
+-113 -160 193 0
+100 -113 193 0
+66 97 160 0
+97 -100 160 0
+-92 -97 -100 0
+-97 -100 156 0
+-40 92 -156 0
+40 59 170 0
+59 -156 -170 0
+15 -59 -156 0
+-15 -43 -59 0
+43 145 159 0
+-15 145 -159 0
+43 -145 167 0
+-48 -145 -167 0
+34 48 -167 0
+-34 54 -167 0
+-34 -54 -130 0
+-34 146 166 0
+-54 146 -166 0
+118 130 -146 0
+-118 -146 165 0
+64 -118 -146 0
+-27 -64 -165 0
+27 36 -64 0
+27 -36 -99 0
+3 -36 99 0
+-3 77 110 0
+-36 77 -110 0
+-33 -77 107 0
+-3 -33 -107 0
+33 -77 148 0
+-77 -104 -148 0
+104 -148 164 0
+23 -148 -164 0
+-23 38 -164 0
+-23 -38 45 0
+-26 -38 -45 0
+26 -45 -154 0
+26 -73 154 0
+-55 73 154 0
+51 55 180 0
+-51 144 180 0
+73 -144 180 0
+55 57 -180 0
+11 -57 -180 0
+-11 -57 -71 0
+-11 71 81 0
+58 -81 195 0
+-58 71 195 0
+-24 -81 -195 0
+-81 179 -195 0
+-10 -81 -179 0
+10 52 -68 0
+-52 -68 -179 0
+10 68 -75 0
+68 75 163 0
+75 -163 -185 0
+82 -163 185 0
+-82 117 185 0
+-82 85 -117 0
+-85 -117 -126 0
+-85 126 -157 0
+-39 -85 126 0
+-85 126 -192 0
+39 157 173 0
+39 -157 173 0
+-79 -173 192 0
+-5 79 -173 0
+5 79 -136 0
+5 -61 79 0
+61 136 169 0
+61 -169 182 0
+-162 -169 -182 0
+-134 162 -182 0
+8 134 -182 0
+-8 128 134 0
+-8 -128 -178 0
+-8 12 -128 0
+-8 -12 60 0
+-12 -60 132 0
+-60 -132 -155 0
+-98 -132 155 0
+-31 89 155 0
+-31 33 98 0
+-31 -33 -89 0
+22 31 98 0
+-22 31 83 0
+-22 41 -83 0
+-25 -41 -83 0
+-41 -83 -144 0
+3 -4 25 0
+-4 25 -83 0
+4 144 196 0
+-2 4 -196 0
+2 -19 178 0
+2 -19 46 0
+2 -19 -196 0
+19 114 -196 0
+-72 -114 -196 0
+72 -114 150 0
+88 -114 -150 0
+56 -150 -151 0
+-56 -88 -151 0
+-88 151 -199 0
+-108 151 199 0
+13 151 199 0
+-13 -69 136 0
+-69 -136 151 0
+-13 65 69 0
+18 -65 69 0
+-18 -65 -197 0
+-18 -102 197 0
+-18 -32 197 0
+32 102 -147 0
+32 102 137 0
+40 102 -154 0
+-40 137 -154 0
+32 48 -109 0
+-48 -109 -137 0
+109 -137 -141 0
+-26 109 -141 0
+76 109 141 0
+76 109 -192 0
+-46 -76 141 0
+-76 109 -191 0
+29 104 191 0
+29 -104 191 0
+-29 91 191 0
+-29 -78 -91 0
+78 -91 -194 0
+-91 -139 194 0
+78 -127 128 0
+78 -127 194 0
+-107 127 194 0
+107 127 161 0
+47 127 -161 0
+-35 -47 -161 0
+-47 96 -161 0
+35 -96 -183 0
+35 -89 -183 0
+17 -96 183 0
+-17 84 -96 0
+-17 -96 110 0
+-17 -84 -121 0
+-84 -110 -111 0
+-20 -110 121 0
+111 -177 200 0
+111 -177 -200 0
+20 44 177 0
+20 -44 -190 0
+37 -44 99 0
+37 84 190 0
+37 -84 -99 0
+-37 -140 190 0
+108 124 140 0
+-37 -108 140 0
+-37 -124 125 0
+-124 -125 -143 0
+106 -125 143 0
+-106 143 -170 0
+105 -106 170 0
+9 -105 170 0
+-9 -28 -105 0
+-9 -105 -149 0
+28 74 149 0
+6 11 149 0
+6 -74 149 0
+-6 -58 -74 0
+-6 -74 120 0
+-6 -120 129 0
+-30 -120 -129 0
+66 -120 -129 0
+-66 -129 135 0
+-66 -70 -135 0
+70 -135 189 0
+119 -135 -189 0
+-119 122 -189 0
+-50 -119 -122 0
+-119 -122 198 0
+50 168 -198 0
+-166 -168 -198 0
+24 -112 -198 0
+-24 -112 -168 0
+112 158 166 0
+112 -158 -181 0
+-51 -158 181 0
+50 74 -171 0
+45 147 -172 0
+38 -93 124 0
+13 17 62 0
+-19 70 86 0
+51 83 114 0
+-2 -55 120 0
+36 176 -190 0
+-40 117 148 0
+9 -20 139 0
+1 -42 -94 0
+-26 -75 93 0
+82 -87 -101 0
+34 119 140 0
+22 125 163 0
+-32 121 -178 0
+18 50 -73 0
+-102 119 -197 0
+138 177 -177 0
+123 142 183 0
+-79 82 -160 0
+86 96 157 0
+7 16 100 0
+-16 44 132 0
+54 -62 -134 0
+-25 90 122 0
+-5 60 -61 0
+23 -159 162 0
+-33 117 133 0
+88 168 179 0
+9 -116 -121 0
+-94 -149 161 0
+53 64 105 0
+-185 -194 196 0
+38 52 -92 0
+12 -98 113 0
+41 85 147 0
+-147 164 182 0
+-131 168 169 0
+-49 -143 -191 0
+-43 48 -149 0
+106 135 158 0
+132 175 184 0
+-10 -70 152 0
+-30 82 118 0
+58 130 -153 0
+-35 -92 -134 0
+6 8 90 0
+103 -116 198 0
+15 28 -39 0
+19 -102 167 0
+-33 -35 178 0
+-10 -58 -162 0
+-49 108 156 0
+30 -35 -62 0
+-35 -176 189 0
+-43 -139 156 0
+24 -27 -165 0
+-140 -170 181 0
+68 110 192 0
+22 138 -193 0
+-21 -126 150 0
+65 91 165 0
+-14 30 -155 0
+20 81 -181 0
+14 103 -197 0
+-39 57 174 0
+144 -164 -188 0
+30 -78 161 0
+14 80 -199 0
+65 81 178 0
+-43 80 133 0
+24 103 187 0
+-32 -58 0
+57 67 139 0
+-98 129 139 0
+8 52 -170 0
+23 -170 176 0
+53 184 -186 0
+17 -21 47 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-200-2_0-yes1-3.cnf b/test/resources/BenchmarkSat/aim-200-2_0-yes1-3.cnf
new file mode 100644
index 0000000..c2cb170
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-200-2_0-yes1-3.cnf
@@ -0,0 +1,411 @@
+c FILE: aim-200-2_0-yes1-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 200 400
+41 83 99 0
+41 -83 125 0
+41 -83 -125 0
+33 -41 99 0
+-33 67 99 0
+-41 -67 166 0
+-33 -67 -166 0
+1 -99 151 0
+1 -99 -151 0
+-1 -94 -99 0
+-1 94 -120 0
+-1 65 -119 0
+-65 94 -119 0
+11 119 162 0
+94 119 162 0
+119 -162 171 0
+-150 -162 -171 0
+-40 -162 -171 0
+60 150 -171 0
+-61 140 150 0
+-60 -61 150 0
+21 40 139 0
+7 -21 139 0
+-7 40 139 0
+16 96 -139 0
+-16 -60 96 0
+-96 -139 -151 0
+21 -96 -139 0
+-21 -43 -96 0
+-31 149 151 0
+-31 -149 151 0
+-21 31 -169 0
+31 104 169 0
+-104 169 -179 0
+-104 169 -198 0
+-104 173 -189 0
+68 -173 -189 0
+-68 -173 -189 0
+117 189 193 0
+117 189 -193 0
+-11 138 198 0
+-117 -138 198 0
+111 -117 189 0
+-111 -117 177 0
+-111 -173 -177 0
+-111 -133 -177 0
+47 173 -177 0
+-46 -47 173 0
+8 46 102 0
+-8 46 102 0
+-47 84 -102 0
+-102 -128 160 0
+-84 -128 -160 0
+-68 -84 -102 0
+35 68 -84 0
+-35 68 193 0
+-35 142 -193 0
+-35 -142 196 0
+-142 163 197 0
+-142 163 -197 0
+95 167 -196 0
+-95 -163 167 0
+87 -163 -196 0
+-87 -160 -163 0
+-87 -167 180 0
+-41 -87 -180 0
+-129 160 -180 0
+-44 129 -180 0
+44 129 137 0
+80 129 -137 0
+-80 -137 159 0
+-70 -137 -159 0
+-80 -156 -159 0
+11 -159 -178 0
+-11 153 191 0
+-11 -178 191 0
+70 -178 -191 0
+-58 70 178 0
+36 156 170 0
+36 156 -170 0
+-36 -62 178 0
+21 107 177 0
+19 29 107 0
+-19 62 107 0
+62 -107 177 0
+29 -36 62 0
+-38 155 179 0
+-38 -155 179 0
+-36 -38 -179 0
+-29 38 -52 0
+-29 -52 -94 0
+38 64 -122 0
+-29 -64 -122 0
+80 91 122 0
+42 80 -91 0
+42 -80 175 0
+38 42 122 0
+-42 61 -106 0
+-61 -106 122 0
+-42 98 106 0
+18 -42 -98 0
+-18 63 -98 0
+-98 103 125 0
+22 -103 125 0
+-18 -22 -103 0
+-18 47 152 0
+-47 -125 152 0
+-63 -85 -152 0
+58 71 124 0
+58 71 -125 0
+-58 71 -152 0
+-71 -152 -185 0
+23 -71 185 0
+-16 -23 -71 0
+-127 176 185 0
+-23 -127 -176 0
+-23 -105 127 0
+105 127 -176 0
+88 105 127 0
+-88 105 -192 0
+-88 176 -186 0
+28 63 -88 0
+28 -63 192 0
+97 176 192 0
+-28 97 -176 0
+-28 -97 -200 0
+-28 73 -97 0
+-97 -126 156 0
+-73 -126 -156 0
+-73 124 126 0
+-91 124 126 0
+-73 74 196 0
+74 -124 -196 0
+-69 -74 -124 0
+-2 -74 -124 0
+2 -34 -74 0
+2 -7 34 0
+24 34 185 0
+7 44 -185 0
+24 -44 -185 0
+7 24 -156 0
+-24 34 165 0
+-24 -130 -165 0
+-24 44 -72 0
+-44 -72 -165 0
+72 -113 -165 0
+72 90 113 0
+-90 113 -144 0
+-90 167 -195 0
+113 -167 -195 0
+-90 161 195 0
+101 -161 195 0
+-101 -161 -164 0
+66 -101 -161 0
+-66 -101 -172 0
+72 112 164 0
+10 112 164 0
+-72 112 164 0
+54 74 115 0
+54 -112 115 0
+-54 -66 142 0
+-54 -66 115 0
+-112 -115 -155 0
+53 79 93 0
+53 65 -79 0
+65 -115 -198 0
+53 -65 93 0
+-53 93 -112 0
+-93 -115 -183 0
+92 -93 155 0
+-76 -92 -93 0
+-22 76 -92 0
+22 37 -92 0
+22 51 170 0
+-37 51 -170 0
+-37 -51 -108 0
+-37 -51 -65 0
+3 108 123 0
+3 -105 123 0
+-51 108 123 0
+49 108 -123 0
+-49 109 -123 0
+4 -49 -109 0
+-4 -30 60 0
+-30 -49 -60 0
+-4 -109 110 0
+-4 -57 -110 0
+-6 57 -110 0
+20 57 -110 0
+-20 57 184 0
+-20 -95 -184 0
+-9 -20 -184 0
+95 -121 -184 0
+95 121 -136 0
+9 13 121 0
+-13 -55 121 0
+-13 55 174 0
+-13 -81 -174 0
+55 147 -190 0
+133 -174 -190 0
+55 -133 -190 0
+78 106 -174 0
+30 78 190 0
+-30 78 -106 0
+-78 -134 190 0
+-78 -91 190 0
+-77 -78 91 0
+-141 198 200 0
+77 -141 -200 0
+91 -141 -198 0
+100 101 120 0
+-50 100 120 0
+-50 -100 120 0
+-50 77 -120 0
+50 77 -100 0
+141 175 196 0
+50 141 175 0
+50 118 -175 0
+-118 -170 -175 0
+-118 -145 -175 0
+86 -118 145 0
+-53 -86 145 0
+-86 -103 145 0
+3 -86 103 0
+-3 103 -114 0
+-3 114 -148 0
+-3 148 -168 0
+-75 114 148 0
+158 168 172 0
+148 158 -172 0
+114 -158 -166 0
+31 -114 -166 0
+-31 -114 168 0
+26 118 166 0
+26 -158 166 0
+-26 48 -158 0
+-48 109 182 0
+-48 -109 182 0
+-26 64 -182 0
+10 -48 -182 0
+-10 -182 -197 0
+-10 -64 194 0
+-10 188 -194 0
+-89 192 -194 0
+-89 -188 -192 0
+-55 -89 -192 0
+147 -188 -194 0
+56 -147 -188 0
+12 40 -147 0
+12 -40 -56 0
+-79 100 -147 0
+-56 -79 -100 0
+-12 -33 -56 0
+8 -12 172 0
+8 33 -172 0
+-8 33 146 0
+-8 -146 153 0
+-45 -146 -153 0
+-146 -153 -157 0
+12 63 199 0
+-12 -153 199 0
+43 157 199 0
+-43 -63 157 0
+5 157 -199 0
+-5 6 20 0
+-6 20 132 0
+43 132 -199 0
+-5 -43 132 0
+-83 -132 -199 0
+-5 -59 -132 0
+15 59 -132 0
+-15 -39 59 0
+-15 59 116 0
+-15 17 -116 0
+-17 -116 -140 0
+-17 -116 181 0
+-17 -54 -181 0
+35 140 -149 0
+140 -149 -181 0
+-67 149 -181 0
+-25 67 149 0
+14 25 67 0
+-14 69 135 0
+25 -69 135 0
+-32 -135 193 0
+-14 -32 -193 0
+-14 -135 -143 0
+-135 -138 143 0
+5 143 187 0
+138 143 187 0
+27 138 -187 0
+26 -107 -187 0
+-26 -27 -107 0
+-27 131 -187 0
+-27 -131 191 0
+-131 154 -191 0
+-19 -131 -154 0
+-82 -154 -191 0
+-40 58 -138 0
+-7 66 162 0
+45 -57 -95 0
+134 -164 186 0
+66 101 180 0
+61 -81 200 0
+-52 -70 126 0
+116 130 183 0
+56 -150 160 0
+23 -127 -169 0
+110 152 -179 0
+-58 90 161 0
+-9 15 -136 0
+-85 -128 141 0
+-108 159 174 0
+-32 -136 -168 0
+86 165 200 0
+17 -69 -157 0
+83 168 182 0
+18 76 98 0
+16 28 52 0
+60 73 135 0
+-151 161 181 0
+43 133 171 0
+64 88 118 0
+-85 183 0
+87 165 -169 0
+25 116 144 0
+-22 48 174 0
+56 -68 104 0
+6 -123 188 0
+-53 -121 -134 0
+5 -6 61 0
+13 96 -157 0
+37 106 -108 0
+45 -77 89 0
+2 -145 181 0
+76 -113 170 0
+-45 54 -167 0
+45 -75 -200 0
+10 70 142 0
+85 92 146 0
+37 104 133 0
+-16 -140 188 0
+84 -160 195 0
+-57 82 187 0
+-113 -129 172 0
+19 -75 -148 0
+4 35 131 0
+-64 -154 -197 0
+83 146 -186 0
+47 -143 158 0
+-2 52 85 0
+1 87 154 0
+19 -140 144 0
+117 -134 -144 0
+155 -168 197 0
+109 -133 137 0
+-122 -129 154 0
+-62 69 75 0
+-2 73 -186 0
+51 102 194 0
+6 -155 -195 0
+39 -82 -119 0
+4 179 -183 0
+-59 92 -121 0
+29 46 128 0
+82 -82 84 0
+-77 178 184 0
+18 137 171 0
+-59 69 86 0
+85 98 153 0
+-45 136 144 0
+15 30 111 0
+14 52 -105 0
+88 134 186 0
+-25 30 48 0
+-46 134 -164 0
+-39 75 131 0
+89 130 184 0
+-34 -126 163 0
+27 -94 194 0
+17 32 130 0
+-130 159 186 0
+27 -34 -143 0
+9 81 -183 0
+14 -55 82 0
+-144 -148 197 0
+79 90 -120 0
+11 23 79 0
+49 89 147 0
+-46 -81 -130 0
+39 -70 -145 0
+111 128 180 0
+9 32 -76 0
+-19 32 110 0
+16 -39 97 0
+39 -76 136 0
+49 128 -150 0
+-9 13 136 0
+-25 -62 81 0
+36 75 81 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-200-3_4-yes1-2.cnf b/test/resources/BenchmarkSat/aim-200-3_4-yes1-2.cnf
new file mode 100644
index 0000000..b1f7a13
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-200-3_4-yes1-2.cnf
@@ -0,0 +1,691 @@
+c FILE: aim-200-3_4-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 200 680
+138 149 150 0
+43 149 150 0
+43 67 -150 0
+54 -67 -150 0
+-67 149 -150 0
+-43 79 149 0
+79 -149 182 0
+-79 109 140 0
+-79 109 -140 0
+23 40 106 0
+23 134 161 0
+23 -106 -134 0
+-10 -106 194 0
+40 152 -194 0
+-10 40 -194 0
+-23 40 161 0
+40 -79 -161 0
+-40 -79 182 0
+110 119 -190 0
+-110 119 -190 0
+73 147 -190 0
+109 -119 -147 0
+-119 -134 -147 0
+96 -109 -119 0
+-96 -147 -190 0
+-73 -182 -190 0
+18 170 180 0
+18 -180 190 0
+29 -170 182 0
+100 -170 -182 0
+-100 -170 197 0
+-29 -170 197 0
+132 190 197 0
+-18 -132 190 0
+148 190 -197 0
+105 141 196 0
+130 196 -197 0
+21 -130 177 0
+21 -141 -177 0
+-21 -130 196 0
+-105 -182 196 0
+-48 66 -196 0
+-48 -66 -196 0
+-57 176 -182 0
+-57 151 -176 0
+-151 -182 -196 0
+-25 -148 -196 0
+-10 39 57 0
+-10 48 57 0
+3 9 48 0
+9 48 -164 0
+-3 9 153 0
+-3 9 -153 0
+-9 20 61 0
+10 -61 179 0
+10 96 -179 0
+-43 96 -179 0
+-9 10 20 0
+57 96 147 0
+57 96 -147 0
+-9 12 -23 0
+-9 -12 -23 0
+-9 -12 -161 0
+14 25 50 0
+25 50 -96 0
+130 133 156 0
+-96 130 -133 0
+-96 -130 156 0
+91 -101 152 0
+-152 156 172 0
+91 -152 -172 0
+60 -91 -101 0
+-91 -101 156 0
+-57 -91 -101 0
+-20 142 167 0
+-20 -142 167 0
+10 -20 174 0
+-10 -20 174 0
+-50 -91 108 0
+-50 -108 -167 0
+-50 80 -156 0
+38 104 155 0
+-38 155 -156 0
+1 155 -156 0
+68 155 -156 0
+-68 -104 155 0
+41 101 -167 0
+43 64 -174 0
+148 -174 198 0
+148 -174 -198 0
+-104 138 148 0
+-64 127 138 0
+41 -64 -127 0
+15 161 -174 0
+41 -138 -161 0
+-15 41 94 0
+-15 -94 -138 0
+5 77 -167 0
+30 56 -77 0
+-56 -77 169 0
+5 30 -77 0
+5 -30 -77 0
+-5 41 -167 0
+-40 54 109 0
+-40 91 -109 0
+-40 69 91 0
+-40 -54 -69 0
+110 -155 198 0
+95 -155 198 0
+-95 -155 198 0
+-155 -174 198 0
+-41 -80 192 0
+-94 105 -198 0
+-94 -105 -198 0
+94 143 -192 0
+51 -143 -198 0
+-12 42 -143 0
+-12 -42 -192 0
+-51 -82 -143 0
+64 141 153 0
+64 94 141 0
+-51 94 -141 0
+12 18 -143 0
+-51 82 -166 0
+60 -64 138 0
+60 -64 -138 0
+-64 82 -145 0
+-60 67 70 0
+46 -60 200 0
+-46 -60 -67 0
+53 70 -148 0
+-18 -60 146 0
+-18 70 -146 0
+-38 145 151 0
+117 145 -151 0
+-108 -151 166 0
+-117 127 166 0
+-38 -117 -127 0
+-39 -60 166 0
+38 39 174 0
+38 131 -174 0
+-70 -124 145 0
+-121 124 -131 0
+81 124 -157 0
+-81 124 -157 0
+5 31 121 0
+5 -31 124 0
+39 -56 172 0
+-56 158 -172 0
+39 -56 -158 0
+56 -118 121 0
+118 137 157 0
+118 144 157 0
+118 148 157 0
+-35 118 -148 0
+16 35 144 0
+-5 -16 144 0
+-49 137 199 0
+-49 56 -137 0
+-5 -49 -199 0
+56 83 -199 0
+21 -32 -83 0
+-21 -49 127 0
+-5 -32 -49 0
+-5 49 69 0
+-95 105 -144 0
+36 -95 -144 0
+-36 -144 148 0
+-95 -144 -148 0
+-69 83 118 0
+82 95 188 0
+55 -82 188 0
+-55 -83 188 0
+-15 95 137 0
+-15 -83 -137 0
+48 -168 186 0
+-15 -48 -83 0
+15 -108 -188 0
+12 15 153 0
+-153 166 182 0
+12 -153 -166 0
+-12 15 159 0
+15 159 -182 0
+108 119 176 0
+4 63 119 0
+-4 63 119 0
+8 -63 -159 0
+-8 -63 -176 0
+-39 -63 -176 0
+-36 78 -188 0
+-36 -78 -119 0
+-81 158 169 0
+36 130 -169 0
+36 -81 -130 0
+-81 122 -158 0
+108 -122 146 0
+-81 108 -146 0
+36 -86 108 0
+133 188 189 0
+-119 -188 189 0
+133 -183 189 0
+81 87 189 0
+81 -87 -133 0
+36 137 -159 0
+125 -141 -189 0
+-125 -141 -189 0
+81 147 -189 0
+-147 175 -180 0
+-175 -180 -189 0
+114 141 -189 0
+45 -90 180 0
+-45 -137 180 0
+51 -86 90 0
+-51 -86 90 0
+61 85 90 0
+75 -85 -114 0
+22 -75 -114 0
+-22 -85 90 0
+-90 169 200 0
+34 61 73 0
+-34 73 -200 0
+-73 90 -114 0
+61 -169 181 0
+56 -169 -181 0
+-56 -114 -181 0
+97 180 186 0
+97 -186 188 0
+97 -186 -188 0
+86 109 -114 0
+-98 104 135 0
+-98 104 -135 0
+-61 -98 -104 0
+89 143 162 0
+85 89 -143 0
+86 89 162 0
+13 86 -109 0
+-13 86 89 0
+89 -90 103 0
+47 -103 -162 0
+-47 -90 -103 0
+-4 86 98 0
+-4 -86 -97 0
+17 -97 120 0
+17 98 -120 0
+4 79 -85 0
+4 10 -85 0
+4 -85 -109 0
+60 -89 -185 0
+-17 26 -60 0
+46 146 -185 0
+38 -89 -185 0
+46 -89 -185 0
+-89 153 182 0
+-17 -46 -153 0
+-46 51 -182 0
+-46 -51 -185 0
+-66 85 -89 0
+4 -17 179 0
+85 132 162 0
+127 -132 162 0
+101 -127 -132 0
+85 -127 -132 0
+139 -162 185 0
+-25 -162 185 0
+64 -68 -162 0
+-68 -179 192 0
+-68 -179 -192 0
+66 68 -199 0
+68 122 -139 0
+68 -139 -151 0
+68 -111 151 0
+-122 136 199 0
+14 -122 151 0
+-22 -136 159 0
+20 -22 152 0
+-104 111 -159 0
+111 -157 -159 0
+-88 111 -157 0
+20 -111 -136 0
+-20 44 69 0
+32 -44 76 0
+-32 69 76 0
+-14 -44 -76 0
+-22 -69 152 0
+2 110 -136 0
+2 110 -166 0
+2 65 -110 0
+-65 -110 -136 0
+-2 -22 -136 0
+33 111 -136 0
+24 -33 111 0
+27 -33 171 0
+22 27 -33 0
+-27 48 -54 0
+-27 -48 64 0
+-14 -27 123 0
+-14 -48 -123 0
+54 113 131 0
+14 22 168 0
+14 22 113 0
+-14 22 113 0
+-113 135 -168 0
+-113 135 -183 0
+-24 126 144 0
+-113 -144 -168 0
+-24 -126 -135 0
+-57 -126 163 0
+-57 -163 -168 0
+-24 54 -62 0
+-24 -62 -86 0
+13 37 168 0
+-13 37 -113 0
+19 62 74 0
+16 75 -87 0
+-19 -75 -87 0
+-19 -87 142 0
+-37 42 162 0
+-37 62 -142 0
+-42 62 -142 0
+-2 -37 74 0
+-37 -74 -87 0
+62 -71 87 0
+47 161 168 0
+26 39 168 0
+-39 168 195 0
+26 -39 -195 0
+-26 27 113 0
+-26 -27 113 0
+-26 -27 -187 0
+-37 47 -113 0
+-47 87 -134 0
+71 -133 134 0
+30 -133 134 0
+-30 -133 -198 0
+-99 134 196 0
+-99 186 -196 0
+-99 115 -186 0
+71 -115 134 0
+-72 -99 199 0
+-72 -99 -199 0
+-47 99 -116 0
+-32 116 133 0
+-67 99 116 0
+32 -73 133 0
+32 -35 -73 0
+53 58 67 0
+32 -53 58 0
+77 95 120 0
+77 95 -120 0
+39 77 -95 0
+-39 67 77 0
+-58 73 112 0
+-58 -69 112 0
+-58 73 -170 0
+63 170 171 0
+-77 165 170 0
+-63 -140 -165 0
+7 105 -171 0
+-7 -171 199 0
+-105 -140 199 0
+-140 170 -199 0
+-45 -58 170 0
+84 -112 189 0
+84 -112 -169 0
+-112 -169 183 0
+-84 -112 -183 0
+45 -112 127 0
+-127 -135 140 0
+112 169 184 0
+135 169 184 0
+3 26 -184 0
+-3 26 -184 0
+-26 135 -163 0
+-84 -163 167 0
+45 -163 -167 0
+-45 -84 -163 0
+72 93 156 0
+72 -93 163 0
+-23 -93 163 0
+72 -156 163 0
+30 41 163 0
+-41 76 100 0
+-41 76 -100 0
+30 -41 -76 0
+-79 115 -184 0
+-72 -115 -184 0
+106 129 179 0
+106 -129 183 0
+-129 179 -183 0
+-30 32 106 0
+-32 106 -179 0
+29 -30 173 0
+29 -30 -173 0
+-72 142 176 0
+67 121 176 0
+-29 -67 121 0
+-29 -72 -121 0
+-7 31 79 0
+-31 165 -176 0
+-31 -165 -176 0
+7 -106 153 0
+18 -106 154 0
+18 -109 154 0
+-29 44 154 0
+1 -106 154 0
+-1 -18 154 0
+-154 -176 -186 0
+-28 -154 -186 0
+7 -29 -164 0
+92 164 173 0
+11 60 164 0
+11 -19 164 0
+-11 -19 -173 0
+-19 38 -92 0
+-38 -92 164 0
+-132 -153 186 0
+19 116 179 0
+-1 19 116 0
+-1 -116 132 0
+19 110 186 0
+59 84 -110 0
+59 -84 -110 0
+1 11 -120 0
+-11 19 -120 0
+120 132 146 0
+1 120 -187 0
+2 -59 166 0
+2 -59 -166 0
+-2 -46 -59 0
+44 -88 -146 0
+-44 -146 187 0
+-18 -88 187 0
+-44 88 187 0
+-44 88 -116 0
+-2 29 117 0
+-2 117 -146 0
+-108 117 122 0
+-108 -122 -146 0
+46 -117 -130 0
+-3 46 130 0
+25 44 -183 0
+-25 59 88 0
+-25 -59 -183 0
+44 -63 183 0
+63 123 183 0
+3 6 -123 0
+6 -123 -131 0
+-6 51 -181 0
+34 -51 -181 0
+3 -34 -181 0
+-6 43 181 0
+-43 152 181 0
+-6 -11 151 0
+-6 -11 63 0
+-6 -11 -134 0
+13 118 -123 0
+13 -118 -123 0
+1 -150 181 0
+-1 -150 181 0
+121 -128 200 0
+-128 150 -200 0
+139 -149 150 0
+-128 -129 139 0
+-121 -128 139 0
+47 -139 -152 0
+-47 -128 -139 0
+11 47 -194 0
+-13 -47 -194 0
+11 -41 -194 0
+-13 -90 -194 0
+107 145 -152 0
+99 107 -145 0
+107 -145 -152 0
+128 150 165 0
+-13 -107 171 0
+-13 -164 171 0
+70 -107 -171 0
+-70 -101 -171 0
+71 124 158 0
+-124 128 180 0
+-124 158 -180 0
+35 98 144 0
+-71 98 194 0
+-71 98 158 0
+-71 -98 194 0
+35 128 167 0
+35 -54 128 0
+35 128 -168 0
+-35 53 137 0
+26 -54 -137 0
+-26 -35 -137 0
+-53 141 194 0
+-35 -53 -141 0
+-34 101 -165 0
+-107 -165 197 0
+129 131 -197 0
+129 -131 187 0
+-165 -187 -197 0
+33 -107 -129 0
+-33 -107 149 0
+17 101 -102 0
+-17 93 -102 0
+-93 -102 -149 0
+-61 -102 115 0
+101 -102 -115 0
+34 66 -115 0
+-66 -158 174 0
+34 -66 -158 0
+34 -115 -158 0
+131 -160 191 0
+9 -160 191 0
+83 -160 164 0
+83 -164 191 0
+-34 83 -164 0
+-83 -131 -160 0
+115 -160 -191 0
+-65 115 160 0
+102 103 191 0
+50 70 102 0
+50 -70 72 0
+-50 72 120 0
+-50 102 -120 0
+102 -103 -149 0
+-149 -188 191 0
+102 -191 -195 0
+74 -191 195 0
+-23 -74 160 0
+65 173 194 0
+23 65 173 0
+42 -74 88 0
+80 -88 195 0
+42 -80 135 0
+-80 -166 195 0
+87 157 192 0
+87 -135 -192 0
+-74 -87 157 0
+42 -135 -157 0
+23 129 -173 0
+-42 -53 -129 0
+-75 80 -173 0
+-75 -80 -173 0
+17 -52 160 0
+17 -42 -52 0
+-17 -52 75 0
+14 53 -142 0
+16 52 159 0
+-14 52 159 0
+53 -142 -159 0
+52 53 105 0
+-104 -105 142 0
+16 52 187 0
+52 78 -187 0
+75 -78 -187 0
+16 -52 75 0
+28 104 171 0
+-28 104 -105 0
+8 104 142 0
+-16 -31 125 0
+-8 -31 -125 0
+-16 184 200 0
+-16 -184 200 0
+-8 29 -103 0
+-8 195 197 0
+-8 -195 -200 0
+-29 -103 -197 0
+31 43 140 0
+31 -140 -171 0
+-43 61 97 0
+-61 103 178 0
+-61 97 103 0
+69 -97 -138 0
+94 -97 -138 0
+-69 -94 -97 0
+-8 78 103 0
+91 92 -200 0
+92 -128 -200 0
+74 -91 92 0
+-74 -91 92 0
+-43 138 -172 0
+-92 122 126 0
+-92 -122 126 0
+27 93 172 0
+78 93 172 0
+-78 93 -126 0
+21 -78 100 0
+21 -78 -100 0
+-21 -84 172 0
+84 -126 -175 0
+-92 -126 -175 0
+62 -93 176 0
+-93 161 175 0
+54 -62 175 0
+-54 -62 175 0
+-28 -161 193 0
+136 192 -193 0
+-21 -28 192 0
+-21 -28 -192 0
+71 131 190 0
+12 71 -193 0
+-12 -131 -193 0
+28 -71 -193 0
+7 -161 -193 0
+-7 178 -193 0
+-7 28 -178 0
+-55 88 193 0
+-55 66 -88 0
+-55 -66 173 0
+-55 84 193 0
+55 175 177 0
+-100 178 193 0
+-100 -178 193 0
+3 -177 178 0
+-1 55 -177 0
+116 -177 178 0
+-3 55 -116 0
+-125 -177 -178 0
+76 125 -178 0
+-68 79 -94 0
+-125 -134 -175 0
+37 125 -145 0
+-7 -16 123 0
+-36 -82 -121 0
+49 143 -191 0
+-82 -100 -152 0
+59 126 165 0
+25 -80 129 0
+-24 33 82 0
+-33 -53 66 0
+28 -76 167 0
+-45 55 -98 0
+33 183 184 0
+37 65 147 0
+-125 -155 177 0
+78 112 160 0
+31 107 139 0
+57 112 -191 0
+-118 -124 -195 0
+-42 -52 -154 0
+-36 -58 136 0
+-34 143 -195 0
+13 65 185 0
+-5 -45 -145 0
+-65 -82 132 0
+25 122 -124 0
+-65 81 146 0
+-25 -65 160 0
+27 -139 -190 0
+-38 99 -155 0
+19 50 99 0
+126 145 177 0
+45 -151 -175 0
+45 51 143 0
+-4 -117 177 0
+7 20 -154 0
+59 -76 -118 0
+58 107 136 0
+-25 -70 -180 0
+37 -96 -178 0
+58 -75 165 0
+-73 123 -148 0
+28 59 74 0
+8 117 -117 0
+24 100 -134 0
+96 114 -181 0
+-3 82 114 0
+-111 114 -116 0
+24 -162 -172 0
+6 80 125 0
+-111 -121 136 0
+49 -76 -108 0
+-4 80 140 0
+6 33 -157 0
+6 49 140 0
+49 -118 -154 0
+-62 -70 123 0
+100 -111 185 0
+8 147 185 0
+24 114 174 0
+8 24 184 0
+58 -59 -172 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-50-1_6-yes1-1.cnf b/test/resources/BenchmarkSat/aim-50-1_6-yes1-1.cnf
new file mode 100644
index 0000000..500dbc5
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-50-1_6-yes1-1.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-yes1-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 80
+5 28 41 0
+5 -28 41 0
+10 30 -41 0
+5 -10 -41 0
+-5 25 30 0
+-5 -25 30 0
+11 -30 -33 0
+-11 -30 -33 0
+7 -30 33 0
+-7 14 33 0
+-4 -7 -14 0
+4 -14 -29 0
+-1 -14 32 0
+-1 4 -32 0
+1 24 29 0
+1 -24 -34 0
+-6 -24 34 0
+6 -24 38 0
+6 -32 -38 0
+32 44 48 0
+-38 -44 48 0
+22 29 -48 0
+22 -29 32 0
+-22 -25 -48 0
+-22 25 40 0
+18 -22 -40 0
+-18 20 -40 0
+-18 28 -40 0
+-18 -28 39 0
+-28 35 -39 0
+-35 -39 43 0
+-35 -43 -50 0
+-43 -45 50 0
+31 45 50 0
+-31 -44 45 0
+-15 44 49 0
+-15 -31 -49 0
+15 -31 36 0
+15 23 -36 0
+-23 -36 46 0
+20 27 -46 0
+-20 -23 27 0
+-16 -27 -46 0
+16 26 -27 0
+16 17 -26 0
+2 13 -17 0
+2 -13 -26 0
+-5 -17 -26 0
+-2 -17 42 0
+-2 12 -13 0
+-2 -12 -42 0
+8 13 -42 0
+-8 -10 13 0
+3 -8 10 0
+-3 10 -37 0
+-3 10 -47 0
+10 19 47 0
+-12 -19 47 0
+12 -19 21 0
+9 -19 -21 0
+-9 -11 -21 0
+-9 11 -49 0
+11 41 49 0
+19 -32 37 0
+-1 39 -50 0
+8 17 40 0
+38 43 49 0
+23 42 -47 0
+-13 -29 37 0
+-34 37 -47 0
+-33 -37 50 0
+-6 14 34 0
+9 -20 -50 0
+35 36 38 0
+3 31 46 0
+7 -16 21 0
+-6 17 26 0
+23 24 46 0
+18 24 -45 0
+-4 -6 7 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-50-2_0-yes1-4.cnf b/test/resources/BenchmarkSat/aim-50-2_0-yes1-4.cnf
new file mode 100644
index 0000000..097158e
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-50-2_0-yes1-4.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-yes1-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 100
+4 37 -44 0
+-4 37 39 0
+-4 37 -39 0
+-37 40 -44 0
+-37 -40 -44 0
+13 31 44 0
+-13 31 44 0
+26 -31 44 0
+-2 -26 -31 0
+-26 -31 49 0
+5 -26 -49 0
+-5 -27 -49 0
+-5 -39 -49 0
+2 -5 43 0
+-2 39 43 0
+39 -43 48 0
+-15 -43 -48 0
+-34 -43 -48 0
+28 34 -48 0
+18 -28 34 0
+-18 -28 -36 0
+-18 24 -28 0
+-3 -18 -24 0
+3 -12 -24 0
+5 10 12 0
+10 12 -24 0
+-10 12 -20 0
+-10 20 25 0
+-10 -25 -35 0
+20 23 -25 0
+2 20 23 0
+-2 23 -39 0
+-19 -23 -25 0
+19 -23 47 0
+19 -20 47 0
+13 43 -47 0
+13 -23 -47 0
+-13 14 34 0
+14 17 -34 0
+14 -17 -34 0
+-13 22 -47 0
+-14 -22 29 0
+-21 -22 35 0
+-22 -29 -35 0
+-29 33 41 0
+1 33 -41 0
+-1 33 -41 0
+16 -29 -33 0
+-16 21 50 0
+27 -33 42 0
+27 -42 50 0
+-21 -27 50 0
+-11 -16 -33 0
+8 22 -50 0
+8 -16 -50 0
+-8 46 -50 0
+-6 -8 -46 0
+1 -8 -17 0
+-1 -17 -46 0
+6 42 45 0
+6 42 -46 0
+6 -37 -42 0
+15 17 45 0
+-15 17 45 0
+9 -42 -45 0
+-9 38 -45 0
+-7 -38 -45 0
+-1 -9 -38 0
+7 15 -30 0
+7 -30 -38 0
+7 30 -41 0
+10 30 -40 0
+30 -40 41 0
+-4 15 40 0
+-15 40 41 0
+4 -32 35 0
+4 21 -32 0
+-21 -32 -35 0
+-30 35 46 0
+21 22 46 0
+-11 26 28 0
+29 -36 49 0
+5 18 36 0
+-7 9 49 0
+19 36 48 0
+-3 -14 16 0
+24 31 32 0
+2 24 32 0
+3 38 48 0
+-7 8 16 0
+1 -11 -19 0
+11 29 36 0
+3 -14 25 0
+-3 38 47 0
+-6 9 -12 0
+11 26 0
+-12 25 28 0
+18 -19 -36 0
+-6 -9 27 0
+-20 -27 32 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-50-3_4-yes1-2.cnf b/test/resources/BenchmarkSat/aim-50-3_4-yes1-2.cnf
new file mode 100644
index 0000000..fa1e433
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-50-3_4-yes1-2.cnf
@@ -0,0 +1,181 @@
+c FILE: aim-50-3_4-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 170
+17 19 38 0
+19 -38 44 0
+15 -19 36 0
+15 -36 39 0
+11 -36 -39 0
+-15 -19 44 0
+1 17 23 0
+-1 42 -44 0
+23 -42 -44 0
+11 17 -23 0
+11 -17 20 0
+-17 20 -28 0
+14 -17 -20 0
+7 -11 21 0
+-7 14 21 0
+-11 14 -21 0
+-14 24 -31 0
+-24 -31 42 0
+-24 -31 -42 0
+31 33 45 0
+-33 45 46 0
+31 -33 45 0
+-2 -45 47 0
+-2 -14 28 0
+-2 25 -47 0
+-14 -25 -47 0
+31 -45 46 0
+17 -18 19 0
+-17 -18 30 0
+-18 30 -45 0
+-18 -30 -45 0
+1 -46 49 0
+1 -8 49 0
+36 -46 -49 0
+13 -46 49 0
+9 13 -49 0
+9 -13 50 0
+-1 -46 -50 0
+9 26 -36 0
+2 9 -26 0
+-9 11 -45 0
+2 18 34 0
+18 -34 40 0
+-9 19 -34 0
+-11 -22 -40 0
+4 16 43 0
+10 35 -43 0
+-10 16 -43 0
+-4 16 35 0
+-11 21 35 0
+-21 22 35 0
+22 40 46 0
+22 36 -46 0
+-35 36 -40 0
+-19 28 50 0
+2 -28 42 0
+2 -19 -42 0
+-2 -40 50 0
+-19 26 -50 0
+6 22 39 0
+-6 28 39 0
+3 5 39 0
+-3 5 36 0
+-3 12 -36 0
+-3 -12 -35 0
+-5 -28 29 0
+-5 22 -29 0
+-5 -22 -35 0
+-36 49 -50 0
+-10 -39 -49 0
+-24 -26 27 0
+10 -24 -26 0
+14 -28 -39 0
+24 -28 -39 0
+7 24 38 0
+24 38 -49 0
+6 15 37 0
+23 33 37 0
+15 -23 33 0
+24 -33 37 0
+10 15 -37 0
+10 -37 -39 0
+-1 10 -37 0
+-15 20 28 0
+-15 -20 41 0
+-12 -20 49 0
+-15 23 41 0
+-23 41 -49 0
+10 -17 -38 0
+-41 -47 48 0
+-41 -47 -48 0
+28 -44 -47 0
+-15 -33 -38 0
+6 14 30 0
+6 -14 30 0
+-30 -37 -41 0
+-6 -37 47 0
+17 23 33 0
+14 -27 35 0
+-14 -27 31 0
+-27 -35 40 0
+-35 -40 50 0
+-27 31 -50 0
+7 -31 47 0
+4 7 -48 0
+-4 7 37 0
+-7 -31 47 0
+33 -42 47 0
+-23 -42 -47 0
+-5 42 50 0
+-5 -23 -50 0
+-13 37 42 0
+13 27 48 0
+13 -25 48 0
+5 8 20 0
+8 11 32 0
+8 -11 16 0
+8 -16 32 0
+5 8 -32 0
+5 26 29 0
+-26 29 38 0
+29 34 -38 0
+29 -34 -48 0
+-12 -29 -48 0
+-29 34 39 0
+-29 34 44 0
+12 -29 44 0
+2 -8 30 0
+-2 -8 -44 0
+12 -25 48 0
+12 -30 48 0
+-25 27 -44 0
+12 -25 -48 0
+25 -30 -43 0
+-1 9 12 0
+-1 -9 -30 0
+-4 41 43 0
+-4 -41 43 0
+-4 -12 -41 0
+4 25 44 0
+4 7 25 0
+1 6 32 0
+-7 13 32 0
+-6 -7 -13 0
+1 -6 32 0
+-7 38 43 0
+16 -38 43 0
+-16 20 -32 0
+-20 21 27 0
+21 27 -47 0
+-16 18 34 0
+-16 18 -27 0
+-16 -18 -20 0
+-3 4 -21 0
+-3 4 -40 0
+3 -6 -21 0
+-32 41 45 0
+-8 -34 46 0
+-8 -9 26 0
+-32 -34 40 0
+-13 25 26 0
+-10 18 -43 0
+-10 19 -26 0
+-12 -24 -30 0
+-22 26 40 0
+-9 -32 46 0
+-21 -22 -43 0
+3 -13 45 0
+3 -10 -22 0
+3 -33 45 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkSat/aim-50-6_0-yes1-4.cnf b/test/resources/BenchmarkSat/aim-50-6_0-yes1-4.cnf
new file mode 100644
index 0000000..c48a91d
--- /dev/null
+++ b/test/resources/BenchmarkSat/aim-50-6_0-yes1-4.cnf
@@ -0,0 +1,311 @@
+c FILE: aim-50-6_0-yes1-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 300
+1 21 24 0
+-1 7 11 0
+5 -11 48 0
+5 7 -11 0
+5 21 34 0
+-5 24 34 0
+-24 34 42 0
+21 -24 -42 0
+16 17 42 0
+16 -17 42 0
+15 31 42 0
+15 -16 -31 0
+15 -34 39 0
+38 -39 41 0
+-34 -38 -39 0
+15 40 -41 0
+15 -40 -41 0
+21 45 50 0
+21 -34 -45 0
+-15 28 37 0
+-15 21 -50 0
+-15 21 -30 0
+-28 -34 -50 0
+9 -19 50 0
+16 -19 -50 0
+9 -16 50 0
+9 -21 -50 0
+-19 -21 32 0
+4 -19 -21 0
+-4 -19 -21 0
+17 23 -32 0
+17 -23 -28 0
+6 9 26 0
+9 -17 26 0
+-9 24 26 0
+12 22 24 0
+12 -22 39 0
+12 -22 24 0
+7 24 38 0
+-7 -19 38 0
+-19 24 -26 0
+1 -21 -24 0
+-1 -21 -24 0
+19 24 -41 0
+19 -24 44 0
+19 -41 -44 0
+11 19 20 0
+-11 19 20 0
+-12 19 20 0
+14 -20 41 0
+-14 15 41 0
+22 27 -45 0
+-20 -22 27 0
+1 -20 -45 0
+-1 -20 -27 0
+6 19 41 0
+9 31 33 0
+-2 27 -31 0
+-2 9 -31 0
+-2 -9 38 0
+-2 -6 -38 0
+1 -2 -33 0
+-1 -2 -33 0
+-15 36 50 0
+4 6 31 0
+-6 31 -50 0
+4 -6 36 0
+-15 -36 48 0
+-4 -15 50 0
+5 -6 50 0
+-4 5 -48 0
+-5 -6 -48 0
+30 38 42 0
+-5 30 -38 0
+10 30 -42 0
+30 -48 50 0
+-6 18 -48 0
+6 18 -48 0
+-6 18 -37 0
+-6 -18 50 0
+5 10 25 0
+2 5 -25 0
+2 -5 10 0
+-20 23 39 0
+2 -23 37 0
+-23 30 37 0
+-23 37 39 0
+-20 37 39 0
+4 -10 42 0
+4 37 -42 0
+-4 -10 18 0
+-4 -14 18 0
+-20 -23 -39 0
+-10 -18 37 0
+32 38 41 0
+-32 38 -50 0
+3 32 -37 0
+-2 -17 -37 0
+30 39 47 0
+-3 14 47 0
+-14 -24 47 0
+29 -37 43 0
+-3 43 47 0
+-3 -39 -43 0
+2 -3 -47 0
+-3 -32 -47 0
+2 -37 -47 0
+2 -17 48 0
+2 26 -32 0
+5 -32 -48 0
+-26 -32 -48 0
+-30 34 44 0
+-17 -30 -44 0
+24 -30 -34 0
+6 -24 -30 0
+2 -24 -30 0
+-10 -30 -34 0
+3 37 45 0
+3 -37 45 0
+-3 4 45 0
+-3 42 45 0
+-3 30 45 0
+-10 17 -25 0
+8 -37 43 0
+-8 -37 43 0
+20 23 -50 0
+23 33 -50 0
+28 -33 43 0
+28 -33 -43 0
+8 -28 -38 0
+8 -38 -45 0
+-8 23 -28 0
+-8 -21 -28 0
+17 25 29 0
+31 -38 40 0
+9 31 -40 0
+-9 31 -40 0
+-18 31 -40 0
+22 25 -43 0
+17 -38 44 0
+-29 -31 32 0
+17 -29 -48 0
+-17 -31 35 0
+-29 -31 -35 0
+25 -29 -47 0
+25 -39 -47 0
+6 -29 -44 0
+-6 32 -44 0
+-29 38 -44 0
+-25 -29 -38 0
+-8 27 47 0
+-8 -27 44 0
+-8 -22 -44 0
+7 8 41 0
+7 -41 48 0
+13 27 45 0
+-7 -13 45 0
+-7 15 -45 0
+-7 27 -31 0
+-7 16 28 0
+-7 10 28 0
+-7 -28 -31 0
+9 -10 -31 0
+8 10 -33 0
+10 25 -40 0
+-25 -33 -40 0
+-10 25 -33 0
+8 -33 48 0
+8 -25 -48 0
+23 33 48 0
+22 33 48 0
+12 -22 33 0
+12 -13 14 0
+-12 14 39 0
+-13 -14 39 0
+6 -13 49 0
+-13 19 49 0
+21 30 -49 0
+-13 -21 -49 0
+-9 -39 -49 0
+4 46 -49 0
+-4 22 46 0
+-4 -22 37 0
+-4 -13 -37 0
+-39 -46 -49 0
+12 -13 41 0
+12 -13 -41 0
+-19 33 41 0
+-19 33 -41 0
+-9 26 -27 0
+2 16 -26 0
+14 16 -44 0
+-14 16 -26 0
+-2 16 -26 0
+-11 -12 13 0
+-11 13 -14 0
+3 22 25 0
+22 -27 34 0
+-25 -27 -34 0
+3 -22 -27 0
+1 11 12 0
+11 -17 19 0
+1 11 -17 0
+1 -9 -11 0
+-1 -9 32 0
+7 -9 12 0
+-7 -9 32 0
+-12 -27 32 0
+16 26 44 0
+11 -16 30 0
+11 -16 44 0
+-15 -16 44 0
+11 13 26 0
+-12 44 45 0
+43 44 -45 0
+-21 43 -45 0
+-12 -43 -45 0
+41 42 -44 0
+-12 17 -41 0
+-12 -17 -41 0
+-16 -28 47 0
+-16 -28 -47 0
+-28 -29 -42 0
+-1 -16 25 0
+-25 43 50 0
+-25 43 -50 0
+-1 27 -43 0
+-25 36 -43 0
+13 -36 -43 0
+-27 -36 -43 0
+1 10 18 0
+10 -42 47 0
+-1 10 -47 0
+-10 -16 18 0
+28 40 47 0
+7 27 48 0
+3 27 40 0
+3 40 -45 0
+3 7 -27 0
+3 40 -47 0
+-23 40 47 0
+-23 -26 -47 0
+-3 -26 40 0
+28 42 -46 0
+28 -42 -46 0
+-30 38 -46 0
+-18 -38 -46 0
+-14 -18 -46 0
+1 -5 46 0
+-5 -12 46 0
+-1 -5 46 0
+13 23 32 0
+13 15 23 0
+13 33 -49 0
+-2 13 -49 0
+23 -32 -42 0
+34 -42 -46 0
+-23 29 -32 0
+15 -23 -29 0
+-15 -32 -49 0
+28 -34 -42 0
+7 29 -35 0
+-7 29 -35 0
+29 31 -35 0
+20 -35 46 0
+-20 -35 46 0
+-18 33 -39 0
+-18 -33 34 0
+-18 -34 46 0
+4 39 46 0
+8 35 -36 0
+-8 35 -36 0
+11 22 36 0
+5 -11 22 0
+14 36 40 0
+18 36 -40 0
+-5 -18 36 0
+-5 14 -39 0
+14 -22 26 0
+14 -22 49 0
+-26 36 -49 0
+-4 -14 -24 0
+21 -30 48 0
+18 -20 -36 0
+6 -15 -46 0
+-10 20 29 0
+4 20 -44 0
+34 -35 -40 0
+35 36 -36 0
+29 -35 49 0
+-8 -36 0
+8 26 34 0
+-11 -14 49 0
+-8 -26 35 0
+-11 35 -43 0
+20 29 -40 0
+20 35 49 0
+17 -35 49 0
+35 -46 49 0
+6 35 49 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkUnsat/aim-100-1_6-no-1.cnf b/test/resources/BenchmarkUnsat/aim-100-1_6-no-1.cnf
new file mode 100644
index 0000000..0b72579
--- /dev/null
+++ b/test/resources/BenchmarkUnsat/aim-100-1_6-no-1.cnf
@@ -0,0 +1,171 @@
+c FILE: aim-100-1_6-no-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 100 160
+16 30 95 0
+-16 30 95 0
+-30 35 78 0
+-30 -78 85 0
+-78 -85 95 0
+8 55 100 0
+8 55 -95 0
+9 52 100 0
+9 73 -100 0
+-8 -9 52 0
+38 66 83 0
+-38 83 87 0
+-52 83 -87 0
+66 74 -83 0
+-52 -66 89 0
+-52 73 -89 0
+-52 73 -74 0
+-8 -73 -95 0
+40 -55 90 0
+-40 -55 90 0
+25 35 82 0
+-25 82 -90 0
+-55 -82 -90 0
+11 75 84 0
+11 -75 96 0
+23 -75 -96 0
+-11 23 -35 0
+-23 29 65 0
+29 -35 -65 0
+-23 -29 84 0
+-35 54 70 0
+-54 70 77 0
+19 -77 -84 0
+-19 -54 70 0
+22 68 81 0
+-22 48 81 0
+-22 -48 93 0
+3 -48 -93 0
+7 18 -81 0
+-7 56 -81 0
+3 18 -56 0
+-18 47 68 0
+-18 -47 -81 0
+-3 68 77 0
+-3 -77 -84 0
+19 -68 -70 0
+-19 -68 74 0
+-68 -70 -74 0
+54 61 -62 0
+50 53 -62 0
+-50 61 -62 0
+-27 56 93 0
+4 14 76 0
+4 -76 96 0
+-4 14 80 0
+-14 -68 80 0
+-10 -39 -89 0
+1 49 -81 0
+1 26 -49 0
+17 -26 -49 0
+-1 17 -40 0
+16 51 -89 0
+-9 57 60 0
+12 45 -51 0
+2 12 69 0
+2 -12 40 0
+-12 -51 69 0
+-33 60 -98 0
+5 -32 -66 0
+2 -47 -100 0
+-42 64 83 0
+20 -42 -64 0
+20 -48 98 0
+-20 50 98 0
+-32 -50 98 0
+-24 37 -73 0
+-24 -37 -100 0
+-57 71 81 0
+-37 40 -91 0
+31 42 81 0
+-31 42 72 0
+-31 42 -72 0
+7 -19 25 0
+-1 -25 -94 0
+-15 -44 79 0
+-6 31 46 0
+-39 41 88 0
+28 -39 43 0
+28 -43 -88 0
+-4 -28 -88 0
+-30 -39 -41 0
+-29 33 88 0
+-16 21 94 0
+-10 26 62 0
+-11 -64 86 0
+-6 -41 76 0
+38 -46 93 0
+26 -37 94 0
+-26 53 -79 0
+78 87 -94 0
+65 76 -87 0
+23 51 -62 0
+-11 -36 57 0
+41 59 -65 0
+-56 72 -91 0
+13 -20 -46 0
+-13 15 79 0
+-17 47 -60 0
+-13 -44 99 0
+-7 -38 67 0
+37 -49 62 0
+-14 -17 -79 0
+-13 -15 -22 0
+32 -33 -34 0
+24 45 48 0
+21 24 -48 0
+-36 64 -85 0
+10 -61 67 0
+-5 44 59 0
+-80 -85 -99 0
+6 37 -97 0
+-21 -34 64 0
+-5 44 46 0
+58 -76 97 0
+-21 -36 75 0
+-15 58 -59 0
+-58 -76 -99 0
+-2 15 33 0
+-26 34 -57 0
+-18 -82 -92 0
+27 -80 -97 0
+6 32 63 0
+-34 -86 92 0
+13 -61 97 0
+-28 43 -98 0
+5 39 -86 0
+39 -45 92 0
+27 -43 97 0
+13 -58 -86 0
+-28 -67 -93 0
+-69 85 99 0
+42 71 -72 0
+10 -27 -63 0
+-59 63 -83 0
+36 86 -96 0
+-2 36 75 0
+-59 -71 89 0
+36 -67 91 0
+36 -60 63 0
+-63 91 -93 0
+25 87 92 0
+-21 49 -71 0
+-2 10 22 0
+6 -18 41 0
+6 71 -92 0
+-53 -69 -71 0
+-2 -53 -58 0
+43 -45 -96 0
+34 -45 -69 0
+63 -86 -98 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkUnsat/aim-100-2_0-no-1.cnf b/test/resources/BenchmarkUnsat/aim-100-2_0-no-1.cnf
new file mode 100644
index 0000000..25a5e6a
--- /dev/null
+++ b/test/resources/BenchmarkUnsat/aim-100-2_0-no-1.cnf
@@ -0,0 +1,211 @@
+c FILE: aim-100-2_0-no-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 100 200
+6 55 66 0
+6 62 -66 0
+-62 -66 68 0
+6 8 -55 0
+8 58 70 0
+-6 58 -70 0
+-6 33 -58 0
+-6 8 -33 0
+-8 61 68 0
+-8 -61 68 0
+35 42 51 0
+30 -42 51 0
+30 -51 75 0
+20 -51 -75 0
+-20 -51 -75 0
+-30 35 -68 0
+34 -35 46 0
+-35 46 86 0
+-34 46 -68 0
+-35 -46 -68 0
+-31 42 91 0
+-7 20 85 0
+-20 -24 -42 0
+18 -85 91 0
+-18 -24 -31 0
+-24 -31 -91 0
+-17 32 60 0
+-17 39 -60 0
+36 50 56 0
+-50 56 91 0
+-44 52 -54 0
+-52 53 -54 0
+71 79 -97 0
+9 71 -79 0
+-8 34 -71 0
+34 -71 95 0
+-56 85 -95 0
+-71 -85 -95 0
+-18 -56 87 0
+-52 -56 87 0
+-7 -76 -93 0
+3 9 86 0
+3 -86 -96 0
+3 12 67 0
+-9 -40 67 0
+-9 13 -67 0
+-9 -67 -88 0
+-3 13 -96 0
+2 12 27 0
+-33 36 -74 0
+-13 -29 -41 0
+11 52 -98 0
+-50 90 92 0
+-26 -47 -77 0
+5 42 -93 0
+28 36 -42 0
+5 28 -36 0
+-28 45 -73 0
+5 -45 -73 0
+7 25 -86 0
+-25 37 -86 0
+19 -25 -37 0
+7 -19 41 0
+12 -34 -47 0
+-12 -34 -47 0
+-13 -60 93 0
+19 -94 98 0
+92 -94 -98 0
+67 -92 -98 0
+1 26 55 0
+26 -53 55 0
+18 -29 31 0
+-1 69 94 0
+23 69 -93 0
+-1 -23 69 0
+-19 29 43 0
+33 37 62 0
+-20 -33 62 0
+-18 39 65 0
+45 51 -53 0
+-1 11 -28 0
+18 33 84 0
+-14 -52 84 0
+7 -40 -53 0
+-7 -17 -40 0
+-19 65 72 0
+-63 77 -85 0
+27 -63 -77 0
+-4 64 94 0
+22 -82 99 0
+-11 41 -99 0
+-11 85 -99 0
+4 -65 -87 0
+17 37 100 0
+25 -37 100 0
+17 -25 -37 0
+83 -89 -100 0
+15 17 -89 0
+-15 -83 -100 0
+-39 -74 -90 0
+19 -26 40 0
+41 -70 -99 0
+-26 -41 -70 0
+-28 59 -62 0
+4 78 90 0
+4 21 78 0
+39 -49 63 0
+-39 -49 -95 0
+48 -54 65 0
+60 82 98 0
+49 -74 97 0
+-21 49 -97 0
+-79 87 -88 0
+21 45 -75 0
+16 -84 -89 0
+-21 -46 63 0
+14 16 -81 0
+-14 -81 -87 0
+-66 -67 -83 0
+-80 81 100 0
+2 -29 99 0
+-2 -39 99 0
+-44 -64 -90 0
+-13 14 23 0
+-10 -45 -91 0
+10 40 73 0
+40 -73 -76 0
+22 -76 78 0
+21 -32 -57 0
+-38 -64 86 0
+-12 -15 54 0
+-12 47 -69 0
+47 -69 -82 0
+-22 -23 32 0
+-22 -23 -78 0
+-10 20 -50 0
+-5 10 84 0
+23 -92 97 0
+-69 72 -78 0
+1 11 -80 0
+-2 27 50 0
+-57 -61 -79 0
+43 76 -90 0
+-22 -49 -92 0
+26 43 -60 0
+-10 50 98 0
+10 -30 59 0
+-55 -72 -100 0
+-41 53 -78 0
+38 -65 94 0
+38 -65 -94 0
+29 -55 61 0
+-46 -48 59 0
+53 73 90 0
+1 -11 74 0
+15 76 82 0
+-27 -82 -97 0
+-3 -36 -48 0
+28 -32 80 0
+9 -63 80 0
+70 73 89 0
+-80 -91 93 0
+22 -64 77 0
+66 72 -87 0
+-36 83 88 0
+24 -38 52 0
+-43 81 -96 0
+-59 -62 81 0
+48 66 71 0
+-2 48 63 0
+29 -83 93 0
+-16 25 -72 0
+-27 57 -84 0
+-5 77 88 0
+-5 -59 88 0
+15 44 -45 0
+13 -84 89 0
+47 -48 83 0
+-14 -44 54 0
+-30 31 64 0
+24 70 75 0
+-15 -32 92 0
+-16 -58 74 0
+-4 54 -77 0
+-43 57 60 0
+-16 61 64 0
+-59 79 95 0
+-4 -61 -88 0
+58 74 80 0
+49 -58 82 0
+16 44 -57 0
+2 89 95 0
+-3 -27 -81 0
+24 75 79 0
+44 96 97 0
+31 -38 57 0
+14 -43 -72 0
+38 76 96 0
+30 32 96 0
+-21 35 56 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkUnsat/aim-200-1_6-no-2.cnf b/test/resources/BenchmarkUnsat/aim-200-1_6-no-2.cnf
new file mode 100644
index 0000000..18539d9
--- /dev/null
+++ b/test/resources/BenchmarkUnsat/aim-200-1_6-no-2.cnf
@@ -0,0 +1,331 @@
+c FILE: aim-200-1_6-no-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 200 320
+61 69 128 0
+62 100 124 0
+62 108 162 0
+-108 -124 162 0
+-69 -124 -162 0
+61 -62 100 0
+61 -69 -100 0
+31 65 128 0
+31 -61 -65 0
+-31 -61 128 0
+6 82 -128 0
+6 -82 -128 0
+-70 140 146 0
+-70 140 -146 0
+66 78 -140 0
+29 125 137 0
+29 125 -137 0
+12 102 -125 0
+12 -102 106 0
+-12 -125 198 0
+-12 106 -125 0
+-29 159 193 0
+-29 159 -193 0
+50 131 -159 0
+82 -131 199 0
+82 -159 -199 0
+50 -82 -131 0
+64 112 133 0
+60 81 107 0
+99 -133 190 0
+81 99 -190 0
+81 -99 -107 0
+9 160 170 0
+-9 -81 160 0
+60 -160 170 0
+-81 -133 -170 0
+-60 64 -133 0
+-64 112 145 0
+-64 112 -145 0
+86 -112 144 0
+86 -112 -144 0
+-50 -86 -112 0
+55 98 -106 0
+55 -98 198 0
+109 197 -198 0
+32 134 -197 0
+32 109 -134 0
+-32 109 -197 0
+35 42 51 0
+-35 51 192 0
+-51 -109 192 0
+-51 -172 192 0
+42 -109 -192 0
+-42 57 -198 0
+-42 -57 -109 0
+14 46 91 0
+-14 91 98 0
+-14 91 -98 0
+46 49 -91 0
+-46 49 -55 0
+-49 -55 66 0
+17 23 -66 0
+-23 78 167 0
+-78 121 167 0
+-78 -121 167 0
+49 132 142 0
+-49 132 142 0
+89 -132 -167 0
+-89 -132 -167 0
+17 -23 -142 0
+-17 -140 163 0
+-17 -66 -163 0
+-6 33 68 0
+33 -68 165 0
+33 -68 -165 0
+-6 -33 107 0
+70 116 155 0
+5 20 184 0
+5 20 -184 0
+-5 122 156 0
+-5 122 -156 0
+-5 -116 -122 0
+-20 -116 172 0
+-20 155 -172 0
+70 -107 -155 0
+-37 -57 -119 0
+-65 117 -188 0
+21 -22 97 0
+-21 -22 97 0
+45 -122 181 0
+45 -122 -181 0
+-2 -76 -181 0
+43 -74 93 0
+14 -33 87 0
+-54 137 -145 0
+-9 -147 195 0
+88 -99 121 0
+-16 48 166 0
+126 169 -180 0
+126 136 -169 0
+-125 -126 -180 0
+-20 -176 -182 0
+71 119 175 0
+96 -147 -187 0
+-4 -21 103 0
+30 68 -164 0
+-53 -108 144 0
+24 67 -193 0
+56 120 -124 0
+104 -143 -150 0
+-67 104 -150 0
+-83 92 184 0
+-18 84 179 0
+1 36 127 0
+-79 116 190 0
+-54 -145 164 0
+1 158 -181 0
+157 161 170 0
+-77 156 -196 0
+-80 -174 -188 0
+-100 129 -187 0
+23 34 -153 0
+74 -97 179 0
+26 -39 -178 0
+11 23 69 0
+-3 -86 -177 0
+-53 101 127 0
+-111 113 163 0
+-34 94 -194 0
+-45 -154 -189 0
+-77 -95 -177 0
+67 92 104 0
+-15 -38 -130 0
+-58 131 -158 0
+129 169 171 0
+171 172 197 0
+-30 -48 200 0
+28 75 -151 0
+-2 -40 139 0
+-90 182 -200 0
+39 63 195 0
+21 68 111 0
+77 111 -200 0
+45 187 -189 0
+58 -123 -135 0
+-119 177 -179 0
+-87 146 -184 0
+7 124 168 0
+-58 -142 -169 0
+13 40 -111 0
+-46 120 -148 0
+30 -35 53 0
+-3 21 -40 0
+-89 181 193 0
+48 -106 -144 0
+57 87 89 0
+38 -79 110 0
+-83 -191 -199 0
+-118 153 -166 0
+-91 154 199 0
+24 123 -188 0
+-16 -95 186 0
+-13 83 -101 0
+-44 -63 74 0
+-117 -129 -157 0
+3 40 -179 0
+90 -103 -154 0
+-71 -88 135 0
+38 94 145 0
+-34 -59 -60 0
+-37 -46 117 0
+-56 -76 89 0
+15 -96 -195 0
+-31 -150 -173 0
+-58 -90 -148 0
+73 -161 186 0
+-46 -77 150 0
+-24 -84 188 0
+135 -163 174 0
+-28 -101 -118 0
+7 -28 -115 0
+68 79 185 0
+-13 -43 73 0
+47 -120 -139 0
+10 -63 172 0
+-60 -119 180 0
+72 103 -139 0
+-15 -129 173 0
+-16 110 136 0
+-9 65 157 0
+19 188 -191 0
+8 -75 -169 0
+39 -93 -141 0
+108 -154 -163 0
+-36 152 168 0
+25 37 52 0
+2 -121 -156 0
+-52 -154 -179 0
+-97 119 173 0
+56 90 186 0
+-10 -121 186 0
+3 -41 149 0
+44 -141 -143 0
+59 -74 -194 0
+16 -75 -170 0
+115 -135 -139 0
+27 95 -137 0
+27 -43 147 0
+4 -120 -185 0
+38 -136 183 0
+-94 -126 138 0
+2 16 -110 0
+8 -63 83 0
+-118 -171 -188 0
+-4 -27 84 0
+-96 166 -168 0
+41 -72 -178 0
+-7 25 -177 0
+4 -25 -67 0
+-62 140 -174 0
+39 -138 173 0
+-129 -173 -195 0
+-19 -105 172 0
+105 -158 -186 0
+13 114 -153 0
+19 28 189 0
+-88 134 191 0
+47 -47 -165 0
+-8 -43 113 0
+-45 -147 -152 0
+40 117 130 0
+85 -149 151 0
+-84 -104 -110 0
+-115 123 -158 0
+-18 35 101 0
+-11 72 -117 0
+-52 177 0
+-113 -151 -183 0
+-152 198 200 0
+41 43 -192 0
+-15 -76 -104 0
+-26 -59 143 0
+37 80 183 0
+-126 141 -187 0
+-87 114 -171 0
+-35 -73 -114 0
+-85 -92 -127 0
+-13 -176 178 0
+-8 10 158 0
+-87 133 161 0
+174 -175 -190 0
+18 -36 -157 0
+-27 -96 -182 0
+67 -162 -175 0
+-90 -134 152 0
+-25 -103 114 0
+108 -120 -148 0
+21 41 -41 0
+-44 -48 -141 0
+-50 52 138 0
+28 -121 176 0
+22 -127 -151 0
+63 80 -161 0
+30 -44 76 0
+10 -39 189 0
+52 76 130 0
+131 -157 -186 0
+22 94 -182 0
+-114 148 194 0
+-138 150 -166 0
+-29 141 -148 0
+-7 -92 -190 0
+-84 95 -136 0
+-25 149 175 0
+-94 -190 196 0
+-34 75 -185 0
+115 185 194 0
+18 19 -94 0
+-79 -113 176 0
+92 93 -93 0
+34 -73 118 0
+54 -105 164 0
+-85 -149 166 0
+-32 85 -160 0
+58 153 186 0
+-146 -177 191 0
+-100 -130 180 0
+9 -16 65 0
+11 -186 -187 0
+-3 -35 165 0
+-10 28 196 0
+-19 154 182 0
+58 -64 -94 0
+44 -104 -123 0
+-1 -47 -115 0
+-2 22 -80 0
+79 102 176 0
+-71 -86 -177 0
+-11 44 86 0
+-56 135 194 0
+-1 -95 -164 0
+139 178 -183 0
+-17 88 187 0
+-27 -43 -160 0
+34 71 -100 0
+15 -72 -168 0
+-102 143 191 0
+-26 54 148 0
+-24 71 -155 0
+-25 105 -196 0
+-1 80 152 0
+59 -117 156 0
+-38 53 151 0
+73 144 196 0
+77 147 188 0
+26 -30 -103 0
+-31 36 -117 0
+-94 118 -183 0
+12 -84 194 0
+96 145 186 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkUnsat/aim-50-1_6-no-1.cnf b/test/resources/BenchmarkUnsat/aim-50-1_6-no-1.cnf
new file mode 100644
index 0000000..0e30892
--- /dev/null
+++ b/test/resources/BenchmarkUnsat/aim-50-1_6-no-1.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-no-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 80
+16 23 42 0
+-16 23 42 0
+26 41 -42 0
+-26 41 -42 0
+32 -41 -42 0
+6 15 -41 0
+-6 15 -32 0
+1 -32 46 0
+-1 -32 46 0
+-15 -41 -46 0
+-15 -21 -46 0
+-23 33 38 0
+-23 -33 38 0
+8 22 33 0
+8 22 -33 0
+-22 37 -38 0
+13 36 -37 0
+13 -22 -36 0
+-13 -22 -37 0
+11 -23 47 0
+-8 11 -47 0
+-8 -11 39 0
+-11 27 -39 0
+-8 -11 -39 0
+-7 26 29 0
+-7 -26 29 0
+-13 20 36 0
+-13 17 20 0
+5 -17 20 0
+5 -19 -45 0
+-5 -10 -45 0
+6 25 47 0
+-6 -10 25 0
+-2 -27 37 0
+-27 -36 40 0
+18 39 -40 0
+-2 -19 31 0
+5 18 -30 0
+-31 -43 -50 0
+10 -30 43 0
+10 -41 43 0
+19 21 29 0
+37 42 45 0
+-20 27 40 0
+-21 -36 48 0
+31 -36 -48 0
+3 -9 -18 0
+16 -40 -47 0
+1 -18 21 0
+2 28 32 0
+-1 -24 -50 0
+-12 35 49 0
+-6 -36 45 0
+7 12 -43 0
+7 30 -43 0
+-5 9 -17 0
+3 14 50 0
+-12 17 -49 0
+24 34 49 0
+14 -20 24 0
+-9 35 -49 0
+-4 -47 50 0
+4 44 -44 0
+28 -28 -38 0
+2 4 -48 0
+-20 35 -44 0
+30 -31 -43 0
+-14 -29 35 0
+-20 35 -35 0
+19 -22 -24 0
+-25 -28 48 0
+-14 -34 44 0
+9 20 44 0
+-3 9 -29 0
+17 34 -34 0
+12 48 0
+-12 -25 -43 0
+-25 -31 48 0
+14 -16 49 0
+-3 -4 -35 0
\ No newline at end of file
diff --git a/test/resources/BenchmarkUnsat/aim-50-2_0-no-2.cnf b/test/resources/BenchmarkUnsat/aim-50-2_0-no-2.cnf
new file mode 100644
index 0000000..c82bd20
--- /dev/null
+++ b/test/resources/BenchmarkUnsat/aim-50-2_0-no-2.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-no-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 100
+4 21 34 0
+21 -34 40 0
+1 -21 40 0
+-21 39 40 0
+20 29 41 0
+-20 39 41 0
+39 -40 41 0
+-40 -41 42 0
+-40 -41 -42 0
+1 25 -39 0
+2 -25 -39 0
+-2 5 -39 0
+-1 4 5 0
+15 26 33 0
+15 26 -33 0
+-5 -15 26 0
+-5 -26 31 0
+-5 -26 -31 0
+6 9 47 0
+9 37 38 0
+9 14 -38 0
+-14 -38 -47 0
+-9 11 37 0
+-9 -11 37 0
+24 -37 48 0
+24 46 -48 0
+-24 -37 46 0
+16 18 -46 0
+-16 18 -46 0
+-18 -37 -46 0
+-4 -6 15 0
+-4 13 -15 0
+-4 -13 -15 0
+-1 -6 38 0
+3 -9 35 0
+7 43 44 0
+7 29 43 0
+-8 -29 44 0
+-29 -32 48 0
+-14 30 46 0
+-1 -14 -30 0
+-11 20 49 0
+20 -44 -49 0
+16 22 -27 0
+13 -19 -35 0
+2 19 -33 0
+2 19 -28 0
+33 -34 -44 0
+-33 -44 50 0
+5 30 -48 0
+10 22 -50 0
+-10 22 -34 0
+1 10 -47 0
+-10 -25 -47 0
+-25 -27 50 0
+11 21 23 0
+-3 11 23 0
+-3 6 -50 0
+-6 23 -50 0
+-31 -43 44 0
+-7 16 -26 0
+-23 28 -38 0
+19 28 50 0
+-18 45 49 0
+-2 -16 -48 0
+7 14 -42 0
+12 25 -36 0
+10 -24 -45 0
+-21 32 -42 0
+12 -18 -27 0
+-13 -23 -24 0
+25 29 38 0
+-8 43 -45 0
+-2 -12 13 0
+-7 14 30 0
+-8 -17 -19 0
+8 -22 49 0
+-12 -17 33 0
+27 -29 32 0
+8 -12 -13 0
+24 -31 47 0
+-3 36 47 0
+3 12 34 0
+-7 -16 36 0
+-22 31 48 0
+17 -22 -49 0
+-17 -19 32 0
+-20 27 36 0
+18 -32 -35 0
+3 -28 -30 0
+17 34 42 0
+-32 -43 -49 0
+17 -28 -43 0
+-23 35 -45 0
+-10 31 -36 0
+27 -41 42 0
+35 -36 45 0
+8 -30 45 0
+4 28 -35 0
+6 -11 -20 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-1_6-yes1-2.cnf b/test/resources/easySat/aim-50-1_6-yes1-2.cnf
new file mode 100644
index 0000000..2b33e50
--- /dev/null
+++ b/test/resources/easySat/aim-50-1_6-yes1-2.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 80
+1 7 28 0
+-1 7 28 0
+-7 13 35 0
+-7 -13 28 0
+-28 35 37 0
+-28 35 -37 0
+2 -35 43 0
+2 -35 -43 0
+-2 -35 38 0
+-2 9 -38 0
+-9 -24 -38 0
+-9 36 -38 0
+-21 -36 -38 0
+12 24 -36 0
+-12 21 31 0
+6 -12 -31 0
+-6 -31 42 0
+-6 33 -42 0
+-18 -33 -42 0
+4 18 -33 0
+-17 18 24 0
+-4 -17 -24 0
+-4 -16 17 0
+17 19 21 0
+-4 19 -21 0
+17 -19 -20 0
+-19 20 -49 0
+20 -47 49 0
+20 26 47 0
+20 25 -26 0
+14 -25 -26 0
+-14 16 44 0
+-16 -25 44 0
+-14 34 -44 0
+3 -34 -44 0
+-1 -3 -34 0
+-3 -34 41 0
+23 39 -41 0
+-3 23 -39 0
+-23 40 -41 0
+-15 -23 49 0
+-15 -40 -49 0
+15 -22 -40 0
+8 15 22 0
+-5 -8 22 0
+5 -8 30 0
+-8 29 -30 0
+-8 -13 -30 0
+5 -29 -37 0
+13 -32 37 0
+32 37 46 0
+32 39 -46 0
+10 -39 -46 0
+-10 27 -39 0
+-10 -27 48 0
+11 -27 -48 0
+-11 -48 50 0
+-11 -45 -50 0
+-28 45 -50 0
+-43 45 -50 0
+7 43 45 0
+10 11 26 0
+14 -47 48 0
+39 43 44 0
+8 27 42 0
+9 -20 38 0
+1 19 50 0
+6 31 36 0
+3 6 -45 0
+13 -22 31 0
+26 46 47 0
+5 12 40 0
+-18 25 33 0
+2 16 30 0
+4 -15 33 0
+25 29 40 0
+-18 36 43 0
+5 -5 -29 0
+-15 -32 41 0
+21 24 34 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-1_6-yes1-3.cnf b/test/resources/easySat/aim-50-1_6-yes1-3.cnf
new file mode 100644
index 0000000..ede7d8b
--- /dev/null
+++ b/test/resources/easySat/aim-50-1_6-yes1-3.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-yes1-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 80
+7 19 24 0
+7 -19 26 0
+7 24 -26 0
+7 22 -24 0
+-7 22 46 0
+-7 22 -46 0
+8 -22 -27 0
+-8 -22 -27 0
+-22 27 43 0
+9 27 -50 0
+-9 -43 -50 0
+38 -43 50 0
+34 -38 50 0
+-34 -38 -41 0
+-34 41 -46 0
+-17 -34 41 0
+-6 17 -34 0
+-4 6 17 0
+4 6 16 0
+4 -16 40 0
+-16 19 -40 0
+-16 29 -40 0
+-19 -29 45 0
+24 -29 -36 0
+-24 -36 -45 0
+7 36 -45 0
+-15 36 -45 0
+-2 15 36 0
+2 15 30 0
+2 -30 35 0
+-8 -30 -35 0
+8 -35 -47 0
+8 -28 47 0
+28 33 47 0
+28 -33 37 0
+-21 -33 -37 0
+-14 21 -37 0
+14 21 44 0
+-9 14 -44 0
+9 -13 -44 0
+13 31 -44 0
+13 -31 42 0
+-18 -31 -42 0
+-12 18 -42 0
+12 18 -48 0
+-1 12 18 0
+1 48 -49 0
+1 -32 49 0
+1 -11 49 0
+1 3 49 0
+5 11 44 0
+-3 5 11 0
+-3 -5 -20 0
+-5 20 -25 0
+-5 23 25 0
+-23 25 -39 0
+10 -23 25 0
+-10 -26 39 0
+-10 24 26 0
+-18 38 48 0
+31 35 39 0
+-36 38 0
+-2 -6 37 0
+34 -39 -47 0
+-2 3 -28 0
+-19 -20 42 0
+16 32 -49 0
+-25 -27 46 0
+-12 16 31 0
+-2 -4 43 0
+-1 23 32 0
+10 -17 40 0
+-21 34 45 0
+20 -21 30 0
+5 -13 33 0
+-15 -48 0
+-14 29 37 0
+3 -14 -47 0
+-11 35 37 0
+10 -32 -41 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-1_6-yes1-4.cnf b/test/resources/easySat/aim-50-1_6-yes1-4.cnf
new file mode 100644
index 0000000..1ccc070
--- /dev/null
+++ b/test/resources/easySat/aim-50-1_6-yes1-4.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-yes1-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 80
+16 17 30 0
+-17 22 30 0
+-17 -22 30 0
+16 -30 47 0
+16 -30 -47 0
+-16 -21 31 0
+-16 -21 -31 0
+-16 21 -28 0
+-13 21 28 0
+13 -16 18 0
+13 -18 -38 0
+13 -18 -31 0
+31 38 44 0
+-8 31 -44 0
+8 -12 -44 0
+8 12 -27 0
+12 27 40 0
+-4 27 -40 0
+12 23 -40 0
+-3 4 -23 0
+3 -23 -49 0
+3 -13 -49 0
+-23 -26 49 0
+12 -34 49 0
+-12 26 -34 0
+19 34 36 0
+-19 26 36 0
+-30 34 -36 0
+24 34 -36 0
+-24 -36 43 0
+6 42 -43 0
+-24 42 -43 0
+-5 -24 -42 0
+5 20 -42 0
+5 -7 -20 0
+4 7 10 0
+-4 10 -20 0
+7 -10 -41 0
+-10 41 46 0
+-33 41 -46 0
+33 -37 -46 0
+32 33 37 0
+6 -32 37 0
+-6 25 -32 0
+-6 -25 -48 0
+-9 28 48 0
+-9 -25 -28 0
+19 -25 48 0
+2 9 -19 0
+-2 -19 35 0
+-2 22 -35 0
+-22 -35 50 0
+-17 -35 -50 0
+-29 -35 -50 0
+-1 29 -50 0
+1 11 29 0
+-11 17 -45 0
+-11 39 45 0
+-26 39 45 0
+-3 -26 45 0
+-11 15 -39 0
+14 -15 -39 0
+14 -15 -45 0
+14 -15 -27 0
+-14 -15 47 0
+17 40 0
+1 -29 -31 0
+-7 32 38 0
+-14 -33 -47 0
+-1 2 -8 0
+35 43 44 0
+21 24 0
+20 29 -48 0
+23 35 -37 0
+2 18 -33 0
+15 25 -45 0
+9 14 -38 0
+-5 11 50 0
+-3 -13 46 0
+-13 -41 43 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-2_0-yes1-1.cnf b/test/resources/easySat/aim-50-2_0-yes1-1.cnf
new file mode 100644
index 0000000..50a0767
--- /dev/null
+++ b/test/resources/easySat/aim-50-2_0-yes1-1.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-yes1-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 100
+-9 17 50 0
+17 20 -50 0
+17 -20 -50 0
+-9 -17 39 0
+-9 -17 -39 0
+9 29 43 0
+9 -29 43 0
+9 10 -43 0
+-10 -27 -43 0
+4 -10 -43 0
+-4 -6 -10 0
+-4 11 -16 0
+6 -11 -16 0
+-4 6 26 0
+11 -26 39 0
+6 -11 39 0
+-26 32 38 0
+32 -38 -39 0
+12 -26 -32 0
+-12 25 -39 0
+-13 -25 -32 0
+7 -12 -25 0
+-7 28 49 0
+-7 -25 49 0
+-7 33 -49 0
+8 -33 -49 0
+1 -8 -49 0
+-1 -8 21 0
+-1 5 36 0
+-5 -8 36 0
+-1 -14 -36 0
+-21 -36 -50 0
+14 24 -36 0
+14 -24 -38 0
+-23 34 50 0
+-23 -24 -34 0
+23 -24 -34 0
+23 34 -42 0
+28 34 42 0
+-11 -28 42 0
+15 -28 42 0
+23 35 45 0
+-23 -28 45 0
+-15 -35 45 0
+-15 -17 -45 0
+12 -15 30 0
+-12 30 -45 0
+22 -30 -45 0
+-22 -30 -37 0
+-3 -22 -30 0
+3 -22 -47 0
+37 40 44 0
+-31 40 44 0
+4 13 37 0
+13 37 -40 0
+-13 33 -40 0
+-13 -33 44 0
+2 3 -44 0
+-2 -40 -44 0
+27 43 47 0
+-2 16 41 0
+-16 27 47 0
+-27 41 47 0
+41 -44 -47 0
+-18 38 -41 0
+-2 -18 -38 0
+40 -41 46 0
+-20 33 -46 0
+-20 -33 -41 0
+18 19 28 0
+14 18 19 0
+-14 18 19 0
+-5 -19 -46 0
+-5 -18 -46 0
+20 21 -35 0
+-19 20 -35 0
+3 35 -48 0
+-3 -19 -48 0
+29 35 48 0
+-29 31 38 0
+27 31 48 0
+-29 31 48 0
+4 12 16 0
+25 26 -42 0
+-6 13 -37 0
+11 25 -37 0
+8 16 -47 0
+1 15 -31 0
+1 10 -21 0
+-14 22 -42 0
+32 -32 36 0
+2 10 -21 0
+-3 5 8 0
+15 21 22 0
+5 7 29 0
+26 -27 50 0
+30 -31 -48 0
+7 -34 46 0
+-6 24 49 0
+2 24 46 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-2_0-yes1-2.cnf b/test/resources/easySat/aim-50-2_0-yes1-2.cnf
new file mode 100644
index 0000000..a345366
--- /dev/null
+++ b/test/resources/easySat/aim-50-2_0-yes1-2.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 100
+-7 17 29 0
+17 -29 43 0
+17 -29 -43 0
+4 15 -17 0
+-7 8 -15 0
+4 -8 -15 0
+-4 -7 -17 0
+3 7 41 0
+3 15 -41 0
+3 7 -41 0
+-3 7 -31 0
+-1 31 41 0
+-1 -3 31 0
+1 -3 28 0
+1 -8 -28 0
+1 25 -28 0
+14 -25 -28 0
+-14 30 43 0
+-25 -30 43 0
+14 -39 46 0
+-14 -39 46 0
+-25 -39 -46 0
+-5 -14 -43 0
+5 9 -43 0
+-4 5 -9 0
+-9 45 46 0
+5 45 -46 0
+-9 -20 -45 0
+2 31 -45 0
+2 20 -31 0
+-2 -17 -45 0
+-2 20 -24 0
+-2 -18 24 0
+18 24 -42 0
+24 42 -47 0
+13 18 -48 0
+-13 42 -48 0
+18 -44 -48 0
+-10 23 48 0
+-10 22 42 0
+-10 -22 -23 0
+10 -30 48 0
+2 21 22 0
+21 22 48 0
+10 21 -22 0
+-21 47 49 0
+34 38 49 0
+34 -38 -47 0
+10 -34 49 0
+-21 -41 -49 0
+-21 36 -49 0
+-33 -36 -49 0
+-19 33 -36 0
+13 25 37 0
+13 -36 37 0
+-13 33 37 0
+-15 33 -37 0
+15 32 -37 0
+11 -32 -37 0
+-11 -12 -32 0
+20 27 -32 0
+-20 25 27 0
+-11 -20 27 0
+-11 -22 -27 0
+6 30 47 0
+6 30 -47 0
+12 23 -30 0
+6 12 -23 0
+-27 -38 39 0
+-6 -27 -38 0
+-6 38 -44 0
+-5 38 -44 0
+-6 26 44 0
+-23 -26 44 0
+8 16 50 0
+8 -26 50 0
+-8 44 50 0
+-13 -26 -50 0
+19 23 -40 0
+-19 -40 41 0
+-19 -40 -50 0
+16 40 47 0
+16 40 -50 0
+-16 35 40 0
+-16 -35 -46 0
+4 -16 -34 0
+-4 -34 -35 0
+-29 34 -35 0
+-31 32 39 0
+11 -24 29 0
+-5 35 45 0
+-12 26 0
+-12 14 -18 0
+11 -18 28 0
+19 -33 39 0
+-1 -33 -42 0
+28 29 35 0
+19 32 36 0
+9 12 -24 0
+9 36 -42 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-2_0-yes1-3.cnf b/test/resources/easySat/aim-50-2_0-yes1-3.cnf
new file mode 100644
index 0000000..3b9354a
--- /dev/null
+++ b/test/resources/easySat/aim-50-2_0-yes1-3.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-yes1-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 100
+-6 17 25 0
+-17 25 41 0
+-17 25 -41 0
+-6 29 40 0
+-25 29 -40 0
+-25 -29 37 0
+-6 -29 -37 0
+6 12 39 0
+10 -39 47 0
+-10 12 47 0
+6 12 -39 0
+6 -12 24 0
+-12 -24 -39 0
+-12 -24 38 0
+-22 -24 -38 0
+16 -38 39 0
+-11 -16 -38 0
+11 -16 42 0
+5 -16 -42 0
+-5 -42 -45 0
+-5 -10 -42 0
+4 42 45 0
+4 -5 45 0
+3 -4 45 0
+-3 -30 33 0
+-4 -30 -33 0
+-3 -4 23 0
+-3 -23 -31 0
+11 -14 30 0
+-11 -14 30 0
+14 -19 -23 0
+14 19 -25 0
+14 19 21 0
+13 -20 -21 0
+-13 19 -20 0
+15 20 44 0
+15 20 48 0
+20 -21 -48 0
+15 -27 -48 0
+-15 -21 34 0
+-8 -15 -34 0
+11 -13 -15 0
+-11 -13 -34 0
+8 30 -37 0
+8 -30 -34 0
+8 13 35 0
+1 13 23 0
+1 -23 -35 0
+-1 10 40 0
+-1 -10 -35 0
+-1 -35 47 0
+-40 43 -47 0
+-43 -47 -48 0
+27 -33 -47 0
+-27 -33 -43 0
+-43 44 48 0
+-17 -44 48 0
+-2 17 28 0
+-2 17 -28 0
+22 -28 -44 0
+2 -22 -28 0
+26 31 46 0
+2 26 -31 0
+2 26 -46 0
+-7 -26 28 0
+-26 28 -41 0
+-26 41 49 0
+36 41 -49 0
+-29 -36 -49 0
+18 -36 -49 0
+-18 37 46 0
+-36 -37 46 0
+9 -18 -46 0
+-9 -18 32 0
+31 -46 -50 0
+-32 44 -50 0
+-31 -44 -50 0
+-32 36 40 0
+-9 27 -32 0
+-9 27 -40 0
+16 43 50 0
+3 18 -19 0
+-20 33 37 0
+9 34 42 0
+-7 -22 -41 0
+-7 31 33 0
+21 34 43 0
+7 49 50 0
+-8 35 36 0
+-8 22 38 0
+9 39 -45 0
+21 24 -45 0
+1 3 10 0
+-14 29 35 0
+23 32 50 0
+4 5 18 0
+-2 -27 32 0
+7 24 49 0
+5 7 38 0
+16 -19 22 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-3_4-yes1-1.cnf b/test/resources/easySat/aim-50-3_4-yes1-1.cnf
new file mode 100644
index 0000000..ae07557
--- /dev/null
+++ b/test/resources/easySat/aim-50-3_4-yes1-1.cnf
@@ -0,0 +1,181 @@
+c FILE: aim-50-3_4-yes1-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 170
+43 46 49 0
+29 -43 46 0
+16 -29 -43 0
+16 46 -49 0
+24 36 -46 0
+-28 36 -46 0
+24 -36 -46 0
+-24 25 34 0
+6 -25 34 0
+16 -24 -34 0
+-6 16 -24 0
+5 9 32 0
+5 -16 -32 0
+-5 9 25 0
+-5 9 -25 0
+-9 -16 17 0
+14 24 35 0
+-5 -17 35 0
+-9 -17 35 0
+11 -35 -49 0
+-11 -35 -49 0
+-26 -35 -49 0
+-9 24 49 0
+-6 -35 49 0
+2 -24 -28 0
+-2 27 -28 0
+-24 -27 -28 0
+26 40 42 0
+28 40 42 0
+28 40 -42 0
+26 28 -40 0
+-14 35 -40 0
+-14 -28 -35 0
+3 27 49 0
+-3 -14 -26 0
+-14 -27 37 0
+9 -27 -37 0
+-9 -14 -40 0
+6 28 42 0
+28 42 -44 0
+6 -19 42 0
+6 -42 45 0
+2 14 33 0
+-2 11 13 0
+11 -13 -45 0
+8 -33 -45 0
+-8 10 23 0
+9 -10 23 0
+-9 -10 23 0
+-8 11 14 0
+11 -13 14 0
+17 29 -42 0
+9 29 -42 0
+29 -38 -42 0
+-5 -29 -40 0
+-5 -17 -40 0
+26 -40 -45 0
+5 10 -38 0
+-10 -38 -42 0
+7 38 48 0
+-7 44 48 0
+-4 38 48 0
+-26 38 48 0
+-11 23 31 0
+-11 23 -31 0
+5 -26 44 0
+-23 -32 39 0
+-23 -32 -39 0
+34 -41 -48 0
+19 -34 -41 0
+32 -41 -48 0
+20 -23 -48 0
+31 34 -44 0
+31 -34 -44 0
+31 -32 -34 0
+-20 31 -47 0
+4 -29 41 0
+4 -29 -33 0
+-4 35 -44 0
+-4 -29 -44 0
+22 32 33 0
+22 32 43 0
+21 41 48 0
+-19 21 -48 0
+21 -32 -48 0
+-19 -21 43 0
+-17 22 25 0
+22 -25 43 0
+41 -43 50 0
+41 -43 -50 0
+-10 -20 39 0
+-20 26 -39 0
+-10 -20 41 0
+-22 -31 39 0
+-20 -39 -50 0
+10 -19 -22 0
+10 15 50 0
+25 -30 -41 0
+10 15 -25 0
+-15 -30 41 0
+1 -15 -41 0
+-15 -30 50 0
+8 30 50 0
+22 -39 46 0
+19 -22 47 0
+-22 46 -47 0
+-1 19 38 0
+-1 19 -46 0
+-1 30 -38 0
+8 -13 30 0
+-8 -13 30 0
+-8 -12 30 0
+1 -4 -46 0
+-4 -6 -46 0
+4 13 -37 0
+-3 12 45 0
+-3 38 -45 0
+-3 12 -38 0
+-3 12 -25 0
+13 17 33 0
+2 -33 37 0
+13 -33 37 0
+1 17 -37 0
+6 -7 13 0
+-7 13 -30 0
+-6 -7 26 0
+1 -6 -26 0
+3 16 17 0
+-1 3 -17 0
+1 -16 44 0
+-1 3 44 0
+-16 44 -49 0
+3 -7 -16 0
+7 12 -43 0
+2 4 18 0
+2 4 -18 0
+4 36 37 0
+8 27 -36 0
+27 -36 43 0
+7 37 47 0
+7 -37 47 0
+7 45 47 0
+-30 -45 47 0
+18 29 36 0
+19 27 -47 0
+-2 -19 -47 0
+18 -27 36 0
+-2 12 18 0
+-2 -12 50 0
+18 -36 -50 0
+-27 34 -36 0
+8 15 -18 0
+-8 15 -18 0
+-15 -33 -47 0
+-15 25 33 0
+21 33 -34 0
+-13 20 -21 0
+-11 -12 -20 0
+5 -21 39 0
+-12 15 -21 0
+-31 32 -50 0
+-12 -23 40 0
+-11 21 45 0
+-18 24 -31 0
+20 -31 -37 0
+-23 40 45 0
+-22 39 49 0
+-18 -39 -50 0
+14 20 23 0
+20 21 -21 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-3_4-yes1-3.cnf b/test/resources/easySat/aim-50-3_4-yes1-3.cnf
new file mode 100644
index 0000000..9a60ec2
--- /dev/null
+++ b/test/resources/easySat/aim-50-3_4-yes1-3.cnf
@@ -0,0 +1,181 @@
+c FILE: aim-50-3_4-yes1-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 170
+11 18 -47 0
+11 12 -18 0
+11 22 25 0
+-22 25 42 0
+11 -12 -42 0
+-11 25 -47 0
+14 16 27 0
+14 -16 27 0
+-14 -25 28 0
+27 -28 32 0
+-14 -28 -32 0
+-25 -27 -47 0
+39 46 47 0
+24 39 48 0
+-24 39 47 0
+1 -39 48 0
+10 30 -48 0
+10 23 -30 0
+-10 23 31 0
+-10 -31 37 0
+22 23 -37 0
+22 -37 -44 0
+-22 -37 47 0
+-23 45 -48 0
+-23 29 -45 0
+-23 -29 -48 0
+2 42 -50 0
+-1 2 -50 0
+-1 -2 -50 0
+-1 -7 50 0
+-6 7 50 0
+7 26 50 0
+7 26 -42 0
+2 44 50 0
+2 44 -45 0
+2 -26 -44 0
+6 23 42 0
+6 7 23 0
+6 -7 50 0
+-2 34 49 0
+-2 -23 -34 0
+6 18 -49 0
+4 -20 -26 0
+-4 -18 -20 0
+-2 -18 22 0
+-2 22 -25 0
+-16 20 -23 0
+6 8 -22 0
+-6 32 49 0
+-6 8 -49 0
+-8 21 -22 0
+21 -32 -44 0
+10 16 -21 0
+4 -10 -21 0
+-21 -22 -44 0
+16 20 -27 0
+9 -18 -27 0
+-9 -27 41 0
+20 -27 -41 0
+16 30 44 0
+-13 16 30 0
+8 27 45 0
+20 35 -45 0
+8 20 -35 0
+-1 8 20 0
+13 -15 46 0
+-13 -15 -30 0
+-15 -30 43 0
+-15 -30 -43 0
+-8 -12 15 0
+-6 -8 -12 0
+-8 26 27 0
+-8 10 -26 0
+15 -30 39 0
+12 21 34 0
+15 21 -48 0
+15 -21 -48 0
+3 5 -10 0
+-3 -10 38 0
+5 -19 -38 0
+-5 -19 -39 0
+29 37 48 0
+12 29 -37 0
+-21 29 39 0
+12 -39 43 0
+29 -39 -43 0
+13 19 -39 0
+17 46 48 0
+17 -29 48 0
+12 -17 -34 0
+13 -34 47 0
+-13 -34 47 0
+1 -16 -29 0
+1 28 31 0
+19 -28 31 0
+1 -19 31 0
+1 -31 -47 0
+-16 -17 43 0
+36 -43 49 0
+-19 36 49 0
+-1 36 -49 0
+-16 -36 -43 0
+-17 -34 -47 0
+-13 25 -45 0
+19 35 -45 0
+-13 -25 -35 0
+-29 36 45 0
+14 34 46 0
+14 34 -46 0
+-17 34 42 0
+-4 -17 42 0
+-14 -31 -36 0
+-29 -31 -36 0
+-9 -42 45 0
+-9 -24 -42 0
+-9 45 -46 0
+-14 15 -41 0
+-14 -15 44 0
+-36 -41 -44 0
+12 -36 -41 0
+-5 7 -41 0
+3 -7 -12 0
+-3 -7 -12 0
+18 33 -42 0
+-18 33 41 0
+-25 31 -33 0
+9 13 38 0
+-6 13 38 0
+9 25 38 0
+-5 9 38 0
+9 -24 49 0
+-24 44 -49 0
+-24 41 -49 0
+-32 -33 -38 0
+10 24 32 0
+11 24 32 0
+-11 32 -35 0
+4 35 -38 0
+-4 -5 35 0
+-4 -5 -7 0
+24 35 46 0
+-11 19 26 0
+-11 -19 -28 0
+-11 -26 -28 0
+5 41 43 0
+5 43 -46 0
+35 -40 -43 0
+36 40 -46 0
+26 40 -46 0
+4 17 40 0
+4 -26 40 0
+3 28 30 0
+3 -4 28 0
+-3 -37 40 0
+-3 33 37 0
+24 33 -50 0
+33 37 -50 0
+21 -33 37 0
+17 -32 -40 0
+5 -35 -40 0
+-2 -35 36 0
+-3 28 30 0
+3 17 41 0
+17 19 -38 0
+18 -20 -33 0
+14 18 -38 0
+-9 17 -33 0
+17 -31 -40 0
+-15 -20 28 0
+-20 -32 -40 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-3_4-yes1-4.cnf b/test/resources/easySat/aim-50-3_4-yes1-4.cnf
new file mode 100644
index 0000000..5936c19
--- /dev/null
+++ b/test/resources/easySat/aim-50-3_4-yes1-4.cnf
@@ -0,0 +1,181 @@
+c FILE: aim-50-3_4-yes1-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 170
+9 10 38 0
+19 39 44 0
+2 19 -44 0
+2 19 38 0
+2 -19 50 0
+2 9 -19 0
+-2 -10 38 0
+11 29 32 0
+-29 32 35 0
+-29 -35 -38 0
+-27 -35 -38 0
+11 -32 -38 0
+9 -11 36 0
+-11 -36 41 0
+21 -36 -41 0
+9 -11 -21 0
+-9 15 48 0
+4 15 -48 0
+-9 39 43 0
+11 39 -43 0
+-39 46 50 0
+4 -39 -50 0
+11 -39 -46 0
+4 -11 -15 0
+-4 -16 49 0
+-16 -40 49 0
+-4 -16 -49 0
+16 23 30 0
+-23 30 -45 0
+-30 34 -45 0
+16 -34 -45 0
+-9 -34 -45 0
+-4 -8 16 0
+17 31 45 0
+17 -31 45 0
+6 26 50 0
+6 -26 50 0
+5 -6 -17 0
+-5 18 -38 0
+-5 -18 45 0
+-17 -38 -50 0
+16 -22 38 0
+-9 16 -22 0
+1 -20 22 0
+10 -20 22 0
+-1 -20 22 0
+8 -20 22 0
+20 38 39 0
+30 -37 45 0
+-17 -37 -45 0
+-37 45 -46 0
+-17 -30 -37 0
+37 -39 48 0
+20 28 43 0
+20 43 -48 0
+8 36 -48 0
+10 36 -43 0
+-8 24 36 0
+-8 -24 -48 0
+-27 -36 37 0
+10 -36 -43 0
+27 30 -47 0
+12 27 -47 0
+18 34 -47 0
+18 27 -47 0
+-18 -30 -47 0
+-10 -46 47 0
+35 -46 47 0
+-35 -46 -50 0
+13 -21 46 0
+5 -13 -21 0
+-5 -21 46 0
+-10 19 -35 0
+-19 27 -35 0
+25 32 47 0
+-25 32 44 0
+21 -25 -44 0
+18 21 32 0
+18 46 50 0
+-18 21 34 0
+-18 -34 50 0
+24 26 -44 0
+24 -26 -50 0
+35 -44 -50 0
+-29 35 43 0
+-29 35 -43 0
+29 -32 -41 0
+-16 29 -41 0
+-7 13 -32 0
+-13 -32 37 0
+-5 -13 37 0
+-7 -32 -37 0
+28 41 44 0
+8 15 20 0
+7 8 -20 0
+7 -8 15 0
+-8 41 47 0
+-14 41 -47 0
+-15 25 29 0
+7 -11 -28 0
+5 6 11 0
+5 -15 24 0
+5 -6 -24 0
+14 -25 37 0
+14 -25 29 0
+14 -28 -29 0
+-12 22 27 0
+-12 -22 -25 0
+-12 -14 -27 0
+-5 -14 -40 0
+9 40 -42 0
+-9 15 -42 0
+-15 -42 43 0
+-15 -42 -43 0
+12 40 -49 0
+12 19 42 0
+-2 -19 40 0
+-19 -31 40 0
+3 -31 -33 0
+-3 7 -31 0
+-7 10 -31 0
+-7 -10 -31 0
+17 23 42 0
+23 42 49 0
+2 -26 49 0
+3 26 31 0
+-23 33 44 0
+17 -23 33 0
+4 28 41 0
+28 33 -41 0
+14 17 -28 0
+1 14 -17 0
+-1 -17 26 0
+4 12 -28 0
+-12 -14 -28 0
+-4 20 33 0
+-4 -20 33 0
+30 40 42 0
+7 31 -40 0
+31 -40 42 0
+26 -33 48 0
+-33 39 -48 0
+-26 31 -33 0
+-14 -26 -33 0
+31 -39 -42 0
+3 12 23 0
+3 23 -24 0
+3 -24 -30 0
+-3 -23 -24 0
+1 10 25 0
+1 -23 25 0
+-1 -12 36 0
+-1 -3 -36 0
+-3 -13 -30 0
+6 13 24 0
+-6 21 34 0
+-6 -21 34 0
+-1 -6 -34 0
+13 -18 49 0
+13 47 -49 0
+13 -34 -47 0
+8 -10 48 0
+1 -2 46 0
+6 -41 48 0
+-16 -22 -49 0
+-13 -22 -40 0
+-7 28 -49 0
+-3 25 44 0
+-27 -44 0
+-2 -16 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-6_0-yes1-1.cnf b/test/resources/easySat/aim-50-6_0-yes1-1.cnf
new file mode 100644
index 0000000..ad030b8
--- /dev/null
+++ b/test/resources/easySat/aim-50-6_0-yes1-1.cnf
@@ -0,0 +1,311 @@
+c FILE: aim-50-6_0-yes1-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 300
+6 17 47 0
+6 -17 43 0
+-6 43 47 0
+19 47 -48 0
+-19 28 47 0
+-28 43 47 0
+-36 46 -48 0
+-36 47 -48 0
+8 -38 -47 0
+-38 -47 48 0
+6 -47 -48 0
+-6 43 -48 0
+-31 43 -47 0
+8 28 33 0
+-8 33 -43 0
+1 38 47 0
+1 28 -38 0
+18 -43 -47 0
+37 40 -47 0
+28 -37 40 0
+-15 28 40 0
+1 22 -40 0
+22 -23 -40 0
+-22 -38 -40 0
+1 -28 -38 0
+13 40 49 0
+-1 13 -40 0
+-13 33 -38 0
+-13 -33 49 0
+-1 -38 -49 0
+4 -27 38 0
+28 29 42 0
+-27 29 -42 0
+16 28 42 0
+14 16 42 0
+16 29 -42 0
+17 25 50 0
+-25 34 50 0
+-34 45 49 0
+38 -45 50 0
+-4 49 -50 0
+16 41 -49 0
+-4 -22 30 0
+14 30 -41 0
+14 -30 47 0
+2 14 -27 0
+-2 14 16 0
+-4 -17 21 0
+-17 -27 45 0
+-17 -27 -45 0
+-21 41 -49 0
+-17 -21 -41 0
+-4 -14 16 0
+-16 20 38 0
+-16 20 -35 0
+-16 -20 -27 0
+15 27 42 0
+-15 21 42 0
+-15 38 42 0
+19 -37 -42 0
+-19 38 -42 0
+7 37 -47 0
+29 37 -47 0
+27 37 -47 0
+11 27 37 0
+1 27 37 0
+7 -42 47 0
+-3 8 27 0
+-3 4 -8 0
+-3 -4 15 0
+-3 -8 -15 0
+11 17 -42 0
+11 -20 -42 0
+11 -17 -42 0
+23 27 -40 0
+-7 -40 48 0
+-7 -23 -40 0
+-11 40 43 0
+-2 3 27 0
+-2 -27 30 0
+3 -30 42 0
+3 12 -30 0
+-12 31 -42 0
+3 -12 -31 0
+3 -13 17 0
+3 -13 -43 0
+16 34 -43 0
+16 22 -34 0
+-22 -34 -43 0
+2 -16 -48 0
+3 -7 11 0
+-7 11 26 0
+11 -12 -26 0
+-11 22 31 0
+7 -22 46 0
+3 37 46 0
+4 -22 37 0
+3 -22 -37 0
+12 25 31 0
+11 12 31 0
+-7 -11 31 0
+1 -11 -12 0
+-1 -11 -12 0
+-11 -22 -29 0
+2 -31 46 0
+-2 15 34 0
+-2 -15 -31 0
+-31 33 46 0
+9 -33 46 0
+-9 46 48 0
+2 20 -46 0
+-11 20 -46 0
+-11 20 -39 0
+18 27 -46 0
+2 18 -46 0
+18 -46 48 0
+9 18 -46 0
+-5 8 36 0
+4 13 33 0
+4 -13 -46 0
+33 -36 39 0
+-36 -39 -46 0
+-9 -36 38 0
+26 32 -33 0
+-9 -26 -33 0
+-9 -32 -33 0
+8 9 -20 0
+-8 9 33 0
+9 -29 -33 0
+-8 -9 -33 0
+-9 -20 28 0
+-28 -29 32 0
+-20 -29 -32 0
+-3 -29 39 0
+-3 -28 -29 0
+21 30 49 0
+21 -30 48 0
+17 48 -49 0
+-18 -21 48 0
+10 13 -20 0
+-18 -20 36 0
+7 8 -15 0
+7 -8 -15 0
+-7 -15 29 0
+6 -9 49 0
+-6 -18 49 0
+6 -9 40 0
+-6 40 -49 0
+-9 -40 -49 0
+2 -22 29 0
+-2 -22 29 0
+14 -19 32 0
+-10 -19 -32 0
+-4 5 22 0
+-5 8 41 0
+-4 -5 -8 0
+2 45 46 0
+22 -41 45 0
+9 -12 22 0
+2 -5 -45 0
+-2 -4 24 0
+-5 -24 38 0
+-2 -5 -38 0
+-6 -17 29 0
+5 6 35 0
+15 32 35 0
+-6 15 -32 0
+5 25 35 0
+5 -20 25 0
+-2 25 35 0
+5 31 32 0
+5 15 -32 0
+29 -31 44 0
+19 -29 44 0
+-19 -29 44 0
+-8 24 44 0
+15 -24 -31 0
+-24 -35 41 0
+-31 -35 -41 0
+15 17 35 0
+4 -17 35 0
+-5 15 35 0
+-10 -14 38 0
+-14 -36 -38 0
+5 18 -35 0
+5 10 -35 0
+7 -10 13 0
+7 -13 -35 0
+4 -7 44 0
+5 -35 -44 0
+4 10 50 0
+1 9 26 0
+9 23 -26 0
+1 9 -23 0
+-10 44 50 0
+-1 7 19 0
+-1 26 43 0
+-1 -26 -44 0
+-3 43 -44 0
+-1 -44 50 0
+19 -44 50 0
+-1 -10 -19 0
+8 24 -37 0
+17 24 -37 0
+10 17 -37 0
+-10 17 -27 0
+-21 36 -37 0
+-24 -36 -37 0
+-21 37 45 0
+14 41 -45 0
+-21 -41 -45 0
+14 -37 43 0
+33 39 -43 0
+-17 -21 -43 0
+1 -21 -43 0
+-1 -21 -39 0
+-5 22 25 0
+19 -30 44 0
+19 -25 -30 0
+19 -29 35 0
+19 -30 -35 0
+4 30 -45 0
+7 24 -25 0
+-7 -25 46 0
+-7 18 -46 0
+-18 44 -50 0
+24 -25 32 0
+-18 24 36 0
+-32 40 44 0
+-18 -32 -40 0
+-24 -25 -50 0
+-25 -48 -50 0
+2 -12 -50 0
+-12 -35 -50 0
+11 21 45 0
+12 33 45 0
+-11 -12 45 0
+10 16 36 0
+10 36 -39 0
+10 13 -16 0
+-13 -16 -39 0
+-8 10 -44 0
+-10 23 35 0
+23 36 -39 0
+-10 -23 36 0
+36 -43 -44 0
+-36 -39 41 0
+20 21 -44 0
+27 -39 -44 0
+21 31 -39 0
+21 26 -27 0
+21 -26 -31 0
+6 -23 48 0
+-23 25 48 0
+-6 -23 -25 0
+-23 -48 50 0
+-23 -48 -50 0
+23 30 32 0
+23 32 39 0
+34 41 50 0
+34 39 49 0
+39 -41 -49 0
+18 -25 -50 0
+13 32 39 0
+13 -32 34 0
+-4 13 34 0
+-13 34 -50 0
+-24 -34 39 0
+20 30 -49 0
+-24 30 -49 0
+-24 30 -33 0
+-30 39 41 0
+-24 -30 -41 0
+10 12 45 0
+12 26 -28 0
+-10 12 -26 0
+-18 -28 -45 0
+12 18 -28 0
+-18 31 -34 0
+-18 -28 -34 0
+12 -28 -33 0
+6 24 -41 0
+-6 14 20 0
+-14 20 -41 0
+-6 -20 28 0
+8 -34 41 0
+-32 -34 49 0
+23 -26 31 0
+23 -26 34 0
+23 -26 -34 0
+-14 -16 -19 0
+-3 -19 25 0
+-3 6 -13 0
+-14 -16 -36 0
+-14 -16 26 0
+-5 -14 -15 0
+-14 42 0
+24 26 -45 0
+-19 25 40 0
+22 26 -45 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-6_0-yes1-2.cnf b/test/resources/easySat/aim-50-6_0-yes1-2.cnf
new file mode 100644
index 0000000..3cd571e
--- /dev/null
+++ b/test/resources/easySat/aim-50-6_0-yes1-2.cnf
@@ -0,0 +1,311 @@
+c FILE: aim-50-6_0-yes1-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 300
+25 27 32 0
+25 -27 32 0
+21 -32 42 0
+-21 25 -32 0
+3 37 -42 0
+1 11 37 0
+25 37 45 0
+25 37 -45 0
+-1 29 -42 0
+2 11 -29 0
+2 22 -42 0
+2 -11 -22 0
+-2 -3 -29 0
+-3 -11 46 0
+-3 -29 -46 0
+-11 -29 -36 0
+6 34 42 0
+20 34 -42 0
+6 -20 26 0
+6 11 -20 0
+6 -8 -20 0
+6 -20 34 0
+27 44 50 0
+27 35 44 0
+-27 40 44 0
+2 35 44 0
+-2 36 44 0
+21 -34 36 0
+-21 27 -44 0
+-21 36 -44 0
+-27 -34 35 0
+-34 -35 45 0
+6 -35 36 0
+-15 -35 -45 0
+-12 32 43 0
+-12 32 -43 0
+6 -12 -32 0
+-25 -36 50 0
+6 -25 -50 0
+-25 -44 -50 0
+-15 -25 -44 0
+-25 -48 -50 0
+-25 37 43 0
+-6 37 -43 0
+3 9 50 0
+3 9 39 0
+3 9 -50 0
+3 11 -37 0
+-9 -11 49 0
+3 8 42 0
+8 -42 -49 0
+3 -8 -9 0
+3 -8 -50 0
+-3 5 -12 0
+-3 7 -12 0
+-12 13 -32 0
+-7 -12 13 0
+-3 -12 -13 0
+-31 -37 38 0
+12 -31 -37 0
+8 12 -38 0
+-23 -38 49 0
+12 -31 -49 0
+-2 -23 -37 0
+-10 12 -38 0
+-5 -31 -38 0
+22 24 42 0
+22 -24 46 0
+34 -37 -46 0
+2 31 34 0
+-2 22 31 0
+8 26 45 0
+26 -42 -45 0
+8 -29 -42 0
+22 -29 -42 0
+11 26 31 0
+-22 26 43 0
+31 34 43 0
+21 31 34 0
+-21 31 -43 0
+14 23 40 0
+-22 35 40 0
+-22 23 40 0
+-14 23 -34 0
+33 -34 40 0
+-23 -33 40 0
+35 41 -46 0
+-12 41 -46 0
+27 -41 -46 0
+-27 32 -46 0
+-32 -40 -41 0
+-3 -35 -46 0
+21 24 46 0
+21 -24 46 0
+21 -37 46 0
+13 -34 46 0
+4 -21 -24 0
+-4 18 -24 0
+-13 -24 42 0
+-13 -21 -24 0
+-13 -24 -28 0
+16 30 -36 0
+11 17 -30 0
+-17 24 -36 0
+-10 16 24 0
+-11 12 16 0
+-16 34 -36 0
+-16 24 -36 0
+12 46 50 0
+33 -34 50 0
+13 29 50 0
+-13 -33 50 0
+-29 -46 50 0
+-13 -40 -43 0
+-9 39 -50 0
+-9 -40 43 0
+-9 16 39 0
+-7 -9 16 0
+-9 -16 -40 0
+-9 -39 -40 0
+11 -17 24 0
+-11 -17 -40 0
+17 32 48 0
+7 16 -48 0
+17 32 -48 0
+-16 17 32 0
+2 38 43 0
+2 -32 38 0
+-2 38 45 0
+-32 38 -45 0
+5 -7 24 0
+1 -7 43 0
+-5 13 24 0
+3 -5 -13 0
+-3 -7 33 0
+-3 -7 43 0
+7 47 48 0
+7 47 -48 0
+9 24 47 0
+-24 -43 47 0
+-14 18 47 0
+7 29 47 0
+7 17 26 0
+22 -26 40 0
+1 36 45 0
+1 37 -45 0
+1 -17 36 0
+-1 12 36 0
+-1 -17 36 0
+22 -26 -50 0
+15 -26 -36 0
+15 41 -48 0
+14 15 -41 0
+-10 27 -48 0
+-10 40 -48 0
+-10 -36 37 0
+-10 -37 -48 0
+4 15 22 0
+-4 -14 15 0
+-15 17 26 0
+-15 -26 -36 0
+-15 -17 -50 0
+9 25 -38 0
+9 -11 -38 0
+9 -26 33 0
+-26 33 -50 0
+9 33 -40 0
+-14 -32 -38 0
+29 -33 -41 0
+14 -33 -41 0
+-14 -33 -41 0
+-22 28 -38 0
+-27 -28 49 0
+-28 41 -49 0
+-27 -28 -41 0
+4 27 38 0
+4 25 -38 0
+22 25 27 0
+-4 11 25 0
+8 14 -23 0
+1 -8 -23 0
+-1 -23 26 0
+14 -23 -26 0
+14 -39 41 0
+14 23 -41 0
+-14 20 -22 0
+-1 20 -22 0
+11 -20 -22 0
+-11 -14 -20 0
+14 -22 45 0
+5 23 46 0
+2 5 14 0
+5 23 34 0
+-2 5 -34 0
+6 9 31 0
+21 -25 -33 0
+-21 -31 -33 0
+-9 -25 -33 0
+-25 -33 -39 0
+-10 44 -45 0
+-10 35 -44 0
+-35 -44 -45 0
+-10 -19 -45 0
+10 -19 39 0
+-4 44 49 0
+-44 47 49 0
+-4 -47 49 0
+-4 10 -49 0
+-5 18 23 0
+-1 -6 19 0
+13 -15 19 0
+-15 19 39 0
+-19 31 39 0
+-19 -31 39 0
+-5 -6 -19 0
+17 20 35 0
+-18 -20 35 0
+2 -18 45 0
+-6 -17 -18 0
+-17 -18 35 0
+-1 -18 40 0
+-17 -18 -40 0
+10 13 39 0
+10 -13 -20 0
+-6 36 -39 0
+-6 -20 26 0
+5 -7 -39 0
+5 -6 -26 0
+-5 30 -39 0
+-30 -39 41 0
+10 -30 41 0
+-5 32 -39 0
+-6 -32 -39 0
+7 8 12 0
+8 12 -18 0
+1 8 -18 0
+-15 19 41 0
+-15 19 -41 0
+15 -16 19 0
+10 20 -43 0
+10 -26 28 0
+-8 20 28 0
+-8 28 -40 0
+-11 23 28 0
+4 28 -35 0
+4 28 -43 0
+-4 28 -42 0
+20 21 28 0
+-21 -23 -47 0
+20 -28 -29 0
+20 -29 -47 0
+1 29 -44 0
+-35 -48 49 0
+16 30 -49 0
+16 -30 -35 0
+-30 46 47 0
+-30 44 -46 0
+17 -30 -47 0
+7 -30 -47 0
+7 -14 -47 0
+-7 15 -47 0
+5 15 -47 0
+15 -30 -47 0
+-28 48 -49 0
+37 39 48 0
+43 48 -49 0
+-43 48 -49 0
+-37 48 50 0
+-37 48 -49 0
+-5 -31 48 0
+27 42 44 0
+29 42 -44 0
+-8 29 42 0
+1 42 -45 0
+-8 -27 29 0
+-1 -27 29 0
+-1 -27 -35 0
+23 30 45 0
+19 -23 31 0
+19 30 -31 0
+19 30 -31 0
+4 -19 45 0
+-4 -28 30 0
+-2 -28 30 0
+13 18 30 0
+17 41 47 0
+-18 -19 0
+-8 18 -24 0
+10 -16 -34 0
+13 -14 16 0
+4 38 0
+-2 10 -28 0
+-5 18 38 0
+33 -43 0
+4 -7 18 0
+-6 -16 49 0
+-4 -13 -21 0
+-16 -19 49 0
+-2 18 33 0
+-16 18 21 0
\ No newline at end of file
diff --git a/test/resources/easySat/aim-50-6_0-yes1-3.cnf b/test/resources/easySat/aim-50-6_0-yes1-3.cnf
new file mode 100644
index 0000000..3e8bdac
--- /dev/null
+++ b/test/resources/easySat/aim-50-6_0-yes1-3.cnf
@@ -0,0 +1,311 @@
+c FILE: aim-50-6_0-yes1-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Satisfiable
+c
+p cnf 50 300
+33 -40 46 0
+-40 41 46 0
+-40 41 -46 0
+3 41 42 0
+-3 41 42 0
+-1 2 30 0
+-1 2 -30 0
+-1 -2 23 0
+-23 -42 44 0
+13 46 48 0
+1 -13 48 0
+4 -13 48 0
+-1 7 -48 0
+4 7 -46 0
+-7 34 35 0
+4 -7 -34 0
+-4 35 43 0
+-1 -4 -43 0
+6 -35 41 0
+-1 -6 -35 0
+34 -40 -41 0
+23 -34 -41 0
+-23 35 -40 0
+-35 -40 42 0
+-35 -41 -42 0
+-10 20 40 0
+3 -10 34 0
+-10 -34 40 0
+-3 -10 -20 0
+15 49 50 0
+-15 49 50 0
+14 -22 44 0
+-26 27 41 0
+14 -26 -41 0
+-14 -22 27 0
+27 44 -49 0
+12 15 26 0
+15 -26 -27 0
+10 15 -27 0
+-27 28 44 0
+-15 -27 44 0
+10 -28 44 0
+26 -28 32 0
+8 26 -28 0
+15 -28 -44 0
+-15 -26 -44 0
+-8 -28 -44 0
+25 28 50 0
+19 40 50 0
+-19 28 45 0
+28 40 -45 0
+1 -32 37 0
+-1 -32 47 0
+22 37 -47 0
+22 24 -37 0
+24 39 50 0
+24 -39 50 0
+24 -26 28 0
+-24 28 -32 0
+5 20 31 0
+11 20 -27 0
+-5 11 20 0
+10 11 31 0
+11 31 -46 0
+10 11 -31 0
+8 19 -44 0
+-8 19 20 0
+20 35 40 0
+5 20 40 0
+-5 22 33 0
+-5 -22 33 0
+-5 -33 40 0
+8 42 -44 0
+8 37 -44 0
+2 8 12 0
+8 -12 25 0
+8 -12 -49 0
+2 -25 49 0
+-11 19 -37 0
+2 -11 -19 0
+-2 8 -11 0
+-2 -11 -18 0
+-2 8 17 0
+-2 -19 49 0
+-2 -19 -49 0
+3 -20 30 0
+-20 30 -33 0
+25 -30 -33 0
+-25 -33 46 0
+-4 -33 46 0
+3 -44 -46 0
+-3 -30 -46 0
+3 35 -50 0
+-3 25 -50 0
+27 29 -50 0
+-11 27 -50 0
+12 -27 35 0
+7 -12 35 0
+9 28 -50 0
+-9 28 -35 0
+-9 -47 -50 0
+-28 33 39 0
+-11 -12 -28 0
+13 15 -33 0
+-15 -35 39 0
+10 13 -50 0
+-7 -10 13 0
+-7 13 -32 0
+-13 39 -50 0
+4 10 25 0
+4 10 33 0
+-4 24 25 0
+-4 31 33 0
+-4 25 -31 0
+-5 -8 -20 0
+5 33 -45 0
+36 38 45 0
+12 36 45 0
+-25 36 45 0
+-12 36 -47 0
+-36 38 47 0
+-36 38 48 0
+16 18 -48 0
+-16 38 -48 0
+5 11 -18 0
+5 -11 -18 0
+-22 24 -38 0
+-20 -24 49 0
+-20 -24 -49 0
+-14 23 -38 0
+-14 23 33 0
+-14 -23 -38 0
+-20 34 37 0
+-34 37 48 0
+7 -20 -30 0
+-7 23 -33 0
+-7 -22 -23 0
+-22 -33 -37 0
+9 45 -47 0
+-9 -38 -47 0
+-39 -45 -47 0
+-28 -45 -47 0
+3 14 22 0
+3 22 47 0
+-14 -31 47 0
+-3 4 23 0
+-3 23 -37 0
+4 -23 37 0
+4 22 -37 0
+-25 -32 -39 0
+-32 -39 48 0
+-29 -32 46 0
+2 -32 -46 0
+-2 -46 -48 0
+7 -25 50 0
+5 -25 31 0
+7 -25 -31 0
+5 7 -50 0
+17 -36 -38 0
+17 -36 -39 0
+-17 19 48 0
+-5 -17 -36 0
+-17 -27 48 0
+-17 -19 -36 0
+-17 -18 -38 0
+-4 -17 48 0
+6 -17 -48 0
+7 32 39 0
+-7 32 39 0
+3 10 -39 0
+-10 32 -39 0
+22 44 49 0
+-22 44 49 0
+3 -6 43 0
+-6 28 43 0
+-3 -6 -28 0
+-43 47 49 0
+-3 16 45 0
+-3 16 -45 0
+16 -27 -45 0
+25 32 42 0
+-25 32 42 0
+32 39 42 0
+-16 41 42 0
+-16 32 -41 0
+9 12 40 0
+9 10 -48 0
+9 -10 -48 0
+-9 29 34 0
+-12 34 -48 0
+-8 -12 34 0
+-6 9 -48 0
+-9 29 -34 0
+5 -6 15 0
+-5 15 16 0
+15 -16 -29 0
+-1 16 -49 0
+-6 11 -49 0
+-1 -6 -49 0
+1 24 -30 0
+1 -24 -30 0
+6 -16 19 0
+6 -16 23 0
+-19 32 38 0
+23 38 40 0
+-19 -32 -40 0
+6 -19 -38 0
+1 -16 46 0
+-16 -23 -49 0
+-8 21 46 0
+1 -8 -21 0
+1 21 -30 0
+-21 -30 47 0
+1 -30 -47 0
+27 -29 -42 0
+4 18 -29 0
+-4 18 -24 0
+18 -41 -42 0
+-18 -29 43 0
+-24 -29 -43 0
+-10 -18 -42 0
+-24 -40 41 0
+-24 -40 -41 0
+-15 -16 46 0
+5 -15 49 0
+-5 -15 43 0
+29 31 -43 0
+-15 31 -49 0
+18 -29 31 0
+-18 -29 31 0
+25 -42 43 0
+17 -42 43 0
+-17 -42 43 0
+30 42 50 0
+-14 30 50 0
+-14 18 30 0
+-14 -18 30 0
+11 33 -43 0
+9 -26 -43 0
+-9 -26 -43 0
+11 -26 -33 0
+-11 -26 -43 0
+13 18 22 0
+13 -18 30 0
+13 -15 30 0
+6 13 -37 0
+-13 26 -37 0
+24 26 -37 0
+-6 -24 -37 0
+-2 26 37 0
+21 -31 36 0
+6 21 -36 0
+-31 -36 -41 0
+-10 -31 -36 0
+-21 -31 38 0
+-21 -31 -38 0
+22 37 39 0
+6 26 -39 0
+6 -22 26 0
+-35 41 45 0
+-35 -41 45 0
+20 -35 -45 0
+-20 44 -45 0
+26 -44 -45 0
+29 38 47 0
+29 39 47 0
+29 -39 47 0
+-7 27 29 0
+27 29 -47 0
+2 14 38 0
+7 14 -38 0
+-7 14 27 0
+2 9 -27 0
+14 34 37 0
+-5 14 34 0
+2 -23 35 0
+-9 12 -21 0
+-9 -12 -21 0
+-19 21 35 0
+12 19 -34 0
+14 19 -22 0
+12 -34 43 0
+-13 20 -29 0
+9 -9 17 0
+-4 16 -42 0
+17 -17 36 0
+-11 18 -21 0
+-12 -25 36 0
+21 24 36 0
+1 -8 -23 0
+21 -21 0
+19 36 -46 0
+-23 -34 -44 0
+-2 21 -46 0
+-8 17 0
+12 -34 -43 0
+-13 16 17 0
+18 -21 45 0
+-13 16 17 0
+-13 -14 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-1_6-no-1.cnf b/test/resources/easyUnsat/aim-50-1_6-no-1.cnf
new file mode 100644
index 0000000..0e30892
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-1_6-no-1.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-no-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 80
+16 23 42 0
+-16 23 42 0
+26 41 -42 0
+-26 41 -42 0
+32 -41 -42 0
+6 15 -41 0
+-6 15 -32 0
+1 -32 46 0
+-1 -32 46 0
+-15 -41 -46 0
+-15 -21 -46 0
+-23 33 38 0
+-23 -33 38 0
+8 22 33 0
+8 22 -33 0
+-22 37 -38 0
+13 36 -37 0
+13 -22 -36 0
+-13 -22 -37 0
+11 -23 47 0
+-8 11 -47 0
+-8 -11 39 0
+-11 27 -39 0
+-8 -11 -39 0
+-7 26 29 0
+-7 -26 29 0
+-13 20 36 0
+-13 17 20 0
+5 -17 20 0
+5 -19 -45 0
+-5 -10 -45 0
+6 25 47 0
+-6 -10 25 0
+-2 -27 37 0
+-27 -36 40 0
+18 39 -40 0
+-2 -19 31 0
+5 18 -30 0
+-31 -43 -50 0
+10 -30 43 0
+10 -41 43 0
+19 21 29 0
+37 42 45 0
+-20 27 40 0
+-21 -36 48 0
+31 -36 -48 0
+3 -9 -18 0
+16 -40 -47 0
+1 -18 21 0
+2 28 32 0
+-1 -24 -50 0
+-12 35 49 0
+-6 -36 45 0
+7 12 -43 0
+7 30 -43 0
+-5 9 -17 0
+3 14 50 0
+-12 17 -49 0
+24 34 49 0
+14 -20 24 0
+-9 35 -49 0
+-4 -47 50 0
+4 44 -44 0
+28 -28 -38 0
+2 4 -48 0
+-20 35 -44 0
+30 -31 -43 0
+-14 -29 35 0
+-20 35 -35 0
+19 -22 -24 0
+-25 -28 48 0
+-14 -34 44 0
+9 20 44 0
+-3 9 -29 0
+17 34 -34 0
+12 48 0
+-12 -25 -43 0
+-25 -31 48 0
+14 -16 49 0
+-3 -4 -35 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-1_6-no-2.cnf b/test/resources/easyUnsat/aim-50-1_6-no-2.cnf
new file mode 100644
index 0000000..17bc8ff
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-1_6-no-2.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-no-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 80
+5 17 37 0
+24 28 37 0
+24 -28 40 0
+4 -28 -40 0
+4 -24 29 0
+13 -24 -29 0
+-13 -24 -29 0
+-4 10 -17 0
+-4 -10 -17 0
+26 33 -37 0
+5 -26 34 0
+33 -34 48 0
+33 -37 -48 0
+5 -33 -37 0
+2 -5 10 0
+2 -5 -10 0
+-2 15 47 0
+15 30 -47 0
+-2 -15 30 0
+20 -30 42 0
+-2 20 -30 0
+13 -20 29 0
+13 16 -20 0
+-13 -20 31 0
+-13 16 -31 0
+-16 23 38 0
+-16 19 -38 0
+-19 23 -38 0
+14 -23 34 0
+1 14 -34 0
+-1 9 14 0
+-1 -9 -23 0
+-14 21 -23 0
+-14 -16 -21 0
+25 -35 41 0
+-25 41 50 0
+-35 49 -50 0
+-25 -49 -50 0
+-19 -48 -49 0
+3 -39 44 0
+1 3 -44 0
+9 35 44 0
+-9 -31 44 0
+22 25 -44 0
+-12 -43 46 0
+-12 -28 -46 0
+6 35 48 0
+11 18 -48 0
+22 38 -42 0
+22 -35 -42 0
+-3 11 41 0
+27 28 -43 0
+-15 -21 31 0
+-33 39 50 0
+-8 -22 -47 0
+-22 -40 -47 0
+39 44 -46 0
+-25 -26 47 0
+38 43 45 0
+-6 -14 -45 0
+-7 12 36 0
+8 -11 45 0
+27 -38 -50 0
+7 -11 -36 0
+-7 -41 42 0
+7 21 23 0
+-18 32 46 0
+8 19 -36 0
+-32 -45 -50 0
+7 17 21 0
+6 18 43 0
+-6 24 -27 0
+40 -41 49 0
+-11 12 26 0
+-3 32 -36 0
+-6 36 -44 0
+-3 36 42 0
+-8 -11 -32 0
+-18 -27 -38 0
+-18 -27 -39 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-1_6-no-3.cnf b/test/resources/easyUnsat/aim-50-1_6-no-3.cnf
new file mode 100644
index 0000000..8d6af78
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-1_6-no-3.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-no-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 80
+15 20 41 0
+-15 20 41 0
+7 8 -41 0
+7 -8 -41 0
+-7 42 50 0
+-7 -42 50 0
+22 35 -50 0
+22 -35 45 0
+18 -22 45 0
+-18 -22 45 0
+33 -45 -50 0
+-7 -33 -50 0
+19 -20 21 0
+-20 21 -41 0
+19 -20 -21 0
+1 14 36 0
+-1 14 36 0
+13 -14 36 0
+3 13 -36 0
+-3 5 -36 0
+-3 -5 13 0
+4 44 49 0
+-4 17 49 0
+-4 -17 44 0
+-13 31 -44 0
+-13 -31 -44 0
+23 33 -49 0
+23 -33 -49 0
+-19 37 42 0
+-19 37 -42 0
+-23 29 -37 0
+-23 -29 -37 0
+-24 -26 32 0
+2 -12 -31 0
+17 28 40 0
+-15 -17 40 0
+2 28 47 0
+26 -28 -39 0
+21 -26 -28 0
+16 24 29 0
+12 -34 -39 0
+10 31 40 0
+-6 -32 35 0
+16 -24 34 0
+-24 -31 38 0
+-16 -24 -38 0
+-2 -10 -47 0
+4 -16 27 0
+-1 24 -30 0
+-18 26 -46 0
+27 30 -45 0
+4 -14 -44 0
+-29 43 47 0
+-8 -10 -46 0
+-11 39 -43 0
+-11 -40 -43 0
+6 -21 26 0
+8 -25 46 0
+-25 -38 46 0
+10 -46 -47 0
+25 -32 -40 0
+5 6 -40 0
+11 15 16 0
+12 39 43 0
+5 11 32 0
+-5 17 32 0
+-12 -40 -48 0
+-2 18 -30 0
+3 10 -34 0
+-2 -9 30 0
+-3 -5 -28 0
+-9 26 48 0
+22 -27 -48 0
+1 9 38 0
+3 -6 48 0
+1 -6 34 0
+15 -35 48 0
+15 26 -27 0
+-9 -27 0
+1 9 25 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-1_6-no-4.cnf b/test/resources/easyUnsat/aim-50-1_6-no-4.cnf
new file mode 100644
index 0000000..f49386d
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-1_6-no-4.cnf
@@ -0,0 +1,91 @@
+c FILE: aim-50-1_6-no-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 80
+1 32 34 0
+4 5 32 0
+-4 5 -34 0
+-5 32 -34 0
+29 -32 43 0
+29 36 -43 0
+29 -32 -36 0
+1 3 -29 0
+-3 -29 -32 0
+-1 24 39 0
+-1 24 -39 0
+7 18 -24 0
+-7 18 28 0
+-7 -21 28 0
+-7 17 -28 0
+18 -24 -28 0
+2 17 40 0
+-17 -18 40 0
+2 39 -40 0
+2 -39 -40 0
+-2 -18 35 0
+-2 -18 -35 0
+9 -32 41 0
+-9 41 45 0
+-1 -9 -45 0
+-5 27 43 0
+14 16 26 0
+14 -16 49 0
+12 -14 26 0
+-12 26 35 0
+26 30 -35 0
+-26 30 49 0
+9 13 25 0
+5 -17 25 0
+15 30 47 0
+-20 27 -49 0
+13 -20 -27 0
+-13 -30 -49 0
+3 8 37 0
+8 23 -43 0
+10 19 22 0
+10 -19 22 0
+-10 -19 36 0
+4 21 38 0
+-4 38 46 0
+21 -38 -47 0
+-21 45 46 0
+-14 -33 -38 0
+-10 11 -26 0
+-14 16 -50 0
+-14 -16 -23 0
+-2 -23 -50 0
+12 -47 50 0
+7 10 48 0
+-6 -13 -41 0
+11 -41 -48 0
+23 -41 -48 0
+-15 42 48 0
+-15 -21 -42 0
+11 34 44 0
+-27 -34 -46 0
+19 28 50 0
+-3 6 -35 0
+-22 -40 -44 0
+-25 -37 -42 0
+-26 -30 -37 0
+6 -31 42 0
+6 -31 -33 0
+-44 -45 47 0
+4 20 47 0
+-6 44 -46 0
+-11 12 20 0
+-8 10 28 0
+-22 31 -36 0
+7 -25 37 0
+-11 31 47 0
+-4 10 -12 0
+-30 -31 44 0
+7 15 33 0
+-8 -11 33 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-2_0-no-1.cnf b/test/resources/easyUnsat/aim-50-2_0-no-1.cnf
new file mode 100644
index 0000000..d01ccda
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-2_0-no-1.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-no-1.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 100
+7 11 19 0
+7 -11 27 0
+7 16 -27 0
+-11 25 48 0
+-16 17 -48 0
+-17 25 -48 0
+-16 -25 -27 0
+19 36 49 0
+-7 -36 49 0
+-7 19 -49 0
+4 12 44 0
+4 -12 44 0
+1 -44 47 0
+-1 4 47 0
+20 34 48 0
+-19 20 34 0
+24 -34 -44 0
+-24 -34 -44 0
+-24 -32 41 0
+-34 -41 -47 0
+-4 -19 20 0
+30 39 41 0
+-30 39 50 0
+-20 -30 -50 0
+-20 -39 41 0
+-19 32 -41 0
+-20 -32 -41 0
+1 18 -35 0
+-14 18 -35 0
+-14 -18 27 0
+-1 25 -46 0
+-4 16 -47 0
+11 16 -25 0
+-4 11 -25 0
+-27 -35 -47 0
+15 31 40 0
+10 39 -49 0
+-8 -10 21 0
+-21 -26 30 0
+6 -11 29 0
+6 31 50 0
+45 49 -50 0
+31 -45 -50 0
+21 30 33 0
+2 37 -49 0
+-2 17 37 0
+-8 14 32 0
+-14 -15 32 0
+-1 37 47 0
+6 -38 45 0
+-21 -38 45 0
+-13 -18 -42 0
+2 -6 22 0
+-2 -6 22 0
+9 -28 -36 0
+8 29 -39 0
+-8 -38 -39 0
+-12 17 38 0
+1 -15 -26 0
+-7 -15 -26 0
+-9 36 42 0
+12 -16 21 0
+-10 -23 -46 0
+-9 -29 34 0
+-9 -21 42 0
+-12 -23 38 0
+-30 38 40 0
+18 23 33 0
+-6 15 33 0
+9 27 -43 0
+22 40 -48 0
+8 -22 26 0
+-5 -33 -36 0
+2 -33 46 0
+5 10 -42 0
+14 -29 -31 0
+12 -23 26 0
+8 35 36 0
+-10 -17 -18 0
+10 -22 -28 0
+15 -17 -43 0
+23 -29 -37 0
+13 -33 35 0
+-2 23 42 0
+9 43 46 0
+5 -24 -45 0
+-5 43 46 0
+-3 -13 -40 0
+3 -28 -42 0
+24 -31 43 0
+14 -22 -32 0
+3 24 26 0
+-13 -43 44 0
+-3 -31 -40 0
+-5 -40 50 0
+35 -37 -45 0
+-3 5 28 0
+13 28 -46 0
+3 28 -37 0
+13 29 48 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-2_0-no-2.cnf b/test/resources/easyUnsat/aim-50-2_0-no-2.cnf
new file mode 100644
index 0000000..c82bd20
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-2_0-no-2.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-no-2.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 100
+4 21 34 0
+21 -34 40 0
+1 -21 40 0
+-21 39 40 0
+20 29 41 0
+-20 39 41 0
+39 -40 41 0
+-40 -41 42 0
+-40 -41 -42 0
+1 25 -39 0
+2 -25 -39 0
+-2 5 -39 0
+-1 4 5 0
+15 26 33 0
+15 26 -33 0
+-5 -15 26 0
+-5 -26 31 0
+-5 -26 -31 0
+6 9 47 0
+9 37 38 0
+9 14 -38 0
+-14 -38 -47 0
+-9 11 37 0
+-9 -11 37 0
+24 -37 48 0
+24 46 -48 0
+-24 -37 46 0
+16 18 -46 0
+-16 18 -46 0
+-18 -37 -46 0
+-4 -6 15 0
+-4 13 -15 0
+-4 -13 -15 0
+-1 -6 38 0
+3 -9 35 0
+7 43 44 0
+7 29 43 0
+-8 -29 44 0
+-29 -32 48 0
+-14 30 46 0
+-1 -14 -30 0
+-11 20 49 0
+20 -44 -49 0
+16 22 -27 0
+13 -19 -35 0
+2 19 -33 0
+2 19 -28 0
+33 -34 -44 0
+-33 -44 50 0
+5 30 -48 0
+10 22 -50 0
+-10 22 -34 0
+1 10 -47 0
+-10 -25 -47 0
+-25 -27 50 0
+11 21 23 0
+-3 11 23 0
+-3 6 -50 0
+-6 23 -50 0
+-31 -43 44 0
+-7 16 -26 0
+-23 28 -38 0
+19 28 50 0
+-18 45 49 0
+-2 -16 -48 0
+7 14 -42 0
+12 25 -36 0
+10 -24 -45 0
+-21 32 -42 0
+12 -18 -27 0
+-13 -23 -24 0
+25 29 38 0
+-8 43 -45 0
+-2 -12 13 0
+-7 14 30 0
+-8 -17 -19 0
+8 -22 49 0
+-12 -17 33 0
+27 -29 32 0
+8 -12 -13 0
+24 -31 47 0
+-3 36 47 0
+3 12 34 0
+-7 -16 36 0
+-22 31 48 0
+17 -22 -49 0
+-17 -19 32 0
+-20 27 36 0
+18 -32 -35 0
+3 -28 -30 0
+17 34 42 0
+-32 -43 -49 0
+17 -28 -43 0
+-23 35 -45 0
+-10 31 -36 0
+27 -41 42 0
+35 -36 45 0
+8 -30 45 0
+4 28 -35 0
+6 -11 -20 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-2_0-no-3.cnf b/test/resources/easyUnsat/aim-50-2_0-no-3.cnf
new file mode 100644
index 0000000..4d0f186
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-2_0-no-3.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-no-3.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 100
+33 37 43 0
+21 -37 43 0
+-21 -37 39 0
+23 39 -43 0
+13 -23 31 0
+-13 -23 31 0
+-23 -31 -43 0
+6 9 25 0
+-6 9 25 0
+9 33 -38 0
+-9 25 -39 0
+24 -25 -39 0
+-24 -25 33 0
+6 27 41 0
+-6 14 41 0
+14 -41 43 0
+14 -41 -43 0
+1 20 27 0
+1 12 -20 0
+1 -12 -14 0
+-1 27 28 0
+-1 -14 -28 0
+-1 -11 -14 0
+-27 -33 39 0
+5 20 28 0
+19 29 -33 0
+-19 -20 29 0
+-20 28 -29 0
+5 -28 37 0
+5 -28 -37 0
+-5 -33 -39 0
+7 17 22 0
+-5 7 17 0
+-7 18 22 0
+22 -24 41 0
+-7 12 18 0
+-12 18 34 0
+-12 34 -42 0
+-7 -34 -41 0
+-16 -29 35 0
+-3 13 -29 0
+-21 -30 37 0
+-15 -21 47 0
+-8 24 40 0
+-3 -8 42 0
+-3 -8 -42 0
+-2 30 36 0
+-2 -30 36 0
+-4 -35 44 0
+42 -45 -50 0
+-42 -45 -50 0
+-11 15 -40 0
+3 46 48 0
+3 -46 48 0
+-11 30 50 0
+-16 30 50 0
+4 -36 -40 0
+8 46 47 0
+24 -40 44 0
+12 16 -46 0
+2 6 -36 0
+-6 -44 46 0
+-22 32 -36 0
+3 32 38 0
+-27 -35 38 0
+11 16 -47 0
+31 -45 -46 0
+19 -24 32 0
+-15 23 -31 0
+4 -34 -49 0
+11 -22 -49 0
+23 -26 50 0
+-9 -31 -32 0
+-2 -27 35 0
+26 34 45 0
+7 36 47 0
+-4 -30 49 0
+-26 -44 -50 0
+2 40 48 0
+26 -44 -47 0
+-18 19 -25 0
+-38 42 49 0
+13 -22 49 0
+-10 -32 -48 0
+2 -19 29 0
+-13 -15 26 0
+-10 -17 20 0
+-17 21 45 0
+-4 -13 -26 0
+-9 21 -48 0
+-10 35 44 0
+-32 -48 -49 0
+4 -16 -19 0
+-5 8 40 0
+15 -18 -35 0
+8 10 -47 0
+10 15 45 0
+10 -18 -34 0
+16 17 38 0
+11 -17 -38 0
\ No newline at end of file
diff --git a/test/resources/easyUnsat/aim-50-2_0-no-4.cnf b/test/resources/easyUnsat/aim-50-2_0-no-4.cnf
new file mode 100644
index 0000000..567c0ec
--- /dev/null
+++ b/test/resources/easyUnsat/aim-50-2_0-no-4.cnf
@@ -0,0 +1,111 @@
+c FILE: aim-50-2_0-no-4.cnf
+c
+c SOURCE: Kazuo Iwama, Eiji Miyano (miyano@cscu.kyushu-u.ac.jp),
+c and Yuichi Asahiro
+c
+c DESCRIPTION: Artifical instances from generator by source. Generators
+c and more information in sat/contributed/iwama.
+c
+c NOTE: Not Satisfiable
+c
+p cnf 50 100
+2 26 32 0
+2 -21 32 0
+2 3 -26 0
+-2 22 44 0
+-2 -22 44 0
+-2 23 -44 0
+3 -23 41 0
+3 -41 -44 0
+-3 9 20 0
+-3 -20 32 0
+7 9 -32 0
+-7 16 -32 0
+9 -16 -32 0
+1 16 37 0
+-1 16 26 0
+-16 26 37 0
+-9 -26 37 0
+5 -9 46 0
+11 21 -46 0
+5 21 -46 0
+-5 21 39 0
+-5 -37 -39 0
+-9 -21 -37 0
+10 -19 -48 0
+10 -13 -19 0
+5 -36 47 0
+-5 -36 47 0
+-16 42 -43 0
+-1 13 -39 0
+8 -27 30 0
+13 18 -30 0
+8 13 -18 0
+-13 15 -17 0
+-13 -15 -30 0
+-17 -27 -45 0
+-12 -27 -45 0
+-18 25 40 0
+-18 34 -40 0
+25 -34 48 0
+-19 -25 48 0
+-1 -12 -34 0
+20 -25 -43 0
+8 19 -45 0
+17 29 34 0
+-17 29 41 0
+15 -31 -35 0
+-15 -31 -35 0
+34 39 -43 0
+-11 -14 45 0
+-11 -12 -14 0
+-24 28 -39 0
+-8 -24 -30 0
+7 -25 45 0
+-7 -44 45 0
+-20 36 50 0
+-8 36 50 0
+-8 -20 -50 0
+20 -41 44 0
+28 -33 39 0
+28 -33 47 0
+10 27 38 0
+-10 27 30 0
+4 -10 38 0
+-6 -35 41 0
+12 18 22 0
+17 22 30 0
+12 29 42 0
+-4 23 31 0
+1 -4 -31 0
+-4 -6 -22 0
+-22 40 50 0
+4 -33 43 0
+-6 -21 42 0
+7 -24 -47 0
+-3 31 -46 0
+4 12 -36 0
+-11 -29 36 0
+-14 -23 -48 0
+-23 -37 -48 0
+15 -42 43 0
+-7 24 -50 0
+-10 33 46 0
+40 -42 46 0
+14 24 -49 0
+11 17 -38 0
+19 -28 -47 0
+14 24 27 0
+6 -15 43 0
+11 18 -41 0
+1 6 49 0
+-29 -47 -50 0
+25 -34 -38 0
+6 31 -49 0
+33 35 0
+33 35 48 0
+49 -49 0
+23 -29 -40 0
+19 -26 -42 0
+14 38 -38 0
+-28 -40 0
\ No newline at end of file
diff --git a/test/resources/sat/test.cnf b/test/resources/sat/test.cnf
new file mode 100644
index 0000000..141fa09
--- /dev/null
+++ b/test/resources/sat/test.cnf
@@ -0,0 +1,2 @@
+p cnf 1 1
+1 0
\ No newline at end of file
diff --git a/test/resources/sat/test2.cnf b/test/resources/sat/test2.cnf
new file mode 100644
index 0000000..72db760
--- /dev/null
+++ b/test/resources/sat/test2.cnf
@@ -0,0 +1,2 @@
+p cnf 1 1
+-1 0
\ No newline at end of file
diff --git a/test/resources/unsat/test3.cnf b/test/resources/unsat/test3.cnf
new file mode 100644
index 0000000..884631b
--- /dev/null
+++ b/test/resources/unsat/test3.cnf
@@ -0,0 +1,4 @@
+p cnf 1 3
+1 -1 0
+-1 0
+1 0