This PR adds a proof for the tangent plane lemmas from nl-ext.
As this lemma uses some insight about the tangent plane of a multiplication term, this PR adds a new proof rule.
case PfRule::INT_TIGHT_LB: return "INT_TIGHT_LB";
case PfRule::INT_TIGHT_UB: return "INT_TIGHT_UB";
case PfRule::INT_TRUST: return "INT_TRUST";
+ case PfRule::ARITH_MULT_TANGENT: return "ARITH_MULT_TANGENT";
case PfRule::ARITH_OP_ELIM_AXIOM: return "ARITH_OP_ELIM_AXIOM";
//================================================= Unknown rule
case PfRule::UNKNOWN: return "UNKNOWN";
// Conclusion: (Q)
INT_TRUST,
+ //======== Multiplication tangent plane
+ // Children: none
+ // Arguments: (t, x, y, a, b, sgn)
+ // ---------------------
+ // Conclusion:
+ // sgn=-1: (= (<= t tplane) (or (and (<= x a) (>= y b)) (and (>= x a) (<= y b)))
+ // sgn= 1: (= (>= t tplane) (or (and (<= x a) (<= y b)) (and (>= x a) (>= y b)))
+ // Where x,y are real terms (variables or extended terms), t = (* x y)
+ // (possibly under rewriting), a,b are real constants, and sgn is either -1
+ // or 1. tplane is the tangent plane of x*y at (a,b): b*x + a*y - a*b
+ ARITH_MULT_TANGENT,
+
//================================================= Unknown rule
UNKNOWN,
};
Kind::AND, nm->mkNode(Kind::GEQ, a, a_v), b2)));
Trace("nl-ext-tplanes")
<< "Tangent plane lemma : " << tlem << std::endl;
+ CDProof* proof = nullptr;
+ if (d_data->isProofEnabled())
+ {
+ proof = d_data->getProof();
+ proof->addStep(tlem,
+ PfRule::ARITH_MULT_TANGENT,
+ {},
+ {t,
+ a,
+ b,
+ a_v,
+ b_v,
+ nm->mkConst(Rational(d == 0 ? -1 : 1))});
+ }
d_data->d_im.addPendingArithLemma(
- tlem, InferenceId::NL_TANGENT_PLANE, nullptr, asWaitingLemmas);
+ tlem, InferenceId::NL_TANGENT_PLANE, proof, asWaitingLemmas);
}
}
}