use of com.microsoft.z3.Params in project bmoth by hhu-stups.
the class Z3SolverFactory method getZ3Solver.
static Solver getZ3Solver(Context ctx) {
Solver solver = ctx.mkSolver();
Params params = ctx.mkParams();
params.add("timeout", BMothPreferences.getIntPreference(BMothPreferences.IntPreference.Z3_TIMEOUT));
solver.setParameters(params);
return solver;
}
use of com.microsoft.z3.Params in project batfish by batfish.
the class Z3ContextJob method mkFixedpoint.
protected Fixedpoint mkFixedpoint(NodProgram program, boolean printAnswer) {
Context ctx = program.getNodContext().getContext();
Params p = ctx.mkParams();
p.add("timeout", _settings.getZ3timeout());
p.add("fixedpoint.engine", "datalog");
p.add("fixedpoint.datalog.default_relation", "doc");
p.add("fixedpoint.print_answer", printAnswer);
Fixedpoint fix = ctx.mkFixedpoint();
fix.setParameters(p);
for (FuncDecl relationDeclaration : program.getNodContext().getRelationDeclarations().values()) {
fix.registerRelation(relationDeclaration);
}
for (BoolExpr rule : program.getRules()) {
fix.addRule(rule, null);
}
return fix;
}