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
238 stars 42 forks source link

Better Defaults: Auto AD Selection for Newton Methods #244

Closed avik-pal closed 1 year ago

avik-pal commented 1 year ago
ChrisRackauckas commented 1 year ago

did you time it at all? It's completely dynamically dispatching and not type stable.

avik-pal commented 1 year ago

Yes not ready yet :sweat:

avik-pal commented 1 year ago

I will loop unroll that version to avoid adding sols for if we add anything to the cache later

codecov[bot] commented 1 year ago

Codecov Report

Merging #244 (91c0ca0) into master (7a5e231) will increase coverage by 7.31%. The diff coverage is 88.63%.

@@            Coverage Diff             @@
##           master     #244      +/-   ##
==========================================
+ Coverage   86.05%   93.37%   +7.31%     
==========================================
  Files          14       14              
  Lines        1205     1147      -58     
==========================================
+ Hits         1037     1071      +34     
+ Misses        168       76      -92     
Files Coverage Δ
src/dfsane.jl 100.00% <100.00%> (+0.67%) :arrow_up:
src/gaussnewton.jl 76.19% <100.00%> (+1.19%) :arrow_up:
src/levenberg.jl 98.46% <100.00%> (+0.03%) :arrow_up:
src/raphson.jl 100.00% <100.00%> (ø)
src/trustRegion.jl 99.36% <100.00%> (+<0.01%) :arrow_up:
src/utils.jl 82.85% <95.83%> (+5.07%) :arrow_up:
src/default.jl 78.48% <79.41%> (+46.20%) :arrow_up:

... and 1 file with indirect coverage changes

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

avik-pal commented 1 year ago

Everything is type-stable to the extent that the output alg is a union type.

avik-pal commented 1 year ago

@ChrisRackauckas this is ready to go in