Skip to content

No jacobian prototype for sparse jacobian SDEProblems? #3527

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
TorkelE opened this issue Apr 2, 2025 · 0 comments · Fixed by #3535
Closed

No jacobian prototype for sparse jacobian SDEProblems? #3527

TorkelE opened this issue Apr 2, 2025 · 0 comments · Fixed by #3535
Assignees
Labels
bug Something isn't working

Comments

@TorkelE
Copy link
Member

TorkelE commented Apr 2, 2025

Not that familiar with SDE solving, but it seems odd that there this field is empty when a sparse jacobian is built for SDEs? They are there for e.g. ODEs and Nonlinear problems. And if one shouldn't do sparse Jacobians here, shouldn't;t there at least be an error/warning?

using ModelingToolkit, StochasticDiffEq
using ModelingToolkit: t_nounits as t, D_nounits as D
using Plots

@parameters σ=10.0 ρ=2.33 β=26.0
@variables x(t)=5.0 y(t)=5.0 z(t)=1.0
@brownian B
eqs = [D(x) ~ σ * (y - x) + 0.3x * B,
    D(y) ~ x *- z) - y + 0.3y * B,
    D(z) ~ x * y - β * z + 0.3z * B]

@mtkbuild de = System(eqs, t)
sprob = SDEProblem(de, [], 0.0, [], jac = true, sparse = true)
sprob.f.jac_prototype == nothing # true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants