Initializing help system before first use

XPRBaddmipsol

XPRBaddmipsol


Purpose
Add a new feasible, infeasible or partial MIP solution to the Optimizer.
Synopsis
int XPRBaddmipsol(XPRBprob prob, XPRBsol sol, const char *name);
Arguments
prob 
Reference to a problem.
sol 
Reference to a solution.
name 
An optional name to associate with the solution. Can be NULL.
Return value
0 if function executed successfully, 1 otherwise.
Example
Add a MIP solution for problem expl2 to the Optimizer.
XPRBprob expl2;
XPRBsol sol;
   ...
XPRBaddmipsol(prob, sol, "myHeurSol");
XPRBdelsol(sol); /* Free the solution object */
/* Request notification of solution status after processing */
XPRSaddcbusersolnotify(XPRBgetXPRSprob(prob), solnotify, NULL, 0);
Further information
1. If the matrix loaded in the Optimizer does not correspond to the current state of the specified problem definition, it is regenerated automatically before adding the solution.
2. The XPRBmipoptimize function by default resets problem status including eventual loaded solutions; to avoid that, flag "c" should be specified for the alg argument of XPRBmipoptimize when called after XPRBaddmipsol.
3. The function returns immediately after passing the solution to the Optimizer. The solution is placed in a pool until the Optimizer is able to analyze the solution during a MIP solve.
4. If the provided solution is partial or found to be infeasible, a limited local search heuristic will be run in an attempt to find a close feasible integer solution. Values provided for continuous columns in partial solutions are currently ignored.
5. The usersolnotify callback can be used to discover the outcome of a loaded solution. The optional name provided as name will be returned in the callback.
Related topics

© 2001-2019 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.