MINLP
From OpenOpt
Mixed-Integer Non-Linear Problems (MINLP)
-
- subjected to
-
-
-
-
-
-
-
-
- (smooth differentiable functions)
-
- OpenOpt MINLP example
- FuncDesigner MINLP examples:
- simple (with automatic differentiation)
- example with specifiable accuracy (via interval analysis by interalg)
MINLP solvers connected to OpenOpt:
| Solver | License | Algorithm | Authors | Info |
|---|---|---|---|---|
| (coming) interalg | BSD | an interval algorithm | Dmitrey | searches global extremum with specifiable accuracy fTol: abs(f - f*) < fTol , where f* is theoretical optimal value. Can handle nonsmooth, multiextremum and even some discontinuous funcs like ceil, floor. |
| branb | BSD | branch-and-bound | Ingar Solberg, Institutt for teknisk kybernetikk, Norges Tekniske Hrgskole, Norway | This is translation of MATLABs fminconset routine to Python (by Dmitrey, with some minor changes). It recuires parameter "nlpSolver" like "ipopt', "scipy_lbfgsb", "scipy_tnc" etc for solving NLP subproblems. |
Note!
- MINLP is NP-Hard class of problems.
- Please pay attention: objective function and non-linear constraints should be defined in whole R^nVars, i.e. for discrete variables as well as for continuous.
- For branb It is assumed that objective function and constraints are at least unimodal (convex is preferred). If it is not the case, you'd better markup your Sk with ranges of integer values (like [-3,-2,-1,0,1,2,3,4,5]) and involve galileo solver from GLP (don't forget to provide correct lb and ub). Non-linear constraints can be handled by rather big penalty S: F(x) = f(x) + S * max(0,ci(x)) + S * max(abs(hj(x))), same trick for linear constraint if any are present.
- Then, for each problem with fixed discrete values you should solve Non-Linear subproblem with unfixed continuous variables via an NLP/NSP solver, i.e.
def auxObjFunc(z): # z_i are components of continuous variables # solve NLP (or NSP, if penalties for constraints are present) for objFunc(y) = f(y,Z) for Z = z (fixed), # y are continuous variables, z are discrete ones # eg if your discrete variables are in the tail of vector of optimized variables you could use objFunc = lambda y: f(hstack((y,z))) p2 = NLP(objFunc, zeros(len(y)), ...) r2 = p2.solve('ralg') # or another solver return r2.ff p = GLP(auxObjFunc, lb=lb, ub=ub) r = p.solve('galileo')


