Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possible improvements to stiffness detection: #2574

Open
oscardssmith opened this issue Jan 13, 2025 · 0 comments
Open

Possible improvements to stiffness detection: #2574

oscardssmith opened this issue Jan 13, 2025 · 0 comments

Comments

@oscardssmith
Copy link
Contributor

  1. Cost of implicit solver goes up with length(u)^3 (or ~length(u)^2 with sparsity), while cost of explicit solvers are O(n). This should be factored into the analysis of which solver will be better.
  2. Take into account order difference between nonstiff and stiff solver.
    If nonstiff solver is higher order (which is common), the nonstiff solver can be stability constrained,
    but switching to a stiff solver won't help since it will be order constrained to a smaller timestep.
  3. Track how close dt is to dtmin to avoid aborting even if stiffness not found This will allow using the nonstiff algorithm more often as long as it isn't at risk of segfaulting.
  4. Track dt for stiff and explicit alg separately and only use the implicit alg if it is maintaining enough higher dt. Similarly, when we switch from the explicit to implicit solver, it's probably better to use the implicit solver's last dt rather than a multiple of the explicit solvers dt since the whole point of having both is that they will want to timestep at different rates.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant