diff --git a/docs/src/release_notes.md b/docs/src/release_notes.md index 0208b1e66..3aa147e27 100644 --- a/docs/src/release_notes.md +++ b/docs/src/release_notes.md @@ -4,13 +4,16 @@ ### Breaking Changes in `NonlinearSolve.jl` v4 + - See [common breaking changes](@ref common-breaking-changes-v4v2) below. + ### Breaking Changes in `SimpleNonlinearSolve.jl` v2 - - `Auto*` structs are no longer exported. Load `ADTypes` to access them. + - See [common breaking changes](@ref common-breaking-changes-v4v2) below. + +### [Common Breaking Changes](@id common-breaking-changes-v4v2) + - Use of termination conditions from `DiffEqBase` has been removed. Use the termination conditions from `NonlinearSolveBase` instead. - - We no longer export the entire `SciMLBase`. Instead selected functionality relevant to - `SimpleNonlinearSolve` has been exported. - If no autodiff is provided, we now choose from a list of autodiffs based on the packages loaded. For example, if `Enzyme` is loaded, we will default to that. In general, we don't guarantee the exact autodiff selected if `autodiff` is not provided (i.e. diff --git a/lib/SimpleNonlinearSolve/Project.toml b/lib/SimpleNonlinearSolve/Project.toml index 82f69c6ad..586341f67 100644 --- a/lib/SimpleNonlinearSolve/Project.toml +++ b/lib/SimpleNonlinearSolve/Project.toml @@ -19,6 +19,7 @@ LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" MaybeInplace = "bb5d69b7-63fc-4a16-80bd-7e42200c7bdb" NonlinearSolveBase = "be0214bd-f91f-a760-ac4e-3421ce2b2da0" PrecompileTools = "aea7be01-6a6a-4083-8856-8a6e6704d82a" +Reexport = "189a3867-3050-52da-a836-e630ba90ab69" SciMLBase = "0bca4576-84f4-4d90-8ffe-ffa030f20462" StaticArraysCore = "1e83bf80-4336-4d27-bf5d-d5a4f845583c" @@ -60,6 +61,7 @@ Pkg = "1.10" PolyesterForwardDiff = "0.1" PrecompileTools = "1.2" Random = "1.10" +Reexport = "1.2" ReverseDiff = "1.15" SciMLBase = "2.50" StaticArrays = "1.9" diff --git a/lib/SimpleNonlinearSolve/src/SimpleNonlinearSolve.jl b/lib/SimpleNonlinearSolve/src/SimpleNonlinearSolve.jl index 6d1187668..f15630e24 100644 --- a/lib/SimpleNonlinearSolve/src/SimpleNonlinearSolve.jl +++ b/lib/SimpleNonlinearSolve/src/SimpleNonlinearSolve.jl @@ -8,6 +8,7 @@ using LineSearch: LiFukushimaLineSearch using LinearAlgebra: LinearAlgebra, dot using MaybeInplace: @bb, setindex_trait, CannotSetindex, CanSetindex using PrecompileTools: @compile_workload, @setup_workload +using Reexport: @reexport using SciMLBase: SciMLBase, AbstractNonlinearAlgorithm, NonlinearFunction, NonlinearProblem, NonlinearLeastSquaresProblem, IntervalNonlinearProblem, ReturnCode, remake using StaticArraysCore: StaticArray, SArray, SVector, MArray @@ -18,7 +19,6 @@ using DifferentiationInterface: DifferentiationInterface using FiniteDiff: FiniteDiff using ForwardDiff: ForwardDiff -using BracketingNonlinearSolve: Alefeld, Bisection, Brent, Falsi, ITP, Ridder using NonlinearSolveBase: NonlinearSolveBase, ImmutableNonlinearProblem, L2_NORM, nonlinearsolve_forwarddiff_solve, nonlinearsolve_dual_solution @@ -138,11 +138,8 @@ function solve_adjoint_internal end end end -export IntervalNonlinearProblem - -export Alefeld, Bisection, Brent, Falsi, ITP, Ridder - -export NonlinearFunction, NonlinearProblem, NonlinearLeastSquaresProblem +# Rexexports +@reexport using ADTypes, SciMLBase, BracketingNonlinearSolve, NonlinearSolveBase export SimpleBroyden, SimpleKlement, SimpleLimitedMemoryBroyden export SimpleDFSane diff --git a/src/NonlinearSolve.jl b/src/NonlinearSolve.jl index 625477a88..e6ca6cb00 100644 --- a/src/NonlinearSolve.jl +++ b/src/NonlinearSolve.jl @@ -48,8 +48,6 @@ using SparseArrays: AbstractSparseMatrix, SparseMatrixCSC using SparseMatrixColorings: ConstantColoringAlgorithm, GreedyColoringAlgorithm, LargestFirst -@reexport using SciMLBase, SimpleNonlinearSolve, NonlinearSolveBase - const DI = DifferentiationInterface const True = Val(true) @@ -157,6 +155,9 @@ include("default.jl") end end +# Rexexports +@reexport using SciMLBase, SimpleNonlinearSolve, NonlinearSolveBase + # Core Algorithms export NewtonRaphson, PseudoTransient, Klement, Broyden, LimitedMemoryBroyden, DFSane export GaussNewton, LevenbergMarquardt, TrustRegion