#include "classify.h"
#include "internal.h"
#include "print.h"
Go to the source code of this file.
◆ kissat_classify()
Definition at line 7 of file classify.c.
7 {
9 uint64_t clauses = s->clauses_binary + s->clauses_irredundant;
10 unsigned small_clauses_limit =
GET_OPTION (smallclauses);
11 if (clauses <= small_clauses_limit) {
12 solver->classification.small =
true;
13 solver->classification.bigbig =
false;
14 } else {
15 solver->classification.small =
false;
16 unsigned bigbigfraction =
GET_OPTION (bigbigfraction);
17 double percent = bigbigfraction / 1000.0;
18 double actual = kissat_percent (s->clauses_binary, clauses);
19 if (actual >= percent)
20 solver->classification.bigbig =
true;
21 else
22 solver->classification.bigbig =
false;
23 }
25 solver,
"formula classified as having a %s total number of clauses",
26 solver->classification.small ?
"small" :
"large");
28 solver,
"formula classified to have a %s binary clauses fraction",
29 solver->classification.bigbig ?
"large" :
"small");
30}
double percent(double a, double b)
#define kissat_very_verbose(...)