# Latest

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

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

**Page:** 1656

---

## [Changing order in the legend](https://discourse.julialang.org/t/changing-order-in-the-legend/45158)

<div class="topic-metadata">

**Author:** [@morkip](https://discourse.julialang.org/u/morkip)\
**Replies:** 2\
**Last updated:** [August 18, 2020, 3:40pm UTC](https://discourse.julialang.org/t/changing-order-in-the-legend/45158 "2020-08-18T15:40:36Z")

</div>

I am creating a plot with multiple lines for comparison using plot!(..) for each new line. The line I plot first, appears at the very bottom of all the lines but at the first line of the legend. Obviously, it is very eas…

---

## [Fortran modules and Julia modules](https://discourse.julialang.org/t/fortran-modules-and-julia-modules/45053)

<div class="topic-metadata">

**Author:** [@Adelson\_Oliveira](https://discourse.julialang.org/u/Adelson_Oliveira)\
**Replies:** 8\
**Last updated:** [August 18, 2020, 3:13pm UTC](https://discourse.julialang.org/t/fortran-modules-and-julia-modules/45053 "2020-08-18T15:13:46Z")

</div>

Hi, Is already possible to plainly use FORTRAN modules in Julia? If not, are there plans to allow for Julia using FORTRAN modules ( .o and .mod)? Thanks in advance

---

## [Error: Unexpected values in bisection. (DifferentialEquations)](https://discourse.julialang.org/t/error-unexpected-values-in-bisection-differentialequations/45145)

<div class="topic-metadata">

**Author:** [@Lachlan-Bn](https://discourse.julialang.org/u/Lachlan-Bn)\
**Replies:** 3\
**Last updated:** [August 18, 2020, 3:08pm UTC](https://discourse.julialang.org/t/error-unexpected-values-in-bisection-differentialequations/45145 "2020-08-18T15:08:02Z")

</div>

I’m encountering an error related to using BigFloats and a callback that terminates the integrator upon certain conditions. More specifically, julia throws the following error when calling solve() with the callback on a …

---

## [Exact sqrt in Julia?](https://discourse.julialang.org/t/exact-sqrt-in-julia/45140)

<div class="topic-metadata">

**Author:** [@Seif\_Shebl](https://discourse.julialang.org/u/Seif_Shebl)\
**Replies:** 13\
**Last updated:** [August 18, 2020, 2:52pm UTC](https://discourse.julialang.org/t/exact-sqrt-in-julia/45140 "2020-08-18T14:52:09Z")

</div>

I want to check if an expression evaluates to Integer result. I know this is never the best solution, but I ran out of ideas and not able to come up with an algorithm to solve the problem in a reasonable time. The only w…

---

## [ApproxFun and Mobius Transforms](https://discourse.julialang.org/t/approxfun-and-mobius-transforms/45161)

<div class="topic-metadata">

**Author:** [@white-c](https://discourse.julialang.org/u/white-c)\
**Replies:** 0\
**Last updated:** [August 18, 2020, 2:48pm UTC](https://discourse.julialang.org/t/approxfun-and-mobius-transforms/45161 "2020-08-18T14:48:32Z")

</div>

I am just starting to learn how to work with ApproxFun. I have worked through a few examples. Now, I want to use it for Mobius transformations. However, I am not sure the best basis to use. Any suggestions on how to work…

---

## [\[Beginner\] How do I see the methods on a type I'm extending?](https://discourse.julialang.org/t/beginner-how-do-i-see-the-methods-on-a-type-im-extending/45155)

<div class="topic-metadata">

**Author:** [@haydenjones](https://discourse.julialang.org/u/haydenjones)\
**Replies:** 3\
**Last updated:** [August 18, 2020, 2:46pm UTC](https://discourse.julialang.org/t/beginner-how-do-i-see-the-methods-on-a-type-im-extending/45155 "2020-08-18T14:46:11Z")

</div>

struct Thing name::AbstractString) end struct ThingHolder holding::Thing end function sayer(t) println(x.name) end function sayer(t\_h) print(t\_h.holding.name) end my\_holder = ThingHolder(Thing("hayden")) say…

---

## [Difference between an ODE with manifold projection and a DAE](https://discourse.julialang.org/t/difference-between-an-ode-with-manifold-projection-and-a-dae/45136)

<div class="topic-metadata">

**Author:** [@cuihantao](https://discourse.julialang.org/u/cuihantao)\
**Replies:** 3\
**Last updated:** [August 18, 2020, 1:08pm UTC](https://discourse.julialang.org/t/difference-between-an-ode-with-manifold-projection-and-a-dae/45136 "2020-08-18T13:08:40Z")

</div>

Hi, I’d like to know the difference between an ODE set with manifold projection callback and a DAE (formulated as ODE with a singular mass matrix). It seems to me that the former one separates the algebraic equations fr…

---

## [Adding command line scripts to path when installing packages?](https://discourse.julialang.org/t/adding-command-line-scripts-to-path-when-installing-packages/43414)

<div class="topic-metadata">

**Author:** [@onetonfoot](https://discourse.julialang.org/u/onetonfoot)\
**Replies:** 6\
**Last updated:** [August 18, 2020, 12:40pm UTC](https://discourse.julialang.org/t/adding-command-line-scripts-to-path-when-installing-packages/43414 "2020-08-18T12:40:21Z")

</div>

What’s the easiest way to add a julia script to a users path when they install a package? I’m wondering if there is a equivalent to entry\_points in pythons setup.py

---

## [Zygote.gradient(): Mutating arrays is not supported](https://discourse.julialang.org/t/zygote-gradient-mutating-arrays-is-not-supported/45148)

<div class="topic-metadata">

**Author:** [@F-YF](https://discourse.julialang.org/u/F-YF)\
**Replies:** 1\
**Last updated:** [August 18, 2020, 10:01am UTC](https://discourse.julialang.org/t/zygote-gradient-mutating-arrays-is-not-supported/45148 "2020-08-18T10:01:42Z")

</div>

When I do a gradient calculation with Zygote, it throw an error: Mutating arrays is not supported. I don’t know why it went wrong, how should I correct it, or how should I debug it so that I would know where it went wron…

---

## [Collecting results in proper order using Multi-threading](https://discourse.julialang.org/t/collecting-results-in-proper-order-using-multi-threading/44889)

<div class="topic-metadata">

**Author:** [@mors](https://discourse.julialang.org/u/mors)\
**Replies:** 7\
**Last updated:** [August 18, 2020, 10:01am UTC](https://discourse.julialang.org/t/collecting-results-in-proper-order-using-multi-threading/44889 "2020-08-18T10:01:16Z")

</div>

Hi, I am performing Montecarlo type method and I would like to perform the Multi-Treding. Unfortunately, I am a beginner in Multi-threading for operations of the form n\_{i}/n\_{i-1}. Usually, I perform multiple cores t…

---

## [Does multithreading require a new process?](https://discourse.julialang.org/t/does-multithreading-require-a-new-process/45056)

<div class="topic-metadata">

**Author:** [@BioTurboNick](https://discourse.julialang.org/u/BioTurboNick)\
**Replies:** 11\
**Last updated:** [August 18, 2020, 8:14am UTC](https://discourse.julialang.org/t/does-multithreading-require-a-new-process/45056 "2020-08-18T08:14:02Z")

</div>

I’m looking at the new multithreading features (vs. multiprocess). Based on the documentation, it looks like currently you cannot generate new threads in a running Julia process? That is, they need to be specified as a s…

---

## [Quadratic and non-linear expressions cannot be mixed up!](https://discourse.julialang.org/t/quadratic-and-non-linear-expressions-cannot-be-mixed-up/45120)

<div class="topic-metadata">

**Author:** [@musman](https://discourse.julialang.org/u/musman)\
**Replies:** 4\
**Last updated:** [August 18, 2020, 8:02am UTC](https://discourse.julialang.org/t/quadratic-and-non-linear-expressions-cannot-be-mixed-up/45120 "2020-08-18T08:02:12Z")

</div>

Hi, I am setting up a non-linear objective which contains both quadratic and non-linear terms. However, I am getting the following error Unexpected quadratic expression 378.5346047250809 e\[1\]² + 378.5346047250809 f\[1\]² …

---

## [\[ANN\] Gridap.jl: A feature-rich Finite Element ecosystem 100% in Julia](https://discourse.julialang.org/t/ann-gridap-jl-a-feature-rich-finite-element-ecosystem-100-in-julia/42824)

<div class="topic-metadata">

**Author:** [@fverdugo](https://discourse.julialang.org/u/fverdugo)\
**Replies:** 49\
**Last updated:** [August 17, 2020, 3:54pm UTC](https://discourse.julialang.org/t/ann-gridap-jl-a-feature-rich-finite-element-ecosystem-100-in-julia/42824 "2020-08-17T15:54:32Z")

</div>

We (@santiagobadia and @fverdugo) are happy to announce Gridap.jl a new Finite Element framework written in Julia for the numerical simulation of a wide range of mathematical models governed by partial differential equat…

---

## [Is there a MPI-based map package?](https://discourse.julialang.org/t/is-there-a-mpi-based-map-package/45087)

<div class="topic-metadata">

**Author:** [@astrojhgu](https://discourse.julialang.org/u/astrojhgu)\
**Replies:** 2\
**Last updated:** [August 18, 2020, 4:14am UTC](https://discourse.julialang.org/t/is-there-a-mpi-based-map-package/45087 "2020-08-18T04:14:08Z")

</div>

Is there such a package providing a function like? function mpi\_map(Function, Array, MPI\_COMM), which bechaviours like result=map(some\_input\_array, comm) do x some\_operation(x) done I wrote one myself based on se…

---

## [How to efficiently figure out correct ways of using packages and syntax?](https://discourse.julialang.org/t/how-to-efficiently-figure-out-correct-ways-of-using-packages-and-syntax/45061)

<div class="topic-metadata">

**Author:** [@DShiu](https://discourse.julialang.org/u/DShiu)\
**Replies:** 7\
**Last updated:** [August 18, 2020, 3:33am UTC](https://discourse.julialang.org/t/how-to-efficiently-figure-out-correct-ways-of-using-packages-and-syntax/45061 "2020-08-18T03:33:02Z")

</div>

My question is a bit general: how to efficiently figure out correct ways of using packages and syntax. I illustrate the difficulty that I am having using the following example: I was trying to learn the code shared by s…

---

## [Broadcast operations with multiple DenseAxisArrays are not yet supported](https://discourse.julialang.org/t/broadcast-operations-with-multiple-denseaxisarrays-are-not-yet-supported/45133)

<div class="topic-metadata">

**Author:** [@zlq178](https://discourse.julialang.org/u/zlq178)\
**Replies:** 2\
**Last updated:** [August 18, 2020, 2:43am UTC](https://discourse.julialang.org/t/broadcast-operations-with-multiple-denseaxisarrays-are-not-yet-supported/45133 "2020-08-18T02:43:13Z")

</div>

using JuMP,Gurobi n=4 a=\[0;0;50;50\] b=\[0;0;351;389\] c=\[0;0;44.4;40.6\] model=Model(Gurobi.Optimizer) @variable(model, P\[1:n,1\])#julia中创建一个全参数决策变量的方式 f=@expression(model,a'\*(P.\*P)+b'\*P+sum(c)) @objective(model,min,f) …

---

## [Zygote : Can't differentiate gc\_preserve\_end expression](https://discourse.julialang.org/t/zygote-cant-differentiate-gc-preserve-end-expression/44973)

<div class="topic-metadata">

**Author:** [@F-YF](https://discourse.julialang.org/u/F-YF)\
**Replies:** 9\
**Last updated:** [August 18, 2020, 2:25am UTC](https://discourse.julialang.org/t/zygote-cant-differentiate-gc-preserve-end-expression/44973 "2020-08-18T02:25:57Z")

</div>

An error was reported when I called Zygote.gradient, with the following error message. What should I do to resolve it?

---

## [Adding second order cone is slow](https://discourse.julialang.org/t/adding-second-order-cone-is-slow/45124)

<div class="topic-metadata">

**Author:** [@sobhan](https://discourse.julialang.org/u/sobhan)\
**Replies:** 13\
**Last updated:** [August 18, 2020, 1:55am UTC](https://discourse.julialang.org/t/adding-second-order-cone-is-slow/45124 "2020-08-18T01:55:43Z")

</div>

Hi, I have a conic model that i want to solve. The model looks like this using MathOptInterface const MOI = MathOptInterface using Gurobi using JuMP n=200 model = Model(Gurobi.Optimizer) @variable(model, t\[i=1:n, j=1:n…

---

## [Stochastic MPC using JuMP - Explained in detail for future example in JuMP](https://discourse.julialang.org/t/stochastic-mpc-using-jump-explained-in-detail-for-future-example-in-jump/45100)

<div class="topic-metadata">

**Author:** [@pandeysudan27](https://discourse.julialang.org/u/pandeysudan27)\
**Replies:** 2\
**Last updated:** [August 18, 2020, 12:23am UTC](https://discourse.julialang.org/t/stochastic-mpc-using-jump-explained-in-detail-for-future-example-in-jump/45100 "2020-08-18T00:23:10Z")

</div>

I need help regarding formulating multi-state stochastic MPC in JuMP. In some way my optimization routine is wrong. Any help is much appreciated! swing MPC The swing equation is given as, M\\frac{d^2\\delta}{dt^2}=P\_\\mat…

---

## [Literate to generate markdown programmatically](https://discourse.julialang.org/t/literate-to-generate-markdown-programmatically/44888)

<div class="topic-metadata">

**Author:** [@jdlara-berkeley](https://discourse.julialang.org/u/jdlara-berkeley)\
**Replies:** 5\
**Last updated:** [August 17, 2020, 7:44pm UTC](https://discourse.julialang.org/t/literate-to-generate-markdown-programmatically/44888 "2020-08-17T19:44:14Z")

</div>

I want to generate Markdown entries programmatically and I am using Literate.jl (maybe that is not the best tool for that, recommendations are also welcome). This is a MWE of what I am trying to do. # # Test import M…

---

## [ANN: DiceRolls.jl](https://discourse.julialang.org/t/ann-dicerolls-jl/44972)

<div class="topic-metadata">

**Author:** [@abelsiqueira](https://discourse.julialang.org/u/abelsiqueira)\
**Replies:** 7\
**Last updated:** [August 17, 2020, 7:18pm UTC](https://discourse.julialang.org/t/ann-dicerolls-jl/44972 "2020-08-17T19:18:25Z")

</div>

Hi all, I am pleased to announce the release of the package Dices.jl, DiceRolls.jl for playing around with dice rolls, histograms, and other fun stuff. Nothing exceptional, just having fun. If someone decides to create a…

---

## [Conceptual Gaussian Process Questions](https://discourse.julialang.org/t/conceptual-gaussian-process-questions/44305)

<div class="topic-metadata">

**Author:** [@nucklass](https://discourse.julialang.org/u/nucklass)\
**Replies:** 15\
**Last updated:** [August 17, 2020, 5:56pm UTC](https://discourse.julialang.org/t/conceptual-gaussian-process-questions/44305 "2020-08-17T17:56:26Z")

</div>

Hi! This is more of a theoretical tangent, so forgive me if this is a bit off topic. I’ve recently finished my undergrad in Statistics and have been trying to navigate the US job market, to fairly dismal results. Anyway,…

---

## [Column-wise reduction on a CUDA.CuArray matrix](https://discourse.julialang.org/t/column-wise-reduction-on-a-cuda-cuarray-matrix/45069)

<div class="topic-metadata">

**Author:** [@mkarikom](https://discourse.julialang.org/u/mkarikom)\
**Replies:** 0\
**Last updated:** [August 16, 2020, 10:33pm UTC](https://discourse.julialang.org/t/column-wise-reduction-on-a-cuda-cuarray-matrix/45069 "2020-08-16T22:33:44Z")

</div>

As suggested here, I am trying to create a version of this findfirst kernel that operates over dimension 2 of input matrix xs and returns the first match for each vector along dimension 1. I think a good approach is a c…

---

## [How to weight a normalized histogram in Plots](https://discourse.julialang.org/t/how-to-weight-a-normalized-histogram-in-plots/45111)

<div class="topic-metadata">

**Author:** [@Christopher\_Fisher](https://discourse.julialang.org/u/Christopher_Fisher)\
**Replies:** 2\
**Last updated:** [August 17, 2020, 4:12pm UTC](https://discourse.julialang.org/t/how-to-weight-a-normalized-histogram-in-plots/45111 "2020-08-17T16:12:36Z")

</div>

I would like to plot a joint distribution as two normalized histograms. One distribution has a weight w and the other has a weight 1-w. Unfortunately, I cannot figure out how to apply the weight to a normalized histogram…

---

## [Reinterpret zero-dimensional view](https://discourse.julialang.org/t/reinterpret-zero-dimensional-view/45047)

<div class="topic-metadata">

**Author:** [@BioTurboNick](https://discourse.julialang.org/u/BioTurboNick)\
**Replies:** 5\
**Last updated:** [August 17, 2020, 4:11pm UTC](https://discourse.julialang.org/t/reinterpret-zero-dimensional-view/45047 "2020-08-17T16:11:24Z")

</div>

Reinterpreting a zero-dimensional view: a = \[1; 2; 3\] b = view(a, 2) c = reinterpret(UInt8, b) # ERROR: ArgumentError: cannot reinterpret a zero-dimensional \`Int64\` array to \`UInt8\` which is of a different size The wor…

---

## [JuliaCon 2020 Proceedings](https://discourse.julialang.org/t/juliacon-2020-proceedings/44347)

<div class="topic-metadata">

**Author:** [@mbesancon](https://discourse.julialang.org/u/mbesancon)\
**Replies:** 2\
**Last updated:** [August 17, 2020, 3:51pm UTC](https://discourse.julialang.org/t/juliacon-2020-proceedings/44347 "2020-08-17T15:51:03Z")

</div>

Hello everyone, We hope you had a fantastic JuliaCon 2020! We always enjoy learning about the breadth and drive of the community, as well as meeting old and new friends. Last year we decided to have conference proceedi…

---

## [JuliaDB: select columns from 2 tables and join based on 2 keys](https://discourse.julialang.org/t/juliadb-select-columns-from-2-tables-and-join-based-on-2-keys/45076)

<div class="topic-metadata">

**Author:** [@DShiu](https://discourse.julialang.org/u/DShiu)\
**Replies:** 3\
**Last updated:** [August 17, 2020, 3:47pm UTC](https://discourse.julialang.org/t/juliadb-select-columns-from-2-tables-and-join-based-on-2-keys/45076 "2020-08-17T15:47:42Z")

</div>

Suppose that we have 2 tables, each contains multiple columns. The first table has (id, date, x1, x2, x3) and the second has (id, date, y1, y2, y3). Is it possible to create a new table by selecting columns (id, date, x1…

---

## [Looking for feedback on PRs in YAML.jl](https://discourse.julialang.org/t/looking-for-feedback-on-prs-in-yaml-jl/45116)

<div class="topic-metadata">

**Author:** [@mirkobunse](https://discourse.julialang.org/u/mirkobunse)\
**Replies:** 0\
**Last updated:** [August 17, 2020, 3:36pm UTC](https://discourse.julialang.org/t/looking-for-feedback-on-prs-in-yaml-jl/45116 "2020-08-17T15:36:11Z")

</div>

The maintainers of YAML.jl are looking for users of the package to provide feedback on pull requests and open issues. In particular, some discussion is needed regarding the API of the package. To which degree should the…

---

## [TextAnalysis.jl Naive Bayes Load Error](https://discourse.julialang.org/t/textanalysis-jl-naive-bayes-load-error/45115)

<div class="topic-metadata">

**Author:** [@Chris\_Anderson](https://discourse.julialang.org/u/Chris_Anderson)\
**Replies:** 0\
**Last updated:** [August 17, 2020, 3:35pm UTC](https://discourse.julialang.org/t/textanalysis-jl-naive-bayes-load-error/45115 "2020-08-17T15:35:56Z")

</div>

I am trying to use TextAnalysis.jl for some text classification using the Naive Bayes Classifier. However, I’ve been unable to begin as I’m getting an error before I can even load the classifier. using TextAnalysis: Nai…

---

## [\[ANN\] Deriving configurations from more abstract MetaConfigurations.jl](https://discourse.julialang.org/t/ann-deriving-configurations-from-more-abstract-metaconfigurations-jl/45114)

<div class="topic-metadata">

**Author:** [@mirkobunse](https://discourse.julialang.org/u/mirkobunse)\
**Replies:** 0\
**Last updated:** [August 17, 2020, 3:24pm UTC](https://discourse.julialang.org/t/ann-deriving-configurations-from-more-abstract-metaconfigurations-jl/45114 "2020-08-17T15:24:11Z")

</div>

When you intend to configure a set of similar jobs, e.g. experiments, it can be helpful to derive these configurations from more abstract and comprehensive meta-configurations. Two examples: conduct an experiment, wher…

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

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