SciMLBase
April 24, 2026 · View on GitHub
SciMLBase.jl is the core interface definition of the SciML ecosystem. It is a low dependency library made to be depended on by the downstream libraries to supply the common interface and allow for interexchange of mathematical problems.
v3.0 Breaking Changes
RecursiveArrayTools v4: Solution types are now AbstractArrays (#1297)
Most impactful change. AbstractVectorOfArray (and thus ODESolution, DDESolution, RODESolution, DAESolution) now subtypes AbstractArray:
sol[i]returns theith scalar element (column-major), not theith timestep. Usesol.u[i]orsol[:, i]for timesteps.length(sol)returns total elements (prod(size(sol))). Uselength(sol.u)for number of timesteps.iterate(sol)iterates scalar elements. Usesol.ufor timestep iteration.map(f, sol)maps over elements. Usemap(f, sol.u)for timesteps.
Ensemble RNG redesign (#1252)
prob_func(prob, i, repeat)→prob_func(prob, ctx)wherectx::EnsembleContextoutput_func(sol, i)→output_func(sol, ctx)EnsembleContextincludessim_id,repeat,rng,sim_seed,worker_id,master_rng- New
seed/rng/rng_funckwargs onsolve()for deterministic, thread-count-independent ensemble solves
Removed deprecated APIs
u_modified!renamed toderivative_discontinuity!(#1289)- Removed
deprecated.jl: old type aliases (DEAlgorithm,DEProblem,DESolution, etc.), constructors, deprecated accessors (#1291) - Removed backward compat shims in
remake.jland MLStyle extension (#1292) - Removed old iterators:
tuples,intervals,TimeChoiceIterator(#1290) - Removed
Symbol→ReturnCode.Tconversion (Base.convert(::Type{ReturnCode.T}, ::Symbol)andsymbol_to_ReturnCode) — deprecated for years across v1/v2 with a warning printed on every use. Comparingsol.retcode == :Successno longer works; useSciMLBase.successful_retcode(sol), which correctly accepts every success-ishReturnCodevalue (Success,StalledSuccess,ExactSolutionLeft,ExactSolutionRight,FloatingPointLimit, …), not justSuccess.
Simplified getproperty
- Removed redundant
getpropertyoverloads on solution abstract types (#1293) - Removed deprecated
getpropertyaliases (.destats,.x,.lb/.ub,.minimizer,.minimum) (#1294)
Other breaking changes
- Replaced Moshi with plain Julia structs for Clocks — 23% precompilation improvement (#1295)
ODEFunctionusesDEFAULT_SPECIALIZATION(AutoSpecialize) for convenience constructors (#1300)- Propagate
interp/denseto DiffEqArrays from solution callables (#1297) is_discrete_time_domain(nothing)now returnsfalse(#1306)
Migration Guide
| Old (v2) | New (v3) |
|---|---|
sol[i] (timestep) | sol.u[i] or sol[:, i] |
length(sol) (timesteps) | length(sol.u) |
for u in sol | for u in sol.u |
u_modified!(integrator, true) | derivative_discontinuity!(integrator, true) |
prob_func(prob, i, repeat) | prob_func(prob, ctx) — use ctx.sim_id, ctx.repeat |
output_func(sol, i) | output_func(sol, ctx) |
sol.destats | sol.stats |
sol.retcode == :Success | SciMLBase.successful_retcode(sol) |
ODEFunction{true}(f) (FullSpecialize) | Now uses AutoSpecialize by default |
v2.0 Breaking Changes
The breaking changes in v2.0 are:
IntegralProblemhas moved to an interface withIntegralFunctionandBatchedIntegralFunctionwhich requires specifyingprototypes for the values to be modified instead ofnoutandbatch. https://github.com/SciML/SciMLBase.jl/pull/497ODEProblemwas made temporarily into amutable structto allow for EnzymeRules support. Using the mutation throws a warning that this is only experimental and should not be relied on. https://github.com/SciML/SciMLBase.jl/pull/501BVProblemnow has a new interface forTwoPointBVProblemwhich splits the bc terms for the two sides, forcing a true two-point BVProblem to allow for further specializations and to allow for wrapping Fortran solvers in the interface. https://github.com/SciML/SciMLBase.jl/pull/477SDEProblemconstructor was changed to remove an anti-pattern which required passing the diffusion functiongtwice, i.e.SDEProblem(SDEFunction(f,g),g, ...). Now this is simplySDEProblem(SDEFunction(f,g),...). https://github.com/SciML/SciMLBase.jl/pull/489