nlpi_all.c
Go to the documentation of this file.
31/*---+----1----+----2----+----3----+----4----+----5----+----6----+----7----+----8----+----9----+----0----+----1----+----2*/
42#define NLPI_DESC "NLP interface that uses all available NLP interfaces" /**< description of solver */
168 SCIP_CALL( SCIPaddNlpiVars(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], nvars, lbs, ubs, varnames) );
190 SCIP_CALL( SCIPaddNlpiConstraints(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], nconss, lhss, rhss,
212 SCIP_CALL( SCIPsetNlpiObjective(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], nlins, lininds, linvals, expr, constant) );
233 SCIP_CALL( SCIPchgNlpiVarBounds(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], nvars, indices, lbs, ubs) );
254 SCIP_CALL( SCIPchgNlpiConsSides(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], nconss, indices, lhss, rhss) );
283 SCIP_CALL( SCIPdelNlpiVarSet(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], tmpdstats, dstatssize) );
287 /* NOTE this works only when all dstats array are the same after calling the nlpidelvarset callback
288 * As long as all solvers use the SCIP NLPI oracle to store the NLP problem data, this is the case.
291 SCIP_CALL( SCIPdelNlpiVarSet(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], dstats, dstatssize) );
323 SCIP_CALL( SCIPdelNlpiConsSet(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], tmpdstats, dstatssize) );
327 /* NOTE this works only when all dstats array are the same after calling the nlpidelconsset callback
328 * As long as all solvers use the SCIP NLPI oracle to store the NLP problem data, this is the case.
331 SCIP_CALL( SCIPdelNlpiConsSet(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], dstats, dstatssize) );
355 SCIP_CALL( SCIPchgNlpiLinearCoefs(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], idx, nvals, varidxs, vals) );
376 SCIP_CALL( SCIPchgNlpiExpr(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], idxcons, expr) );
397 SCIP_CALL( SCIPchgNlpiObjConstant(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], objconstant) );
418 SCIP_CALL( SCIPsetNlpiInitialGuess(scip, nlpidata->nlpis[i], problem->nlpiproblems[i], primalvalues, consdualvalues,
477 else if( bestsolstat >= SCIP_NLPSOLSTAT_LOCINFEASIBLE && solstat <= SCIP_NLPSOLSTAT_LOCINFEASIBLE )
531 return SCIPgetNlpiSolstat(scip, nlpidata->nlpis[problem->bestidx], problem->nlpiproblems[problem->bestidx]);
548 return SCIPgetNlpiTermstat(scip, nlpidata->nlpis[problem->bestidx], problem->nlpiproblems[problem->bestidx]);
565 SCIP_CALL( SCIPgetNlpiSolution(scip, nlpidata->nlpis[problem->bestidx], problem->nlpiproblems[problem->bestidx],
585 SCIP_CALL( SCIPgetNlpiStatistics(scip, nlpidata->nlpis[problem->bestidx], problem->nlpiproblems[problem->bestidx],
595/** create solver interface for the solver "All" and includes it into SCIP, if at least 2 NLPIs have already been included
630 nlpiChgObjConstantAll, nlpiSetInitialGuessAll, nlpiSolveAll, nlpiGetSolstatAll, nlpiGetTermstatAll,
#define SCIPfreeBlockMemoryArrayNull(scip, ptr, num)
Definition: scip_mem.h:111
SCIP_RETCODE SCIPincludeNlpi(SCIP *scip, const char *name, const char *description, int priority, SCIP_DECL_NLPICOPY((*nlpicopy)), SCIP_DECL_NLPIFREE((*nlpifree)), SCIP_DECL_NLPIGETSOLVERPOINTER((*nlpigetsolverpointer)), SCIP_DECL_NLPICREATEPROBLEM((*nlpicreateproblem)), SCIP_DECL_NLPIFREEPROBLEM((*nlpifreeproblem)), SCIP_DECL_NLPIGETPROBLEMPOINTER((*nlpigetproblempointer)), SCIP_DECL_NLPIADDVARS((*nlpiaddvars)), SCIP_DECL_NLPIADDCONSTRAINTS((*nlpiaddconstraints)), SCIP_DECL_NLPISETOBJECTIVE((*nlpisetobjective)), SCIP_DECL_NLPICHGVARBOUNDS((*nlpichgvarbounds)), SCIP_DECL_NLPICHGCONSSIDES((*nlpichgconssides)), SCIP_DECL_NLPIDELVARSET((*nlpidelvarset)), SCIP_DECL_NLPIDELCONSSET((*nlpidelconsset)), SCIP_DECL_NLPICHGLINEARCOEFS((*nlpichglinearcoefs)), SCIP_DECL_NLPICHGEXPR((*nlpichgexpr)), SCIP_DECL_NLPICHGOBJCONSTANT((*nlpichgobjconstant)), SCIP_DECL_NLPISETINITIALGUESS((*nlpisetinitialguess)), SCIP_DECL_NLPISOLVE((*nlpisolve)), SCIP_DECL_NLPIGETSOLSTAT((*nlpigetsolstat)), SCIP_DECL_NLPIGETTERMSTAT((*nlpigettermstat)), SCIP_DECL_NLPIGETSOLUTION((*nlpigetsolution)), SCIP_DECL_NLPIGETSTATISTICS((*nlpigetstatistics)), SCIP_NLPIDATA *nlpidata)
Definition: scip_nlpi.c:108
Definition: objbenders.h:44
static SCIP_DECL_NLPIGETSOLSTAT(nlpiGetSolstatAll)
Definition: nlpi_all.c:519
static SCIP_DECL_NLPIGETSOLUTION(nlpiGetSolutionAll)
Definition: nlpi_all.c:553
static SCIP_DECL_NLPICHGOBJCONSTANT(nlpiChgObjConstantAll)
Definition: nlpi_all.c:384
static SCIP_DECL_NLPICHGVARBOUNDS(nlpiChgVarBoundsAll)
Definition: nlpi_all.c:220
static SCIP_DECL_NLPISETOBJECTIVE(nlpiSetObjectiveAll)
Definition: nlpi_all.c:199
static SCIP_DECL_NLPICREATEPROBLEM(nlpiCreateProblemAll)
Definition: nlpi_all.c:101
static SCIP_DECL_NLPICHGCONSSIDES(nlpiChgConsSidesAll)
Definition: nlpi_all.c:241
static SCIP_DECL_NLPIGETSTATISTICS(nlpiGetStatisticsAll)
Definition: nlpi_all.c:573
static SCIP_DECL_NLPISETINITIALGUESS(nlpiSetInitialGuessAll)
Definition: nlpi_all.c:405
static SCIP_DECL_NLPIADDCONSTRAINTS(nlpiAddConstraintsAll)
Definition: nlpi_all.c:177
static SCIP_DECL_NLPICHGLINEARCOEFS(nlpiChgLinearCoefsAll)
Definition: nlpi_all.c:342
static SCIP_DECL_NLPIFREEPROBLEM(nlpiFreeProblemAll)
Definition: nlpi_all.c:129
static SCIP_DECL_NLPIGETTERMSTAT(nlpiGetTermstatAll)
Definition: nlpi_all.c:536
static SCIP_DECL_NLPIDELCONSSET(nlpiDelConstraintSetAll)
Definition: nlpi_all.c:302
NLP interface that uses all available NLP interfaces.
public methods for message output
public methods for memory management
public methods for NLPI solver interfaces
public methods for numerical tolerances
Definition: type_nlpi.h:198
Definition: nlpi_all.c:56
Definition: struct_nlpi.h:47
Definition: struct_scip.h:70