Examples of satisfiable()


Examples of de.fuberlin.wiwiss.d2rq.algebra.VariableConstraints.satisfiable()

        }
        nodeSets.add(Var.alloc(t.getSubject()), r.nodeMaker(TripleRelation.SUBJECT), new AliasMap(aliases));
      }

    }
    if (!nodeSets.satisfiable()) {
      return null;
    }
    return new TripleRelationJoiner(nodeSets, newPatterns, newRelations, useAllOptimizations);
  }
 
View Full Code Here

Examples of edu.mit.csail.sdg.alloy4compiler.translator.A4Solution.satisfiable()

        long tempoAntes = System.currentTimeMillis();

        while (ans != null) {
           System.out.println("Geracao: " + i);
          ans = ans.next();
          if (ans.satisfiable())
            cont++;

          else
            break;
          i++;
View Full Code Here

Examples of edu.mit.csail.sdg.alloy4compiler.translator.A4Solution.satisfiable()

    void runFor3(Expr expr) throws Err {
        A4Options opt = new A4Options();
        Command cmd = new Command(false, 3, 3, 3, expr.and(fact));
        A4Solution sol = TranslateAlloyToKodkod.execute_command(NOP, sigs, cmd, opt);
        System.out.println(sol.toString().trim());
        if (sol.satisfiable()) {
            System.out.println("In particular, File = " + sol.eval(file));
            System.out.println("In particular, Dir = " + sol.eval(dir));
            System.out.println("In particular, contains = " + sol.eval(contains));
            System.out.println("In particular, parent = " + sol.eval(parent));
        }
View Full Code Here

Examples of edu.mit.csail.sdg.alloy4compiler.translator.A4Solution.satisfiable()

                if (latestKodkod==null || latestModule==null || latestKodkodSRC==null)
                   {cb("pop", "Error: the SAT solver that generated the instance has exited,\nso we cannot enumerate unless you re-solve that command.\n"); return;}
                sol=latestKodkod;
                mod=latestModule;
            }
            if (!sol.satisfiable())
                {cb("pop", "Error: This command is unsatisfiable,\nso there are no solutions to enumerate."); return;}
            if (!sol.isIncremental())
                {cb("pop", "Error: This solution was not generated by an incremental SAT solver.\n" +
                "Currently only MiniSat and SAT4J are supported."); return;}
            int tries=0;
View Full Code Here

Examples of edu.mit.csail.sdg.alloy4compiler.translator.A4Solution.satisfiable()

                {cb("pop", "Error: This solution was not generated by an incremental SAT solver.\n" +
                "Currently only MiniSat and SAT4J are supported."); return;}
            int tries=0;
            while(true) {
                sol=sol.next();
                if (!sol.satisfiable())
                   {cb("pop", "There are no more satisfying instances.\n\n" +
                   "Note: due to symmetry breaking and other optimizations,\n" +
                   "some equivalent solutions may have been omitted."); return;}
                String toString = sol.toString();
                synchronized(SimpleReporter.class) {
View Full Code Here

Examples of edu.mit.csail.sdg.alloy4compiler.translator.A4Solution.satisfiable()

                final Command cmd=cmds.get(i);
                rep.tempfile=tempCNF;
                cb(out, "bold", "Executing \""+cmd+"\"\n");
                A4Solution ai=TranslateAlloyToKodkod.execute_commandFromBook(rep, world.getAllReachableSigs(), cmd, options);
                if (ai==null) result.add(null);
                else if (ai.satisfiable()) result.add(tempXML);
                else if (ai.highLevelCore().a.size()>0) result.add(tempCNF+".core");
                else result.add("");
            }
            (new File(tempdir)).delete(); // In case it was UNSAT, or canceled...
            if (result.size()>1) {
View Full Code Here

Examples of edu.mit.csail.sdg.alloy4compiler.translator.A4Solution.satisfiable()

                System.out.println("============ Command "+command+": ============");
                A4Solution ans = TranslateAlloyToKodkod.execute_command(rep, world.getAllReachableSigs(), command, options);
                // Print the outcome
                System.out.println(ans);
                // If satisfiable...
                if (ans.satisfiable()) {
                    // You can query "ans" to find out the values of each set or type.
                    // This can be useful for debugging.
                    //
                    // You can also write the outcome to an XML file
                    ans.writeXML("alloy_example_output.xml");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.