CyRoot Documentation
CYTHON ROOT FINDING · VERSION 2.0
Where Functions Meet Zero
Start with a Python function. Explore every iteration. Move the numerical hot path into native code when you need it.
A Small Function, A Native Engine
from cyroot import newton
answer = newton(lambda x: x*x - 2., None, 1.5)
assert answer.success
assert abs(answer.root - 2.**.5) < 1e-10
Pass an analytic derivative, or None for a native finite difference. Vector
callbacks may return tuples, lists or NumPy arrays. With native callbacks the
whole numerical loop runs without the GIL; Python callbacks take it for each
call. NumPy and SciPy are required.
Version 2.0 is not backward compatible with 1.x; the migration guides map the old API to the new one. Stopping And Results explains how to tell a residual root from a narrow scalar bracket or a stationary point with a nonzero residual.
Explore The Manual
Getting Started
Scalar Solvers
Vector Solvers
- Vector Newton
- Vrahatis Bisection
- Broyden
- Barnes
- Klement
- Robinson
- Traub–Steffensen
- Wolfe–Bittner
- Vector Chebyshev
- Vector Halley And Super-Halley
- Vector Modified Halley
- Rectangular Chebyshev
- Rectangular Halley
- Rectangular Modified Halley
- Native Least Squares
Matrix-Free And Optimization
- Damped Newton
- Jacobian Products
- Newton–Krylov
- Optimization And Objective Derivatives
- Levenberg–Marquardt
Derivatives
- Numerical Derivatives
- Finite Differences
- Scalar First Derivatives
- Scalar Second Derivatives
- Runtime-Order Scalar Derivatives
- Jacobian Plans
- Vector Hessians
- Rectangular Hessians
- Higher Mixed Partials
Callbacks And Native API
- Native Core And Ownership
- Compile Python Callbacks
- Rectangular Callbacks
- Tensor Callbacks And Contractions
Stopping And Results
Migration From 1.x
The repository README includes the algorithm gallery and project links.