@@ -589,11 +589,15 @@ class theory_lra::imp {
589
589
590
590
void mk_clause (literal l1, literal l2, unsigned num_params, parameter * params) {
591
591
TRACE (" arith" , literal lits[2 ]; lits[0 ] = l1; lits[1 ] = l2; ctx ().display_literals_verbose (tout, 2 , lits); tout << " \n " ;);
592
- ctx ().mk_th_axiom (get_id (), l1, l2, num_params, params);
592
+ // static unsigned num_bin = 0;
593
+ // std::cout << "binary " << (num_bin++) << "\n";
594
+ ctx ().mk_th_lemma (get_id (), l1, l2, num_params, params);
593
595
}
594
596
595
597
void mk_clause (literal l1, literal l2, literal l3, unsigned num_params, parameter * params) {
596
598
TRACE (" arith" , literal lits[3 ]; lits[0 ] = l1; lits[1 ] = l2; lits[2 ] = l3; ctx ().display_literals_smt2 (tout, 3 , lits); tout << " \n " ;);
599
+ static unsigned num_ter = 0 ;
600
+ std::cout << " ternary " << (num_ter++) << " \n " ;
597
601
ctx ().mk_th_axiom (get_id (), l1, l2, l3, num_params, params);
598
602
}
599
603
@@ -3342,7 +3346,7 @@ class theory_lra::imp {
3342
3346
// The lemmas can come in batches
3343
3347
// and the same literal can appear in several lemmas in a batch: it becomes l_true
3344
3348
// in earlier processing, but it was not so when the lemma was produced
3345
- ctx ().mk_th_axiom (get_id (), m_core.size (), m_core.data ());
3349
+ ctx ().mk_th_lemma (get_id (), m_core.size (), m_core.data ());
3346
3350
}
3347
3351
}
3348
3352
@@ -3703,17 +3707,16 @@ class theory_lra::imp {
3703
3707
3704
3708
app_ref coeffs2app (u_map<rational> const & coeffs, rational const & offset, bool is_int) {
3705
3709
expr_ref_vector args (m);
3706
- for (auto const & kv : coeffs) {
3707
- theory_var w = kv.m_key ;
3710
+ for (auto const & [w, coeff] : coeffs) {
3708
3711
expr* o = get_enode (w)->get_expr ();
3709
- if (kv. m_value .is_zero ()) {
3712
+ if (coeff .is_zero ()) {
3710
3713
// continue
3711
3714
}
3712
- else if (kv. m_value .is_one ()) {
3715
+ else if (coeff .is_one ()) {
3713
3716
args.push_back (o);
3714
3717
}
3715
3718
else {
3716
- args.push_back (a.mk_mul (a.mk_numeral (kv. m_value , is_int), o));
3719
+ args.push_back (a.mk_mul (a.mk_numeral (coeff , is_int), o));
3717
3720
}
3718
3721
}
3719
3722
if (!offset.is_zero ()) {
0 commit comments