# JuMP Ipopt on Julia 0.7

**URL:** <https://discourse.julialang.org/t/jump-ipopt-on-julia-0-7/14041>\
**Category:** Optimization (Mathematical)\
**Tags:** jump\
**Created:** [August 25, 2018, 2:51pm UTC](https://discourse.julialang.org/t/jump-ipopt-on-julia-0-7/14041 "2018-08-25T14:51:27Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Bernard\_GODARD](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/bernard_godard/32/4155_2.png) [@Bernard\_GODARD](https://discourse.julialang.org/u/Bernard_GODARD)\
**Post date:** [August 25, 2018, 2:51pm UTC](https://discourse.julialang.org/t/jump-ipopt-on-julia-0-7/14041/1 "2018-08-25T14:51:27Z")

</div>

This is a continuation of [Julia 0.7 and JuMP: ERROR: cosd is not defined for type Variable - #5 by tkoolen](https://discourse.julialang.org/t/julia-0-7-and-jump-error-cosd-is-not-defined-for-type-variable/13296/5) trying to get my JuMP problem converted to Julia 0.7.

How to create an Ipopt problem with JuMP on Julia 0.7? According to [http://www.juliaopt.org/meetings/bordeaux2018/lubin.pdf](http://www.juliaopt.org/meetings/bordeaux2018/lubin.pdf) this should be possible with JuMP master.

```julia
(v0.7) pkg> st
    Status `~/.julia/environments/v0.7/Project.toml`
  [f83cbe0b] AstroTime v0.0.0 [`~/.julia/dev/AstroTime`]
  [6e4b80f9] BenchmarkTools v0.4.0
  [1537fe66] CALCEPH v0.0.3+ [`~/.julia/dev/CALCEPH`]
  [5ae59095] Colors v0.9.3
  [0c46a032] DifferentialEquations v5.3.0+ #master (https://github.com/JuliaDiffEq/DifferentialEquations.jl.git)
  [7a1cc6ca] FFTW v0.2.4
  [7073ff75] IJulia v1.9.3
  [c601a237] Interact v0.9.0
  [b6b21f68] Ipopt v0.3.0
  [4076af6c] JuMP v0.18.2+ #master (https://github.com/JuliaOpt/JuMP.jl.git)
  [76087f3c] NLopt v0.5.0
  [91a5bcdd] Plots v0.19.3
  [c46f51b8] ProfileView v0.3.0
  [9a3f8284] Random 

```

I have tried the optimizer keyword but I don’t know what object (no IpoptOptimizer) to pass it and it does not seem it accepts an optimizer keyword.

---

<div class="post-metadata">

**Author:** ![Bernard\_GODARD](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/bernard_godard/32/4155_2.png) [@Bernard\_GODARD](https://discourse.julialang.org/u/Bernard_GODARD)\
**Post date:** [August 25, 2018, 2:55pm UTC](https://discourse.julialang.org/t/jump-ipopt-on-julia-0-7/14041/2 "2018-08-25T14:55:31Z")

</div>

Maybe this is my problem:  
[https://github.com/JuliaOpt/Ipopt.jl/issues/129](https://github.com/JuliaOpt/Ipopt.jl/issues/129)

---

<div class="post-metadata">

**Author:** ![blegat](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/blegat/32/217090_2.png) [@blegat](https://discourse.julialang.org/u/blegat)\
**Post date:** [August 26, 2018, 7:21am UTC](https://discourse.julialang.org/t/jump-ipopt-on-julia-0-7/14041/3 "2018-08-26T07:21:54Z")

</div>

The syntax has changed since the workshop at Nordeaux. See [the doc](http://www.juliaopt.org/JuMP.jl/latest/solvers.html) for the new syntax.  
You now need to do

```julia
model = Model(with_optimizer(IpoptOptimizer))

```

---

<div class="post-metadata">

**Author:** ![Bernard\_GODARD](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/bernard_godard/32/4155_2.png) [@Bernard\_GODARD](https://discourse.julialang.org/u/Bernard_GODARD)\
**Post date:** [August 26, 2018, 2:39pm UTC](https://discourse.julialang.org/t/jump-ipopt-on-julia-0-7/14041/4 "2018-08-26T14:39:36Z")

</div>

Thank you for your reply. Unfortunately I need to update Ipopt to get IpoptOptimizer. However it cannot be updated without downgrading MathOptInterface from v0.5 to v0.4 which would not meet JuMP#master requirement.

---

<div class="post-metadata">

**Author:** ![blegat](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/blegat/32/217090_2.png) [@blegat](https://discourse.julialang.org/u/blegat)\
**Post date:** [August 26, 2018, 3:35pm UTC](https://discourse.julialang.org/t/jump-ipopt-on-julia-0-7/14041/5 "2018-08-26T15:35:32Z")

</div>

Yes, you need to go back a few commits in JuMP master or wait for Ipopt to be updated.
