scip_validation.c
Go to the documentation of this file.
34 /*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
51 * - checking the feasibility of the incumbent solution in the original problem (using SCIPcheckSolOrig())
53 * - checking if the objective bounds computed by SCIP agree with external primal and dual reference bounds.
57 * For infeasible problems, +/-SCIPinfinity() should be passed as reference bounds depending on the objective sense
62 SCIP_Real primalreference, /**< external primal reference value for the problem, or SCIP_UNKNOWN */
66 SCIP_Bool* feasible, /**< pointer to store if the best solution is feasible in the original problem,
68 SCIP_Bool* primalboundcheck, /**< pointer to store if the primal bound respects the given dual reference
70 SCIP_Bool* dualboundcheck /**< pointer to store if the dual bound respects the given primal reference
129 /* check the primal and dual bounds computed by SCIP against the external reference values within reference tolerance */
131 if( SCIPgetNSols(scip) > 0 && ((SCIPgetObjsense(scip) == SCIP_OBJSENSE_MINIMIZE && SCIPisInfinity(scip, dualreference))
136 /* check if reference primal bound is not better than the proven dual bound and, if SCIP claims to be optimal,
142 /* compute the relative violation between the primal bound and dual reference value, and vice versa */
178 SCIPinfoMessage(scip, NULL, " %-17s: %10.8g (reference: %16.9e)\n", "primal violation", primviol, dualreference);
179 SCIPinfoMessage(scip, NULL, " %-17s: %10.8g (reference: %16.9e)\n", "dual violation", dualviol, primalreference);
SCIP_Bool SCIPisEQ(SCIP *scip, SCIP_Real val1, SCIP_Real val2)
Definition: scip_numerics.c:438
SCIP_RETCODE SCIPvalidateSolve(SCIP *scip, SCIP_Real primalreference, SCIP_Real dualreference, SCIP_Real reftol, SCIP_Bool quiet, SCIP_Bool *feasible, SCIP_Bool *primalboundcheck, SCIP_Bool *dualboundcheck)
Definition: scip_validation.c:60
public methods for SCIP parameter handling
Definition: struct_scip.h:59
Definition: type_prob.h:38
public methods for validation
public methods for numerical tolerances
public methods for querying solving statistics
Definition: struct_sol.h:64
Definition: type_retcode.h:33
SCIP_RETCODE SCIPgetRealParam(SCIP *scip, const char *name, SCIP_Real *value)
Definition: scip_param.c:298
public data structures and miscellaneous methods
SCIP_RETCODE SCIPcheckSolOrig(SCIP *scip, SCIP_SOL *sol, SCIP_Bool *feasible, SCIP_Bool printreason, SCIP_Bool completely)
Definition: scip_sol.c:3497
Definition: type_set.h:36
general public methods
public methods for solutions
public methods for message output
public methods for message handling
void SCIPinfoMessage(SCIP *scip, FILE *file, const char *formatstr,...)
Definition: scip_message.c:199
Definition: type_prob.h:39
Definition: objbenders.h:33
SCIP_RETCODE SCIPchgFeastol(SCIP *scip, SCIP_Real feastol)
Definition: scip_numerics.c:246
public methods for global and local (sub)problems