diff --git a/Project.toml b/Project.toml index 78b8bca..5371ac7 100644 --- a/Project.toml +++ b/Project.toml @@ -13,6 +13,7 @@ PDMats = "90014a1f-27ba-587c-ab20-58faa44d9150" PrecompileTools = "aea7be01-6a6a-4083-8856-8a6e6704d82a" RecursiveArrayTools = "731186ca-8d62-57ce-b412-fbd966d074cd" SciMLBase = "0bca4576-84f4-4d90-8ffe-ffa030f20462" +SymbolicIndexingInterface = "2efcf032-c050-4f8e-a9bb-153293bab1f5" UnPack = "3a884ed6-31ef-47d7-9d2a-63182c4928ed" [compat] @@ -25,5 +26,6 @@ PDMats = "0.11" PrecompileTools = "1" RecursiveArrayTools = "2.34, 4" SciMLBase = "2, 3" +SymbolicIndexingInterface = "0.3" UnPack = "1" julia = "1.8" diff --git a/docs/Project.toml b/docs/Project.toml index 89b8b05..22f82f6 100644 --- a/docs/Project.toml +++ b/docs/Project.toml @@ -16,7 +16,7 @@ Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" [compat] ChainRulesCore = "1" DataFrames = "1" -DiffEqBase = "6" +DiffEqBase = "6.145, 7" DifferenceEquations = "1.1" Distributions = "0.25" Documenter = "1" diff --git a/src/DifferenceEquations.jl b/src/DifferenceEquations.jl index 77b22ea..a67fb34 100644 --- a/src/DifferenceEquations.jl +++ b/src/DifferenceEquations.jl @@ -11,6 +11,7 @@ using LinearAlgebra: LinearAlgebra, Cholesky, Diagonal, NoPivot, Symmetric, chol using PDMats: PDMats, PDMat using SciMLBase: SciMLBase, @add_kwonly, NullParameters, promote_tspan, AbstractRODESolution, ODEFunction, remake, ConstantInterpolation, build_solution +using SymbolicIndexingInterface: SymbolCache using UnPack: UnPack, @unpack include("utilities.jl") diff --git a/src/problems/state_space_problems.jl b/src/problems/state_space_problems.jl index c683008..351d7d3 100644 --- a/src/problems/state_space_problems.jl +++ b/src/problems/state_space_problems.jl @@ -57,7 +57,7 @@ struct LinearStateSpaceProblem{ syms = nothing, f = ODEFunction{false}( (u, p, t) -> error("not implemented"); - syms = syms + sys = syms === nothing ? nothing : SymbolCache(collect(syms)) ), kwargs... ) where {iip} @@ -131,7 +131,7 @@ struct QuadraticStateSpaceProblem{ syms = nothing, f = ODEFunction{false}( (u, p, t) -> error("not implemented"); - syms = syms + sys = syms === nothing ? nothing : SymbolCache(collect(syms)) ), kwargs... ) where {iip}