# Modelling & Simulations

**URL:** https://discourse.julialang.org/c/domain/models/21.md?page=25

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

**Page:** 26

---

## [Simulating a PID in a DAE - how to simulate a DDAE?](https://discourse.julialang.org/t/simulating-a-pid-in-a-dae-how-to-simulate-a-ddae/111320)

<div class="topic-metadata">

**Author:** [@lpz18](https://discourse.julialang.org/u/lpz18)\
**Replies:** 4\
**Last updated:** [March 11, 2024, 6:16pm UTC](https://discourse.julialang.org/t/simulating-a-pid-in-a-dae-how-to-simulate-a-ddae/111320 "2024-03-11T18:16:45Z")

</div>

I would like to run a PID controller with a nonlinear set of ODEs with 6 continous variables. I thought I could do this with delay differential algebraic equaions, since in DelayDiffEq.jl it says Covers neutral and re…

---

## [Custom Noise Process for DifferentialEquations.jl](https://discourse.julialang.org/t/custom-noise-process-for-differentialequations-jl/111418)

<div class="topic-metadata">

**Author:** [@StefanPerko](https://discourse.julialang.org/u/StefanPerko)\
**Replies:** 2\
**Last updated:** [March 11, 2024, 10:03am UTC](https://discourse.julialang.org/t/custom-noise-process-for-differentialequations-jl/111418 "2024-03-11T10:03:34Z")

</div>

I’m trying to define my own noise process for usage with the SDEProblem function. Mathematically its defined like this: take a Brownian motion on \[0,1\]. Stick the path on \[0,1\] at its own tail (continuously) to get a pr…

---

## [SDE driven by a NoiseTransport noise](https://discourse.julialang.org/t/sde-driven-by-a-noisetransport-noise/110422)

<div class="topic-metadata">

**Author:** [@Damiano](https://discourse.julialang.org/u/Damiano)\
**Replies:** 6\
**Last updated:** [March 10, 2024, 2:31pm UTC](https://discourse.julialang.org/t/sde-driven-by-a-noisetransport-noise/110422 "2024-03-10T14:31:05Z")

</div>

Hi everybody, first of all let me say that I still consider myself new to Julia (and even programming in general), so everything I say and write is likely to contain very naive mistakes. Also, if there is anything I sho…

---

## [MethodOfLines & Boundary Conditions](https://discourse.julialang.org/t/methodoflines-boundary-conditions/111393)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 2\
**Last updated:** [March 9, 2024, 3:15pm UTC](https://discourse.julialang.org/t/methodoflines-boundary-conditions/111393 "2024-03-09T15:15:51Z")

</div>

I have a PDE system with: 3 PDEs A number of additional algebraic equations I have boundary and initial value conditions with a number of added algebraic equations to describe the boundary conditions When I try to dis…

---

## [PDESystem & MOL](https://discourse.julialang.org/t/pdesystem-mol/111283)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 2\
**Last updated:** [March 8, 2024, 5:05pm UTC](https://discourse.julialang.org/t/pdesystem-mol/111283 "2024-03-08T17:05:21Z")

</div>

I’m trying to formulate a PDE system for solution via MethodOfLines.jl. In the last step, I need to use the PDESystem constructor. It is not clear to me what the arguments of that function need to be. Here is what I have…

---

## [How to change parmaters for solver in GLMakie?](https://discourse.julialang.org/t/how-to-change-parmaters-for-solver-in-glmakie/111351)

<div class="topic-metadata">

**Author:** [@Luigi\_Marongiu](https://discourse.julialang.org/u/Luigi_Marongiu)\
**Replies:** 1\
**Last updated:** [March 8, 2024, 1:30pm UTC](https://discourse.julialang.org/t/how-to-change-parmaters-for-solver-in-glmakie/111351 "2024-03-08T13:30:16Z")

</div>

Hello, I am trying to make an interactive figure of a SIV system. I have implemented a parameter vector with Parsers so that each parameter is accessed by name. But how can I change such a vector with lift from GLMakie…

---

## [Problem with simulating SBML Model](https://discourse.julialang.org/t/problem-with-simulating-sbml-model/110942)

<div class="topic-metadata">

**Author:** [@max-de-rooij](https://discourse.julialang.org/u/max-de-rooij)\
**Replies:** 4\
**Last updated:** [March 7, 2024, 12:10pm UTC](https://discourse.julialang.org/t/problem-with-simulating-sbml-model/110942 "2024-03-07T12:10:38Z")

</div>

I am trying to solve an ODE problem from a downloaded SBML file, but I seem to get an error. I used to be able to run this file (although I do not remember the specific versions of each package I used before). My code i…

---

## [MethodOfLines & functions in BCs](https://discourse.julialang.org/t/methodoflines-functions-in-bcs/111260)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 1\
**Last updated:** [March 7, 2024, 8:45am UTC](https://discourse.julialang.org/t/methodoflines-functions-in-bcs/111260 "2024-03-07T08:45:07Z")

</div>

I’m trying to implement a distributed model using MethodOfLines with: 3 PDEs + a number of AEs within the volume a number of Boundary conditions In the boundary conditions, some flows depend on valve signals, e.g., as…

---

## [ModelingToolkit -- news?](https://discourse.julialang.org/t/modelingtoolkit-news/111126)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 3\
**Last updated:** [March 4, 2024, 1:08pm UTC](https://discourse.julialang.org/t/modelingtoolkit-news/111126 "2024-03-04T13:08:17Z")

</div>

There seems to be a few changes to the latest versions of ModelingToolkit: Constructor ODESystem now requires the independent variable as second argument \[e.g., ODESystem(eqs,t) – in the past, the constructor tried to…

---

## [How to link observables with ODE to make interactive plot?](https://discourse.julialang.org/t/how-to-link-observables-with-ode-to-make-interactive-plot/111043)

<div class="topic-metadata">

**Author:** [@Luigi\_Marongiu](https://discourse.julialang.org/u/Luigi_Marongiu)\
**Replies:** 1\
**Last updated:** [March 2, 2024, 8:01am UTC](https://discourse.julialang.org/t/how-to-link-observables-with-ode-to-make-interactive-plot/111043 "2024-03-02T08:01:57Z")

</div>

I would like to make an interactive plot of a SIV model using GLMakie. But how can I link GLMakie with DifferentialEquations? The latter requires parameters that are passed to the solver and these parameters are made of …

---

## [Different time scales in ODE system](https://discourse.julialang.org/t/different-time-scales-in-ode-system/111030)

<div class="topic-metadata">

**Author:** [@Nick1](https://discourse.julialang.org/u/Nick1)\
**Replies:** 1\
**Last updated:** [March 1, 2024, 9:08pm UTC](https://discourse.julialang.org/t/different-time-scales-in-ode-system/111030 "2024-03-01T21:08:57Z")

</div>

Hi everyone, I have an ODE system that involves reactions that happen in different time scales (minutes and seconds). I know I can convert all the ODEs to seconds but I am curious if there is a way to tackle different t…

---

## [How to make a vector of observables in GLMakie](https://discourse.julialang.org/t/how-to-make-a-vector-of-observables-in-glmakie/111012)

<div class="topic-metadata">

**Author:** [@Luigi\_Marongiu](https://discourse.julialang.org/u/Luigi_Marongiu)\
**Replies:** 2\
**Last updated:** [March 1, 2024, 2:22pm UTC](https://discourse.julialang.org/t/how-to-make-a-vector-of-observables-in-glmakie/111012 "2024-03-01T14:22:00Z")

</div>

I am trying to make an interactive plot of a SIV model using GLMakie. I have created the parameters as observable. I now need to make the parameters to pass to the solver. One is u0 that stores the initial values of the …

---

## [PolyesterForwardDiff - backend choice is not available](https://discourse.julialang.org/t/polyesterforwarddiff-backend-choice-is-not-available/110985)

<div class="topic-metadata">

**Author:** [@sob](https://discourse.julialang.org/u/sob)\
**Replies:** 4\
**Last updated:** [March 1, 2024, 1:25am UTC](https://discourse.julialang.org/t/polyesterforwarddiff-backend-choice-is-not-available/110985 "2024-03-01T01:25:57Z")

</div>

Hi everybody, I’m trying to use PolyesterForwardDiff in my code but stumbling upon an error for which the MWE is inspired by the doc: julia\> using Optimization, OptimizationOptimJL, ForwardDiff, PolyesterForwardDiff j…

---

## [Multi-threads error (undefRefError) in simple ABM with Agents.jl](https://discourse.julialang.org/t/multi-threads-error-undefreferror-in-simple-abm-with-agents-jl/110900)

<div class="topic-metadata">

**Author:** [@elisadonati23](https://discourse.julialang.org/u/elisadonati23)\
**Replies:** 21\
**Last updated:** [February 29, 2024, 8:57pm UTC](https://discourse.julialang.org/t/multi-threads-error-undefreferror-in-simple-abm-with-agents-jl/110900 "2024-02-29T20:57:26Z")

</div>

Dear all, I am working on an ABM and now I am trying to improve performance through in-model parallelization using @threads since I have 10^6 agents (I am working with fish populations and simulation is in 0D for now, I …

---

## [List of supported fluids in Clapeyron.jl](https://discourse.julialang.org/t/list-of-supported-fluids-in-clapeyron-jl/110903)

<div class="topic-metadata">

**Author:** [@Sushrut\_Deshpande](https://discourse.julialang.org/u/Sushrut_Deshpande)\
**Replies:** 4\
**Last updated:** [February 29, 2024, 5:04pm UTC](https://discourse.julialang.org/t/list-of-supported-fluids-in-clapeyron-jl/110903 "2024-02-29T17:04:11Z")

</div>

Hello, I am trying to use the Clapeyron.jl package for Thermodynamic properties. My question: is there an available list of the fluids that is supported by default?

---

## [Bifurcation diagram DynamicalSystems.jl](https://discourse.julialang.org/t/bifurcation-diagram-dynamicalsystems-jl/110951)

<div class="topic-metadata">

**Author:** [@Sergey\_Novak](https://discourse.julialang.org/u/Sergey_Novak)\
**Replies:** 0\
**Last updated:** [February 29, 2024, 1:18pm UTC](https://discourse.julialang.org/t/bifurcation-diagram-dynamicalsystems-jl/110951 "2024-02-29T13:18:42Z")

</div>

Hello, I got this error after two hours of calculation ArgumentError: The interval \[a,b\] is not a bracketing interval. You need f(a) and f(b) to have different signs (f(a) \* f(b) \< 0). Consider a different bracket or tr…

---

## [Forward differentiation and differential equations](https://discourse.julialang.org/t/forward-differentiation-and-differential-equations/21002)

<div class="topic-metadata">

**Author:** [@moesphere](https://discourse.julialang.org/u/moesphere)\
**Replies:** 13\
**Last updated:** [November 7, 2023, 9:01am UTC](https://discourse.julialang.org/t/forward-differentiation-and-differential-equations/21002 "2023-11-07T09:01:46Z")

</div>

I am trying to use forward AD in combination with solving an ODE using DifferentialEquations.jl. I want to use an own loss function. However, with the is-in-place version there is a type assertion error. I have come up w…

---

## [Modeling Step function in ODEs](https://discourse.julialang.org/t/modeling-step-function-in-odes/110313)

<div class="topic-metadata">

**Author:** [@Nick1](https://discourse.julialang.org/u/Nick1)\
**Replies:** 4\
**Last updated:** [February 29, 2024, 12:07am UTC](https://discourse.julialang.org/t/modeling-step-function-in-odes/110313 "2024-02-29T00:07:32Z")

</div>

Hi, I am modeling a stimulus that lasts for a certain amount of time. The way I model it is with a set of callback functions, e.g. ton = 0.0; toff = 2.0; stim = 10.0; function condition1(u, t, integrator) t\>=ton &&…

---

## [Is there a way to change a single parameter in am ODEproblem and rerun it?](https://discourse.julialang.org/t/is-there-a-way-to-change-a-single-parameter-in-am-odeproblem-and-rerun-it/86775)

<div class="topic-metadata">

**Author:** [@TS-CUBED](https://discourse.julialang.org/u/TS-CUBED)\
**Replies:** 15\
**Last updated:** [February 28, 2024, 8:30pm UTC](https://discourse.julialang.org/t/is-there-a-way-to-change-a-single-parameter-in-am-odeproblem-and-rerun-it/86775 "2024-02-28T20:30:57Z")

</div>

I do define a model with a set of parameters that comes from the default settings for the components. I then want to change a parameter and rerun the problem. I could of course set up a parameter input map p = \[ p1 =\> …

---

## [DiffEqCallback and quadrature calculation with IntegratingCallback](https://discourse.julialang.org/t/diffeqcallback-and-quadrature-calculation-with-integratingcallback/110836)

<div class="topic-metadata">

**Author:** [@a6a3uh](https://discourse.julialang.org/u/a6a3uh)\
**Replies:** 0\
**Last updated:** [February 27, 2024, 9:36am UTC](https://discourse.julialang.org/t/diffeqcallback-and-quadrature-calculation-with-integratingcallback/110836 "2024-02-27T09:36:58Z")

</div>

Hi! I’m trying to calculate some integral along the IVP for some ODE. In particular I’m calculating a running cost for my control system simulation (or value of some functional). It looks like IntegratingCallback and In…

---

## [How to connect MTK thermal Heatport?](https://discourse.julialang.org/t/how-to-connect-mtk-thermal-heatport/110586)

<div class="topic-metadata">

**Author:** [@Zhijian](https://discourse.julialang.org/u/Zhijian)\
**Replies:** 4\
**Last updated:** [February 23, 2024, 4:35pm UTC](https://discourse.julialang.org/t/how-to-connect-mtk-thermal-heatport/110586 "2024-02-23T16:35:12Z")

</div>

Hi guys, I am new to Julia and am using ModelingToolkit to try to build a simple heat conduction model (3R2C wall model). So it will look like this… I am trying to create a constant ambient temperature then switch t…

---

## [Problems performing 1D-FDTD for dispersive dielectric uisng lorentz model in Julia](https://discourse.julialang.org/t/problems-performing-1d-fdtd-for-dispersive-dielectric-uisng-lorentz-model-in-julia/110617)

<div class="topic-metadata">

**Author:** [@geoselenicmonkey](https://discourse.julialang.org/u/geoselenicmonkey)\
**Replies:** 0\
**Last updated:** [February 23, 2024, 1:34am UTC](https://discourse.julialang.org/t/problems-performing-1d-fdtd-for-dispersive-dielectric-uisng-lorentz-model-in-julia/110617 "2024-02-23T01:34:15Z")

</div>

So I am trying to model a dispersive dielectric using the Lorentz model in Julia, more specifically I am trying to obtain the frequency-dependent reflectivity of the material. I am ultimately trying to replicate the resu…

---

## [Error in dblquad integration with Unitful and MonteCarloMeasurements](https://discourse.julialang.org/t/error-in-dblquad-integration-with-unitful-and-montecarlomeasurements/110420)

<div class="topic-metadata">

**Author:** [@GSavvidis](https://discourse.julialang.org/u/GSavvidis)\
**Replies:** 5\
**Last updated:** [February 22, 2024, 7:00pm UTC](https://discourse.julialang.org/t/error-in-dblquad-integration-with-unitful-and-montecarlomeasurements/110420 "2024-02-22T19:00:05Z")

</div>

Hello everyone, This is my first post so apologies in advance for any mistakes in the question format. I have been trying to calculate an integral of two variables using dblquad. The function to be integrated contains …

---

## [Reduce memory usage for ensemble problems](https://discourse.julialang.org/t/reduce-memory-usage-for-ensemble-problems/90591)

<div class="topic-metadata">

**Author:** [@henry2004y](https://discourse.julialang.org/u/henry2004y)\
**Replies:** 4\
**Last updated:** [February 22, 2024, 4:24am UTC](https://discourse.julialang.org/t/reduce-memory-usage-for-ensemble-problems/90591 "2024-02-22T04:24:32Z")

</div>

Hi, I have a test particle tracer which is built on top of OrdinaryDiffEq.jl. This model can have 3D numerical fields as input parameters and solve ODEs for each set of initial conditions. However, when testing on the …

---

## [Error when using LawsonEuler method on SplitODE](https://discourse.julialang.org/t/error-when-using-lawsoneuler-method-on-splitode/110495)

<div class="topic-metadata">

**Author:** [@ian](https://discourse.julialang.org/u/ian)\
**Replies:** 1\
**Last updated:** [February 21, 2024, 9:52pm UTC](https://discourse.julialang.org/t/error-when-using-lawsoneuler-method-on-splitode/110495 "2024-02-21T21:52:32Z")

</div>

Hi all. I have a Split/Semiinear ODE I want to solve efficiently. The docs suggest the LawsonEuler algorithm. I tried to implement but am running into an error I don’t understand. Here is a MWE using DifferentialEquatio…

---

## [Trouble writing custom rule in Enzyme: \`AssertionError: !(overwritten\[end\])\`](https://discourse.julialang.org/t/trouble-writing-custom-rule-in-enzyme-assertionerror-overwritten-end/108939)

<div class="topic-metadata">

**Author:** [@Gianluca\_Fuwa](https://discourse.julialang.org/u/Gianluca_Fuwa)\
**Replies:** 3\
**Last updated:** [February 20, 2024, 11:25pm UTC](https://discourse.julialang.org/t/trouble-writing-custom-rule-in-enzyme-assertionerror-overwritten-end/108939 "2024-02-20T23:25:57Z")

</div>

Hi, I am currently trying to use Enzyme to get the derivative of a function that takes a multidimensional array of 3x3 matrices and outputs a scalar. The caveat is that these matrices are elements of the Lie-group of sp…

---

## [Matrix for storage sol from DifferentialEquations](https://discourse.julialang.org/t/matrix-for-storage-sol-from-differentialequations/110464)

<div class="topic-metadata">

**Author:** [@Sergey\_Novak](https://discourse.julialang.org/u/Sergey_Novak)\
**Replies:** 2\
**Last updated:** [February 20, 2024, 5:12pm UTC](https://discourse.julialang.org/t/matrix-for-storage-sol-from-differentialequations/110464 "2024-02-20T17:12:07Z")

</div>

Hello, i solve system with different initial condition and i want to save all sol. I’m thinking about creating a matrix or vector and storing solutions there for various initial conditions. How can this be done? Thank yo…

---

## [DifferentialEquations.jl -- change in \`remake\`?](https://discourse.julialang.org/t/differentialequations-jl-change-in-remake/110283)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 8\
**Last updated:** [February 18, 2024, 10:48am UTC](https://discourse.julialang.org/t/differentialequations-jl-change-in-remake/110283 "2024-02-18T10:48:07Z")

</div>

Has there been a change in the remake function recently? The following code worked one month ago: prob\_rm = remake(prob, u0=\[\], p=p\_modify) sol = solve(prob\_rm, QBDF(), reltol=1e-5,tstops=t\_u\_switch) Now, I get an err…

---

## [Shape optimization in FEM](https://discourse.julialang.org/t/shape-optimization-in-fem/107635)

<div class="topic-metadata">

**Author:** [@rguerrab](https://discourse.julialang.org/u/rguerrab)\
**Replies:** 10\
**Last updated:** [February 16, 2024, 10:10pm UTC](https://discourse.julialang.org/t/shape-optimization-in-fem/107635 "2024-02-16T22:10:25Z")

</div>

Hi there, I have a feeling this may have been asked before but I can’t seem to find an answer online. The general question is: how can I compute the gradient of a function where the function depends on the solution of …

---

## [Transient, multifield simulations in Gridap.jl](https://discourse.julialang.org/t/transient-multifield-simulations-in-gridap-jl/110292)

<div class="topic-metadata">

**Author:** [@instant0n](https://discourse.julialang.org/u/instant0n)\
**Replies:** 0\
**Last updated:** [February 16, 2024, 1:21pm UTC](https://discourse.julialang.org/t/transient-multifield-simulations-in-gridap-jl/110292 "2024-02-16T13:21:29Z")

</div>

Hi all- Is it currently possible to solve transient problems for multifield FE spaces using Gridap.jl? I’m currently trying to solve a Boussinesq Navier-Stokes system, and am running into some issues, so I’d like to kno…

[Previous page](https://discourse.julialang.org/c/domain/models/21.md?page=24)

[Next page](https://discourse.julialang.org/c/domain/models/21.md?page=26)
