From a87a75b8a663701837d79c9e5705306a1a589520 Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Fri, 19 Jul 2024 19:56:26 -0400 Subject: [PATCH 1/3] Bump ModelingToolkit v9 Catalyst v14 --- lib/JumpProblemLibrary/Project.toml | 2 +- lib/NonlinearProblemLibrary/Project.toml | 2 +- lib/ODEProblemLibrary/Project.toml | 2 +- lib/SDEProblemLibrary/Project.toml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/JumpProblemLibrary/Project.toml b/lib/JumpProblemLibrary/Project.toml index 1da0ef7..beb0caf 100644 --- a/lib/JumpProblemLibrary/Project.toml +++ b/lib/JumpProblemLibrary/Project.toml @@ -9,7 +9,7 @@ RuntimeGeneratedFunctions = "7e49a35a-f44a-4d26-94aa-eba1b4ca6b47" [compat] Aqua = "0.5" -Catalyst = "13" +Catalyst = "14" DiffEqBase = "6" RuntimeGeneratedFunctions = "0.5" julia = "1.10" diff --git a/lib/NonlinearProblemLibrary/Project.toml b/lib/NonlinearProblemLibrary/Project.toml index 66d5f78..1507cca 100644 --- a/lib/NonlinearProblemLibrary/Project.toml +++ b/lib/NonlinearProblemLibrary/Project.toml @@ -9,7 +9,7 @@ SciMLBase = "0bca4576-84f4-4d90-8ffe-ffa030f20462" [compat] Aqua = "0.8" LinearAlgebra = "1.6" -SciMLBase = "1, 2" +SciMLBase = "2" julia = "1.10" [extras] diff --git a/lib/ODEProblemLibrary/Project.toml b/lib/ODEProblemLibrary/Project.toml index fe2d318..c341ff7 100644 --- a/lib/ODEProblemLibrary/Project.toml +++ b/lib/ODEProblemLibrary/Project.toml @@ -14,7 +14,7 @@ RuntimeGeneratedFunctions = "7e49a35a-f44a-4d26-94aa-eba1b4ca6b47" [compat] Aqua = "0.5" DiffEqBase = "6" -Latexify = "0.15, 0.16" +Latexify = "0.16" ModelingToolkit = "9" RuntimeGeneratedFunctions = "0.5" julia = "1.10" diff --git a/lib/SDEProblemLibrary/Project.toml b/lib/SDEProblemLibrary/Project.toml index 0cbf41c..fa65e32 100644 --- a/lib/SDEProblemLibrary/Project.toml +++ b/lib/SDEProblemLibrary/Project.toml @@ -11,7 +11,7 @@ SciMLBase = "0bca4576-84f4-4d90-8ffe-ffa030f20462" [compat] Aqua = "0.5" -Catalyst = "13" +Catalyst = "14" DiffEqBase = "6" RuntimeGeneratedFunctions = "0.5" SciMLBase = "2.0.1" From e1675029a2b8dea422d437b441d8c5106e15d0bd Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Fri, 19 Jul 2024 20:04:14 -0400 Subject: [PATCH 2/3] update to v9 language --- lib/JumpProblemLibrary/src/JumpProblemLibrary.jl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/JumpProblemLibrary/src/JumpProblemLibrary.jl b/lib/JumpProblemLibrary/src/JumpProblemLibrary.jl index 6b4988b..ef0ab02 100644 --- a/lib/JumpProblemLibrary/src/JumpProblemLibrary.jl +++ b/lib/JumpProblemLibrary/src/JumpProblemLibrary.jl @@ -141,7 +141,7 @@ end rsi = rates_sym_to_idx rates = params[[rsi[:kon], rsi[:kAon], rsi[:koff], rsi[:kAoff], rsi[:kAp], rsi[:kAdp]]] u0 = zeros(Int, 9) -statesyms = ModelingToolkit.tosymbol.(ModelingToolkit.operation.(states(rs))) +statesyms = ModelingToolkit.tosymbol.(ModelingToolkit.operation.(unknowns(rs))) u0[findfirst(isequal(:S1), statesyms)] = params[1] u0[findfirst(isequal(:S2), statesyms)] = params[2] u0[findfirst(isequal(:S3), statesyms)] = params[3] @@ -202,10 +202,10 @@ function construct_genenetwork(N) genenetwork end rs = construct_genenetwork(N) -u0 = zeros(Int, length(states(rs))) -statesyms = ModelingToolkit.tosymbol.(ModelingToolkit.operation.(states(rs))) +u0 = zeros(Int, length(unknowns(rs))) +statesyms = ModelingToolkit.tosymbol.(ModelingToolkit.operation.(unknowns(rs))) for i in 1:(2 * N) - u0[findfirst(isequal(G[i]), states(rs))] = 1 + u0[findfirst(isequal(G[i]), unknowns(rs))] = 1 end tf = 2000.0 prob = DiscreteProblem(rs, u0, (0.0, tf), eval_module = @__MODULE__) From 736af11f5c02fbe0986397b8c74dc066696d3808 Mon Sep 17 00:00:00 2001 From: Christopher Rackauckas Date: Sat, 20 Jul 2024 06:35:05 -0400 Subject: [PATCH 3/3] Update lib/JumpProblemLibrary/Project.toml --- lib/JumpProblemLibrary/Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/JumpProblemLibrary/Project.toml b/lib/JumpProblemLibrary/Project.toml index beb0caf..1da0ef7 100644 --- a/lib/JumpProblemLibrary/Project.toml +++ b/lib/JumpProblemLibrary/Project.toml @@ -9,7 +9,7 @@ RuntimeGeneratedFunctions = "7e49a35a-f44a-4d26-94aa-eba1b4ca6b47" [compat] Aqua = "0.5" -Catalyst = "14" +Catalyst = "13" DiffEqBase = "6" RuntimeGeneratedFunctions = "0.5" julia = "1.10"