User Tools

Site Tools


nlopt

Non-working NLopt

julia has many other optimization functions…some working, some not.

snippet.juliarepl
julia> using NLopt

julia> opt = Opt(:LD_NELDERMEAD, 2)  ## 2 dimensional optimization (x[1] and x[2]
Opt(:LD_MMA, 2)

julia> myfun(x::Vector, parms::Vector)= (x[1]2)^2 + (x[2]3)^2 + (x[1]*x[2])^2
myfun (generic function with 1 method)

julia> lower_bounds!(opt, [0,0])

julia> xtol_rel!(opt,1e–6)

julia> min_objective!(opt, myfun)

julia> optimize(opt, [1.0, 1.0])
SEGFAULT

Parallel Thread (Multicore) Algorithms

nlopt.txt · Last modified: 2018/06/13 15:08 (external edit)