This will install Ipopt.jl, as well as Ipopt itself. A binary will be downloaded
by default on macOS or Windows, and Ipopt will be automatically built from source
on Linux unless a pre-existing version is found on the
If your platform is not supported, or if you prefer to compile your own version
of Ipopt in order to use commercial sparse linear algebra libraries, use
the instructions below.
Make sure you have the required packages before installing, e.g.,
sudo apt-get install build-essential gfortran pkg-config liblapack-dev libblas-dev
The script below was tested successfully for installing Ipopt. You may modify the configuration options, but be sure to install Ipopt into the correct prefix location.
wget https://www.coin-or.org/download/source/Ipopt/Ipopt-3.12.8.tgz tar xvzf Ipopt-3.12.8.tgz cd Ipopt-3.12.8/ # Blas and Lapack must be installed already. If not, run # ThirdParty/Blas/get.Blas and ThirdParty/Lapack/get.Lapack. # ASL is required even if you do not plan to use it. cd ThirdParty/ASL/ ./get.ASL cd .. cd Mumps # Compiling Mumps requires gfortran. ./get.Mumps cd ../.. # Update the prefix location! The following is correct only for Julia 0.6. ./configure --prefix=$HOME/.julia/v0.6/Ipopt/deps/usr make make test make install
Now in Julia:
julia> Pkg.build("Ipopt") INFO: Building Ipopt julia> Pkg.test("Ipopt") ... INFO: Ipopt tests passed
Ipopt implements the solver-independent MathProgBase interface,
and so can be used within modeling software like JuMP.
The solver object is called
IpoptSolver. All options listed in the Ipopt documentation may be passed directly. For example, you can suppress output by saying
IpoptSolver(print_level=0). If you wish to pass an option specifically for the restoration phase, instead of using the prefix
resto., use the prefix
resto_. For example
Full documentation for the Ipopt C wrapper is available here. Use of the nonlinear MathProgBase interface is recommended over the low-level C interface because it permits one to easily switch between solvers.
5 days ago