Skip to content

Commit 209366b

Browse files
committed
cleanup porting comments
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
1 parent 839594a commit 209366b

File tree

1 file changed

+9
-18
lines changed

1 file changed

+9
-18
lines changed

src/nlsat/nlsat_explain.cpp

+9-18
Original file line numberDiff line numberDiff line change
@@ -733,7 +733,6 @@ namespace nlsat {
733733
bool have_zero = false;
734734
for (unsigned i = 0; i < num_factors; i++) {
735735
f = m_factors.get(i);
736-
// std::cout << "f=";display(std::cout, f) << "\n";
737736
if (coeffs_are_zeroes_in_factor(f)) {
738737
have_zero = true;
739738
break;
@@ -1043,7 +1042,6 @@ namespace nlsat {
10431042
// Otherwise, the isolate_roots procedure will assume p is a constant polynomial.
10441043
m_am.isolate_roots(p, undef_var_assignment(m_assignment, y), roots);
10451044
unsigned num_roots = roots.size();
1046-
//#linxi begin add_cell_lits faster
10471045
bool all_lt = true;
10481046
for (unsigned i = 0; i < num_roots; i++) {
10491047
int s = m_am.compare(y_val, roots[i]);
@@ -1092,7 +1090,6 @@ namespace nlsat {
10921090
i_lower = j + 1;
10931091
}
10941092
}
1095-
//#linxi end add_cell_lits faster
10961093
}
10971094

10981095
if (!lower_inf) {
@@ -1148,7 +1145,6 @@ namespace nlsat {
11481145
// Otherwise, the isolate_roots procedure will assume p is a constant polynomial.
11491146
m_am.isolate_roots(p, undef_var_assignment(m_assignment, y), roots);
11501147
unsigned num_roots = roots.size();
1151-
//#linxi begin add_cell_lits faster
11521148
bool all_lt = true;
11531149
for (unsigned i = 0; i < num_roots; i++) {
11541150
int s = m_am.compare(y_val, roots[i]);
@@ -1196,7 +1192,6 @@ namespace nlsat {
11961192
i_lower = j + 1;
11971193
}
11981194
}
1199-
//#linxi end add_cell_lits faster
12001195
}
12011196

12021197
if (!lower_inf) {
@@ -1254,12 +1249,18 @@ namespace nlsat {
12541249
add_cell_lits(ps, x);
12551250
}
12561251
}
1257-
void project_cdcac(polynomial_ref_vector & ps, var max_x) {
1258-
bool first = true;
1259-
12601252

1253+
/**
1254+
* Sample Projection
1255+
* Reference:
1256+
* Haokun Li and Bican Xia.
1257+
* "Solving Satisfiability of Polynomial Formulas By Sample - Cell Projection"
1258+
* https://arxiv.org/abs/2003.00409
1259+
*/
1260+
void project_cdcac(polynomial_ref_vector & ps, var max_x) {
12611261
if (ps.empty())
12621262
return;
1263+
bool first = true;
12631264
m_todo.reset();
12641265
for (poly* p : ps) {
12651266
m_todo.insert(p);
@@ -1282,22 +1283,12 @@ namespace nlsat {
12821283
TRACE("nlsat_explain", tout << "project loop, processing var "; display_var(tout, x); tout << "\npolynomials\n";
12831284
display(tout, ps); tout << "\n";);
12841285

1285-
1286-
/**
1287-
* Sample Projection
1288-
* Reference:
1289-
* Haokun Li and Bican Xia.
1290-
* "Solving Satisfiability of Polynomial Formulas By Sample - Cell Projection"
1291-
* https://arxiv.org/abs/2003.00409
1292-
*/
1293-
12941286
if (first) {
12951287
add_lc(ps, x);
12961288
psc_discriminant(ps, x);
12971289
psc_resultant(ps, x);
12981290
first = false;
12991291
}
1300-
13011292
else {
13021293
add_lc(ps, x);
13031294
// add_sample_coeff(ps, x);

0 commit comments

Comments
 (0)