Optimization packages for the Julia language.

What is Julia?

"Julia is a high-level, high-performance dynamic programming language for technical computing". It is free (open source) and supports Windows, OSX, and Linux. It has a familiar syntax, works well with external libraries, is fast, and has advanced language features like metaprogramming that enable interesting possibilities for optimization software.

Case study: "Computing in Operations Research using Julia". INFORMS Journal on Computing. [PDF].

What is JuliaOpt?

JuliaOpt is an organization that brings together packages written in Julia that are related to optimization. All JuliaOpt packages should be high-quality, documented, tested, support the main operating systems, and interact with each other.

Getting Started

  1. You can find downloads and installation instructions for Julia for your operating system on the Julia site.
  2. To install a JuliaOpt package, simply use the Pkg.add command from inside Julia:
    julia> Pkg.update() # Get latest package info
    julia> Pkg.add("Optim")
    julia> Pkg.add("JuMP")
    julia> Pkg.add("Cbc") # and so on
  3. Open-source solvers will automatically be downloaded and installed in your Julia package directory. If you want to use an external commercial solver, you will need to download those before installing the corresponding JuliaOpt package.


We have a collection of JuliaOpt examples in the form of Jupyter/IJulia notebooks, including:

The source for these notebooks is available here.

Overview of Packages

JuMP Convex.jl MathProgBase.jl Cbc.jl Clp.jl CPLEX.jl ECOS.jl GLPK.jl Gurobi.jl Ipopt.jl KNITRO.jl Mosek.jl NLopt.jl SCS.jl Optim.jl LsqFit.jl CoinOptServices.jl AmplNLWriter.jl

JuliaOpt's packages can be loosely grouped into two sets. The first set are standalone Julia packages:

  • Optim.jl - Implementations in Julia of standard optimization algorithms for unconstrained or box-constrained problems such as BFGS, Nelder-Mead, conjugate gradient, etc. (documentation/code)
  • LsqFit.jl - Least-squares non-linear curve fitting in Julia. (documentation/code)

The second set comprises modeling languages (red), external solver interfaces (purple), and an abstraction layer over the solvers (green), primarily for constrained optimization:

  • JuMP - An algebraic modeling language for linear, quadratic, and nonlinear constrained optimization problems embedded in Julia. Generates models as quick as commercial modeling tools and supports advanced features like solver callbacks. (documentation, code)
  • Convex.jl - An algebraic modeling language for disciplined convex programming embedded in Julia. (documentation, code)
  • MathProgBase - A standardized interface implemented by all solvers that allows code to remain solver-agnostic. Used by JuMP and Convex.jl, but can be called by user code directly if a user doesn't want to go through a modeling language, but wishes to remain solver-independent. (documentation, code)

JuliaOpt provides wrappers for a wide variety of solvers. The following table summarizes the capabilities of each solver, and also shows the problem forms supported by the two modeling languages.

Key: Notes:
  1. Problem must be convex.
Bonmin (via AmplNLWriter.jl)
Cbc (.jl)
Clp (.jl)
Couenne (via AmplNLWriter.jl)
CPLEX (.jl) IP Callbacks
ECOS (.jl)
GLPK (.jl) IP Callbacks
Gurobi (.jl) IP Callbacks
Ipopt (.jl)
Artelys Knitro (.jl)
Mosek (.jl) 1
NLopt (.jl)
SCS (.jl)

Papers about JuliaOpt packages

  • I. Dunning, J. Huchette, and M. Lubin, "JuMP: A modeling language for mathematical optimization". [PDF]
  • M. Lubin and I. Dunning, "Computing in Operations Research using Julia". INFORMS Journal on Computing 27(2), pages 238-248, 2015 [DOI] [arXiv]
  • M. Udell, K. Mohan, D. Zeng, J. Hong, S. Diamond, and S. Boyd, "Convex Optimization in Julia". Proceedings of the 1st First Workshop for High Performance Technical Computing in Dynamic Languages, IEEE Press, 2014. [arXiv]

JuliaOpt packages used in courses at

  • MIT
  • Sapienza Università di Roma
  • Stanford University
  • Universidad Carlos III de Madrid
  • Université de Liège
  • University at Buffalo
  • University of Iowa
  • University of Southern California
  • University of South Florida
  • University of Wisconsin, Madison
  • Virginia Commonwealth University

Papers using JuliaOpt packages

  • R. Brandt and M. Bengtsson, "Fast-Convergent Distributed Coordinated Precoding for TDD Multicell MIMO Systems", IEEE Int. Workshop Computational Advances in Multi-Sensor Adaptive Process. (CAMSAP'15), 2015. [PDF] [Code]
  • D. Bertsimas and F. de Ruiter, "Duality in Two-stage Adaptive Linear Optimization: Faster Computation and Stronger Bounds". 2015. [PDF]
  • E. Anderes, S. Borgwardt, and J. Miller, "Discrete Wasserstein Barycenters: Optimal Transport for Discrete Data". 2015. [arXiv]
  • S. D. Gupta, J. K. Tobin, and L. Pavel, "Linear Programming Makes Railway Networks Energy-efficient". 2015. [arXiv]
  • T. Rossi, R. Pozzi, and M. Testa, "A preliminary proposal to include capacity constraint in the multi-product EOQ model using hybrid systems and integer linear programming". 2015. [DOI]
  • R. Giordano, T. Broderick, and M. Jordan, "Linear Response Methods for Accurate Covariance Estimates from Mean Field Variational Bayes". 2015. [arXiv]
  • J. Gorham and L. Mackey, "Measuring Sample Quality with Stein's Method". 2015. [arXiv]
  • J. Vielma, I. Dunning, J. Huchette, and M. Lubin, "Extended Formulations in Mixed Integer Conic Quadratic Programming". 2015. [PDF]
  • I. Dunning, V. Gupta, A. King, J. Kung, M. Lubin, and J. Silberholz, "A course on advanced software tools for Operations Research and Analytics". INFORMS Transactions on Education 15(2), pages 169-179, 2015. [DOI] [PDF]
  • J. Huchette, M. Lubin, and C. Petra. "Parallel algebraic modeling for stochastic optimization". 2014. Proceedings of HPTCDL '14. [PDF]
  • V. Gupta, "Data-driven models for uncertainty and behavior". 2014. [PDF]