Questions tagged [differentialequations.jl]
103 questions
2
votes
1 answer
Insane amount of space allocated solving system of stochastic differential equations
first time asking a question here.
I previously used a simple MATLAB script to model 90 Hopf oscillators, coupled through a matrix, with randn noise, with a simple Euler step integration. I wanted to upgrade this, so I got into Julia, seems to have…

Ignacio Perez Ipiña
- 21
- 1
2
votes
1 answer
How do I implement the termination of an ODE solution based on an event in Julia? Why am I getting a BoundsError?
I am trying to solve a coupled ODE using the DifferentialEquations package in Julia, and trying to implement a Continuous Callback to check when a certain variable becomes small enough, so I can terminate the integration. The functions xdot, ddot…

hg153
- 87
- 5
2
votes
1 answer
Why does DifferentialEquations in Julia give me a "no matching method" error for this system of ODEs?
I want to solve a system of seven coupled ODEs in Julia.
My code is:
function bsys!(dv,v,k,t)
dp,thp,dr,thr,dx,thx,phi = v
a = exp(t)
rp = r_y(a)
rr = r_r(a)
rx = r_x(a)
ix = T_a(a)/mx
vy = v_a(a)
tci =…

hg153
- 87
- 5
2
votes
1 answer
How to remove oscillations in a solution to Differential Equation having indeterminate form using DifferentialEquations.jl
I am trying to solve differential equations with indeterminate forms and I am playing with Julia and DifferentialEquations.jl package to do so.
I started with a simple differential equation with indeterminate form that I know of (as a test case)…

SupremeBeing
- 21
- 2
2
votes
1 answer
How to use new Initialization Schemes in DifferentialEquations.jl?
I am trying to use the new Initialization Schemes option of DifferentialEquations.jl
https://diffeq.sciml.ai/dev/solvers/dae_solve/#Initialization-Schemes-1
But I do not know how to access the new methods.
using DifferentialEquations
import…
user12158459
2
votes
1 answer
How can I access the trained parameters of a Neural ODE in Julia?
I'm trying to fit one Neural ODE to a time series usind Julia's DiffEqFlux. Here my code:
u0 = Float32[2.;0]
train_size = 15
tspan_train = (0.0f0,0.75f0)
function trueODEfunc(du,u,p,t)
true_A = [-0.1 2.0; -2.0 -0.1]
du .=…

SimonAda
- 167
- 1
- 9
2
votes
1 answer
predicting ODE parameters with DiffEqFlux
I'm trying to build a neural network that will take in the solutions to a system of ODE's and predict the parameters of the system. I'm using Julia and in particular, the DiffEqFlux package. The structure of a network is a few simple Dense layers…

rkurchin
- 21
- 4
2
votes
2 answers
Terminal Velocity using Differential Equation
I am new to Juia lang and trying to solve the following differential equations to find the terminal velocity of a ball using Julia.
F = - m * g - 1/2 rho * v² Cd * A
This is the code that I wrote:
# Termal velocity of a falling ball
using…
user12158459
2
votes
1 answer
Complex PDE (Ginzburg Landau) in Julia with Pseudo-Spectral method
I want to teach myself about solving PDEs with Julia and I am trying to solve the complex Ginzburg Landau equation (CGLE) with a pseudospectral method in Julia now. However, I struggle with it and I am a bit of ideas what to try.
The CGLE reads:…

max xilian
- 463
- 2
- 11
2
votes
1 answer
writing into shared arrays within a distributed for loop in JULIA
I have an ODE that I need to solver over a wide range of parameters.
Previously I have used MATLAB's parfor to divide the parameter ranges between multiple threads. I am new to Julia and need to do the same thing in Julia now. Here is the code that…

Hossein Haghi
- 39
- 3
2
votes
1 answer
How to get Rosenbrock23 to work with ODE in ParameterizedFunctions.jl DSL?
Further to this question, I have the same model implemented in ParameterizedFunctions.jl DSL. The following MWE works:
using DifferentialEquations
using Plots
# Modeling a consecutive / parallel reaction in a CSTR
# A --> 2B --> C, C --> 2B, B -->…

winkmal
- 622
- 1
- 6
- 16
2
votes
1 answer
Julia Plots; How can I increase number of samples/data points?
When solving differential equations and plotting the results, how can I increase the number of data points that are plotted? I have
using DifferentialEquations
using Plots
function lorenz(du,u,p,t)
du[1] = 10.0*(u[2]-u[1])
du[2] =…

Dontdownvote
- 25
- 3
2
votes
1 answer
Parameter estimation of multiple datasets in julia DifferentialEquations
I have been looking and I could not find a direct way of using the DifferentialEquations parameter estimation in julia to fit multiple datasets. So, let's say we have this simple differential equation with two parameters:
f1 = function (du,u,p,t)
…

JIbab
- 23
- 4
2
votes
1 answer
failed to execute first example of Differential Algebraic Equations
I am using JuliaPro v0.6.0.1 and the JunoIDE
I tried to apply the DifferentialEquations.jl. In order to run a first example I added the package DifferentialEquations followed by the using statement. In a next step I copied the first example:
f(t,u)…

user5293815
- 51
- 2
2
votes
2 answers
Simulate a bouncing ball?
Is it possible to create a simple model of a bouncing ball, using Julia's equation solvers?
I started with this:
using ODE
function bb(t, f)
(y, v) = f
dy_dt = v
dv_dt = -9.81
[dy_dt, dv_dt]
end
const y0 = 50.0 #…

daycaster
- 2,655
- 2
- 15
- 18