How to do MINLP?

97 views
Skip to first unread message

anon

unread,
Nov 7, 2016, 9:39:51 AM11/7/16
to julia-opt
Can anyone give me an example of MINLP in action using JuMP, including what solver you're using.

I've tried both KNITRO and CoinOptServices, for example:

using JuMP
using CoinOptServices

model = Model()
@variable(model, 0 <= n <= 5, Int)
@NLobjective(model, Max, exp(n))
solve(model, suppress_warnings=true)

println(getvalue(n))

But including the integer constraint in the @variable results in the error:

Error: LoadError: Solver does not support discrete variables

Changhyun Kwon

unread,
Nov 7, 2016, 11:25:15 AM11/7/16
to juli...@googlegroups.com

You can use CouenneNLSolver() or BonminNLSolver() via AmplNLWriter.jl package.






--
You received this message because you are subscribed to the Google Groups "julia-opt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to julia-opt+...@googlegroups.com.
Visit this group at https://groups.google.com/group/julia-opt.
For more options, visit https://groups.google.com/d/optout.

--



anon

unread,
Nov 7, 2016, 12:18:18 PM11/7/16
to julia-opt
@Changhyun Kwon 

Thanks! that did it.
Reply all
Reply to author
Forward
0 new messages