# Optimization (Mathematical)

**URL:** https://discourse.julialang.org/c/domain/opt/13.md

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

---

## [About the Optimization (Mathematical) category](https://discourse.julialang.org/t/about-the-optimization-mathematical-category/90)

<div class="topic-metadata">

**Author:** [@StefanKarpinski](https://discourse.julialang.org/u/StefanKarpinski)\
**Replies:** 2\
**Last updated:** [July 4, 2019, 4:17pm UTC](https://discourse.julialang.org/t/about-the-optimization-mathematical-category/90 "2019-07-04T16:17:22Z")

</div>

For discussion of mathematical optimization software in Julia. This includes modeling software and solvers for linear optimization, mixed-integer optimization, convex optimization, nonlinear optimization, semidefinite op…

---

## [In my JuMP model, the LP file preserves the original variable names, but the MPS file appears to rename them, so how can I map the Gurobi .sol solution back to the original JuMP variables?](https://discourse.julialang.org/t/in-my-jump-model-the-lp-file-preserves-the-original-variable-names-but-the-mps-file-appears-to-rename-them-so-how-can-i-map-the-gurobi-sol-solution-back-to-the-original-jump-variables/139462)

<div class="topic-metadata">

**Author:** [@amit\_97](https://discourse.julialang.org/u/amit_97)\
**Replies:** 2\
**Last updated:** [September 14, 2026, 10:19pm UTC](https://discourse.julialang.org/t/in-my-jump-model-the-lp-file-preserves-the-original-variable-names-but-the-mps-file-appears-to-rename-them-so-how-can-i-map-the-gurobi-sol-solution-back-to-the-original-jump-variables/139462 "2026-09-14T22:19:23Z")

</div>

Hi everyone, I’m generating both .lp and .mps files from the same JuMP model using Gurobi. In the LP file, the original JuMP variable names are preserved, for example: 1200 x2\[1,(1,\_0)\] - 41054.62117964038 B2\[1,(1,\_0)…

---

## [The Uno (Unifying Nonlinear Optimization) solver](https://discourse.julialang.org/t/the-uno-unifying-nonlinear-optimization-solver/115883)

<div class="topic-metadata">

**Author:** [@cvanaret](https://discourse.julialang.org/u/cvanaret)\
**Replies:** 61\
**Last updated:** [September 10, 2026, 10:08am UTC](https://discourse.julialang.org/t/the-uno-unifying-nonlinear-optimization-solver/115883 "2026-09-10T10:08:44Z")

</div>

Dear all, For the past 6 years, I have been working (on and off, this year full time) on Uno, a modular C++ solver for nonconvex optimization. It unifies the workflows of most gradient-based iterative methods (such as S…

---

## [Connection between BFGS and ROOT.Minuit. Stopping criteria](https://discourse.julialang.org/t/connection-between-bfgs-and-root-minuit-stopping-criteria/48729)

<div class="topic-metadata">

**Author:** [@misha\_mikhasenko](https://discourse.julialang.org/u/misha_mikhasenko)\
**Replies:** 9\
**Last updated:** [August 11, 2026, 8:00am UTC](https://discourse.julialang.org/t/connection-between-bfgs-and-root-minuit-stopping-criteria/48729 "2026-08-11T08:00:01Z")

</div>

Dear experts on optimization problems, I am trying to establish a connection between the common tools in High Energy Physics (HEP) and Julia ecosystem. In HEP, the main tool for optimization is Minuit library. Nowadays…

---

## [Julia stability vs Rust for Scientific Computing](https://discourse.julialang.org/t/julia-stability-vs-rust-for-scientific-computing/137094)

<div class="topic-metadata">

**Author:** [@gunner](https://discourse.julialang.org/u/gunner)\
**Replies:** 43\
**Last updated:** [August 10, 2026, 12:33pm UTC](https://discourse.julialang.org/t/julia-stability-vs-rust-for-scientific-computing/137094 "2026-08-10T12:33:08Z")

</div>

Hi everyone! I’ve been seriously considering investing time into Julia for scientific computing and operations research, and I genuinely want it to succeed: the promise of high-level syntax with near-C performance is inc…

---

## [Ipopt has trouble with \`Vector{AffExpr} in MOI.Zeros\`](https://discourse.julialang.org/t/ipopt-has-trouble-with-vector-affexpr-in-moi-zeros/138395)

<div class="topic-metadata">

**Author:** [@bernardofpc](https://discourse.julialang.org/u/bernardofpc)\
**Replies:** 10\
**Last updated:** [August 8, 2026, 8:30am UTC](https://discourse.julialang.org/t/ipopt-has-trouble-with-vector-affexpr-in-moi-zeros/138395 "2026-08-08T08:30:50Z")

</div>

I have a JuMP model where solving with HiGHS and Ipopt results in different objective\_values. A JuMP Model ├ solver: Ipopt ├ objective\_sense: MIN\_SENSE │ └ objective\_function\_type: AffExpr ├ num\_variables: 54 ├ num\_cons…

---

## [Improving JuMP for AI agents](https://discourse.julialang.org/t/improving-jump-for-ai-agents/138437)

<div class="topic-metadata">

**Author:** [@odow](https://discourse.julialang.org/u/odow)\
**Replies:** 6\
**Last updated:** [August 3, 2026, 3:38pm UTC](https://discourse.julialang.org/t/improving-jump-for-ai-agents/138437 "2026-08-03T15:38:10Z")

</div>

Attention JuMP users! In the last release we spent some time improving JuMP for use by AI agents. Error messages are now clearer and include an actionable next step, which helps agents debug issues. (This also helps reg…

---

## [Confused by Gurobi's primal simplex algorithm](https://discourse.julialang.org/t/confused-by-gurobis-primal-simplex-algorithm/138318)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 5\
**Last updated:** [July 18, 2026, 1:42am UTC](https://discourse.julialang.org/t/confused-by-gurobis-primal-simplex-algorithm/138318 "2026-07-18T01:42:09Z")

</div>

I have some my own understanding about the primal simplex algorithm and the dual simplex algorithm. (Suppose the original primal-side problem is min-cost.) For the primal simplex algorithm, the idea is to maintain prima…

---

## [Why CPLEX’s Automatic Benders Outperforms Callback Benders in Julia?](https://discourse.julialang.org/t/why-cplex-s-automatic-benders-outperforms-callback-benders-in-julia/134440)

<div class="topic-metadata">

**Author:** [@ASUKaiwenFang](https://discourse.julialang.org/u/ASUKaiwenFang)\
**Replies:** 14\
**Last updated:** [July 11, 2026, 1:59pm UTC](https://discourse.julialang.org/t/why-cplex-s-automatic-benders-outperforms-callback-benders-in-julia/134440 "2026-07-11T13:59:35Z")

</div>

Hi all, I am trying to understand how to reproduce CPLEX’s automatic Benders decomposition using callbacks in Julia (via CPLEX.jl). CPLEX provides an automatic Benders mode, and the underlying procedure is described in …

---

## [Optimization.jl - Define the objective function and its gradient in the same function](https://discourse.julialang.org/t/optimization-jl-define-the-objective-function-and-its-gradient-in-the-same-function/137968)

<div class="topic-metadata">

**Author:** [@Maucejo](https://discourse.julialang.org/u/Maucejo)\
**Replies:** 3\
**Last updated:** [July 7, 2026, 6:30am UTC](https://discourse.julialang.org/t/optimization-jl-define-the-objective-function-and-its-gradient-in-the-same-function/137968 "2026-07-07T06:30:44Z")

</div>

Hi all, I am working on an optimization problem involving Complex Gaussian Processes and Kalman Filter. To optimize the hyperparameters of the kernels, I use Optimization.jl. Because I have calculated the analytical grad…

---

## [Decomposing a scenario-feasibility MILP with binary recourse in JuMP](https://discourse.julialang.org/t/decomposing-a-scenario-feasibility-milp-with-binary-recourse-in-jump/137898)

<div class="topic-metadata">

**Author:** [@decomp-lab](https://discourse.julialang.org/u/decomp-lab)\
**Replies:** 10\
**Last updated:** [July 5, 2026, 10:52pm UTC](https://discourse.julialang.org/t/decomposing-a-scenario-feasibility-milp-with-binary-recourse-in-jump/137898 "2026-07-05T22:52:47Z")

</div>

I have a two-stage multi-scenario MILP in JuMP with an inventory/order-flow structure. The first-stage variables are shared across all scenarios. Each scenario then has its own continuous flow variables and binary timin…

---

## [Why doesn't the solver reach the optimal solution?](https://discourse.julialang.org/t/why-doesnt-the-solver-reach-the-optimal-solution/137852)

<div class="topic-metadata">

**Author:** [@HenriDeh](https://discourse.julialang.org/u/HenriDeh)\
**Replies:** 7\
**Last updated:** [July 1, 2026, 3:14am UTC](https://discourse.julialang.org/t/why-doesnt-the-solver-reach-the-optimal-solution/137852 "2026-07-01T03:14:12Z")

</div>

Hello, I am working on improving a formulation of an optimization problem with JuMP and have encountered an issue that has been blocking me for several days. After extensive debugging and manual verification, I am reason…

---

## [Making a Universal Differential Equation Faster](https://discourse.julialang.org/t/making-a-universal-differential-equation-faster/137829)

<div class="topic-metadata">

**Author:** [@Ashima\_Kalathingal](https://discourse.julialang.org/u/Ashima_Kalathingal)\
**Replies:** 1\
**Last updated:** [June 28, 2026, 1:57am UTC](https://discourse.julialang.org/t/making-a-universal-differential-equation-faster/137829 "2026-06-28T01:57:32Z")

</div>

I have a two-state ODE, one of which is embedded in a neural network, making it a UDE. I am using 9 datasets for training, resulting in 9 distinct ODEs. prob1 = ODEProblem(UDE\_model1!,\[SOC0\_1, T∞1\],(time1\[1\],time1\[end\])…

---

## [How does ForwardDiff.jl and FiniteDiff.jl handle edge-hitting cases?](https://discourse.julialang.org/t/how-does-forwarddiff-jl-and-finitediff-jl-handle-edge-hitting-cases/137828)

<div class="topic-metadata">

**Author:** [@Xu\_Shan](https://discourse.julialang.org/u/Xu_Shan)\
**Replies:** 3\
**Last updated:** [June 27, 2026, 11:18pm UTC](https://discourse.julialang.org/t/how-does-forwarddiff-jl-and-finitediff-jl-handle-edge-hitting-cases/137828 "2026-06-27T23:18:02Z")

</div>

Hi guys, I am using ForwardDiff.jl to calculate the parameter uncertainty in my model (see below about the more detailed information…). I am wondering, how does ForwardDiff.jl and FiniteDiff.jl handle the edge-hitting p…

---

## [Hexaly solver with JuMP](https://discourse.julialang.org/t/hexaly-solver-with-jump/124827)

<div class="topic-metadata">

**Author:** [@baprata](https://discourse.julialang.org/u/baprata)\
**Replies:** 8\
**Last updated:** [June 26, 2026, 7:45pm UTC](https://discourse.julialang.org/t/hexaly-solver-with-jump/124827 "2026-06-26T19:45:57Z")

</div>

Dear Colleagues, Is it feasible to call the Hexaly solver (https://www.hexaly.com/) within the JuMP library? If so, could someone provide some source code with an example? Best regards, Bruno

---

## [Question about SDDP.jl](https://discourse.julialang.org/t/question-about-sddp-jl/137741)

<div class="topic-metadata">

**Author:** [@david-hri](https://discourse.julialang.org/u/david-hri)\
**Replies:** 2\
**Last updated:** [June 26, 2026, 8:15am UTC](https://discourse.julialang.org/t/question-about-sddp-jl/137741 "2026-06-26T08:15:57Z")

</div>

Hello, I am new to SDDP.jl, so my question may be naive. I currently have a working SDDP model in which the generation profits are computed using a fixed hydraulic head effect (so the efficiency does not depend on the…

---

## [Memory blow-up when solving a sparse affine Hermitian SDP translated from YALMIP to JuMP](https://discourse.julialang.org/t/memory-blow-up-when-solving-a-sparse-affine-hermitian-sdp-translated-from-yalmip-to-jump/137744)

<div class="topic-metadata">

**Author:** [@hz-xiaxz](https://discourse.julialang.org/u/hz-xiaxz)\
**Replies:** 10\
**Last updated:** [June 23, 2026, 7:24am UTC](https://discourse.julialang.org/t/memory-blow-up-when-solving-a-sparse-affine-hermitian-sdp-translated-from-yalmip-to-jump/137744 "2026-06-23T07:24:42Z")

</div>

Hi JuMP developers, I am translating a MATLAB/YALMIP semidefinite program to Julia/JuMP + MosekTools. The model comes from a many-body bootstrap calculation. The MATLAB/YALMIP version can solve a small 3 x 3 lattice cas…

---

## [ANN: JuMP-dev 2026 talk recordings](https://discourse.julialang.org/t/ann-jump-dev-2026-talk-recordings/137627)

<div class="topic-metadata">

**Author:** [@odow](https://discourse.julialang.org/u/odow)\
**Replies:** 0\
**Last updated:** [June 14, 2026, 10:27pm UTC](https://discourse.julialang.org/t/ann-jump-dev-2026-talk-recordings/137627 "2026-06-14T22:27:41Z")

</div>

Hi all, Talk recordings from JuMP-dev 2026 are rolling out on this playlist. Check them out here: Cheers, Oscar

---

## [How to manage memory when using JuMP+Gurobi?](https://discourse.julialang.org/t/how-to-manage-memory-when-using-jump-gurobi/136807)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 10\
**Last updated:** [June 11, 2026, 9:18pm UTC](https://discourse.julialang.org/t/how-to-manage-memory-when-using-jump-gurobi/136807 "2026-06-11T21:18:30Z")

</div>

Observe this usr@usr:~/julia\_projects/uc/Uc$ julia --project=. --threads=1,0 \_ \_ \_ \_(\_)\_ | Documentation: https://docs.julialang.org (\_) | (\_) (\_) | \_ \_ \_| |\_ \_\_ \_ | Type "…

---

## [Starting to learn about optimization](https://discourse.julialang.org/t/starting-to-learn-about-optimization/137481)

<div class="topic-metadata">

**Author:** [@Benny](https://discourse.julialang.org/u/Benny)\
**Replies:** 11\
**Last updated:** [June 9, 2026, 1:37pm UTC](https://discourse.julialang.org/t/starting-to-learn-about-optimization/137481 "2026-06-09T13:37:43Z")

</div>

I’m considering tackling a problem that appears to have a fixed handful of cutoffs and a performance metric, so I started reading a bit about optimization with essentially zero initial knowledge (not sure ordinary least …

---

## [Derivative-free optimization of bounded nonlinear least squares](https://discourse.julialang.org/t/derivative-free-optimization-of-bounded-nonlinear-least-squares/137302)

<div class="topic-metadata">

**Author:** [@claudiop21](https://discourse.julialang.org/u/claudiop21)\
**Replies:** 13\
**Last updated:** [May 31, 2026, 5:28pm UTC](https://discourse.julialang.org/t/derivative-free-optimization-of-bounded-nonlinear-least-squares/137302 "2026-05-31T17:28:40Z")

</div>

Hello everybody! I am looking for an optimization package to solve the following minimization problem: \\min\_{\\bf x \\in \\Omega} \\frac{1}{2}||{\\bf f} ({\\bf x})||^2 + \\lambda ||{\\bf x}||^2, where \\Omega is a bounded dom…

---

## [Creating JuMP decision variables more cautiously](https://discourse.julialang.org/t/creating-jump-decision-variables-more-cautiously/137208)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 4\
**Last updated:** [May 21, 2026, 2:52am UTC](https://discourse.julialang.org/t/creating-jump-decision-variables-more-cautiously/137208 "2026-05-21T02:52:31Z")

</div>

I’m studying the Unit Commitment problem which typically has a 24-hour planning horizon. So each generator (if we use the 2-Bin formulation with turn-on decision u and ON/OFF state decision x) will have at least 48 binar…

---

## [Does anybody know OpenMDAO](https://discourse.julialang.org/t/does-anybody-know-openmdao/122840)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 3\
**Last updated:** [May 19, 2026, 4:08pm UTC](https://discourse.julialang.org/t/does-anybody-know-openmdao/122840 "2026-05-19T16:08:39Z")

</div>

One of our project partners suggested to use GitHub - OpenMDAO/OpenMDAO: OpenMDAO repository. for control co-design, which is based on Python. Is this a good framework, or are there better alternatives using Julia?

---

## [Open source Solver to replace CPLEX in example?](https://discourse.julialang.org/t/open-source-solver-to-replace-cplex-in-example/137097)

<div class="topic-metadata">

**Author:** [@rt9f](https://discourse.julialang.org/u/rt9f)\
**Replies:** 6\
**Last updated:** [May 17, 2026, 8:03am UTC](https://discourse.julialang.org/t/open-source-solver-to-replace-cplex-in-example/137097 "2026-05-17T08:03:35Z")

</div>

Ten years ago this week, I read an article entitled Optimization in Julia. It was my first introduction to Julia and a great example of how easy one can define a constrained optimization problem in JuMP. The example used…

---

## [Tree-Structured Parzen Estimator (TPE) algorithm](https://discourse.julialang.org/t/tree-structured-parzen-estimator-tpe-algorithm/137001)

<div class="topic-metadata">

**Author:** [@Resul.Akay](https://discourse.julialang.org/u/Resul.Akay)\
**Replies:** 1\
**Last updated:** [May 6, 2026, 8:37am UTC](https://discourse.julialang.org/t/tree-structured-parzen-estimator-tpe-algorithm/137001 "2026-05-06T08:37:49Z")

</div>

Hello everyone, Is there any package that implements Tree-Structured Parzen Estimator (TPE) algorithm in Julia. TPE is the same algorithm behind Optuna and Hyperopt, two of the most widely used hyperparameter tuning fr…

---

## [Multi objective Markov decision processes](https://discourse.julialang.org/t/multi-objective-markov-decision-processes/111982)

<div class="topic-metadata">

**Author:** [@slwu89](https://discourse.julialang.org/u/slwu89)\
**Replies:** 11\
**Last updated:** [May 3, 2026, 10:49am UTC](https://discourse.julialang.org/t/multi-objective-markov-decision-processes/111982 "2026-05-03T10:49:14Z")

</div>

Hi all. If this is the wrong section, please let me know and I’ll move my question. I am curious if there is any work on multi-objective MDPs in Julia. I’m not very familiar with the MDP landscape in Julia; I perused th…

---

## [Gurobi fails to invoke the primal simplex method when doing column generation?](https://discourse.julialang.org/t/gurobi-fails-to-invoke-the-primal-simplex-method-when-doing-column-generation/133675)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 18\
**Last updated:** [April 30, 2026, 9:17pm UTC](https://discourse.julialang.org/t/gurobi-fails-to-invoke-the-primal-simplex-method-when-doing-column-generation/133675 "2026-04-30T21:17:20Z")

</div>

I have a refreshing discovery today, based on my acquaintance Column generation · JuMP wherein, the only thing I changed was the solver (I used Gurobi instead of HiGHS). This is the master LP’s re-solving logging I acq…

---

## [Speed issue for Quadratic Program](https://discourse.julialang.org/t/speed-issue-for-quadratic-program/136898)

<div class="topic-metadata">

**Author:** [@vaibhav.u](https://discourse.julialang.org/u/vaibhav.u)\
**Replies:** 4\
**Last updated:** [April 30, 2026, 9:16pm UTC](https://discourse.julialang.org/t/speed-issue-for-quadratic-program/136898 "2026-04-30T21:16:30Z")

</div>

I am dealing with a projection problem in a space defined by multiple linear constraints, with a problem dimension of about 1000, and I have 1000 such problems in a ‘for’ loop. I initially used the OSQP solver with JuMP,…

---

## [JuMP: unused \`@operator\` has critical impact](https://discourse.julialang.org/t/jump-unused-operator-has-critical-impact/136895)

<div class="topic-metadata">

**Author:** [@cstjean](https://discourse.julialang.org/u/cstjean)\
**Replies:** 2\
**Last updated:** [April 27, 2026, 5:45am UTC](https://discourse.julialang.org/t/jump-unused-operator-has-critical-impact/136895 "2026-04-27T05:45:25Z")

</div>

I have some model defined like fake\_fun(a,b) = 0 function my\_model() ... @operator(m, unused\_op, 2, fake\_fun) ... end where both unused\_op and fake\_fun are not used anywhere except on that line. With thi…

---

## [Error 10005: Cannot retrieve UnbdRay from Gurobi](https://discourse.julialang.org/t/error-10005-cannot-retrieve-unbdray-from-gurobi/136886)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 4\
**Last updated:** [April 26, 2026, 11:39am UTC](https://discourse.julialang.org/t/error-10005-cannot-retrieve-unbdray-from-gurobi/136886 "2026-04-26T11:39:08Z")

</div>

Is this a bug? julia\> Gurobi.GRBsetdblattrarray(lps.o, "Obj", 1, xllen, mst.Xlb) 0 julia\> function opt\_and\_ter(m) # my definition of optimize! and return Gurobi's termination code o, r = m.o, m.refi …

[Next page](https://discourse.julialang.org/c/domain/opt/13.md?page=1)
