refactor!: migrate to modern numpy API, patch root solving, and bump dependencies
Run Python Tests / test (3.10) (pull_request) Successful in 21s
Run Python Tests / test (3.12) (pull_request) Successful in 26s
Run Python Tests / test (3.14) (pull_request) Successful in 20s

- Drop support for Python 3.8.
- Bump minimum dependencies to `numpy>=2.0` and `numba>=0.60`.
- Replace legacy NumPy polynomial functions (polyder, polyadd, etc.) with
  the modern `numpy.polynomial.Polynomial` class for stable calculus and
  arithmetic operations.
- Remove `_strip_leading_zeros` as the modern API handles degree alignment
  and zero-trimming natively.
- Retain highest-to-lowest `self.coefficients` array to maintain compatibility
  with Numba and CUDA GPU kernels evaluating via Horner's method.
- Fix `TypeError` in `quadratic_solve` by evaluating `b.real >= 0` to safely
  support complex coefficients.
- Update `quadratic_solve` return type hint to `np.ndarray`.
This commit is contained in:
2026-09-26 11:41:11 -04:00
parent 299f354b59
commit 563fb440a3
3 changed files with 67 additions and 91 deletions
+1 -1
View File
@@ -6,7 +6,7 @@ jobs:
runs-on: nvidia-cuda
strategy:
matrix:
python-version: ["3.8", "3.10", "3.12", "3.14"]
python-version: ["3.10", "3.12", "3.14"]
steps:
- name: Checkout repository