Dualization.jl
Dualization.jl is an extension package for MathOptInterface.jl that formulates the dual of conic optimization problems.
Dualization.jl has two main features:
- The
Dualization.dualizefunction that computes the dual formulation of either a MathOptInterface.jl or a JuMP model. - The
Dualization.dual_optimizerfunction that creates a MathOptInterface-compatible optimizer that solves the dual of the problem instead of the primal.
License
Dualization.jl is licensed under the MIT License.
Installation
Install Dualization using Pkg.add:
import PkgPkg.add("Dualization")Use with JuMP
To compute the dual formulation of a JuMP model, use dualize:
using JuMP, Dualizationmodel = Model()# ... build model ...dual_model = dualize(model)To solve the dual formulation of a JuMP model, create a dual_optimizer:
using JuMP, Dualization, SCSmodel = Model(dual_optimizer(SCS.Optimizer))# ... build model ...optimize!(model) # Solves the dual instead of the primalDocumentation
The documentation for Dualization.jl includes a detailed description of the dual reformulation, along with examples and an API reference.