All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
lpi_xprs.c
Go to the documentation of this file.
24 /*--+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
37 int XPRS_CC XPRSstrongbranch( XPRSprob prob, const int _nbnd, const int *_mbndind, const char *_cbndtype,
97 typedef SCIP_DUALPACKET COLPACKET; /* each column needs two bits of information (basic/on_lower/on_upper) */
99 typedef SCIP_DUALPACKET ROWPACKET; /* each row needs two bit of information (basic/on_lower/on_upper) */
130 int par_presolve; /**< need to distinguish between the users setting and the optimizer setting of presolve */
539 /** converts Xpress' sen/rhs/rng triplets into SCIP's lhs/rhs pairs, only storing the left hand side */
584 /** converts Xpress' sen/rhs/rng triplets into SCIP's lhs/rhs pairs, only storing the right hand side */
713 assert(sizeof(SCIP_Real) == sizeof(double)); /* Xpress only works with doubles as floating points */
770 CHECK_ZEROPLPIE( XPRSloadlp((*lpi)->xprslp, "temp", 0, 0, NULL, NULL, NULL, NULL, &izero, NULL, NULL, NULL, NULL, NULL) );
870 /* get the longest name since we need to ask Xpress to make enough space before loading the LP. */
1061 /** deletes columns from SCIP_LP; the new position of a column must not be greater that its old position */
1144 CHECK_ZERO( XPRSaddrows(lpi->xprslp, nrows, nnonz, lpi->senarray, lpi->rhsarray, lpi->rngarray, mstart, ind, val) );
1217 /** deletes rows from SCIP_LP; the new position of a row must not be greater that its old position */
1366 SCIPdebugMessage("changing coefficient row %d, column %d in Xpress to %g\n", row, col, newval);
1411 /** multiplies a row with a non-zero scalar; for negative scalars, the row's sense is switched accordingly */
1437 SCIP_CALL( SCIPlpiGetRows(lpi, row, row, &lhs, &rhs, &nnonz, &beg, lpi->indarray, lpi->valarray) );
1466 /** multiplies a column with a non-zero scalar; the objective value is multiplied with the scalar, and the bounds
1495 SCIP_CALL( SCIPlpiGetCols(lpi, col, col, &lb, &ub, &nnonz, &beg, lpi->indarray, lpi->valarray) );
1594 /** gets columns from LP problem object; the arrays have to be large enough to store all values
1733 int namestoragesize, /**< size of namestorage (if 0, storageleft returns the storage needed) */
1748 int namestoragesize, /**< size of namestorage (if 0, -storageleft returns the storage needed) */
1895 const char* method /**< indicates the method to use ('p' - primal, 'd' - dual, 'b' - barrier) */
1909 SCIPdebugMessage("calling Xpress lp solver type %s: %d cols, %d rows\n", method, ncols, nrows);
2002 /** calls barrier or interior point algorithm to solve the LP with crossover to simplex basis */
2066 SCIPdebugMessage("calling Xpress strong branching on variable %d (%d iterations)\n", col, itlim);
2098 CHECK_ZERO( XPRSstrongbranch(lpi->xprslp, 2, mbndind, cbndtype, dbndval, itlim, dobjval, mstatus) );
2252 SCIPdebugMessage("calling Xpress strong branching on %d variables (%d iterations)\n", ncols, itlim);
2288 CHECK_ZERO( XPRSstrongbranch(lpi->xprslp, 2*ncols, mbndind, cbndtype, dbndval, itlim, dobjval, mstatus) );
2467 SCIP_CALL( lpiStrongbranches(lpi, cols, ncols, psols, itlim, down, up, downvalid, upvalid, iter) );
2510 SCIP_CALL( lpiStrongbranches(lpi, cols, ncols, psols, itlim, down, up, downvalid, upvalid, iter) );
2551 *primalfeasible = (SCIP_Bool) (lpi->solstat==XPRS_LP_OPTIMAL || lpi->solstat == XPRS_LP_OPTIMAL_SCALEDINFEAS || (lpi->solmethod == 'p' && lpi->solstat==XPRS_LP_UNBOUNDED));
2552 *dualfeasible = (SCIP_Bool) (lpi->solstat==XPRS_LP_OPTIMAL || lpi->solstat == XPRS_LP_OPTIMAL_SCALEDINFEAS || (lpi->solmethod == 'd' && lpi->solstat==XPRS_LP_INFEAS));
2557 /** returns TRUE iff LP is proven to have a primal unbounded ray (but not necessary a primal feasible point);
2571 /** returns TRUE iff LP is proven to have a primal unbounded ray (but not necessary a primal feasible point),
2610 /* If the solution status of Xpress is XPRS_LP_UNBOUNDED, it only means, there is an unbounded ray,
2644 return lpi->solstat == XPRS_LP_OPTIMAL || lpi->solstat == XPRS_LP_OPTIMAL_SCALEDINFEAS || (lpi->solstat == XPRS_LP_UNBOUNDED && lpi->solmethod == 'p');
2647 /** returns TRUE iff LP is proven to have a dual unbounded ray (but not necessary a dual feasible point);
2661 /** returns TRUE iff LP is proven to have a dual unbounded ray (but not necessary a dual feasible point),
2732 return lpi->solstat == XPRS_LP_OPTIMAL || lpi->solstat == XPRS_LP_OPTIMAL_SCALEDINFEAS || (lpi->solstat == XPRS_LP_INFEAS && lpi->solmethod == 'd');
2758 /* If the solution status of Xpress is XPRS_LP_UNBOUNDED, it only means, there is an unbounded ray,
2759 * but not necessarily a feasible primal solution. If primalfeasible == FALSE, we interpret this
2846 /** tries to reset the internal status of the LP solver in order to ignore an instability of the last solving call */
3075 * Such information is usually only available, if also a (maybe not optimal) solution is available.
3076 * The LPI should return SCIP_INVALID for @p quality, if the requested quantity is not available.
3104 /** gets current basis status for columns and rows; arrays must be large enough to store the basis status */
3183 /** returns the indices of the basic columns and rows; basic column n gives value n, basic row m gives value -1-m */
3195 assert((0 == SCIP_BASESTAT_LOWER) && (1 == SCIP_BASESTAT_BASIC) && (2 == SCIP_BASESTAT_UPPER) && (3 == SCIP_BASESTAT_ZERO));
3276 const SCIP_Real* binvrow_in, /**< row in (A_B)^-1 from prior call to SCIPlpiGetBInvRow(), or NULL */
3310 CHECK_ZERO( XPRSgetcols(lpi->xprslp, NULL, lpi->indarray, lpi->valarray, nrows, &nnonz, c, c) );
3347 CHECK_ZERO( XPRSgetcols(lpi->xprslp, NULL, lpi->indarray, lpi->valarray, nrows, &nnonz, c, c) );
3385 /* if there is no basis information available (e.g. after barrier without crossover), no state can be saved */
3400 SCIPdebugMessage("storing Xpress LPI state in %p (%d cols, %d rows)\n", (void*)*lpistate, ncols, nrows);
3413 /** loads LPi state (like basis information) into solver; note that the LP might have been extended with additional
3440 SCIPdebugMessage("loading LPI state %p (%d cols, %d rows) into Xpress\n", (void*)lpistate, lpistate->ncols, lpistate->nrows);
3486 SCIPmessagePrintWarning(lpi->messagehdlr, "Xpress interface does not implement SCIPlpiClearState()\n");
|