# Specific Domains

**URL:** https://discourse.julialang.org/c/domain/10.md?no_subcategories=false&page=47

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

**Page:** 48

---

## [Issue with Interior point method for HiGHS](https://discourse.julialang.org/t/issue-with-interior-point-method-for-highs/88814)

<div class="topic-metadata">

**Author:** [@adow031](https://discourse.julialang.org/u/adow031)\
**Replies:** 3\
**Last updated:** [April 16, 2025, 3:08am UTC](https://discourse.julialang.org/t/issue-with-interior-point-method-for-highs/88814 "2025-04-16T03:08:32Z")

</div>

I’m using JuMP, and have just started testing out the HiGHS optimizer, and I’ve encounted a strange issue with the interior point method. For a small model, the HiGHS optimizer toggles between returning the optimal solu…

---

## [Meta optimization with Julia](https://discourse.julialang.org/t/meta-optimization-with-julia/128065)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 6\
**Last updated:** [April 16, 2025, 3:05am UTC](https://discourse.julialang.org/t/meta-optimization-with-julia/128065 "2025-04-16T03:05:43Z")

</div>

A student of me wants to build a meta-optimization tool for wind energy systems. It shall integrate a number (4 or 5) other design tools. I suggested him to use JuMP.jl Are there any other tools or packages I could sugg…

---

## [How to avoid "unsupported dynamic function invocation" in CUDA with nested gradients](https://discourse.julialang.org/t/how-to-avoid-unsupported-dynamic-function-invocation-in-cuda-with-nested-gradients/127982)

<div class="topic-metadata">

**Author:** [@andrewrosemberg](https://discourse.julialang.org/u/andrewrosemberg)\
**Replies:** 2\
**Last updated:** [April 15, 2025, 2:58pm UTC](https://discourse.julialang.org/t/how-to-avoid-unsupported-dynamic-function-invocation-in-cuda-with-nested-gradients/127982 "2025-04-15T14:58:32Z")

</div>

I am trying to train a model in Flux in which the loss has a nested gradient. I know I should avoid dynamic function invocation, but I am unsure how. The following code works on CPU but not on CUDA/GPU: using Flux using…

---

## [When adding a SumOfSquares constraint, is it possible to get the JuMP variable corresponding to the Gram matrix?](https://discourse.julialang.org/t/when-adding-a-sumofsquares-constraint-is-it-possible-to-get-the-jump-variable-corresponding-to-the-gram-matrix/127966)

<div class="topic-metadata">

**Author:** [@aaspeel](https://discourse.julialang.org/u/aaspeel)\
**Replies:** 2\
**Last updated:** [April 15, 2025, 12:28pm UTC](https://discourse.julialang.org/t/when-adding-a-sumofsquares-constraint-is-it-possible-to-get-the-jump-variable-corresponding-to-the-gram-matrix/127966 "2025-04-15T12:28:54Z")

</div>

Hello! I have an optimization model with an SOS constraint and I would like to add extra constraints on the corresponding Gram matrix. Unfortunately, I could not find a way to obtain the JuMP variable corresponding to t…

---

## [Gurobi's tolerance on convexity in QCP is about \`1e-13\`](https://discourse.julialang.org/t/gurobis-tolerance-on-convexity-in-qcp-is-about-1e-13/127297)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 10\
**Last updated:** [April 15, 2025, 6:18am UTC](https://discourse.julialang.org/t/gurobis-tolerance-on-convexity-in-qcp-is-about-1e-13/127297 "2025-04-15T06:18:40Z")

</div>

Following this topic I do the following test to verify the title using JuMP, Gurobi function test\_convexity(d) # if it ain't Error, the model is deemed convex (by Gurobi) model = Model(Gurobi.Optimizer) @vari…

---

## [Internal error: during type inference Encountered stack overflow. This might be caused by recursion over very long tuples or argument lists](https://discourse.julialang.org/t/internal-error-during-type-inference-encountered-stack-overflow-this-might-be-caused-by-recursion-over-very-long-tuples-or-argument-lists/128037)

<div class="topic-metadata">

**Author:** [@Viacol0916](https://discourse.julialang.org/u/Viacol0916)\
**Replies:** 2\
**Last updated:** [April 15, 2025, 2:15am UTC](https://discourse.julialang.org/t/internal-error-during-type-inference-encountered-stack-overflow-this-might-be-caused-by-recursion-over-very-long-tuples-or-argument-lists/128037 "2025-04-15T02:15:24Z")

</div>

Julia Version : 1.11.4+0.aarch64.apple.darwin14 Related package: ModelingToolkit, NonlinearSolve Our project is to use C++ to pass function parameter information to Julia, then use julia to implement numerical calculat…

---

## [Gtk / Gtk4: transperent window (overlay) with layers](https://discourse.julialang.org/t/gtk-gtk4-transperent-window-overlay-with-layers/128080)

<div class="topic-metadata">

**Author:** [@PharmCat](https://discourse.julialang.org/u/PharmCat)\
**Replies:** 0\
**Last updated:** [April 15, 2025, 1:07am UTC](https://discourse.julialang.org/t/gtk-gtk4-transperent-window-overlay-with-layers/128080 "2025-04-15T01:07:58Z")

</div>

Hi! I want to make transparent window with several graphic layers and information. I found ‘opacity’ property, but it work with window and child canvas. So, I found partial solution: c = @GtkCanvas() win = GtkWindow(c…

---

## [Cart-pole trajectory optimization with ModelingToolkit, Multibody and JuliaSimCompiler model, how to improve performance? Constraints jacobian sparsity pattern issue?](https://discourse.julialang.org/t/cart-pole-trajectory-optimization-with-modelingtoolkit-multibody-and-juliasimcompiler-model-how-to-improve-performance-constraints-jacobian-sparsity-pattern-issue/127856)

<div class="topic-metadata">

**Author:** [@Odie](https://discourse.julialang.org/u/Odie)\
**Replies:** 7\
**Last updated:** [April 14, 2025, 2:15pm UTC](https://discourse.julialang.org/t/cart-pole-trajectory-optimization-with-modelingtoolkit-multibody-and-juliasimcompiler-model-how-to-improve-performance-constraints-jacobian-sparsity-pattern-issue/127856 "2025-04-14T14:15:30Z")

</div>

Hi! I’m trying to do a trajectory optimization problem with a direct collocation method on my own model. To begin with, I decided to reproduce a documented problem : the cart-pole. I used ModelingToolkit and Multibody …

---

## [Reusing random numbers in EnsembleProblem](https://discourse.julialang.org/t/reusing-random-numbers-in-ensembleproblem/127514)

<div class="topic-metadata">

**Author:** [@aleCombi](https://discourse.julialang.org/u/aleCombi)\
**Replies:** 6\
**Last updated:** [April 14, 2025, 2:13pm UTC](https://discourse.julialang.org/t/reusing-random-numbers-in-ensembleproblem/127514 "2025-04-14T14:13:46Z")

</div>

I am trying to take derivatives of Montecarlo expectations against parameters using DifferentialEquations.jl. I am doing it using geometric brownian motion, and I want to bump the sigma and reevaluate (later I will try A…

---

## [Sending a logistic function to Gurobi.jl with JuMP](https://discourse.julialang.org/t/sending-a-logistic-function-to-gurobi-jl-with-jump/128027)

<div class="topic-metadata">

**Author:** [@votroto](https://discourse.julialang.org/u/votroto)\
**Replies:** 2\
**Last updated:** [April 14, 2025, 1:02pm UTC](https://discourse.julialang.org/t/sending-a-logistic-function-to-gurobi-jl-with-jump/128027 "2025-04-14T13:02:42Z")

</div>

JuMP and Gurobi seem to be able to accept nl functions via their new interface. But while I can see that Gurobi claims to accept :logistic as the “head” of a non-linear expression :logistic =\> GRB\_OPCODE\_LOGISTIC, I can’…

---

## [Memory usage increasing with each epoch](https://discourse.julialang.org/t/memory-usage-increasing-with-each-epoch/121798)

<div class="topic-metadata">

**Author:** [@JoshuaBillson](https://discourse.julialang.org/u/JoshuaBillson)\
**Replies:** 18\
**Last updated:** [April 14, 2025, 12:30pm UTC](https://discourse.julialang.org/t/memory-usage-increasing-with-each-epoch/121798 "2025-04-14T12:30:43Z")

</div>

I’m having a problem where memory usage is gradually increasing with each epoch when training large neural networks with Flux (v0.14.22) and CUDA (v5.5.2). At the same time, training appears to get progressively slower a…

---

## [ModelingToolkit -- can I use \`min\` and \`max\` functions?](https://discourse.julialang.org/t/modelingtoolkit-can-i-use-min-and-max-functions/127934)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 20\
**Last updated:** [April 14, 2025, 6:05am UTC](https://discourse.julialang.org/t/modelingtoolkit-can-i-use-min-and-max-functions/127934 "2025-04-14T06:05:26Z")

</div>

I have written a PID controller in ModelingToolkit (yes, I know it probably exists…). I need to clip the control output u to lie in the range \[u\_min, u\_max\]. So I try to do: # Constraining the unconstrained control sign…

---

## [Defining constraint over dense and sparse constraint](https://discourse.julialang.org/t/defining-constraint-over-dense-and-sparse-constraint/128030)

<div class="topic-metadata">

**Author:** [@danrib07](https://discourse.julialang.org/u/danrib07)\
**Replies:** 2\
**Last updated:** [April 13, 2025, 10:42pm UTC](https://discourse.julialang.org/t/defining-constraint-over-dense-and-sparse-constraint/128030 "2025-04-13T22:42:49Z")

</div>

Hi! I have a question regarding the definition of constraints including both dense and sparse variables. In the example below, I am trying to define the constraint x\_{ij} + y\_{ij} \\leq 0 \\quad \\forall \\quad i \\in \\mathca…

---

## [Finding the minimum of the Bellman operator inside SDDP iterations](https://discourse.julialang.org/t/finding-the-minimum-of-the-bellman-operator-inside-sddp-iterations/128031)

<div class="topic-metadata">

**Author:** [@Mathis\_3](https://discourse.julialang.org/u/Mathis_3)\
**Replies:** 5\
**Last updated:** [April 13, 2025, 10:23pm UTC](https://discourse.julialang.org/t/finding-the-minimum-of-the-bellman-operator-inside-sddp-iterations/128031 "2025-04-13T22:23:01Z")

</div>

Hello! I’m currently working on a multistage stochastic optimization problem using SDDP.jl. At each iteration (and each node), I would like to solve the following problem: inf\_{x \\in X} T(V^k)(x) where T is the Bellma…

---

## [I added 1 Million constraints to an LP unwittingly](https://discourse.julialang.org/t/i-added-1-million-constraints-to-an-lp-unwittingly/127668)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 36\
**Last updated:** [April 13, 2025, 8:59pm UTC](https://discourse.julialang.org/t/i-added-1-million-constraints-to-an-lp-unwittingly/127668 "2025-04-13T20:59:22Z")

</div>

This topic is sharing an experience, probably a noob has not seen before (me included). Put it simply, I’m solving a disjointed bilinear programming using RLT, and wasn’t realizing that the number of constraints will be…

---

## [JuMP IPOPT plugin can’t find or interface with LAPACK at runtime?](https://discourse.julialang.org/t/jump-ipopt-plugin-can-t-find-or-interface-with-lapack-at-runtime/127809)

<div class="topic-metadata">

**Author:** [@askvorts](https://discourse.julialang.org/u/askvorts)\
**Replies:** 9\
**Last updated:** [April 13, 2025, 8:55pm UTC](https://discourse.julialang.org/t/jump-ipopt-plugin-can-t-find-or-interface-with-lapack-at-runtime/127809 "2025-04-13T20:55:12Z")

</div>

I am trying to solve a MIQP portfolio optimisation problem using JuMP and SCIP (tried Juniper before but it crashed Julia). There are repeated errors: Error: no BLAS/LAPACK library loaded for dsyev\_() \[nlpi\_ipopt.cpp:26…

---

## [\[ANN\] NumericalDistributions.jl: user-defined distributions](https://discourse.julialang.org/t/ann-numericaldistributions-jl-user-defined-distributions/128025)

<div class="topic-metadata">

**Author:** [@misha\_mikhasenko](https://discourse.julialang.org/u/misha_mikhasenko)\
**Replies:** 1\
**Last updated:** [April 13, 2025, 3:54pm UTC](https://discourse.julialang.org/t/ann-numericaldistributions-jl-user-defined-distributions/128025 "2025-04-13T15:54:50Z")

</div>

I’m happy to share NumericalDistributions.jl, a package for working with numerically defined univariate continuous distributions in Julia. It wraps user-defined PDF functions, numerically normalizes them, and provides sa…

---

## [Help wanted with a music-related optimisation-ish problem](https://discourse.julialang.org/t/help-wanted-with-a-music-related-optimisation-ish-problem/128004)

<div class="topic-metadata">

**Author:** [@cjdoris](https://discourse.julialang.org/u/cjdoris)\
**Replies:** 4\
**Last updated:** [April 13, 2025, 3:14pm UTC](https://discourse.julialang.org/t/help-wanted-with-a-music-related-optimisation-ish-problem/128004 "2025-04-13T15:14:27Z")

</div>

In the UK we have a form of social dance called ceilidh dancing, which is super fun. A bit like contra dancing in the USA if you’re familiar with that. Ceilidhs are “called” by a “caller” whose job is to decide which da…

---

## [Font family 'Computer Modern' not found](https://discourse.julialang.org/t/font-family-computer-modern-not-found/93355)

<div class="topic-metadata">

**Author:** [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)\
**Replies:** 5\
**Last updated:** [April 13, 2025, 3:25am UTC](https://discourse.julialang.org/t/font-family-computer-modern-not-found/93355 "2025-04-13T03:25:40Z")

</div>

Defining “Computer Modern” as default font familly is very convenient when using Plots.jl default gr() backend, as per this other post. However, using the pyplot or pythonplot backends issues the warning message: find…

---

## [PlotlyKaleido cannot save PlotlyLight drawings created from templates](https://discourse.julialang.org/t/plotlykaleido-cannot-save-plotlylight-drawings-created-from-templates/127779)

<div class="topic-metadata">

**Author:** [@karei](https://discourse.julialang.org/u/karei)\
**Replies:** 1\
**Last updated:** [April 12, 2025, 10:32am UTC](https://discourse.julialang.org/t/plotlykaleido-cannot-save-plotlylight-drawings-created-from-templates/127779 "2025-04-12T10:32:01Z")

</div>

I first created a template for my drawing and then applied the template using PlotlyLight.settings.layout.template = a\_template. But the saved image is still the unapplied template version. Is there any solution for this…

---

## [Divide collection into two groups](https://discourse.julialang.org/t/divide-collection-into-two-groups/127983)

<div class="topic-metadata">

**Author:** [@HugoTrentesaux](https://discourse.julialang.org/u/HugoTrentesaux)\
**Replies:** 1\
**Last updated:** [April 11, 2025, 4:48pm UTC](https://discourse.julialang.org/t/divide-collection-into-two-groups/127983 "2025-04-11T16:48:04Z")

</div>

I can filter a group based on a condition: using DataPipes a = \[1,2,5,5,3,9,8\] large = @p filter(\_\>4, a) # 5,5,9,8 small = @p filter(\_\<=4, a) # 1,2,3 But is there a way to achieve the same in a single action? # I woul…

---

## [Having trouble with StatsModels.jl \`modelmatrix\` to replicate R results](https://discourse.julialang.org/t/having-trouble-with-statsmodels-jl-modelmatrix-to-replicate-r-results/127981)

<div class="topic-metadata">

**Author:** [@slwu89](https://discourse.julialang.org/u/slwu89)\
**Replies:** 1\
**Last updated:** [April 11, 2025, 4:07pm UTC](https://discourse.julialang.org/t/having-trouble-with-statsmodels-jl-modelmatrix-to-replicate-r-results/127981 "2025-04-11T16:07:49Z")

</div>

Hi all, I’m trying to generate a model matrix to replicate R results, I’d appreciate some guidance. The input data is the Rail data from the nlme package in R, it has the format below: \> library(nlme) \> data(Rail) \> Rai…

---

## [Convergence of SDDP with nonlinear objective and mixed-integer variables](https://discourse.julialang.org/t/convergence-of-sddp-with-nonlinear-objective-and-mixed-integer-variables/127947)

<div class="topic-metadata">

**Author:** [@Engr\_Moiz\_Ahmad](https://discourse.julialang.org/u/Engr_Moiz_Ahmad)\
**Replies:** 9\
**Last updated:** [April 11, 2025, 7:55am UTC](https://discourse.julialang.org/t/convergence-of-sddp-with-nonlinear-objective-and-mixed-integer-variables/127947 "2025-04-11T07:55:30Z")

</div>

@odow what reference should I cite if I want to claim that due to the simultaneous occurrence of exponential terms in the objective and mixed integer decision space, SDDP can not be used?

---

## [Projection onto intersection of L\_0 ball and L\_infty ball via ShiftedProximalOperators](https://discourse.julialang.org/t/projection-onto-intersection-of-l-0-ball-and-l-infty-ball-via-shiftedproximaloperators/127949)

<div class="topic-metadata">

**Author:** [@jacob-roth](https://discourse.julialang.org/u/jacob-roth)\
**Replies:** 2\
**Last updated:** [April 11, 2025, 2:00am UTC](https://discourse.julialang.org/t/projection-onto-intersection-of-l-0-ball-and-l-infty-ball-via-shiftedproximaloperators/127949 "2025-04-11T02:00:17Z")

</div>

I am trying to follow the paper describing a method to project a point x^0 onto the set C:=\\{x : x\\in kB\_0 \\cap x\\in \\Delta B\_\\infty\\} where kB\_0=\\{x : ||x||\_0\\leq k\\} and \\Delta B\_\\infty=\\{x:||x||\_\\infty\\leq\\Delta\\}. I…

---

## [SDDP: how to use Juniper.jl for optimizer](https://discourse.julialang.org/t/sddp-how-to-use-juniper-jl-for-optimizer/82719)

<div class="topic-metadata">

**Author:** [@chenr86](https://discourse.julialang.org/u/chenr86)\
**Replies:** 7\
**Last updated:** [June 15, 2022, 1:45am UTC](https://discourse.julialang.org/t/sddp-how-to-use-juniper-jl-for-optimizer/82719 "2022-06-15T01:45:21Z")

</div>

Hello, I’m trying to solve MI-NLP problem with SDDP.jl. I would like to use juniper.jl as optimizer: using SDDP using Ipopt using Juniper nl\_solver = optimizer\_with\_attributes(Ipopt.Optimizer, "print\_level"=\>0) minl…

---

## [Enzyme with Const() on a vector throws an error](https://discourse.julialang.org/t/enzyme-with-const-on-a-vector-throws-an-error/121927)

<div class="topic-metadata">

**Author:** [@weltenbummler](https://discourse.julialang.org/u/weltenbummler)\
**Replies:** 20\
**Last updated:** [April 10, 2025, 3:53pm UTC](https://discourse.julialang.org/t/enzyme-with-const-on-a-vector-throws-an-error/121927 "2025-04-10T15:53:55Z")

</div>

Hello all, I would like to autodiff a function where some vector-valued arguments are kept constant. I thought to use Enzyme with the Const() functionality but run into issues when applying Const() to vectors. The fol…

---

## [Satellogic data in pure Julia](https://discourse.julialang.org/t/satellogic-data-in-pure-julia/127909)

<div class="topic-metadata">

**Author:** [@Zgabalj](https://discourse.julialang.org/u/Zgabalj)\
**Replies:** 3\
**Last updated:** [April 10, 2025, 11:41am UTC](https://discourse.julialang.org/t/satellogic-data-in-pure-julia/127909 "2025-04-10T11:41:33Z")

</div>

Mark Litwintschik has a blog (cannot add link) showing how to obtain satellite images from Satellogic using python. How would one start to implement this in Julia? The author uses GDAL and duckdb; both GDAL.jl and Duck…

---

## [Is there a way to use @allowscalar in a heterogeneous manner using KernelAbstractions?](https://discourse.julialang.org/t/is-there-a-way-to-use-allowscalar-in-a-heterogeneous-manner-using-kernelabstractions/127828)

<div class="topic-metadata">

**Author:** [@0samuraiE](https://discourse.julialang.org/u/0samuraiE)\
**Replies:** 3\
**Last updated:** [April 10, 2025, 6:33am UTC](https://discourse.julialang.org/t/is-there-a-way-to-use-allowscalar-in-a-heterogeneous-manner-using-kernelabstractions/127828 "2025-04-10T06:33:57Z")

</div>

Hi all, Is it correct that scalar indexing like Out\[1\] is not allowed with KernelAbstractions.jl alone, and that we need GPUArrays.@allowscalar for this? Should we always use GPUArrays together with KernelAbstractions f…

---

## [How to have more examples for ModelingToolkit Standard Library?](https://discourse.julialang.org/t/how-to-have-more-examples-for-modelingtoolkit-standard-library/127879)

<div class="topic-metadata">

**Author:** [@Matthew1](https://discourse.julialang.org/u/Matthew1)\
**Replies:** 5\
**Last updated:** [April 9, 2025, 7:40pm UTC](https://discourse.julialang.org/t/how-to-have-more-examples-for-modelingtoolkit-standard-library/127879 "2025-04-09T19:40:25Z")

</div>

It would be really great if there are more examples in the MTSL docs. I see that there are already some great ‘examples’ in the tests. However, most potential users won’t navigate to the tests. Also, if the goal is to re…

---

## [How to reinit! an integrator in a non-allocating and consistent way?](https://discourse.julialang.org/t/how-to-reinit-an-integrator-in-a-non-allocating-and-consistent-way/127771)

<div class="topic-metadata">

**Author:** [@Bart\_van\_de\_Lint](https://discourse.julialang.org/u/Bart_van_de_Lint)\
**Replies:** 10\
**Last updated:** [April 9, 2025, 6:37pm UTC](https://discourse.julialang.org/t/how-to-reinit-an-integrator-in-a-non-allocating-and-consistent-way/127771 "2025-04-09T18:37:47Z")

</div>

I am trying to create a control function from a ModelingToolkit.jl model: f(x, u, p) → x\_next I want to do that by re-initializing the integrator with the current state x and input u, and then stepping the integrator: …

[Previous page](https://discourse.julialang.org/c/domain/10.md?no_subcategories=false&page=46)

[Next page](https://discourse.julialang.org/c/domain/10.md?no_subcategories=false&page=48)
