From 34743d257deeafb5bd2998fa5d72e4f2d80d2fdf Mon Sep 17 00:00:00 2001 From: Oscar Smith Date: Thu, 15 Aug 2024 09:57:25 -0400 Subject: [PATCH] fix DDE/SDE --- lib/OrdinaryDiffEqDifferentiation/src/linsolve_utils.jl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/OrdinaryDiffEqDifferentiation/src/linsolve_utils.jl b/lib/OrdinaryDiffEqDifferentiation/src/linsolve_utils.jl index 2783468376..d18f570ca0 100644 --- a/lib/OrdinaryDiffEqDifferentiation/src/linsolve_utils.jl +++ b/lib/OrdinaryDiffEqDifferentiation/src/linsolve_utils.jl @@ -10,10 +10,11 @@ function dolinsolve(integrator, linsolve; A = nothing, linu = nothing, b = nothi _alg = unwrap_alg(integrator, true) if !isnothing(A) - (;du, u, p, t) = integrator if isnothing(integrator) reinit!(linsolve; A) else + (;u, p, t) = integrator + du = hasproperty(integrator) ? integrator.du : nothing p = (du, u, p, t) reinit!(linsolve; A, p) end