This repository was archived by the owner on Mar 18, 2026. It is now read-only.
Phase 15: Move initdt to ODE, delete dead code, unify resize#697
Merged
ChrisRackauckas merged 6 commits intoSciML:masterfrom Mar 17, 2026
Merged
Conversation
- Delete src/initdt.jl (98 lines): sde_determine_initdt moved to OrdinaryDiffEqCore. Keep thin _determine_initdt override that calls OrdinaryDiffEqCore.sde_determine_initdt. - Delete iip_generate_W/oop_generate_W (64 lines): dead code, never called anywhere in the codebase. - Unify resize!/deleteat!/addat!: merge ratenoise_cache iteration into *_non_user_cache! methods, delete top-level resize!/deleteat!/addat! overrides (ODE's versions now handle full_cache iteration). - Clean stepsize_controllers.jl: remove comment clutter. - Bump OrdinaryDiffEqCore compat to 3.22. Net: -198 lines removed. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
TauLeaping uses DiscreteProblem (not AbstractRODEProblem), so the _determine_initdt override must check the problem type and fall through to ode_determine_initdt for non-RODE problems. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
TauLeaping uses DiscreteProblem which has no f.g or f.mass_matrix, so neither sde_ nor ode_determine_initdt applies. Return a small dt fraction (same as the original SDE code's jump shortcut). Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Replace OrdinaryDiffEqCore.sde_determine_initdt with OrdinaryDiffEqCore.ode_determine_initdt, which now handles both ODE and RODE/SDE problems via conditional noise terms. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
5 tasks
Matches registered v3.23.0 which contains the unified ode_determine_initdt with AbstractRODEProblem dispatch. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Net: -219 lines removed from StochasticDiffEq
Details
initdt
SDE _determine_initdt now calls OrdinaryDiffEqCore.ode_determine_initdt with AbstractRODEProblem dispatch. Noise terms are conditionally folded into the d1/d2 estimates when prob.f.g is not nothing. Requires OrdinaryDiffEqCore >= 3.22.
Dead code removal
iip_generate_W and oop_generate_W were never called anywhere. Deleted.
resize!/deleteat!/addat! unification
Moved ratenoise_cache iteration into *_non_user_cache! methods. Top-level overrides deleted (ODE handles full_cache iteration).
Companion PR: SciML/OrdinaryDiffEq.jl#3137
Test plan