# Optimization (Mathematical)

**URL:** https://discourse.julialang.org/c/domain/opt/13.md?page=7

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

**Page:** 8

---

## [Getting value from unregistered variables](https://discourse.julialang.org/t/getting-value-from-unregistered-variables/129869)

<div class="topic-metadata">

**Author:** [@nhebel](https://discourse.julialang.org/u/nhebel)\
**Replies:** 3\
**Last updated:** [June 16, 2025, 5:13pm UTC](https://discourse.julialang.org/t/getting-value-from-unregistered-variables/129869 "2025-06-16T17:13:22Z")

</div>

Sorry if this has already been asked - I tried searching and re-reading the documentation and couldn’t find anything. I have a model with unregistered variables (though we did assign base names/strings) and I’m trying to…

---

## [Scaling issues in a nonlinear program](https://discourse.julialang.org/t/scaling-issues-in-a-nonlinear-program/129835)

<div class="topic-metadata">

**Author:** [@fmanfredini1](https://discourse.julialang.org/u/fmanfredini1)\
**Replies:** 2\
**Last updated:** [June 16, 2025, 9:29am UTC](https://discourse.julialang.org/t/scaling-issues-in-a-nonlinear-program/129835 "2025-06-16T09:29:06Z")

</div>

Dear all, I’m trying to solve a non-linear constrained program. The program consists of minimizing the sum of the relative squared deviations between the data and their model counterpart. I’m doing it using IpOpt on JUMP…

---

## [Covariance Optimization for Joint estimation using UKF](https://discourse.julialang.org/t/covariance-optimization-for-joint-estimation-using-ukf/129677)

<div class="topic-metadata">

**Author:** [@vh94](https://discourse.julialang.org/u/vh94)\
**Replies:** 5\
**Last updated:** [June 16, 2025, 9:08am UTC](https://discourse.julialang.org/t/covariance-optimization-for-joint-estimation-using-ukf/129677 "2025-06-16T09:08:14Z")

</div>

Hello, I am using an Unscented Kalman Filter to perform a joint state and parameter estimation. I am trying to improve the accuracy of the parameters estimation foremost ( fit to the measured data is less important) . F…

---

## [JuMP.set\_upper\_bound on AffExpr?](https://discourse.julialang.org/t/jump-set-upper-bound-on-affexpr/129904)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 6\
**Last updated:** [June 16, 2025, 7:47am UTC](https://discourse.julialang.org/t/jump-set-upper-bound-on-affexpr/129904 "2025-06-16T07:47:06Z")

</div>

Is it possible to extend the syntax of set\_upper\_bound to an expression, despite (perhaps) there might not be a corresponding solver API? Consider julia\> using JuMP julia\> model = Model(); julia\> @variable(model, x\[1…

---

## [JuMP.NormOneCone()](https://discourse.julialang.org/t/jump-normonecone/129768)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 13\
**Last updated:** [June 15, 2025, 10:47pm UTC](https://discourse.julialang.org/t/jump-normonecone/129768 "2025-06-15T22:47:45Z")

</div>

Can this NormOneCone be made easier? as SecondOrderCone is? It will find it use in linear programming. In my code, I now write something like nm1e = JuMP.@variable(outer) nm1c = JuMP.@constraint(outer, \[nm1e; vec(out…

---

## [Changing penalty parameter in objective function in JuMP](https://discourse.julialang.org/t/changing-penalty-parameter-in-objective-function-in-jump/129791)

<div class="topic-metadata">

**Author:** [@Lester](https://discourse.julialang.org/u/Lester)\
**Replies:** 4\
**Last updated:** [June 13, 2025, 11:37am UTC](https://discourse.julialang.org/t/changing-penalty-parameter-in-objective-function-in-jump/129791 "2025-06-13T11:37:07Z")

</div>

Hi Saying in JuMP, I want to a objective function being a conbination of the cost function f(x) and the constraint violation evaluation h(x), as @objective(model, Min, f(x) + μ \* h(x)). Is there a way for me to changeμ …

---

## [Define a recursive JuMP.@expression](https://discourse.julialang.org/t/define-a-recursive-jump-expression/129848)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 3\
**Last updated:** [June 13, 2025, 3:35am UTC](https://discourse.julialang.org/t/define-a-recursive-jump-expression/129848 "2025-06-13T03:35:35Z")

</div>

Is this a good syntax that can be supported? julia\> using JuMP; model = Model(); julia\> x0 = 1.3; # initial state julia\> @variable(model, u\[t = 1:3\], Bin); # actions julia\> @expression(model, x\[t = 1:3\], (t == 1 ? x0…

---

## [A toy example triggering Gurobi's Warning: Model contains variables with very large bounds participating in product terms](https://discourse.julialang.org/t/a-toy-example-triggering-gurobis-warning-model-contains-variables-with-very-large-bounds-participating-in-product-terms/127295)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 13\
**Last updated:** [June 11, 2025, 7:32pm UTC](https://discourse.julialang.org/t/a-toy-example-triggering-gurobis-warning-model-contains-variables-with-very-large-bounds-participating-in-product-terms/127295 "2025-06-11T19:32:30Z")

</div>

It’s common to find Gurobi logging the following Warning in QCP Warning: Model contains variables with very large bounds participating in product terms. Presolve was not able to compute smaller bounds for these variabl…

---

## [ParametricOptInterface + Clarabel](https://discourse.julialang.org/t/parametricoptinterface-clarabel/129745)

<div class="topic-metadata">

**Author:** [@klamike](https://discourse.julialang.org/u/klamike)\
**Replies:** 5\
**Last updated:** [June 11, 2025, 2:25pm UTC](https://discourse.julialang.org/t/parametricoptinterface-clarabel/129745 "2025-06-11T14:25:46Z")

</div>

I am trying to use POI with Clarabel. Based on the ParametricOptInterface.jl readme, the recommended usage is with direct\_model. Here, I’ve just swapped HiGHS.jl for Clarabel.jl: using JuMP, Clarabel import ParametricOp…

---

## [JuMP.shadow\_price conveys a misconception?](https://discourse.julialang.org/t/jump-shadow-price-conveys-a-misconception/127503)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 5\
**Last updated:** [June 11, 2025, 7:44am UTC](https://discourse.julialang.org/t/jump-shadow-price-conveys-a-misconception/127503 "2025-06-11T07:44:19Z")

</div>

In constraint optimization, the shadow price is the change, per infinitesimal unit of the constraint, in the optimal value of the objective function, obtained by relaxing the constraint. This is the wikipedia definiti…

---

## [Gurobi Error 10030: No compatible runtime available for version 12.0.2](https://discourse.julialang.org/t/gurobi-error-10030-no-compatible-runtime-available-for-version-12-0-2/129763)

<div class="topic-metadata">

**Author:** [@manoj.centura](https://discourse.julialang.org/u/manoj.centura)\
**Replies:** 1\
**Last updated:** [June 9, 2025, 8:09pm UTC](https://discourse.julialang.org/t/gurobi-error-10030-no-compatible-runtime-available-for-version-12-0-2/129763 "2025-06-09T20:09:59Z")

</div>

:1st\_place\_medal: i All, Getting this error please help us out. This is for Julia 1.6 \`\`\`Status C:\\Users\\manojkumar.ram\\.julia\\environments\\v1.10\\Project.toml \[a93c6f00\] DataFrames v1.7.0 \[2e9cd046\] Gurobi v1.7.4 \[4…

---

## [How to rectify a \`v::Vector{Float64}\` so that \`sum(v) == 0\`?](https://discourse.julialang.org/t/how-to-rectify-a-v-vector-float64-so-that-sum-v-0/129633)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 14\
**Last updated:** [June 9, 2025, 11:40am UTC](https://discourse.julialang.org/t/how-to-rectify-a-v-vector-float64-so-that-sum-v-0/129633 "2025-06-09T11:40:07Z")

</div>

I have a vector v::Vector{Float64} which satisfies isapprox(sum(v), 0; atol = 1e-12). Now I want to rectify the v somehow so that sum(v) == 0 becomes true. Is there a nice method? The following is an example where my …

---

## [DenseAxisArray in JuMP](https://discourse.julialang.org/t/denseaxisarray-in-jump/129258)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 5\
**Last updated:** [June 3, 2025, 8:35am UTC](https://discourse.julialang.org/t/denseaxisarray-in-jump/129258 "2025-06-03T08:35:46Z")

</div>

I wonder why is the y below so complicated, unlike x. julia\> using JuMP julia\> model = Model(); julia\> @variable(model, x\[1:3\]); x 3-element Vector{VariableRef}: x\[1\] x\[2\] x\[3\] julia\> R = 1:3 1:3 julia\> @variable…

---

## [Why are names not allowed for upper/lower bound constraints?](https://discourse.julialang.org/t/why-are-names-not-allowed-for-upper-lower-bound-constraints/129727)

<div class="topic-metadata">

**Author:** [@klamike](https://discourse.julialang.org/u/klamike)\
**Replies:** 3\
**Last updated:** [June 8, 2025, 9:36pm UTC](https://discourse.julialang.org/t/why-are-names-not-allowed-for-upper-lower-bound-constraints/129727 "2025-06-08T21:36:42Z")

</div>

I saw Implement names for constrained variables · Issue #193 · jump-dev/Dualization.jl · GitHub was recently opened based on another post Can't get the example dualization to work. What is the reasoning behind not allow…

---

## [For a training iteration or the evaluation simulation (after training), is burn-in period implemented in SDDP.jl?](https://discourse.julialang.org/t/for-a-training-iteration-or-the-evaluation-simulation-after-training-is-burn-in-period-implemented-in-sddp-jl/129652)

<div class="topic-metadata">

**Author:** [@Engr\_Moiz\_Ahmad](https://discourse.julialang.org/u/Engr_Moiz_Ahmad)\
**Replies:** 4\
**Last updated:** [June 6, 2025, 9:35pm UTC](https://discourse.julialang.org/t/for-a-training-iteration-or-the-evaluation-simulation-after-training-is-burn-in-period-implemented-in-sddp-jl/129652 "2025-06-06T21:35:11Z")

</div>

I am dealing with a multi-stage mixed-integer stochastic global supply chain optimization problem. In this regard, I want to determine whether the burn-in period (for the random sampling process) is already incorporated…

---

## [Optimizing Large-Scale Problems: One Large Problem vs. Multiple Smaller Ones](https://discourse.julialang.org/t/optimizing-large-scale-problems-one-large-problem-vs-multiple-smaller-ones/129711)

<div class="topic-metadata">

**Author:** [@fdekerme](https://discourse.julialang.org/u/fdekerme)\
**Replies:** 1\
**Last updated:** [June 6, 2025, 6:50pm UTC](https://discourse.julialang.org/t/optimizing-large-scale-problems-one-large-problem-vs-multiple-smaller-ones/129711 "2025-06-06T18:50:46Z")

</div>

Hello :grinning:, By reading this example of NonlinearSolve.jl, I was asking myself if it was better to define large-scale optimization problem as 1 large problem (f2) or several small problems (f1). According to the c…

---

## [ForwardDiff over closed interval](https://discourse.julialang.org/t/forwarddiff-over-closed-interval/129629)

<div class="topic-metadata">

**Author:** [@weymouth](https://discourse.julialang.org/u/weymouth)\
**Replies:** 4\
**Last updated:** [June 6, 2025, 1:32pm UTC](https://discourse.julialang.org/t/forwarddiff-over-closed-interval/129629 "2025-06-06T13:32:43Z")

</div>

I need to optimize a function f(u) defined over a closed domain u =\[0,1\]. I was happily using Newton’s method and FowardDiff for this until I tried upgrading to v1.0. Now, ForwardDiff intentionally gives the derivative o…

---

## [JuMP support for "linear conditional expression" reformulation as MILP in 2025](https://discourse.julialang.org/t/jump-support-for-linear-conditional-expression-reformulation-as-milp-in-2025/129679)

<div class="topic-metadata">

**Author:** [@pierre-haessig](https://discourse.julialang.org/u/pierre-haessig)\
**Replies:** 4\
**Last updated:** [June 6, 2025, 7:59am UTC](https://discourse.julialang.org/t/jump-support-for-linear-conditional-expression-reformulation-as-milp-in-2025/129679 "2025-06-06T07:59:56Z")

</div>

Hello, I’d like to know to what extent the present (mid-2025) state of JuMP includes the work of @rdeits in GitHub - rdeits/ConditionalJuMP.jl: Automatic transformation of implications and complementarity into mixed-int…

---

## [Coluna.jl iteratively generate columns infos](https://discourse.julialang.org/t/coluna-jl-iteratively-generate-columns-infos/129636)

<div class="topic-metadata">

**Author:** [@Luca](https://discourse.julialang.org/u/Luca)\
**Replies:** 13\
**Last updated:** [June 6, 2025, 1:58am UTC](https://discourse.julialang.org/t/coluna-jl-iteratively-generate-columns-infos/129636 "2025-06-06T01:58:41Z")

</div>

Dear Coluna.jl developers, I am using Coluna.jl (https://atoptima.github.io/Coluna.jl/dev/) for a simple branch-and-price approach to the VRP. Is there a way to use Coluna.jl without having all the column information at…

---

## [Cyclic Job shop Scheduling](https://discourse.julialang.org/t/cyclic-job-shop-scheduling/129409)

<div class="topic-metadata">

**Author:** [@Ely](https://discourse.julialang.org/u/Ely)\
**Replies:** 6\
**Last updated:** [June 4, 2025, 9:07pm UTC](https://discourse.julialang.org/t/cyclic-job-shop-scheduling/129409 "2025-06-04T21:07:37Z")

</div>

Hi everyone, I am trying to work on the cyclic job shop scheduling problem mentioned in the following paper:https://laas.hal.science/hal-02318936v1/document especially equations from 5a to 5f and the example 2. Attached…

---

## [Modify a JuMP model via modifying expressions](https://discourse.julialang.org/t/modify-a-jump-model-via-modifying-expressions/129594)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 2\
**Last updated:** [June 3, 2025, 11:00pm UTC](https://discourse.julialang.org/t/modify-a-jump-model-via-modifying-expressions/129594 "2025-06-03T23:00:04Z")

</div>

Currently the doc of JuMP teaches people how to modify constraints and how to modify objective\_expression. In my mind, there is a more natural way: Build an initial model (that we will revise later) partly involving so…

---

## [Solve Regularized Nonlinear Least Squares](https://discourse.julialang.org/t/solve-regularized-nonlinear-least-squares/129608)

<div class="topic-metadata">

**Author:** [@fdekerme](https://discourse.julialang.org/u/fdekerme)\
**Replies:** 1\
**Last updated:** [June 3, 2025, 10:01pm UTC](https://discourse.julialang.org/t/solve-regularized-nonlinear-least-squares/129608 "2025-06-03T22:01:20Z")

</div>

Hi everyone :grinning:, I want to solve a large Regularized Nonlinear Least Squares problem min \\text{Cost} \\left(T^{1}, T^{2}\\right) = \\|r\\|^2 + R(T^{1}, T^{2}) where r log-sum-exponential terms: r^{i}(T^{1}, T^…

---

## [How to handle quadratic objectives with SDDP.jl?](https://discourse.julialang.org/t/how-to-handle-quadratic-objectives-with-sddp-jl/129589)

<div class="topic-metadata">

**Author:** [@Samuel\_M](https://discourse.julialang.org/u/Samuel_M)\
**Replies:** 1\
**Last updated:** [June 3, 2025, 8:51am UTC](https://discourse.julialang.org/t/how-to-handle-quadratic-objectives-with-sddp-jl/129589 "2025-06-03T08:51:53Z")

</div>

Hello everybody. I have to solve a problem similar to an economicd dispatch or unit commitment and I have seen that a good alternative is the Stochastic Dual Dynamic Programming and I was thinking about using SDDP.jl. H…

---

## [Convert a nonlinear model defined by JuMP's legacy version to latest version](https://discourse.julialang.org/t/convert-a-nonlinear-model-defined-by-jumps-legacy-version-to-latest-version/129542)

<div class="topic-metadata">

**Author:** [@zhu266](https://discourse.julialang.org/u/zhu266)\
**Replies:** 7\
**Last updated:** [June 2, 2025, 3:44am UTC](https://discourse.julialang.org/t/convert-a-nonlinear-model-defined-by-jumps-legacy-version-to-latest-version/129542 "2025-06-02T03:44:00Z")

</div>

Hi everyone, I am fetching models from MINLPLib.jl, and I guess they use “Nonlinear Modeling (Legacy)” to define nonlinear constraints/objectives. I am curious if there is any way to transform a nonlinear model defined b…

---

## [Where to implement new matrix multiplication algorithms?](https://discourse.julialang.org/t/where-to-implement-new-matrix-multiplication-algorithms/129525)

<div class="topic-metadata">

**Author:** [@PepeRoConde](https://discourse.julialang.org/u/PepeRoConde)\
**Replies:** 3\
**Last updated:** [June 1, 2025, 4:27pm UTC](https://discourse.julialang.org/t/where-to-implement-new-matrix-multiplication-algorithms/129525 "2025-06-01T16:27:03Z")

</div>

like the ones proposed here h\_ttps://arxiv.org/pdf/2505.05896 h\_ttps://github.com/mkauers/matrix-multiplication thanks!

---

## [About JuMP's speed of building an expression](https://discourse.julialang.org/t/about-jumps-speed-of-building-an-expression/129018)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 20\
**Last updated:** [June 1, 2025, 2:17pm UTC](https://discourse.julialang.org/t/about-jumps-speed-of-building-an-expression/129018 "2025-06-01T14:17:58Z")

</div>

I find that it seems to be not that fast for JuMP to build a “large” expression I wonder: is this speed normal? Why? Can (or how can) it be improved somehow? import LinearAlgebra.dot as dot using JuMP, BenchmarkTools N…

---

## [Dual\_ftol\_rel keyword not allowed in Optimization.jl](https://discourse.julialang.org/t/dual-ftol-rel-keyword-not-allowed-in-optimization-jl/129480)

<div class="topic-metadata">

**Author:** [@miguelborrero](https://discourse.julialang.org/u/miguelborrero)\
**Replies:** 1\
**Last updated:** [May 30, 2025, 5:58pm UTC](https://discourse.julialang.org/t/dual-ftol-rel-keyword-not-allowed-in-optimization-jl/129480 "2025-05-30T17:58:29Z")

</div>

Hi there, I’m trying out different solvers for my problem which requires evaluation of non-linear constraints. Currently I’m trying NLopt thought Optimization in particular LD\_CCSAQ solver. However, its taking forever a…

---

## [What should be the acceptable tolerance value between the lower bound and the estimated upper bound for the results of SDDP.jl to be reliable?](https://discourse.julialang.org/t/what-should-be-the-acceptable-tolerance-value-between-the-lower-bound-and-the-estimated-upper-bound-for-the-results-of-sddp-jl-to-be-reliable/129450)

<div class="topic-metadata">

**Author:** [@Engr\_Moiz\_Ahmad](https://discourse.julialang.org/u/Engr_Moiz_Ahmad)\
**Replies:** 4\
**Last updated:** [May 30, 2025, 7:40am UTC](https://discourse.julialang.org/t/what-should-be-the-acceptable-tolerance-value-between-the-lower-bound-and-the-estimated-upper-bound-for-the-results-of-sddp-jl-to-be-reliable/129450 "2025-05-30T07:40:04Z")

</div>

I am dealing with a multi-stage mixed-integer stochastic global supply chain optimization problem. In this regard, I want to determine a tolerance value for the gap between the lower bound and the estimated upper bound …

---

## [Where is the "rate\_a" in PowerModels.jl from](https://discourse.julialang.org/t/where-is-the-rate-a-in-powermodels-jl-from/129424)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 8\
**Last updated:** [May 29, 2025, 11:52pm UTC](https://discourse.julialang.org/t/where-is-the-rate-a-in-powermodels-jl-from/129424 "2025-05-29T23:52:24Z")

</div>

The data provided by PowerModels.jl is inconsistent with my local raw Matpower file. The latter is all zero (seems to mean that there is no limit), but the former has a vector of numbers that I can’t tell where they com…

---

## [How to solve infinite horizon problem under Makovian policy graph in SDDP.jl?](https://discourse.julialang.org/t/how-to-solve-infinite-horizon-problem-under-makovian-policy-graph-in-sddp-jl/129420)

<div class="topic-metadata">

**Author:** [@Engr\_Moiz\_Ahmad](https://discourse.julialang.org/u/Engr_Moiz_Ahmad)\
**Replies:** 16\
**Last updated:** [May 29, 2025, 7:28pm UTC](https://discourse.julialang.org/t/how-to-solve-infinite-horizon-problem-under-makovian-policy-graph-in-sddp-jl/129420 "2025-05-29T19:28:08Z")

</div>

I am dealing with a multi-stage mixed-integer stochastic global supply chain optimization problem and want to solve infinite-horizon problem instances under a Markovian policy graph. I am using the Markovian policy graph…

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

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