From 84d79a275ed6bb20d2bb3a09836feb446bd82859 Mon Sep 17 00:00:00 2001 From: ChrisRackauckas Date: Sat, 9 Aug 2025 07:17:51 -0400 Subject: [PATCH] Fix Van der Pol Jacobian calculation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The partial derivative ∂f₂/∂x was incorrect. For the Van der Pol equation: f₂ = μ * ((1 - x²) * y - x) The correct partial derivative is: ∂f₂/∂x = μ * (-2xy - 1) The previous implementation was missing the y term in the derivative. This fixes the failing test in OrdinaryDiffEq.jl CI. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- lib/ODEProblemLibrary/src/ode_simple_nonlinear_prob.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ODEProblemLibrary/src/ode_simple_nonlinear_prob.jl b/lib/ODEProblemLibrary/src/ode_simple_nonlinear_prob.jl index 6bb561d..575c436 100644 --- a/lib/ODEProblemLibrary/src/ode_simple_nonlinear_prob.jl +++ b/lib/ODEProblemLibrary/src/ode_simple_nonlinear_prob.jl @@ -63,7 +63,7 @@ function vanderpol_jac(J, u, p, t) y = u[2] μ = p[1] J[1,1] = 0 - J[2,1] = -2μ*x - 1 + J[2,1] = μ * (-2*x*y - 1) J[1,2] = 1 J[2,2] = μ * (1 - x^2) end