# Latest

**URL:** https://discourse.julialang.org/latest.md?page=1204

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

**Page:** 1205

---

## [Plot a Differential Equation or a 3 variable function](https://discourse.julialang.org/t/plot-a-differential-equation-or-a-3-variable-function/71625)

<div class="topic-metadata">

**Author:** [@brett\_knoss](https://discourse.julialang.org/u/brett_knoss)\
**Replies:** 6\
**Last updated:** [November 17, 2021, 1:47am UTC](https://discourse.julialang.org/t/plot-a-differential-equation-or-a-3-variable-function/71625 "2021-11-17T01:47:55Z")

</div>

How do I plot a function with 3 variables, either in 3d or a 2d contour plot. U(x,y)=16\*log(x)+9\*log(y)

---

## [Implicit gradients with mutable struct returns an error](https://discourse.julialang.org/t/implicit-gradients-with-mutable-struct-returns-an-error/71455)

<div class="topic-metadata">

**Author:** [@a709e9a0c](https://discourse.julialang.org/u/a709e9a0c)\
**Replies:** 1\
**Last updated:** [November 17, 2021, 1:15am UTC](https://discourse.julialang.org/t/implicit-gradients-with-mutable-struct-returns-an-error/71455 "2021-11-17T01:15:28Z")

</div>

Hi, When I try to compute the gradients of a mutable struct via implicit gradients, this code fails, but the same exact code works when the struct is not mutable: using Zygote mutable struct Linear\_ W::Array{Float…

---

## [Performance of creating model with many terms](https://discourse.julialang.org/t/performance-of-creating-model-with-many-terms/71623)

<div class="topic-metadata">

**Author:** [@kiranshila](https://discourse.julialang.org/u/kiranshila)\
**Replies:** 3\
**Last updated:** [November 17, 2021, 12:40am UTC](https://discourse.julialang.org/t/performance-of-creating-model-with-many-terms/71623 "2021-11-17T00:40:29Z")

</div>

Hey everyone, I am working on implementing SVMs using JuMP and am running into some performance issues when trying to set up the Dual problem. Specifically, the setup of the objective function is proving to be very cos…

---

## [DiffEqFlux gradient error: breaks with increasing size of problem, size should not affect autodiff](https://discourse.julialang.org/t/diffeqflux-gradient-error-breaks-with-increasing-size-of-problem-size-should-not-affect-autodiff/71610)

<div class="topic-metadata">

**Author:** [@evolbio](https://discourse.julialang.org/u/evolbio)\
**Replies:** 7\
**Last updated:** [November 17, 2021, 12:32am UTC](https://discourse.julialang.org/t/diffeqflux-gradient-error-breaks-with-increasing-size-of-problem-size-should-not-affect-autodiff/71610 "2021-11-17T00:32:25Z")

</div>

I am optimizing a simple ODE problem with DiffEqFlux to get started with Julia. This code worked on TensorFlow. In the following code, running main(S=5, B=256) works, but main(S=7, B=256) fails. I previously used Ensemb…

---

## [How to implement an efficient Readers-Writer lock?](https://discourse.julialang.org/t/how-to-implement-an-efficient-readers-writer-lock/27446)

<div class="topic-metadata">

**Author:** [@findmyway](https://discourse.julialang.org/u/findmyway)\
**Replies:** 6\
**Last updated:** [November 17, 2021, 12:14am UTC](https://discourse.julialang.org/t/how-to-implement-an-efficient-readers-writer-lock/27446 "2021-11-17T00:14:43Z")

</div>

I read a blog about Readers-Writer Lock here Implementing reader-writer locks last week. The original code was written in Golang. And I attempted to rewrite the code in Julia. The reader count based implementation is st…

---

## [Scientific Software Developer at the Flatiron Institute - Tensor Networks, ITensor](https://discourse.julialang.org/t/scientific-software-developer-at-the-flatiron-institute-tensor-networks-itensor/71498)

<div class="topic-metadata">

**Author:** [@mtfishman](https://discourse.julialang.org/u/mtfishman)\
**Replies:** 0\
**Last updated:** [November 15, 2021, 2:24pm UTC](https://discourse.julialang.org/t/scientific-software-developer-at-the-flatiron-institute-tensor-networks-itensor/71498 "2021-11-15T14:24:26Z")

</div>

Introduction: Miles Stoudenmire (@miles) and I (@mtfishman) are hiring a software developer to work on the new Julia port of ITensor, a leading tensor network software package used for cutting edge projects in quantum ph…

---

## [Memory consumption growth with many large MILP's in JuMP](https://discourse.julialang.org/t/memory-consumption-growth-with-many-large-milps-in-jump/61895)

<div class="topic-metadata">

**Author:** [@nlaws](https://discourse.julialang.org/u/nlaws)\
**Replies:** 63\
**Last updated:** [November 16, 2021, 11:21pm UTC](https://discourse.julialang.org/t/memory-consumption-growth-with-many-large-milps-in-jump/61895 "2021-11-16T23:21:34Z")

</div>

We are running into an issue with JuMP models run in an API that are leading to our servers running out of RAM. Oddly, it does appear that the memory consumption plateaus after some time/iterations. Also, it can be recre…

---

## [Strategies for parallelization of fast non-uniform tasks](https://discourse.julialang.org/t/strategies-for-parallelization-of-fast-non-uniform-tasks/71531)

<div class="topic-metadata">

**Author:** [@lmiq](https://discourse.julialang.org/u/lmiq)\
**Replies:** 12\
**Last updated:** [November 16, 2021, 11:11pm UTC](https://discourse.julialang.org/t/strategies-for-parallelization-of-fast-non-uniform-tasks/71531 "2021-11-16T23:11:50Z")

</div>

Which are the recommended strategies/packages to deal with the parallelization of many (thousands of) tasks that are: Individually relatively fast (costs associated to spawning may not be negligible). Possibly somewha…

---

## [Multithreading using FLoops for updating discrete distribution](https://discourse.julialang.org/t/multithreading-using-floops-for-updating-discrete-distribution/71176)

<div class="topic-metadata">

**Author:** [@PatrickMcFarlane](https://discourse.julialang.org/u/PatrickMcFarlane)\
**Replies:** 11\
**Last updated:** [November 16, 2021, 10:46pm UTC](https://discourse.julialang.org/t/multithreading-using-floops-for-updating-discrete-distribution/71176 "2021-11-16T22:46:39Z")

</div>

I’m working on a heterogeneous agent macroeconomics model. One of the steps in the solution method for the model is to update the (discrete) wealth distribution across agents. The model is quite big so I need to multi…

---

## [NeuralODE Layer Strategy](https://discourse.julialang.org/t/neuralode-layer-strategy/71297)

<div class="topic-metadata">

**Author:** [@lindblot](https://discourse.julialang.org/u/lindblot)\
**Replies:** 4\
**Last updated:** [November 16, 2021, 9:20pm UTC](https://discourse.julialang.org/t/neuralode-layer-strategy/71297 "2021-11-16T21:20:36Z")

</div>

To embed as much known information as possible, I’m trying to include a known equation in a NeuralODE. Using the simple pendulum example for dynamics and following the DiffEqFlux local minima documentation page with a ba…

---

## [Adding custom keybinding overrides other keys](https://discourse.julialang.org/t/adding-custom-keybinding-overrides-other-keys/71612)

<div class="topic-metadata">

**Author:** [@rs31415](https://discourse.julialang.org/u/rs31415)\
**Replies:** 0\
**Last updated:** [November 16, 2021, 9:14pm UTC](https://discourse.julialang.org/t/adding-custom-keybinding-overrides-other-keys/71612 "2021-11-16T21:14:44Z")

</div>

I want to add a custom keyboard shortcut as described here: The Julia REPL · The Julia Language. I thought it would be quite easy to set an alias for the “home” key: import REPL const mykeys = Dict{Any,Any}( # Mov…

---

## [Advice on using ModelingToolkit to solve Lagrange Problems](https://discourse.julialang.org/t/advice-on-using-modelingtoolkit-to-solve-lagrange-problems/71473)

<div class="topic-metadata">

**Author:** [@brett\_knoss](https://discourse.julialang.org/u/brett_knoss)\
**Replies:** 29\
**Last updated:** [November 16, 2021, 7:41pm UTC](https://discourse.julialang.org/t/advice-on-using-modelingtoolkit-to-solve-lagrange-problems/71473 "2021-11-16T19:41:19Z")

</div>

How would I use ModelingToolkit.jl to solve Lagrange problems? I know of the @varable macro, and the @derivative macro, but I’m not sure the purpose of the @parameters macro.

---

## [How to reset theming cycler in Makie axis?](https://discourse.julialang.org/t/how-to-reset-theming-cycler-in-makie-axis/71607)

<div class="topic-metadata">

**Author:** [@aramirezreyes](https://discourse.julialang.org/u/aramirezreyes)\
**Replies:** 1\
**Last updated:** [November 16, 2021, 7:22pm UTC](https://discourse.julialang.org/t/how-to-reset-theming-cycler-in-makie-axis/71607 "2021-11-16T19:22:40Z")

</div>

Hi there! I am plotting two sets of lines in the same axis. I would like each line on a set to have the same style (line color, style, width, etc…) to the corresponding line in the other set. Currently, the style cycles…

---

## [Function definitions with literal parameters](https://discourse.julialang.org/t/function-definitions-with-literal-parameters/71538)

<div class="topic-metadata">

**Author:** [@banksiaboy](https://discourse.julialang.org/u/banksiaboy)\
**Replies:** 7\
**Last updated:** [November 16, 2021, 6:28pm UTC](https://discourse.julialang.org/t/function-definitions-with-literal-parameters/71538 "2021-11-16T18:28:41Z")

</div>

I’m tinkering with groups, bitstrings and XOR. I don’t care about efficiency - but it’s always nice… I create the type then I want functions dispatching on value :slight\_smile: @enum Bit zero one ⨁(zero, zero) = zero …

---

## [What happens when you throw an error from a \`@cfunction\`?](https://discourse.julialang.org/t/what-happens-when-you-throw-an-error-from-a-cfunction/71510)

<div class="topic-metadata">

**Author:** [@simonbyrne](https://discourse.julialang.org/u/simonbyrne)\
**Replies:** 4\
**Last updated:** [November 16, 2021, 6:23pm UTC](https://discourse.julialang.org/t/what-happens-when-you-throw-an-error-from-a-cfunction/71510 "2021-11-16T18:23:30Z")

</div>

If I define a C-callable function pointer (via @cfunction) which can internally throw an error, and then perform a ccall which would then invoke the function and trigger the error, what actually happens? I assume it does…

---

## [Plot with three y-axes (, so one y-axis has to be double)](https://discourse.julialang.org/t/plot-with-three-y-axes-so-one-y-axis-has-to-be-double/58699)

<div class="topic-metadata">

**Author:** [@BMval](https://discourse.julialang.org/u/BMval)\
**Replies:** 10\
**Last updated:** [November 16, 2021, 5:49pm UTC](https://discourse.julialang.org/t/plot-with-three-y-axes-so-one-y-axis-has-to-be-double/58699 "2021-11-16T17:49:07Z")

</div>

Hello, I need to put on the same graph three lines with different y-axis). I know how to do it with two y-axises (one is right and the other is left). How to do it with 3 lines, so the left y-axis has to be double. th…

---

## [What would be julia equivalent of this ruby one liner?](https://discourse.julialang.org/t/what-would-be-julia-equivalent-of-this-ruby-one-liner/71596)

<div class="topic-metadata">

**Author:** [@benibilme](https://discourse.julialang.org/u/benibilme)\
**Replies:** 6\
**Last updated:** [November 16, 2021, 5:43pm UTC](https://discourse.julialang.org/t/what-would-be-julia-equivalent-of-this-ruby-one-liner/71596 "2021-11-16T17:43:53Z")

</div>

Hello, I often use following one liner in ruby to see the details of my PATH. What would be the cleanest version of it in julia with less typing. ruby -e 'puts ENV\["PATH"\].split(":").sort' or longer version ruby -e '…

---

## [Nonlinear expression without scalar expressions](https://discourse.julialang.org/t/nonlinear-expression-without-scalar-expressions/71544)

<div class="topic-metadata">

**Author:** [@chupin](https://discourse.julialang.org/u/chupin)\
**Replies:** 2\
**Last updated:** [November 16, 2021, 5:34pm UTC](https://discourse.julialang.org/t/nonlinear-expression-without-scalar-expressions/71544 "2021-11-16T17:34:52Z")

</div>

Hi, I’ve read that nonlinear optimization has limited support. Unfortunately, my objective function cannot be written with scalar expressions and my matrix variable is at least 1000x1000 and I need to call several functi…

---

## [Deepcopy against the grain of Julia?](https://discourse.julialang.org/t/deepcopy-against-the-grain-of-julia/71580)

<div class="topic-metadata">

**Author:** [@idontgetoutmuch](https://discourse.julialang.org/u/idontgetoutmuch)\
**Replies:** 9\
**Last updated:** [November 16, 2021, 4:41pm UTC](https://discourse.julialang.org/t/deepcopy-against-the-grain-of-julia/71580 "2021-11-16T16:41:03Z")

</div>

I have implemented a particle filter for an agent-based model using JuliaDynamics but I seem to have ended up using deepcopy a lot. Also when I run the simple particle filter over a very simple model I don’t get very goo…

---

## [Looking For A Few Talented Julia Developers- Remote Work Opportunity](https://discourse.julialang.org/t/looking-for-a-few-talented-julia-developers-remote-work-opportunity/71598)

<div class="topic-metadata">

**Author:** [@juliafanatics](https://discourse.julialang.org/u/juliafanatics)\
**Replies:** 0\
**Last updated:** [November 16, 2021, 4:35pm UTC](https://discourse.julialang.org/t/looking-for-a-few-talented-julia-developers-remote-work-opportunity/71598 "2021-11-16T16:35:39Z")

</div>

Julia Programmers- Remote Work This is your opportunity to be part of a growing team that loves Julia! We are an established software development company that has been using Julia for many years. We are currently lookin…

---

## [Finding an equality between two datetime](https://discourse.julialang.org/t/finding-an-equality-between-two-datetime/71594)

<div class="topic-metadata">

**Author:** [@jnewbie](https://discourse.julialang.org/u/jnewbie)\
**Replies:** 3\
**Last updated:** [November 16, 2021, 4:20pm UTC](https://discourse.julialang.org/t/finding-an-equality-between-two-datetime/71594 "2021-11-16T16:20:11Z")

</div>

Hi, a = \[DateTime(“2021-08-02T10:00:00”), DateTime(“2021-08-05T07:00:00”), DateTime(“2021-08-05T07:00:00”)\] b = DateTime(“2021-08-05T07:00:00”) for i in 1:length(a) print(findall(b == a\[i\])) end Result : Int6…

---

## [\[ANN\] GXBeam.jl v0.3.0 - Geometrically Exact Beam Theory](https://discourse.julialang.org/t/ann-gxbeam-jl-v0-3-0-geometrically-exact-beam-theory/71337)

<div class="topic-metadata">

**Author:** [@taylormcd](https://discourse.julialang.org/u/taylormcd)\
**Replies:** 11\
**Last updated:** [November 16, 2021, 2:56pm UTC](https://discourse.julialang.org/t/ann-gxbeam-jl-v0-3-0-geometrically-exact-beam-theory/71337 "2021-11-16T14:56:10Z")

</div>

I’m pleased to announce the release of version 0.3 of the GXBeam package, which contains a thoroughly verified and validated pure Julia implementation of geometrically exact beam theory. This version introduces: Point…

---

## [What happened to shift! unshift! on collections](https://discourse.julialang.org/t/what-happened-to-shift-unshift-on-collections/71588)

<div class="topic-metadata">

**Author:** [@benibilme](https://discourse.julialang.org/u/benibilme)\
**Replies:** 2\
**Last updated:** [November 16, 2021, 2:45pm UTC](https://discourse.julialang.org/t/what-happened-to-shift-unshift-on-collections/71588 "2021-11-16T14:45:13Z")

</div>

Hello, I have some notes about julia and there are supposed to be functions called shift! and unshift! on arrays. However in julia 1.6 environment, I receive error. There are no reference in the documentation. Are there…

---

## [Preferred OS for Raspberry Pi](https://discourse.julialang.org/t/preferred-os-for-raspberry-pi/71586)

<div class="topic-metadata">

**Author:** [@Jake](https://discourse.julialang.org/u/Jake)\
**Replies:** 1\
**Last updated:** [November 16, 2021, 2:08pm UTC](https://discourse.julialang.org/t/preferred-os-for-raspberry-pi/71586 "2021-11-16T14:08:44Z")

</div>

I mostly use Windows and VSCode when using Julia. I am familiar with Ubuntu. I have a Raspberry Pi 4 with 8 Gig of RAM and an MCC\_172 HAT, which I am working on getting accessible to Julia. So far I have used Raspbian…

---

## [Plot blurred (again) in VS Code with GR](https://discourse.julialang.org/t/plot-blurred-again-in-vs-code-with-gr/71546)

<div class="topic-metadata">

**Author:** [@luboshanus](https://discourse.julialang.org/u/luboshanus)\
**Replies:** 4\
**Last updated:** [November 16, 2021, 1:50pm UTC](https://discourse.julialang.org/t/plot-blurred-again-in-vs-code-with-gr/71546 "2021-11-16T13:50:48Z")

</div>

I have a problem with plots in VS Code. Plots are blurred and one cannot zoom in/out within it as it used to be. It saves the plot correctly into pdf. Plots v1.23.1, v1.23.6. GR 0.61.0

---

## [ASGI equivalent in Julia for High performance?](https://discourse.julialang.org/t/asgi-equivalent-in-julia-for-high-performance/69809)

<div class="topic-metadata">

**Author:** [@mks](https://discourse.julialang.org/u/mks)\
**Replies:** 4\
**Last updated:** [November 16, 2021, 1:44pm UTC](https://discourse.julialang.org/t/asgi-equivalent-in-julia-for-high-performance/69809 "2021-11-16T13:44:08Z")

</div>

Hello, I wonder if there will be more work on an ASGI Framework equivalent in Julia. I see all the recent Python webframeworks use ASGI, like FastAPI, Scarlette or Quart. How come we do not see this in Julia? FastCGI a…

---

## [How to set markers in julia pyplot's legend?](https://discourse.julialang.org/t/how-to-set-markers-in-julia-pyplots-legend/71527)

<div class="topic-metadata">

**Author:** [@Luigi\_Marongiu](https://discourse.julialang.org/u/Luigi_Marongiu)\
**Replies:** 1\
**Last updated:** [November 16, 2021, 1:19pm UTC](https://discourse.julialang.org/t/how-to-set-markers-in-julia-pyplots-legend/71527 "2021-11-16T13:19:17Z")

</div>

Hello, I plotted some data with lines and then highlighted some specific points with dots using PyPlot. When I add the legend, the icons next to the names only shows line because the first elements of the plot are indee…

---

## [Makie - SLOW Code: ax = Axis(fig\[1,1\]) takes 50 seconds to execute](https://discourse.julialang.org/t/makie-slow-code-ax-axis-fig-1-1-takes-50-seconds-to-execute/71457)

<div class="topic-metadata">

**Author:** [@nelsonah](https://discourse.julialang.org/u/nelsonah)\
**Replies:** 19\
**Last updated:** [November 16, 2021, 12:56pm UTC](https://discourse.julialang.org/t/makie-slow-code-ax-axis-fig-1-1-takes-50-seconds-to-execute/71457 "2021-11-16T12:56:18Z")

</div>

using GLMakie println(“Starting Program”) t0 = time(); t\_last = t0 println(“Initialize the figure”) fig = Figure(); t\_n = time(); del\_t = t\_n - t\_last; t\_last = t\_n; println(“del\_t = $del\_t”); println(“”) println(“…

---

## [Struct initialization error](https://discourse.julialang.org/t/struct-initialization-error/71582)

<div class="topic-metadata">

**Author:** [@emanuellima](https://discourse.julialang.org/u/emanuellima)\
**Replies:** 2\
**Last updated:** [November 16, 2021, 12:49pm UTC](https://discourse.julialang.org/t/struct-initialization-error/71582 "2021-11-16T12:49:20Z")

</div>

I am having an error that I don’t understand. The code works on the REPL but it doesn’t when called from the terminal (after being compiled with Comonicon): There is this struct called State, and it’s constructor tha…

---

## [Circular array in Julia](https://discourse.julialang.org/t/circular-array-in-julia/25588)

<div class="topic-metadata">

**Author:** [@udistr](https://discourse.julialang.org/u/udistr)\
**Replies:** 27\
**Last updated:** [November 16, 2021, 12:28pm UTC](https://discourse.julialang.org/t/circular-array-in-julia/25588 "2021-11-16T12:28:02Z")

</div>

Is the a simple way in Julia to define circular array, e.g., if I have: x=zeros(4,4) I would like that: x\[1,5\] = x\[1,1\] x\[1,6\] = x\[1,2\] … and x\[5,1\] = x\[1,1\] x\[6,1\] = x\[2,1\] … I would like to define a more comp…

[Previous page](https://discourse.julialang.org/latest.md?page=1203)

[Next page](https://discourse.julialang.org/latest.md?page=1205)
