Question about chosing a solver

124 views
Skip to first unread message

Murilo Souza

unread,
Apr 10, 2018, 10:29:21 AM4/10/18
to OPTI Toolbox Forum
Hello again,

I have a question about the solver that is going to be used to solve a problem.

In the first example of this page:


I just added this command, after the Initial Guess:

% Options
opts = optiset('solver','nomad','display','iter')

And even tried other solvers (like scip, for example)

But it's still using Bonmin to solve the problem, as you can see from the results:

opts = 

         solver: 'nomad'
        maxiter: 1500
       maxfeval: 10000
       maxnodes: 10000
        maxtime: 1000
        tolrfun: 1.0000e-07
        tolafun: 1.0000e-07
         tolint: 1.0000e-05
     solverOpts: []
    dynamicOpts: []
        iterfun: []
       warnings: 'critical'
        display: 'iter'
     derivCheck: 'off'

------------------------------------------------------
Mixed Integer Nonlinear Program (MINLP) Optimization
 min  f(x)
 s.t. rl <= Ax <= ru
      lb <= x <= ub
      cl <= c(x) <= cu
      xi = Integer / Binary
------------------------------------------------------
   Problem Properties: 
# Decision Variables:        4
# Constraints:              11
  # Linear Inequality:       2
  # Bounds:                  6
  # Binary Variables:        1
  # Integer Variables:       1
  # Nonlinear Inequality:    1
------------------------------------------------------
  Solver Parameters:
Solver:                    BONMIN
Objective Gradient:        @(x)mklJac(prob.fun,x,1) [numdiff]
Constraint Jacobian:       @(x)mklJac(prob.nlcon,x,nnl) [numdiff]
Jacobian Structure:        Assumed 100% Dense
Lagrangian Hessian:        Not Supplied
Hessian Structure:         Assumed 100% Dense
------------------------------------------------------

x =

    1.0000
    1.0000
    0.5001
         0


fval =

   -2.5001


exitflag =

     1


info = 

    Iterations: 0
         Nodes: 0
        AbsGap: 0.1179
        RelGap: 0.0453
          Time: 0.0956
     Algorithm: 'BONMIN: Branch & Bound using IPOPT & CBC'
        Status: 'Success'

Is there anything i'm doing wrong here? Sorry for the long post and probably for the silly question, i'm just not that good at programming/Matlab.

Jonathan Currie

unread,
Apr 11, 2018, 4:17:56 AM4/11/18
to OPTI Toolbox Forum
OPTI will automatically change the solver if the selected solver does not support the problem you are trying to solve. In this case NOMAD does not solve equality constrained MINLPs, so BONMIN is selected instead. You can see OPTI's decision to do this by enabling all warnings via: 

opts = optiset('warnings','all')

Jonathan

--
You received this message because you are subscribed to the Google Groups "OPTI Toolbox Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to opti-toolbox-forum+unsub...@googlegroups.com.
To post to this group, send email to opti-toolbox-forum@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Murilo Souza

unread,
Apr 11, 2018, 8:25:12 AM4/11/18
to OPTI Toolbox Forum
Oh, i see... thanks for the explanation Jonathan.

May i ask you one more thing... Does Baron solve non-convex problems with non-linear equalities and inequalities constraints? And can i use it in Matlab to solve problems with any numbers of variable, or just 10 variables?

Because i've followed the instructions found here:


And after running a problem with more than 10 variables, i got the following message:

BARON version 17.10.16. Built: WIN-64 Mon Oct 16 20:35:36 EDT 2017 
 
 BARON is a product of The Optimization Firm, LLC. http://www.minlp.com/ 
 No BARON license file found in user PATH.  Continuing in demo mode. 
 Model exceeds demo size (10 variables, 10 constraints, 50 nonlinearities) 
 A valid BARON license is required for this model. 
 BARON will exit now. 
 
                          *** Licensing error ***              
 
 All done 
Message has been deleted

Jonathan Currie

unread,
Apr 16, 2018, 2:59:13 AM4/16/18
to OPTI Toolbox Forum
BARON is a commercial solver and you will require a license for problems with more than 10 variables.


Jonathan

On Thu, Apr 12, 2018 at 12:25 AM, Murilo Souza <muriloasou...@gmail.com> wrote:
Oh, i see... thanks for the explanation Jonathan.

May i ask you one more thing... Does Baron solve non-convex problems with non-linear equalities and inequalities constraints? And can i use it in Matlab to solve problems with any numbers of variable, or just 10 variables?

Because i've followed the instructions found here:


And after running a problem with more than 10 variables, i got the following message:

BARON version 17.10.16. Built: WIN-64 Mon Oct 16 20:35:36 EDT 2017 
 
 BARON is a product of The Optimization Firm, LLC. http://www.minlp.com/ 
 No BARON license file found in user PATH.  Continuing in demo mode. 
 Model exceeds demo size (10 variables, 10 constraints, 50 nonlinearities) 
 A valid BARON license is required for this model. 
 BARON will exit now. 
 
                          *** Licensing error ***              
 
 All done 

Em terça-feira, 10 de abril de 2018 11:29:21 UTC-3, Murilo Souza escreveu:

--
Reply all
Reply to author
Forward
0 new messages