SciML / NonlinearSolve.jl

High-performance and differentiation-enabled nonlinear solvers (Newton methods), bracketed rootfinding (bisection, Falsi), with sparsity and Newton-Krylov support.
https://docs.sciml.ai/NonlinearSolve/stable/
MIT License
226 stars 40 forks source link

Use a proper polyalgorithm algorithm type #278

Closed avik-pal closed 10 months ago

avik-pal commented 10 months ago

Adding this since it makes it easy to write type-stable polyalgorithms. Once this is in we can simply define a custom polyalgorithm algorithm for https://github.com/SciML/NonlinearSolve.jl/pull/277 as well.

avik-pal commented 10 months ago

I thing that might break is if someone was writing ::RobustMultiNewton. Do we guarantee that the algorithms are types that can be dispatched on?

codecov[bot] commented 10 months ago

Codecov Report

Merging #278 (c5c0176) into master (adc3b31) will decrease coverage by 44.89%. The diff coverage is 55.55%.

@@             Coverage Diff             @@
##           master     #278       +/-   ##
===========================================
- Coverage   93.58%   48.69%   -44.89%     
===========================================
  Files          19       19               
  Lines        1807     1805        -2     
===========================================
- Hits         1691      879      -812     
- Misses        116      926      +810     
Files Coverage Δ
src/NonlinearSolve.jl 97.10% <ø> (-1.45%) :arrow_down:
src/default.jl 33.75% <55.55%> (-49.80%) :arrow_down:

... and 16 files with indirect coverage changes

:mega: Codecov offers a browser extension for seamless coverage viewing on GitHub. Try it in Chrome or Firefox today!

ChrisRackauckas commented 10 months ago

no

avik-pal commented 10 months ago

@ChrisRackauckas is the forwarddiff linear solve failure from nonlinear solve or something changed in linear solve?

ChrisRackauckas commented 10 months ago

That's a LinearSolve thing, don't worry about it.

ChrisRackauckas commented 10 months ago

Can you make the 23 tests more robust?

avik-pal commented 10 months ago

Probably disable the GeneralBroyden? It fails only sometimes on CI and locally always passes. I can't even reproduce the failure reliably

ChrisRackauckas commented 10 months ago

Or make it simpler, like number of successes > 5