fullseye

cplx_newton_basins — MATH complex op

使い方

Which root of a polynomial does Newton’s method fall into, from each point?

Labels the window 1..len(roots) by the root reached, and 0 where the iteration has not converged within max_iter (the Julia set and its neighbourhood). Roots come from numpy.roots — the same routine behind this family’s poly_roots — and are sorted by (Re, Im) so the label of a given root does not change between runs.

★Degree 2 has a closed-form answer, so the operator can be checked exactly rather than plausibly. Cayley (1879): for z**2 - 1 the basins are the two open half-planes Re z > 0 and Re z < 0, and the boundary is the imaginary axis — no fractal. The famous fractal boundary appears at degree 3, which Cayley could not settle; there the honest checks are structural (every root’s basin is non-empty; z**3 - 1 is invariant under rotation by 2*pi/3, and so is its labelling, up to the cyclic relabelling of the roots).

coeffs is highest-degree-first, as numpy.roots and poly_roots take it.

Raises ValueError: text, non-finite or all-zero coefficients; a non-zero constant (no roots); max_iter < 1; tol <= 0; degenerate window. Points where the derivative vanishes are left unconverged (label 0) rather than divided by — a critical point is genuinely undecided.

HALCON: no operator.

ファミリ共通の入力契約(fail-closed)

mathops の全 op は入力を検証してから計算する(黙って通さない):

詳しい使い方ガイド

参考(サンプルデータ・文献)

実行できる例(この op を実際に呼ぶ検証済みサンプル)

型が繋がる次の op(labels2d を入力に取れる)

—

同カテゴリ(complex)

cplx_contour_circle · cplx_poly_eval · cplx_contour_integral · cplx_winding_number · cplx_cauchy_value · cplx_argument_principle · cplx_laurent_coeffs · cplx_joukowski


Provenance: mathops.py — MATH operator registry. この per-op ノートは tools/opdocs.py md が自動生成(手編集しない)。

© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.