From 748964c8718eb13a5ee0eab08dafd2e9fe0badf4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20M=C3=BCller?= Date: Sat, 25 May 2024 02:37:34 +0200 Subject: [PATCH] Fixed broken polynomial degree in bisection algorithm --- UPolynomialRoots.pas | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UPolynomialRoots.pas b/UPolynomialRoots.pas index a4b029a..b2636f8 100644 --- a/UPolynomialRoots.pas +++ b/UPolynomialRoots.pas @@ -112,11 +112,11 @@ begin Result := TIsolatingIntervals.Create; stack := TWorkStack.Create; - n := item.P.Degree; item.C := 0; item.K := 0; item.P := APolynomial.ScaleVariable(ABound); stack.Push(item); + n := item.P.Degree; while stack.Count > 0 do begin