core mode checking added
authorAlexander Fedotov <soyaxhoya@gmail.com>
Wed, 20 Apr 2016 13:30:20 +0000 (15:30 +0200)
committerAlexander Fedotov <soyaxhoya@gmail.com>
Wed, 20 Apr 2016 13:30:20 +0000 (15:30 +0200)
modelchecker/main.c

index 6c94363..2b2b602 100644 (file)
@@ -118,7 +118,11 @@ void solve(FILE *inputstream)
                 t = t->next_rel;
                 //ERRPRINT("Satcount: %f\n", sylvan_satcount(new, init->vars.varset));
             }
-
+            double check = sylvan_satcount(sylvan_and(goal->bdd, new), init->vars.varset);
+            if (check > 0){
+                printf("Solution is found after %d iteration(s)!\n", iteration);
+                break;
+            }
         }
     }
     else printf("No solution found!\n");