From 8d065d5bc350bbb02c68577bdd5441f9bcc8f93d Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Mon, 4 Mar 2024 08:47:06 -0500 Subject: [PATCH 1/7] Version bumps --- docs/Project.toml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/docs/Project.toml b/docs/Project.toml index f065d632d..9aed2e582 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -37,7 +37,7 @@ Symbolics = "0c5d862f-8b57-4792-8d23-62f2024744c7" Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d" [compat] -AlgebraicMultigrid = "0.5, 0.6" +AlgebraicMultigrid = "0.6" BSON = "0.3" BVProblemLibrary = "0.1.2" BenchmarkTools = "1" @@ -49,7 +49,7 @@ DASKR = "2.9.1" DDEProblemLibrary = "0.1" DataFrames = "1.4" DiffEqBase = "6.106" -DiffEqCallbacks = "2.24" +DiffEqCallbacks = "3" DifferentialEquations = "7.6" Distributions = "0.25" Documenter = "1" @@ -57,18 +57,18 @@ FiniteDiff = "2" ForwardDiff = "0.10" IncompleteLU = "0.2" JLD2 = "0.4" -JumpProblemLibrary = "0.1, 1" -ModelingToolkit = "8" +JumpProblemLibrary = "1" +ModelingToolkit = "9" ODEProblemLibrary = "0.1" Optimization = "3" -OptimizationNLopt = "0.1, 0.2" +OptimizationNLopt = "0.2" OrdinaryDiffEq = "6.76" Plots = "1" -RecursiveArrayTools = "2, 3" +RecursiveArrayTools = "3" SDEProblemLibrary = "0.1" SciMLBase = "2" SciMLOperators = "0.3" StaticArrays = "1" Sundials = "4.11.3" -Symbolics = "4, 5, 6" +Symbolics = "6" Unitful = "1" From e89c2583edf5013096a02f34ea0c2d444681a6d9 Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Mon, 4 Mar 2024 18:06:08 -0500 Subject: [PATCH 2/7] remove unused dep --- docs/Project.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/Project.toml b/docs/Project.toml index 9aed2e582..39e980a9e 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -20,7 +20,6 @@ FiniteDiff = "6a86dc24-6348-571c-b903-95158fe2bd41" ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" IncompleteLU = "40713840-3770-5561-ab4c-a76e7d0d7895" JLD2 = "033835bb-8acc-5ee8-8aae-3f567f8a3819" -JumpProblemLibrary = "faf0f6d7-8cee-47cb-b27c-1eb80cef534e" ModelingToolkit = "961ee093-0014-501f-94e3-6117800e7a78" ODEProblemLibrary = "fdc4e326-1af4-4b90-96e7-779fcce2daa5" Optimization = "7f7a1694-90dd-40f0-9382-eb1efda571ba" From a2e039ec57d4848603e9f69ec39d82ee44fd962e Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Wed, 4 Sep 2024 07:51:43 -0400 Subject: [PATCH 3/7] Update docs/Project.toml --- docs/Project.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/Project.toml b/docs/Project.toml index 39e980a9e..85696762f 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -56,7 +56,6 @@ FiniteDiff = "2" ForwardDiff = "0.10" IncompleteLU = "0.2" JLD2 = "0.4" -JumpProblemLibrary = "1" ModelingToolkit = "9" ODEProblemLibrary = "0.1" Optimization = "3" From 7218d5383ff9905fbf1e6491e855dc0b1608130b Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Wed, 4 Sep 2024 08:29:49 -0400 Subject: [PATCH 4/7] add core --- docs/Project.toml | 1 + docs/make.jl | 3 ++- docs/src/extras/timestepping.md | 8 ++++---- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/docs/Project.toml b/docs/Project.toml index 85696762f..02d1adf30 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -25,6 +25,7 @@ ODEProblemLibrary = "fdc4e326-1af4-4b90-96e7-779fcce2daa5" Optimization = "7f7a1694-90dd-40f0-9382-eb1efda571ba" OptimizationNLopt = "4e6fcdb7-1186-4e1f-a706-475e75c168bb" OrdinaryDiffEq = "1dea7af3-3e70-54e6-95c3-0bf5283fa5ed" +OrdinaryDiffEqCore = "bbf590c4-e513-4bbe-9b18-05decba2e5d8" Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80" RecursiveArrayTools = "731186ca-8d62-57ce-b412-fbd966d074cd" SDEProblemLibrary = "c72e72a9-a271-4b2b-8966-303ed956772e" diff --git a/docs/make.jl b/docs/make.jl index d598de8c4..95a199555 100644 --- a/docs/make.jl +++ b/docs/make.jl @@ -1,4 +1,4 @@ -using Documenter, DiffEqBase, SciMLBase, OrdinaryDiffEq +using Documenter, DiffEqBase, SciMLBase, OrdinaryDiffEq, OrdinaryDiffEqCore import ODEProblemLibrary, SDEProblemLibrary, DDEProblemLibrary, DAEProblemLibrary, BVProblemLibrary using Sundials, DASKR @@ -21,6 +21,7 @@ makedocs( DAEProblemLibrary, BVProblemLibrary, OrdinaryDiffEq, + OrdinaryDiffEqCore, Sundials, DASKR ], linkcheck = true, diff --git a/docs/src/extras/timestepping.md b/docs/src/extras/timestepping.md index a7311747a..ab362f859 100644 --- a/docs/src/extras/timestepping.md +++ b/docs/src/extras/timestepping.md @@ -54,7 +54,7 @@ one step to the next, it can effect the stability of explicit methods. Thus, it's only applied by default to low order implicit solvers. ```@docs -IController +OrdinaryDiffEqCore.IController ``` ## Proportional-Integral Controller (PI Controller) @@ -84,13 +84,13 @@ q history portion. `qoldinit` is the initialized value for the gain history. ```@docs -PIController +OrdinaryDiffEqCore.PIController ``` ## Proportional-Integral-Derivative Controller (PID Controller) ```@docs -PIDController +OrdinaryDiffEqCore.PIDController ``` ## Gustafsson Acceleration @@ -148,7 +148,7 @@ end ``` ```@docs -PredictiveController +OrdinaryDiffEqCore.PredictiveController ``` ## Abstract Controller From 3858b9b51e23c1682c4e004da6667112b11d5704 Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Wed, 4 Sep 2024 08:36:44 -0400 Subject: [PATCH 5/7] update MTK calls --- docs/src/features/callback_functions.md | 2 +- docs/src/tutorials/advanced_ode_example.md | 8 ++++---- docs/src/tutorials/faster_ode_example.md | 12 ++++++------ 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/docs/src/features/callback_functions.md b/docs/src/features/callback_functions.md index c764d0cb2..d8c077ee9 100644 --- a/docs/src/features/callback_functions.md +++ b/docs/src/features/callback_functions.md @@ -245,7 +245,7 @@ It's clear from the plot how the controls affected the outcome. ### Example 3: AutoAbstol -MATLAB's Simulink has the option for [an automatic absolute tolerance](https://www.mathworks.com/help/simulink/gui/absolute-tolerance.html). +MATLAB's Simulink has the option for [an automatic absolute tolerance](https://www.mathworks.com/help/simulink/gui/absolutetolerance.html). In this example we will implement a callback which will add this behavior to any JuliaDiffEq solver which implements the `integrator` and callback interface. diff --git a/docs/src/tutorials/advanced_ode_example.md b/docs/src/tutorials/advanced_ode_example.md index 2c5c7dcc2..1b9fc7e50 100644 --- a/docs/src/tutorials/advanced_ode_example.md +++ b/docs/src/tutorials/advanced_ode_example.md @@ -11,7 +11,7 @@ equations (PDEs). For example, we will use the stiff Brusselator partial differential equation (BRUSS). !!! note - + This tutorial is for advanced users to dive into advanced features! DifferentialEquations.jl automates most of this usage, so we recommend users try `solve(prob)` with the automatic algorithm first! @@ -19,7 +19,7 @@ differential equation (BRUSS). ## Definition of the Brusselator Equation !!! note - + Feel free to skip this section: it simply defines the example problem. The Brusselator PDE is defined on a unit square periodic domain as follows: @@ -208,7 +208,7 @@ information on linear solver choices, see the valid [LinearSolve.jl](https://linearsolve.sciml.ai/dev/) solver. !!! note - + Switching to a Krylov linear solver will automatically change the ODE solver into Jacobian-free mode, dramatically reducing the memory required. This can be overridden by adding `concrete_jac=true` to the algorithm. @@ -340,7 +340,7 @@ function. We will use [ModelingToolkit.jl](https://mtk.sciml.ai/dev/)'s ```@example stiff1 using ModelingToolkit prob_ode_brusselator_2d_mtk = ODEProblem( - modelingtoolkitize(prob_ode_brusselator_2d_sparse), + complete(modelingtoolkitize(prob_ode_brusselator_2d_sparse)), [], (0.0, 11.5), jac = true, sparse = true); # @btime solve(prob_ode_brusselator_2d_mtk,CVODE_BDF(linear_solver=:KLU),save_everystep=false); # compiles very slowly nothing # hide diff --git a/docs/src/tutorials/faster_ode_example.md b/docs/src/tutorials/faster_ode_example.md index ab4e2714b..6757b81bd 100644 --- a/docs/src/tutorials/faster_ode_example.md +++ b/docs/src/tutorials/faster_ode_example.md @@ -1,7 +1,7 @@ # [Code Optimization for Differential Equations](@id speed) !!! note - + See [this FAQ](@ref faq_performance) for information on common pitfalls and how to improve performance. @@ -95,7 +95,7 @@ When the in-place form is used, DifferentialEquations.jl takes a different internal route that minimizes the internal allocations as well. !!! note - + Notice that nothing is returned. When in in-place form, the ODE solver ignores the return. Instead, make sure that the original `du` array is mutated instead of constructing a new array @@ -310,7 +310,7 @@ the Julia code for this. ```@example faster_ode2 using ModelingToolkit -de = modelingtoolkitize(prob) +de = complete(modelingtoolkitize(prob)) ``` We can tell it to compute the Jacobian if we want to see the code: @@ -370,7 +370,7 @@ In this tutorial, we will optimize the right-hand side definition of a PDE semi-discretization. !!! note - + We highly recommend looking at the [Solving Large Stiff Equations](@ref stiff) tutorial for details on customizing DifferentialEquations.jl for more efficient large-scale stiff ODE solving. This section will only focus on the @@ -663,7 +663,7 @@ r0[:, :, 1] .= uss .+ 0.1 .* rand.() r0[:, :, 2] .= vss prob = ODEProblem(basic_version!, r0, (0.0, 0.1), p) -de = modelingtoolkitize(prob) +de = complete(modelingtoolkitize(prob)) # Note jac=true,sparse=true makes it automatically build sparse Jacobian code # as well! @@ -690,7 +690,7 @@ algorithms. `CVODE_BDF` allows us to use a sparse Newton-Krylov solver by setting `linear_solver = :GMRES`. !!! note - + The [Solving Large Stiff Equations](@ref stiff) tutorial goes through these details. This is simply to give a taste of how much optimization opportunity is left on the table! From 38aca0369cb5cea803ecfffb27d3f629f9f9a39e Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Wed, 4 Sep 2024 08:51:53 -0400 Subject: [PATCH 6/7] format --- docs/src/basics/solution.md | 5 +++-- docs/src/tutorials/advanced_ode_example.md | 6 +++--- docs/src/tutorials/faster_ode_example.md | 8 ++++---- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/docs/src/basics/solution.md b/docs/src/basics/solution.md index 4a7158734..3229fb50e 100644 --- a/docs/src/basics/solution.md +++ b/docs/src/basics/solution.md @@ -191,9 +191,10 @@ Extra fields for solutions of specific problems are specified in the appropriate problem definition page. ## Solution Function Stripping -By default solution objects store functions, making them difficult to serialize. Using the function + +By default solution objects store functions, making them difficult to serialize. Using the function `strip_solution(sol)`, a copy of the solution that does not contain any functions is created. ```@docs SciMLBase.strip_solution -``` \ No newline at end of file +``` diff --git a/docs/src/tutorials/advanced_ode_example.md b/docs/src/tutorials/advanced_ode_example.md index 1b9fc7e50..e1fec7aa5 100644 --- a/docs/src/tutorials/advanced_ode_example.md +++ b/docs/src/tutorials/advanced_ode_example.md @@ -11,7 +11,7 @@ equations (PDEs). For example, we will use the stiff Brusselator partial differential equation (BRUSS). !!! note - + This tutorial is for advanced users to dive into advanced features! DifferentialEquations.jl automates most of this usage, so we recommend users try `solve(prob)` with the automatic algorithm first! @@ -19,7 +19,7 @@ differential equation (BRUSS). ## Definition of the Brusselator Equation !!! note - + Feel free to skip this section: it simply defines the example problem. The Brusselator PDE is defined on a unit square periodic domain as follows: @@ -208,7 +208,7 @@ information on linear solver choices, see the valid [LinearSolve.jl](https://linearsolve.sciml.ai/dev/) solver. !!! note - + Switching to a Krylov linear solver will automatically change the ODE solver into Jacobian-free mode, dramatically reducing the memory required. This can be overridden by adding `concrete_jac=true` to the algorithm. diff --git a/docs/src/tutorials/faster_ode_example.md b/docs/src/tutorials/faster_ode_example.md index 6757b81bd..448cb6a1f 100644 --- a/docs/src/tutorials/faster_ode_example.md +++ b/docs/src/tutorials/faster_ode_example.md @@ -1,7 +1,7 @@ # [Code Optimization for Differential Equations](@id speed) !!! note - + See [this FAQ](@ref faq_performance) for information on common pitfalls and how to improve performance. @@ -95,7 +95,7 @@ When the in-place form is used, DifferentialEquations.jl takes a different internal route that minimizes the internal allocations as well. !!! note - + Notice that nothing is returned. When in in-place form, the ODE solver ignores the return. Instead, make sure that the original `du` array is mutated instead of constructing a new array @@ -370,7 +370,7 @@ In this tutorial, we will optimize the right-hand side definition of a PDE semi-discretization. !!! note - + We highly recommend looking at the [Solving Large Stiff Equations](@ref stiff) tutorial for details on customizing DifferentialEquations.jl for more efficient large-scale stiff ODE solving. This section will only focus on the @@ -690,7 +690,7 @@ algorithms. `CVODE_BDF` allows us to use a sparse Newton-Krylov solver by setting `linear_solver = :GMRES`. !!! note - + The [Solving Large Stiff Equations](@ref stiff) tutorial goes through these details. This is simply to give a taste of how much optimization opportunity is left on the table! From bdaceb20340ca9a46e68ad9ac86715f4564772ac Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Wed, 4 Sep 2024 09:22:16 -0400 Subject: [PATCH 7/7] set core --- docs/src/extras/timestepping.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/src/extras/timestepping.md b/docs/src/extras/timestepping.md index ab362f859..ac85bc36d 100644 --- a/docs/src/extras/timestepping.md +++ b/docs/src/extras/timestepping.md @@ -1,7 +1,7 @@ # [Timestepping Method Descriptions](@id timestepping) ```@meta -CurrentModule = OrdinaryDiffEq +CurrentModule = OrdinaryDiffEqCore ``` ## Common Setup