From: Alexander Fedotov Date: Wed, 20 Apr 2016 13:30:20 +0000 (+0200) Subject: core mode checking added X-Git-Url: https://git.martlubbers.net/?a=commitdiff_plain;h=fa9ee9befed4b0d0b7ce4209a970ac415fbe9725;p=mc1516pa.git core mode checking added --- diff --git a/modelchecker/main.c b/modelchecker/main.c index 6c94363..2b2b602 100644 --- a/modelchecker/main.c +++ b/modelchecker/main.c @@ -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");