Skip to main content

Module nonlinear_systems

Module nonlinear_systems 

Source
Expand description

Roots of nonlinear systems F(x) = 0, F: ℝⁿ → ℝⁿ.

Both solvers are globalised by a backtracking line search on ½‖F‖² (Numerical Recipes’ newt and broydn), so they converge from much farther away than plain iteration:

  • newton_system: Newton’s method with an analytic or finite-difference Jacobian; quadratic convergence, one Jacobian per iteration.
  • broyden_system: Broyden’s “good” rank-one update of the Jacobian; superlinear convergence with a single function evaluation per iteration, re-forming the Jacobian by finite differences only when the update stops producing descent.

See the book entry Nonlinear systems.

Structs§

SystemOptions
Settings for the system solvers.
SystemRootResult
The outcome of a system solve.

Functions§

broyden_system
Broyden’s method for F(x) = 0 from x0: the Jacobian estimate B (initially by finite differences) is corrected after each step by B ← B + ((Δf − B s) sᵀ) / (sᵀ s).
newton_system
Globally convergent Newton’s method for F(x) = 0 from x0. jacobian(x) returns the rows ∂Fᵢ/∂xⱼ; with jacobian = None the Jacobian is formed by forward differences. Errors for an empty x0 or mismatched dimensions; a singular Jacobian ends the iteration unconverged.