a planar quadratic clipping method for computing a root of a polynomial in an interval

10
SMI 2014 A planar quadratic clipping method for computing a root of a polynomial in an interval Xiao-Diao Chen a,b,n , Weiyin Ma b a Hangzhou Dianzi University, Hangzhou 310037, PR China b Department of MBE, City University of Hong Kong, Hong Kong, PR China article info Article history: Received 7 July 2014 Received in revised form 20 August 2014 Accepted 16 September 2014 Available online 2 October 2014 Keywords: Optimal approximation order Root nding Quadratic clipping Convergence rate abstract This paper presents a new quadratic clipping method for computing a root of a polynomial f(t) of degree n within an interval. Different from the traditional one in R 1 space, it derives three quadratic curves in R 2 space for approximating ðt; f ðtÞÞ instead, which leads to a higher approximation order. Two bounding polynomials are then computed in Oðn 2 Þ for bounding the roots of f(t) within the interval. The new clipping method achieves a convergence rate of 4 for a single root, compared with that of 3 from traditional method using quadratic polynomial approximation in R 1 space. When f(t) is convex within the interval, the two bounding polynomials are able to be directly constructed without error estimation, which leads to computational complexity O(n). Numerical examples show the approximation effect and efciency of the new method. The method is particularly useful for the y computation in many geometry processing and graphics rendering applications. & 2014 Elsevier Ltd. All rights reserved. 1. Introduction Computing the solutions of (systems of) non-linear equations is frequently needed for solving various geometric and graphics pro- blems [1,2,8,9,12,13,15,20,22],. Typical examples include curve/sur- face intersection and surface rendering by ray-tracing [7,15,18,19], point projection, which is to compute the closest point on a curve or surface to a given point [3], collision detection [4,14], and bisectors/ medial axes computation [8]. The method is particularly useful for the y computation in connection with the above applications in both geometry processing and graphics rendering. For solving a polynomial equation, the Descartes rule [5,21] and the Sturm theorem [10,11] are two well-known techniques for isolating real roots. A collection of related references can be found in [16]. A Bézier curve is bounded by the convex hull of its control polygon, the corresponding roots are then bounded by the roots of the convex hull. Note that the number of the zeros of a Bézier function is less or equal to that of its control polygon, the zeros of its control polygon can be used for isolating the zeros of a Bézier function [17]. There are also several clipping algorithms developed for nding the roots of polynomials [1,15,17,23]. In 1990, Sederberg and Nishita proposed a Bézier clipping technique, which is to identify regions of the polynomial which do not include the part of the roots by using the convex hull property of Bézier curves [23]. The Bézier clipping method was proved to be quadratically convergent in [24]. Mørken and Reimers presented a linear approximation method [17], in which the given B-Spline (or Bézier) curve is approximated by its control polygon, which achieves a convergence rate of 2. Bartoň and Jüttler presented a quadratic clipping method for computing all the roots of a univariate polynomial equation within an interval [1]. In the quadratic clipping method in [1], the original univariate poly- nomial is rstly approximated by a quadratic polynomial based on degree reduction. Then two quadratic polynomials bounding the original polynomial within an interval are estimated, and the roots of the original polynomial are also bounded by the roots of the two bounding polynomials. The quadratic clipping method achieves a convergence rate of 3 for a single root and a super-linear rate of 3/2 for double roots, which is faster than the Bézier clipping method. Later, Liu et al. extended the quadratic clipping technique and proposed a cubic clipping method, which uses a cubic polynomial to approximate the original polynomial based on degree reduction and achieves a convergence rate of 4 for single roots [15]. This paper presents a planar quadratic clipping method for computing a root of a polynomial within an interval, which can achieve an optimal convergence rate of 4 for a single root by using quadratic polynomial curves. Suppose that the given polynomial f (t) is of degree n. Instead of approximating f(t) in R 1 space by using degree reduction, we use a planar quadratic polynomial curve to Contents lists available at ScienceDirect journal homepage: www.elsevier.com/locate/cag Computers & Graphics http://dx.doi.org/10.1016/j.cag.2014.09.014 0097-8493/& 2014 Elsevier Ltd. All rights reserved. n Corresponding author. E-mail addresses: [email protected] (X.-D. Chen), [email protected] (W. Ma). Computers & Graphics 46 (2015) 8998

Upload: weiyin

Post on 09-Mar-2017

213 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: A planar quadratic clipping method for computing a root of a polynomial in an interval

SMI 2014

A planar quadratic clipping method for computing a rootof a polynomial in an interval

Xiao-Diao Chen a,b,n, Weiyin Ma b

a Hangzhou Dianzi University, Hangzhou 310037, PR Chinab Department of MBE, City University of Hong Kong, Hong Kong, PR China

a r t i c l e i n f o

Article history:Received 7 July 2014Received in revised form20 August 2014Accepted 16 September 2014Available online 2 October 2014

Keywords:Optimal approximation orderRoot findingQuadratic clippingConvergence rate

a b s t r a c t

This paper presents a new quadratic clipping method for computing a root of a polynomial f(t) of degreenwithin an interval. Different from the traditional one in R1 space, it derives three quadratic curves in R2

space for approximating ðt; f ðtÞÞ instead, which leads to a higher approximation order. Two boundingpolynomials are then computed in Oðn2Þ for bounding the roots of f(t) within the interval. The newclipping method achieves a convergence rate of 4 for a single root, compared with that of 3 fromtraditional method using quadratic polynomial approximation in R1 space. When f(t) is convex withinthe interval, the two bounding polynomials are able to be directly constructed without error estimation,which leads to computational complexity O(n). Numerical examples show the approximation effect andefficiency of the new method. The method is particularly useful for the fly computation in manygeometry processing and graphics rendering applications.

& 2014 Elsevier Ltd. All rights reserved.

1. Introduction

Computing the solutions of (systems of) non-linear equations isfrequently needed for solving various geometric and graphics pro-blems [1,2,8,9,12,13,15,20,22],. Typical examples include curve/sur-face intersection and surface rendering by ray-tracing [7,15,18,19],point projection, which is to compute the closest point on a curve orsurface to a given point [3], collision detection [4,14], and bisectors/medial axes computation [8]. The method is particularly useful forthe fly computation in connection with the above applications inboth geometry processing and graphics rendering.

For solving a polynomial equation, the Descartes rule [5,21] andthe Sturm theorem [10,11] are two well-known techniques forisolating real roots. A collection of related references can be foundin [16]. A Bézier curve is bounded by the convex hull of its controlpolygon, the corresponding roots are then bounded by the roots ofthe convex hull. Note that the number of the zeros of a Bézierfunction is less or equal to that of its control polygon, the zeros ofits control polygon can be used for isolating the zeros of a Bézierfunction [17].

There are also several clipping algorithms developed for findingthe roots of polynomials [1,15,17,23]. In 1990, Sederberg and Nishita

proposed a Bézier clipping technique, which is to identify regions ofthe polynomial which do not include the part of the roots by usingthe convex hull property of Bézier curves [23]. The Bézier clippingmethod was proved to be quadratically convergent in [24].

Mørken and Reimers presented a linear approximation method[17], inwhich the given B-Spline (or Bézier) curve is approximated byits control polygon, which achieves a convergence rate of 2. Bartoňand Jüttler presented a quadratic clipping method for computing allthe roots of a univariate polynomial equation within an interval [1].In the quadratic clipping method in [1], the original univariate poly-nomial is firstly approximated by a quadratic polynomial based ondegree reduction. Then two quadratic polynomials bounding theoriginal polynomial within an interval are estimated, and the roots ofthe original polynomial are also bounded by the roots of the twobounding polynomials. The quadratic clipping method achieves aconvergence rate of 3 for a single root and a super-linear rate of 3/2for double roots, which is faster than the Bézier clipping method.

Later, Liu et al. extended the quadratic clipping technique andproposed a cubic clipping method, which uses a cubic polynomialto approximate the original polynomial based on degree reductionand achieves a convergence rate of 4 for single roots [15].

This paper presents a planar quadratic clipping method forcomputing a root of a polynomial within an interval, which canachieve an optimal convergence rate of 4 for a single root by usingquadratic polynomial curves. Suppose that the given polynomial f(t) is of degree n. Instead of approximating f(t) in R1 space by usingdegree reduction, we use a planar quadratic polynomial curve to

Contents lists available at ScienceDirect

journal homepage: www.elsevier.com/locate/cag

Computers & Graphics

http://dx.doi.org/10.1016/j.cag.2014.09.0140097-8493/& 2014 Elsevier Ltd. All rights reserved.

n Corresponding author.E-mail addresses: [email protected] (X.-D. Chen),

[email protected] (W. Ma).

Computers & Graphics 46 (2015) 89–98

Page 2: A planar quadratic clipping method for computing a root of a polynomial in an interval

approximate the curve ðt; f ðtÞÞ in R2 space. Three constructiveinterpolation methods QT1, QT2 and QT3 are proposed, in which thequadratic curve interpolates either two points and their twodirectional tangent vectors, or three points and one directionaltangent vector. QT1 and QT2 are used for convex cases that thecurve ðt; f ðtÞÞ has no inflexion point, while QT3 is applied for othercases. In principle, QT1 and QT2 can be used for bounding f(t)within a linear computation complexity, which is much betterthan that of previous clipping methods Oðn2Þ. Numerical examplesillustrate the effectiveness and the effect of the new method.

The remainder of this paper is organized as follows. Section 2introduces three constructive quadratic tangent methods withoptimal approximation order that are used as the foundation ofthe proposed root finding method. Section 3 presents the new rootfinding method named planar quadratic clipping, while Section 4discusses the computation complexity and convergence of theproposed method. Some further examples with comparisons aregiven in Section 5, and the conclusions are drawn at the end ofthis paper.

2. Constructive planar quadratic clipping methods

Given a smooth function f(t) and an interval ½a; b�. For the sakeof convenience, we transfer the parameter interval ½a; b� into ½0;1�by using f ðtÞ ¼ f ðaþhtÞ and f

0ðtÞ ¼ f 0ðaþhtÞh, where h¼ b�a.Without loss of generality, suppose that the given interval is½0;1�. Let

p0 ¼ ð0; f ð0ÞÞ ¼ ð0; p0Þ; pm ¼ ð0:5; f ð0:5ÞÞ ¼ ð0:5; pmÞ;p1 ¼ ð1; f ð1ÞÞ ¼ ð1; p1Þ; v0 ¼ ð1; f 0ð0ÞÞ ¼ ð1; d0Þ;vm ¼ ð1; f 0ð0:5ÞÞ ¼ ð1; dmÞ; v1 ¼ ð1; f 0ð1ÞÞ ¼ ð1; d1Þ;λ0 ¼ detðp1�p0; v0Þ; λ1 ¼ detðp1�p0; v1Þ;where “det” denotes determinant of the two vectors. Suppose thatthe quadratic Bézier curves are

AjðuÞ ¼ ðxjðuÞ; yjðuÞÞ¼ p0B

20ðuÞþqjB

21ðuÞþp1B

22ðuÞ; j¼ 1;2;3; ð1Þ

which are used to approximate the curve CðtÞ ¼ ðt; f ðtÞÞ within theinterval ½0;1�, where B2

0ðuÞ ¼ ð1�uÞ2, B21ðuÞ ¼ 2ð1�uÞu and B2

2ðuÞ ¼ u2

are Bernstein polynomials.

2.1. Outline of the idea

In the previous quadratic clipping method, it utilizes a quadraticpolynomial y(t) to approximate f(t), while in the planar quadraticclipping method, it utilizes a quadratic polynomial curve ðx2ðuÞ; y2ðuÞÞto approximate ðt; f ðtÞÞ in R2 space instead, which needs to estimatethe mapping function between parameters u and t. In principle,the planar quadratic clipping method is to find a quadratic reparame-terization function ϕðtÞ ¼ tþρ1ðt�1Þt and a quadratic polynomialyðtÞ ¼ ρ2þρ3tþρ4t

2 such that yðϕðtÞÞ obtains the approximationorder of 4 to f(t), where ϕ0ðtÞZ0, for all tA ½0;1�. Note that thereare four unknowns ρi; i¼ 1;2;3;4 in yðϕðtÞÞ, we can introduce fourconstraints such that yðϕðtÞÞ interpolates either two points and theirtwo derivatives (see also QT1 in Section 2.2), or three points and onederivative of f(t) (see also QT2 in Section 2.3 and QT3 in Section 2.4).From [6, Theorem 3.5.1, p. 67, Chapter 3.5], yðϕðtÞÞ can obtain both theapproximation order of 4 and the convergence rate of 4, which isbetter than that of previous quadratic clipping method 3.

Generally speaking, QT1 and QT2 are used for convex cases thatðt; f ðtÞÞ has no inflexion point, while QT3 is applied for other casesthat QT1 and QT2 fail. In principle, both QT1 and QT2 can constructtwo polynomials which can be used to bound f(t), and the corre-

sponding computation complexity is linear, which is much betterthan those of previous clipping methods.

2.2. The first planar quadratic clipping method (QT1)

Suppose that λ0 � λ1o0, e.g., when CðtÞ is convex within ½0;1�,see also Fig. 1. Let q1 be the intersection point between the twolines p0þv0t and p1þv1t, which can be computed by solving thefollowing constraints:

q1 ¼ p0þα0v0 ¼ p1�α1v1; ð2Þwhere α0 and α1 are two unknown real numbers. From Eq. (2), wehave that

A1ðiÞ ¼ pi;A01ðiÞ ¼ 2αivi; i¼ 0;1; ð3Þ

which means that A1ðuÞ interpolates two end-points and twodirectional tangent vectors of the two end-points. It can be verifiedthat the values of α0 and α1 are positive. In fact, if the length ofinterval ½a; b� tends to be zero, then x1ðuÞ tends to be u, whichmeans that the value of αi tends to be 0.5, i¼0, 1.

In this case, letϕ1ðtÞ ¼ tþρ1;0ðt�1Þt, y1ðtÞ ¼ p0B20ðuÞþρ1;1B

21ðuÞþ

p1B21ðuÞ and Y 1ðtÞ ¼ y1ðϕ1ðtÞÞ, where ρ1;i is a unknown. The equation

system

pi ¼ Y 1ðiÞ; di ¼ Y01ðiÞ; i¼ 0;1; ð4Þ

can be simplified into

2ðp1�p0Þρ21;0þðd0�d1Þρ1;0þ2p0þd1�2p1þd0 ¼ 0;

ρ1;1 ¼ p1�d1

2ð1þρ1;0Þ:

8><>:There may be two values of ρ1;0, and we select the one which is of thesmaller absolute value. Let H1ðtÞ ¼ f ðtÞ�Y 1ðtÞ. Combing Eq. (4) with[6, Theorem 3.5.1, p. 67, Chapter 3.5], there exists ξ1ðtÞA ½0;1� suchthat

f ðtÞ�Y 1ðtÞ ¼H

ð4Þ1 ðξ1ðtÞÞ24

ðt�1Þ2t2: ð5Þ

2.3. The second planar quadratic clipping method (QT2)

Let υ0 ¼ detðpm�p0; vmÞ, υ1 ¼ detðp1�pm; vmÞ and υ2 ¼ detðp1�p0; vmÞ. Suppose that υ0 � υ1o0, e.g., when CðtÞ is convex within

p0

q1 p1v1

v0

Fig. 1. Illustration of QT1. The curve in solid black is the curve CðtÞ, while the curvein dashed blue is the quadratic Bézier curve with control points p0, q1 and p1. (Forinterpretation of the references to color in this figure caption, the reader is referredto the web version of this article.)

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–9890

Page 3: A planar quadratic clipping method for computing a root of a polynomial in an interval

½0;1�, see also Fig. 2. We look for a quadratic curve A2ðuÞ together withtwo unknowns β and um such that

A2ð0Þ ¼ p0; A2ð1Þ ¼ p1; A2ðumÞ ¼ pm; A02ðumÞ ¼ βvm; ð6Þ

which means that A2ðuÞ interpolates three points and one directionaltangent vector at the middle point. The numerator of the divideddifferences of A2ðuÞ on ½0;um;um;1� becomes

A2½0;um;um;1� ¼ ðu2m�umÞA0

2ðumÞþðA2ð1Þ�A2ð0ÞÞu2m

�2ðA2ðmÞ�A2ð0ÞÞumþðA2ðumÞ�A2ð0ÞÞ¼ ðu2

m�umÞβvmþðp1�p0Þu2m�2ðpm�p0Þum

þðpm�p0Þ ¼ 0: ð7ÞBy taking the determinant with vm, Eq. (7) can be simplified as

R2ðmÞ ¼ υ0�2υ0umþυ2u2m ¼ υ0ð1�umÞ2þυ1u2

m ¼ 0: ð8ÞFrom the assumption that υ0 � υ1o0, we obtain

um ¼ 1ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi�υ1=υ0

pþ1

Að0;1Þ: ð9Þ

Finally, from the constraint A2ðumÞ ¼ pm, we obtain

q2 ¼pm�p0B

20ðumÞ�p1B

22ðumÞ

B21ðumÞ

:

Similar to Section 2.2, we can find ϕ2ðtÞ ¼ tþρ2;0ðt�1Þt,y2ðtÞ ¼ f ð0ÞB2

0ðuÞþρ2;1B21ðuÞþ f ð1ÞB2

1ðuÞ and Y 2ðtÞ ¼ y2ðϕ2ðtÞÞ suchthat

p0 ¼ Y 2ð0Þ; pm ¼ Y 2ð0:5Þ; p1 ¼ Y 2ð1Þ; dm ¼ Y02ð0:5Þ; ð10Þ

where the two unknowns ρ2;0 and ρ2;1 are determined by

ðp0�p1�dmÞρ22;0þ4ðp0þp1�2pmÞρ2;0

þ4ðdmþp0�p1Þ ¼ 0;

ρ2;1 ¼2ðp0�p1þdmÞþðp0þp1Þρ2;0

2ρ2;0:

8>>>><>>>>:

Combing Eq. (10) with [6, Theorem 3.5.1, p. 67, Chapter 3.5],there exists ξ2ðtÞA ½0;1� such that

H2ðtÞ ¼ f ðtÞ�Y 2ðtÞ ¼H

ð4Þ2 ðξ2ðtÞÞ24

ðt�0:5Þ2tðt�1Þ: ð11Þ

2.4. The third planar quadratic clipping method (QT3)

The QT3 method is to find A3ðuÞ interpolating three points andone directional tangent vector at one end point. Suppose thatλ0 � λ140, e.g., when CðtÞ is concave within ½0;1�, see Fig. 3. Withoutloss of generality, suppose that λ040. Let λ2 ¼ detðpm�p0; v0Þ andλ3 ¼ detðp1�pm; v1Þ. If pm locates inside the triangle △p0p1r0 suchthat 0oλ2oλ0, we try to construct the quadratic Bézier curve A3ðuÞsuch that

A3ð0Þ ¼ p0; A3ð1Þ ¼ p1; A3ðumÞ ¼ pm; A03ð0Þ ¼ γ0v0: ð12Þ

where γ0 is a positive real number determined by Eq. (12). In fact, thenumerator of the divided differences of A3ðuÞ on ½0;0;um;1� becomes

A3½0;0;um;1� ¼ ðu2m�umÞA0

3ð0Þ�u2mðA3ð1Þ�A3ð0ÞÞ

þðA3ðmÞ�A3ð0ÞÞ¼ ðu2

m�umÞγ0v0�u2mðp1�p0Þþðpm�p0Þ ¼ 0: ð13Þ

By taking the determinant with v0, Eq. (13) can be simplified into

R2ðumÞ ¼ �λ0u2mþλ2 ¼ 0: ð14Þ

From the assumption that 0oλ2oλ0, the value of um isffiffiffiffiffiffiffiffiffiffiffiffiλ2=λ0

pAð0;1Þ.

Similarly, let ϕ3ðtÞ ¼ tþρ3;0ðt�1Þt, y3ðtÞ ¼ p0B20ðuÞþρ3;2B

21ðuÞþ

p1B21ðuÞ and Y 3ðtÞ ¼ y3ðϕ3ðtÞÞ. It can be verified that ϕ3ð0Þ ¼ 0,

ϕ3ð1Þ ¼ 1, p0 ¼ Y 3ð0Þ and p1 ¼ Y 3ð1Þ. In many cases, we can setρ3;1 ¼ 0 and find two unknowns ρ3;0 and ρ3;2 such that

pm ¼ Y 3ð0:5Þ and d0 ¼ Y03ð0Þ: ð15Þ

If ϕ03ðtÞZ0 is not satisfied for all tA ½0;1�, we set y3ðtÞ as the

y-coordinate of A3ðuÞ, and ϕ3ðtÞ ¼ tþρ3;0ðt�1Þt=ðρ3;1tþ1Þ suchthat

ϕ3ð0Þ ¼ 0; ϕ3ð1Þ ¼ 1; ϕ3ð0:5Þ ¼ um and ϕ03ð0Þ ¼ γ�1

0 ;

where um and γ0 are determined by Eq. (12).Let Y 3ðtÞ ¼ y3ðϕ3ðtÞÞ and H3ðtÞ ¼ f ðtÞ�Y 3ðtÞ. We have that

χ3ð0Þ ¼ 0; χ3ð0:5Þ ¼ 0; χ3ð1Þ ¼ 0 and χ 03ð0Þ ¼ 0; ð16Þ

where χ3 ¼H3; H3. Similarly, there exists ξ3ðtÞA ½0;1� such that

χ3ðtÞ ¼χð4Þ3 ðξ3ðtÞÞ24

t2ðt�0:5Þðt�1Þ; χ3 ¼H3; H3: ð17Þ

p0

q2p1

pm

vm

Fig. 2. Illustration of QT2. The curve in solid black is the curve CðtÞ, while the curvein dashed blue is the quadratic Bézier curve with control points p0, q2 and p1. (Forinterpretation of the references to color in this figure caption, the reader is referredto the web version of this article.)

p0

q3

p1

pm

v0

r1

r0

v1

Fig. 3. Illustration of QT3. r0 (or r1) is the foot point of p1 (or p0) to the tangent lineL0ðp0 ;v0Þ (or L1ðp1; v1Þ), the curve in solid black and the curve in dashed blue arethe curve CðtÞ and the quadratic Bézier curve with control points p0, q3 and p1,respectively. (For interpretation of the references to color in this figure caption, thereader is referred to the web version of this article.)

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–98 91

Page 4: A planar quadratic clipping method for computing a root of a polynomial in an interval

Otherwise, if pm locates inside the triangle △p0p1r1 such that0oλ3oλ1, we try to construct

A3ð0Þ ¼ p0; A3ð1Þ ¼ p1; A3ðumÞ ¼ pm; A03ð1Þ ¼ γ1v1; ð18Þ

where γ1 is a positive real number determined by Eq. (18). In fact,the numerator of the divided differences of A3ðuÞ on ½0; um;1;1�becomes

A3½0; um;1;1� ¼ ð� u2mþ umÞA0

3ð1Þþðum�1Þ2

ðA3ð1Þ�A3ð0ÞÞ�ðA3ð1Þ�A3ðmÞÞ

¼ ð� u2mþ umÞγ1v1þðum�1Þ2ðp1�p0Þ�ðp1�pmÞ

¼ 0: ð19Þ

By taking the determinant with v1, Eq. (19) can be simplified into

R2ðumÞ ¼ λ1ðum�1Þ2�λ3 ¼ 0: ð20Þ

From the assumption that 0oλ3oλ1, the value of um is1�

ffiffiffiffiffiffiffiffiffiffiffiffiλ3=λ1

pAð0;1Þ.

In this case, letϕ4ðtÞ ¼ tþρ4;0ðt�1Þt, y4ðtÞ ¼ p0B20ðuÞþρ4;2B

21ðuÞþ

p1B21ðuÞ and Y 4ðtÞ ¼ y4ðϕ4ðtÞÞ. It can be verified that ϕ4ð0Þ ¼ 0,

ϕ4ð1Þ ¼ 1, p0 ¼ Y 4ð0Þ and p1 ¼ Y 4ð1Þ. In many cases, we can findtwo unknowns ρ4;0 and ρ4;2 such that

pm ¼ Y 4ð0:5Þ and d1 ¼ Y04ð1Þ: ð21Þ

If ϕ04ðtÞZ0 is not satisfied for all tA ½0;1�, we set y4ðtÞ as the y-

coordinate of A3ðuÞ, and ϕ4ðtÞ ¼ tþρ4;0ðt�1Þt=ðρ4;1tþ1Þ such that

ϕ4ð0Þ ¼ 0; ϕ4ð1Þ ¼ 1; ϕ4ð0:5Þ ¼ um and ϕ04ð1Þ ¼ γ�1

1 ;

where A3ðuÞ, um and γ1 are determined by Eq. (18).Let Y 4ðtÞ ¼ y4ðϕ4ðtÞÞ and H4ðtÞ ¼ f ðtÞ�Y 4ðtÞ. We have that

χ4ð0Þ ¼ 0; χ4ð0:5Þ ¼ 0; χ4ð1Þ ¼ 0 and χ 04ð1Þ ¼ 0; ð22Þ

where χ4 ¼H4; H4. Similarly, there exists ξ4ðtÞA ½0;1� such that

χ4ðtÞ ¼χð4Þ4 ðξ4ðtÞÞ24

t2ðt�0:5Þðt�1Þ; χ4 ¼H4; H4: ð23Þ

Fig. 3 illustrates the condition of 0oλ2oλ0, and the illustra-tion of 0oλ3oλ1 can be done in a similar way. In Fig. 3, thedirectional vector ðp1�r0Þ is perpendicular to v0. If the inner pointpm locates into the triangle Δðp0;p1; r0Þ, it can be verified that0oλ2oλ0. In principle, when the length h of the interval ½a; b� issmall enough, the middle point pm (or even the whole curvesegment) locates in the quadrilateral p0r0p1r1, and thus, thequadratic curve A3ðuÞ determined by either Eq. (12) or Eq. (18)exists.

Remark 1. If p0, p1 and pm are collinear, or λ0 � λ1 ¼ 0, we simplyset the quadratic curve as the line p0ð1�tÞþp1t. Usually, we canextend the idea of the planar clipping method by using cubicpolynomial curves and achieve a much better approximation effectand a higher convergence rate, which is beyond the topic ofthis paper.

3. The new quadratic clipping method for root finding

Similar to the k-clipping method, each clipping process of thenew quadratic clipping has three steps: (1) compute the referencepolynomial; (2) estimate the bounding polynomials; and (3) boundthe roots of f(t) by using the roots of the bounding polynomials.

Given a polynomial f(t) of degree nZ4, the interval ½a; b�, f 0ðtÞ andf ð4ÞðtÞ as well (by pre-computation once). We try to obtain a smallersubinterval by using one clipping process, which is as follows. For thesake of convenience, let the number pair ðT1; T2Þ denotes T1 multiply/division operations and T2 minus/add operations.

3.1. The first two steps for obtaining two bounding polynomials

Without loss of generality, we assume that λ0 � λ1a0. Supposethat we obtain the values of f(i) and f 0ðiÞ, i¼ a; b, which costsð4n�2;4n�2Þ.

� Case 1: λ0 � λ1o0.We use QT1 to obtain the reference polynomial Y 1ðtÞ ¼ y1ðϕ1ðtÞÞ,

where Y 1ðtÞ, y1ðtÞ and ϕ1ðtÞ are of degree 4, 2 and 2, respectively.

Thus, Yð4Þ1 ðtÞ � κ1 and H

ð4Þ1 ðtÞ ¼ f

ð4ÞðtÞ�κ1, where κ1 is a constant.

If y1ðtÞ is rewritten as At2þ2BtþC in ð1;3Þ, κ1 can be computed in

ð2;0Þ. The differentiation fð4ÞðtÞ within ½a; b� can be rewritten into

Bernstein form within ð2ðn�4Þðn�3Þ; ðn�4Þðn�3ÞÞ. Thus, an upper

bound τ1 and a lower bound τ2 of Hð4Þ1 ðtÞ can be obtained from

ð2ðn�4Þðn�3Þþ3; ðn�4Þðn�3Þþ2Þ. Note that 0r ðt�1Þ2t2r116 ; 8 tA ½0;1�, let K1 ¼ 1

384 , τ r;1 ¼maxf0;K1τ1g and τ l;1 ¼minf0;K1τ2g, we have the two bounding polynomials

Yl;1ðtÞ ¼ τ l;1þY 1ðtÞr f ðtÞrτ r;1þY 1ðtÞ ¼ Yr;1ðtÞ: ð24ÞSuppose that uj;1A ½0;1� is a root of y1ðuÞþτ j;1, then the correspond-ing root t⋆j;1 of Yj;1ðtÞ can be computed by solving a quadratic equation

ϕ1ðtÞ�uj;1 ¼ 0, j¼ l; r.

Remark 2. For the case that

ð�1ÞiH ð4Þ1 ðtÞr0 and ð�1ÞiH ð4Þ

2 ðtÞr0; i¼ 0 or i¼ 1; 8 tA ½0;1�;combining Eq. (5) with Eq. (11), we have that ð�1ÞiY1ðtÞZð�1Þif ðtÞZ ð�1ÞiY2ðtÞ, which means that Y1ðtÞ and Y2ðtÞ can beused as the two bounding polynomials. The total computation timeof each clipping process is O(n). In this case, the newmethod is calledas the optimized one (see also Opt in Fig. 6).

� Case 2: λ0 � λ140.In this case, we firstly use QT3 to obtain the reference poly-

nomial Y jðtÞ ¼ yjðϕjðtÞÞ, where j¼3 or 4. Without loss of generality,suppose that j¼3. Let τ3 and τ4 be an upper bound and a lowerbound of H

ð4Þ3 ðtÞ within ½0;1�, respectively. Note that

K3 ¼ �51ffiffiffiffiffiffi17

pþ107

8192rðt�1Þðt�0:5Þt2r51

ffiffiffiffiffiffi17

p�107

8192¼ K2

for all tA ½0;1�, we have the two bounding polynomials

Yl;3ðtÞ ¼ τ l;3þY 3ðtÞr f ðtÞrτ r;3þY 3ðtÞ ¼ Yr;3ðtÞ; ð25Þwhere τ r;3 ¼maxf0; τ3K2;K3τ4g and τ l;3 ¼minf0; τ4K2; τ3K3g.

Similarly, suppose that uj;3A ½0;1� is a root of y3ðuÞþτ j;3, thenthe corresponding root t⋆j;3 of Yj;3ðtÞ can be computed by solving aquadratic equation ϕ3ðtÞ�uj;3 ¼ 0, j¼ l; r.

Remark 3. Suppose the length ½a; b� is small enough such that thevalue of γ0 tends to be 1, i.e., γ0 ¼ 1þoð1Þ, where “oð1Þ” denotesinfinitively small. The reparameterization function ϕ3ðtÞ can be acubic or other polynomial satisfying

ϕ3ð0Þ ¼ 0; ϕ3ð1Þ ¼ 1; ϕ3ð0:5Þ ¼ um and ϕ03ð0Þ ¼ γ�1

0 :

Let x3ðuÞ be a cubic polynomial determined by

x3ð0Þ ¼ 0; x3ð1Þ ¼ 1; x3ðumÞ ¼ 0:5 and x 03ð0Þ ¼ γ0:

It can be checked that ϕ3ðx3ðuÞÞ ¼ uþðu�1Þðu�umÞu2 � oð1Þ andϕ3ðx3ðuj;3ÞÞ�uj;3 ¼ oð1Þ � 0. Thus, the root of ϕ3ðtÞ�uj;3 ¼ 0 can beapproximated by x3ðuj;3Þ.

3.2. The third step for computing resulting subintervals

The third step is to compute the subinterval ½a1; b1�D ½0;1�bounding the roots of f ðtÞ, then ½aþa1ðb�aÞ; aþb1ðb�aÞ�D ½a; b� isthe resulting subinterval bounding the root of f(t). Suppose that

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–9892

Page 5: A planar quadratic clipping method for computing a root of a polynomial in an interval

the two bounding polynomials obtained in the first two steps areY lðtÞr f ðtÞrY rðtÞ. We rearrange the roots of Y lðtÞ and Y rðtÞ andobtain that 0¼ t0ot1o⋯otd ¼ 1. Let Ωi be the subinterval½t i; t iþ1�. If d¼1, i.e., there is no root of Y lðtÞ and Y rðtÞ within½0;1�, similar to that of the k-clipping method, we subdivide ½0;1�and obtain two subintervals ½0;0:5� and ½0:5;1�.

Otherwise, if f ðtÞZY lðtÞZ0 or 0ZY rðtÞZ f ðtÞ; 8 tAΩi, note thatthe two inequalities are usually not satisfied at the same time, f ðtÞ hasno root within Ωi, which means that Ωi can be removed. For theremaining case that both of Y lðtÞ and Y rðtÞ have roots within ½0;1�,note that f ðt l;iÞZY lðt l;iÞ ¼ 0 and f ðt r;iÞrY rðt r;iÞ ¼ 0, from the middlevalue theorem, there exists t⋆ between t l;i and t r;i such that f ðt⋆Þ ¼ 0,which means that the remaining subinterval has at least one root off ðtÞ. Finally, the resulting subintervals are obtained in the above way.

3.3. Outline of the algorithm

In the new clipping method, the following clipping algorithm isiteratively executed until there are no roots of f(t) or the length ofthe subinterval is less than the given tolerance.

Algorithm 1. Finding all of the roots of polynomial f(t) in ½a; b�.

Input: The given polynomial f(t), interval ½a;b�, tolerances ε1and ε2.

Output: The set Φ containing the roots of f(t) within ½a; b�.1. Compute the zeros of the control polygon of f(t), divide ½a; b�

into several subintervals by using these zeros, put all of thesubintervals into Ω, and goto next step.

2. If Ω is empty, goto Step (7);otherwise, goto next step.

3. Pop up an element (i.e., an interval denoted as ½a1; b1�) of Ω.If b1�a1oε1, put ða1þb1Þ=2 into Φ;otherwise, goto next step.

4. If jf ða1Þjoε2, put a1 into Φ, and update the ½a1; b1� as½a1þε1; b1�.If jf ðb1Þjoε2, put b1 into Φ, and update the ½a1; b1� as½a1; b1�ε1�.Goto next step.

5. Compute the corresponding lower and upper bounds of f(t)by using Eq. (24), Eq. (25) or other similar ones, respectively.Solve the roots of the bounds and turn them into the valuesof parameter t to obtain a¼ t0ot1o⋯otκ ¼ b.Goto next step.

6. If the number of roots κ is less than 2, put ½a; ðaþbÞ=2� and½ðaþbÞ=2;b� into Ω, and goto Step (2);Otherwise, remove the subinterval ½ti; tiþ1� which containsno roots of f(t), put the remaining subintervals into Ω, andgoto Step (2).

7. End: Output Φ.

We show two examples to illustrate one clipping step of thenew algorithm.

Example 1 (A convex case). Given f ðtÞ ¼ ðt�1=3Þð2�tÞðtþ5Þ2;tA ½0;1�, which has a single root t¼1/3 in ½0;1�, see also Fig. 4(a).Note that λ0 � λ1 ¼ �682=3o0, we firstly use QT1 to obtain

ðx1ðuÞ; y1ðuÞÞ ¼124u�29u2

95;�950þ3844uþ1526u2

57

� �;

ϕ1ðtÞ ¼ tþ0:20124ðt�1ÞÞt:It can be verified that �0:0045rH1ðtÞ ¼ f ðtÞ�Y 1ðtÞ ¼ f ðtÞ�y1ðϕ1ðtÞÞr0. The roots of the two bounding polynomials Y 1ðtÞ andY 1ðtÞ�0:0045 form the resulting subinterval ½0:333304;0:333400� oflength 0.000096.

In this case, the condition in Remark 2 is satisfied. From QT2, weconstruct

ϕ2ðtÞ ¼ tþ0:2012ðt�1Þt;y2ðtÞ ¼ �50=3þ64:6788t�24:0122t2:

Then Y iðtÞ ¼ yiðϕiðtÞÞ bound f(t), 8 tA ½0;1�, i¼1, 2, see also Fig. 4(b).The corresponding subinterval is ½0:333304;0:333336� of length0.000032.

Example 2 (A concave case). Given f ðtÞ ¼ ððt�1=3Þ2þ1Þðt�1=3Þðtþ2Þ; tA ½0;1�, which has a single root t¼1/3 in ½0;1�, see Fig. 5(a). In this case, λ0 ¼ �4=3 and λ1 ¼ �8=3, so λ0 � λ140. From QT3,note that point pm locates inside the triangle △p0p1r1, we utilizeEq. (18) to obtain

ðx3ðuÞ; y3ðuÞÞ ¼ ð�0:6254t2þ1:6254t;2:5682t2�8:2719tþ50=27Þ;

ϕ4ðtÞ ¼ t�0:2280ðt�1Þtt�1:3653

or ϕ4ðtÞ ¼ tþtðt�1Þð0:2695þ0:6086tÞ:

It can be verified that 0:413535ZH3ðtÞ ¼ f ðtÞ�y3ðϕ4ðtÞÞZ�0:1878.The roots of the two bounding polynomials lead to the resultingsubinterval ½0:3151;0:4331� of length 0.1180. By the estimation met-hod in Remark 3, the corresponding subinterval is ½0:3213;0:4341� oflength 0.1128.

f (t)

t

H2(t)

H1 (t)

t

Fig. 4. Example 1: (a) plots of the curve ðt; f ðtÞÞ in solid black, ðx1ðuÞ; y1ðuÞÞ in dashed blue and ðx2ðuÞ; y2ðuÞÞ in dashed red; (b) the error plots of H1ðtÞ in blue and H2ðtÞ in red.(For interpretation of the references to color in this figure caption, the reader is referred to the web version of this article.)

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–98 93

Page 6: A planar quadratic clipping method for computing a root of a polynomial in an interval

Let Mk and Mn be the k-clipping method and the new quadraticclipping method, respectively, k¼2, 3. The approximation errorand the length of the resulting subinterval in the different met-hods are listed in Table 1. It shows that M3 achieves the bestapproximation error in Example 2 while Mn achieves the bestapproximation error in Example 1, both M3 and Mn have betterapproximation error than that of M2.

4. Computational complexity and convergence rate

4.1. Analysis of computational complexity

Each clipping process in M2, M3 and Mn is similar to each other,which has three steps: (1) to find a reference polynomial; (2) tocompute two bounding polynomials and their roots within thegiven interval; and (3) to find the resulting subintervals containingthe roots of f(t).

Suppose that the degree nZ4. We discuss the case λ0 � λ1o0 byusing QT1, and the other case λ0 � λ140 can be done in a similar way.One needs to compute the values of p0, p1, d0 and d1 before deter-mining y1ðtÞ and ϕ1ðtÞ. It can be verified that y1ðtÞ and ϕ1ðtÞ can becomputed in ð4nþ4;4nþ7Þ, and then the two bounding polynomialscan be computed in ð2n2�14nþ29;n2�7nþ16Þ. A quadratic poly-nomial has at most two roots, and in the worst case, the roots of thetwo bounding polynomials can be computed in ð6;18Þ and four “√”

operations. When the condition in Remark 2 is satisfied, Y1ðtÞ andY2ðtÞ can bound f(t) within the given subinterval, which leads to anoptimized computation time ð6nþ23;6nþ53Þ and ten “√” opera-tions in the worst case. Fig. 6 plots the operation number curves ofboth multiply/division operation and add/minus operation in M2, M3,Mn and the optimized one mentioned in Remark 2 (denoted as “Opt”).

It shows that Mn has the least computation time among M2, M3

and Mn.

4.2. Analysis of convergence rate

For the sake of convenience, assume that t⋆ is the unique rootof f(t) in the interval ½a; b�, m ¼ ðaþbÞ=2, and mr3 is the multi-plicity of t⋆ such that

f ðiÞðt⋆Þ ¼ 0; i¼ 0;1;…;m�1; and f ðmÞðt⋆Þa0: ð26ÞWe have the following Lemma.

Lemma 1. Assuming that h is small enough, we have

12f ðmÞðt⋆Þ

m!ðt�t⋆Þm

����������r f ðtÞ ; 8 tA ½a; b�:

���� ð27Þ

Proof. From Taylor expansion of f(t) at t⋆, there exists ξ5ðtÞA ½a; b�such that

f ðtÞ ¼ f ðmÞðt⋆Þm!

ðt�t⋆Þmþ f ðmþ1Þðξ5ðtÞÞðmþ1Þ! ðt�t⋆Þmþ1; 8 tA ½a; b�: ð28Þ

From the assumption that h is small enough such that

f ðmþ1Þðξ5ðtÞÞmþ1

ðt�t⋆Þ r f ðmÞðt⋆Þ2

����������; 8 tA ½a;b�:

���������� ð29Þ

Combining Eq. (28) with Eq. (29), we obtain Eq. (27). Thus, wehave completed the proof. □

Firstly, we discuss the case that λ0 � λ1o0, e.g., the convex case.From QT1, we obtain y1ðtÞ, the reparameterization function ϕ1ðtÞand then the reference polynomial Y1ðtÞ ¼ y1ðϕ1ðtÞÞ such that

f ðiÞ ¼ Y1ðiÞ; f 0ðiÞ ¼ Y 01ðiÞ; i¼ a; b: ð30Þ

From Eq. (30), there exists ξ6ðtÞA ½a; b� such that

H1ðtÞ ¼ f ðtÞ�Y1ðtÞ ¼Hð4Þ

1 ðξ6ðtÞÞ4!

ðt�aÞ2ðt�bÞ2: ð31Þ

Let η1 ¼ supar trbjðHð4Þ1 ðtÞÞ=384j, combining with Eq. (31), we have

that

jH1ðtÞjrη1ðb�aÞ4 ¼ η1h4: ð32Þ

Fig. 5. Example 2: (a) plots of the curve ðt; f ðtÞÞ in solid black and ðx3ðuÞ; y3ðuÞÞ in dashed red; (b) the error plots between f(t) and the reference polynomials inM2,M3 andMn.(For interpretation of the references to color in this figure caption, the reader is referred to the web version of this article.)

Table 1Comparisons on length and approximation error.

Method Example 1 Example 2

M2 M3 Mn M2 M3 Mn

Length 0.0411 0.0030 0.000096 0.1602 0.0303 0.1180Error 0.4976 0.0142 0.0017 0.2142 0.0142 0.1945

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–9894

Page 7: A planar quadratic clipping method for computing a root of a polynomial in an interval

Let t⋆j;lA ½a; b� is the root of Yj;1ðtÞ; j¼ l; r. We have that

jf ðt⋆Þ� f ðt⋆j;lÞj ¼ jYj;1ðt⋆j;lÞ� f ðt⋆j;lÞjr jY1ðt⋆j;lÞ� f ðt⋆j;lÞjþjYj;1ðt⋆j;lÞ�Y1ðt⋆j;lÞjr2η1h

4: ð33Þ

Combining Eq. (27) with Eq. (33), we have that

12f ðmÞðt⋆Þ

m!ðt⋆j;l�t⋆Þm

����������r2η1h

4;

which leads to

jðt⋆j;l�t⋆Þmjr 4η1 �m!

jf ðmÞðt⋆Þjh4: ð34Þ

Similarly, from QT2, we obtain y2ðtÞ, the reparameterizationfunction ϕ2ðtÞ and then the reference polynomial Y2ðtÞ ¼ y2ðϕ2ðtÞÞsuch that

f ðiÞ ¼ Y2ðiÞ; f ðmÞ ¼ Y2ðmÞ; f 0ðmÞ ¼ Y 02ðmÞ; i¼ a; b: ð35Þ

From Eq. (35), there exists ξ7ðtÞA ½a; b� such that

H2ðtÞ ¼ f ðtÞ�Y2ðtÞ ¼Hð4Þ

2 ðξ7ðtÞÞ4!

ðt�aÞðt�bÞðt�mÞ2: ð36Þ

Let η2 ¼ supar trbjðHð4Þ2 ðtÞÞ=384j, combining with Eq. (36), we have

that

jH2ðtÞjrη2ðb�aÞ4 ¼ η2h4: ð37Þ

Let t⋆j;2A ½a; b� is the root of Yj;2ðtÞ; j¼ l; r. We have that

jf ðt⋆Þ� f ðt⋆j;2Þj ¼ jYj;2ðt⋆j;2Þ� f ðt⋆j;2Þjr jY2ðt⋆j;2Þ� f ðt⋆j;2ÞjþjYj;2ðt⋆j;2Þ�Y2ðt⋆j;2Þjr2η2h

4: ð38Þ

Combining Eq. (27) with Eq. (38), we have that

12f ðmÞðt⋆Þ

m!ðt⋆j;2�t⋆Þm

����������r2η2h

4;

which leads to

jðt⋆j;2�t⋆Þmjr 4η2 �m!

jf ðmÞðt⋆Þjh4: ð39Þ

Secondly, we discuss the case λ0 � λ140, e.g., a concave case.Without loss of generality, by using QT3, suppose that we obtainy3ðtÞ, the reparameterization function ϕ3ðtÞ and then the referencepolynomial Y3ðtÞ ¼ y3ðϕ3ðtÞÞ such that

f ðiÞ ¼ Y3ðiÞ; f 0ðaÞ ¼ Y 03ðaÞ; i¼ a;m; b: ð40Þ

From Eq. (40), there exists ξ8ðtÞA ½a; b� such that

H3ðtÞ ¼ f ðtÞ�Y3ðtÞ ¼Hð4Þ

3 ðξ8ðtÞÞ4!

ðt�aÞ2ðt�bÞðt�mÞ: ð41Þ

Let η3 ¼ supar trbjðHð4Þ3 ðtÞÞ=384j, combining with Eq. (41), we have

that

jH3ðtÞjrη3ðb�aÞ4 ¼ η3h4: ð42Þ

Let t⋆j;3A ½a; b� is the root of Yj;3ðtÞ; j¼ l; r. We have that

jf ðt⋆Þ� f ðt⋆j;3Þj ¼ jYj;3ðt⋆j;3Þ� f ðt⋆j;3Þjr jY3ðt⋆j;3Þ� f ðt⋆j;3ÞjþjYj;3ðt⋆j;3Þ�Y3ðt⋆j;3Þjr2η3h

4: ð43Þ

Combining Eq. (27) with Eq. (43), we have that

12f ðmÞðt⋆Þ

m!ðt⋆j;3�t⋆Þm

����������r2η3h

4;

which leads to

jðt⋆j;3�t⋆Þmjr 4η3 �m!

jf ðmÞðt⋆Þjh4: ð44Þ

From the above discussions, by combining Eqs. (34) and (39)with Eq. (44), we have the following theorem.

Theorem 1. The new quadratic clipping method (by using QT1, QT2or QT3) is capable of achieving a convergence rate of 4/m for solvingthe root t⋆ of multiplicity mr3.

5. Further examples with comparison and discussions

Let Mk and Mn be the k-clipping method in [1,15] and the newquadratic clipping method, k¼2, 3. For the sake of convenience,when the condition in Remark 2 is satisfied, the optimized one isstill denoted as Mn. We utilize the Maple software for testing moreexamples on PC with CPU 2.2 G and 4 G memory. In this section,the average computation time of the first clipping process is testedby using 17 valid digits after the point, which is similar to the floatnumber, and the corresponding unit is millisecond. In the follow-ing tables, αi e �βi denotes the real number Li ¼ αi � 10�βi , whichis also the length of the resulting subinterval of the i-th clippingprocess. And then, the corresponding convergence rate can besimply approximated by βiþ1=βi. From Theorem 1, we can deducethe distribution of the roots from the information of the intervalsf½ai; bi�gNi ¼ 0. For example, suppose that Li ¼ bi�ai ¼ αi e�βi, where

Nop

n

Nop

n

Fig. 6. Plots of operation numbers (Nop) in each clipping process of M2, M3 and Mn: (a) multiply/division operation; and (b) add/minus operation.

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–98 95

Page 8: A planar quadratic clipping method for computing a root of a polynomial in an interval

the interval ½ai; bi� is obtained from the i-th iteration step,1rαio10 and βi is a positive integer. If the closest integernumber to βiþ1=βi is 4 for all iZN, where N is a positive integer,then there is a single root in the interval ½ai; bi�; if the closestinteger number to βiþ1=βi is 2 for all iZN, then there is a doubleroot in the interval ½ai; bi�; if the closest integer number to βiþ1=βiis 2 for N1Z iZN, but becomes 1 for iZN1, there are possibly two(near double) roots in the interval ½ai;bi�.

Example 3. Given six polynomials f iðtÞ; i¼ 1;…;6, within ½0;1�,

f 1ðtÞ ¼ ðt�1=3Þð2�tÞðtþ5Þ2;f 2ðtÞ ¼ ðt�1=3Þð2�tÞ3ðtþ5Þ4;f 3ðtÞ ¼ ðt�1=3Þð2�tÞ5ðtþ5Þ10;f 4ðtÞ ¼ ðt�1=3Þ2ð4�tÞðtþ7Þ;f 5ðtÞ ¼ ðt�1=3Þ2ðt�4Þ3ðtþ5Þ2ðtþ7Þ;f 6ðtÞ ¼ ðt�1=3Þ2ðt�4Þ7ðtþ5Þ6ðtþ7Þ;

8>>>>>>>>>><>>>>>>>>>>:where the corresponding curve CiðtÞ ¼ ðt; f iðtÞÞ is convex nearbythe root t⋆ ¼ 1=3. Table 2 shows computation time and length ofthe resulting subinterval from M2, M3 and Mn. In Table 2, k meansthe multiplicity of the root, and cr denotes the convergence rate. Itshows that both M3 and Mn achieve convergence rate 4/k while M2

is of 3/k. M3 obtains the smallest length in cases f 2ðtÞ and f 3ðtÞ,while Mn obtains the smallest length in other four cases. Theoptimized method can work for these six cases, and the averagecomputation time of Mn is about 10% of those of M2 and M3.

Example 4. We apply the algorithm to the three polynomialsf 7ðtÞ ¼ ðt�1=3Þ2ð4�tÞðtþ7Þ, f 8ðtÞ ¼ ðt�1=3Þ2ðt�4Þ3ðtþ5Þ2ðtþ7Þand f 9ðtÞ ¼ ðt�1=3Þ2ðt�4Þ7ðtþ5Þ6ðtþ7Þ, in order to computethe double root 1/3 in the interval ½0;1�. Table 3 shows theresulting lengths of the subintervals and the computationtime in M2, M3 and Mn. These three cases show that Mn has thesmallest length and is the fastest among M2, M3 and Mn. Theconvergence rates of M2, M3 and Mn tend to be 3/2, 2 and 2.4,which shows that Mnhas the best performance on theconvergence rate.

As mentioned in [15], the k-clipping method is usually used forcomputing the cases where there are at most k real roots (countingthe multiplicity) of the given polynomial f(t) in an interval.Example 6 shows a triple root case, in which f ″ðt⋆Þ ¼ 0 and thecurve ðt; f ðtÞÞ is concave nearby the root t⋆.

Example 5. We apply M2, M3 and Mn to the polynomial f ðtÞ ¼ðt�1=3Þ3ðt�3Þ, in order to compute the triple root t⋆ ¼ 1=3 in theinterval ½0;1�. As shown in Fig. 7(a), M2, M3 and Mn work for thiscase, and M3 has the best approximation effect, while Mn has aslightly better approximation effect than that of M2.

We have also tested the numerical robustness of the planarquadratic clipping method (PQCM). Similar to the quadratic clip-ping method, PQCM needs to solve quadratic polynomial equa-tions, which is trivial and stable to solve. Similar to the cubicclipping method in [15], we have also used PQCM to compute the

Table 2(Example 3). Length Li of the resulting subinterval at different N.

f(t) f 1 ðk¼ 1Þ f 2 ðk¼ 1Þ f 3 ðk¼ 1Þ

N M2 M3 Mn M2 M3 Mn M2 M3 Mn

1 4e�2 3e�3 3e�5 1e�2 9e�3 1e�2 1e�2 1e�2 3e�22 2e�6 2e�13 1e�23 2e�8 8e�11 2e�10 2e�7 1e�9 3e�83 6e�19 1e�53 2e�96 9e�26 5e�43 3e�41 5e�22 3e�38 7e�324 1e�56 4e�215 4e�388 5e�78 7e�172 4e�165 7e�66 2e�152 2e�1275 8e�170 1e�860 6e�1555 9e�235 3e�687 2e�660 2e�197 8e�596 6e�509cr 3 4 4 3 4 4 3 4 4Time 2.247 3.994 0.2932 2.652 4.336 0.327 3.916 5.772 0.374

f(t) f 4 ðk¼ 2Þ f 5 ðk¼ 2Þ f 6 ðk¼ 2Þ

N M2 M3 Mn M2 M3 Mn M2 M3 Mn

1 2e�1 1e�1 3e�2 2e�1 7e�2 5e�2 3e�1 2e�2 7e�22 2e�2 1e�3 9e�6 2e�2 4e�4 8e�5 6e�2 2e�4 3e�43 7e�4 2e�7 3e�14 1e�3 1e�8 1e�11 5e�3 5e�9 4e�104 5e�6 4e�15 9e�35 8e�6 1e�17 4e�28 1e�4 2e�18 4e�245 2e�9 2e�30 3e�84 6e�9 2e�35 7e�68 6e�7 5e�37 5e�58cr 1.5 2 2.4 1.5 2 2.4 1.5 2 2.4Time 2.543 4.118 0.3541 3.623 4.196 0.4025 4.166 5.679 0.4337

Table 3(Example 4) Length Li of the resulting subinterval at different N.

f(t) f 7 ðk¼ 2Þ f 8 ðk¼ 2Þ f 9 ðk¼ 2Þ

N M2 M3 Mn M2 M3 Mn M2 M3 Mn

1 2e�1 1e�1 3e�2 1e�1 8e�2 6e�2 1e�1 6e�2 7e�22 2e�2 1e�3 9e�6 7e�3 4e�4 8e�5 2e�2 3e�4 3e�43 8e�4 2e�7 3e�14 1e�4 1e�8 1e�11 7e�4 6e�9 3e�104 5e�6 5e�15 1e�34 4e�7 2e�17 4e�28 7e�6 3e�18 2e�245 3e�9 3e�30 3e�84 7e�11 2e�35 8e�68 7e�9 5e�37 8e�596 3e�14 8e�61 9e�204 1e�16 4e�71 9e�164 2e�13 2e�74 9e�142cr 1.5 2 2.4 1.5 2 2.4 1.5 2 2.4Time 3.104 5.070 0.336 3.542 5.211 0.363 5.023 6.474 0.429

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–9896

Page 9: A planar quadratic clipping method for computing a root of a polynomial in an interval

roots of the Wilkinson polynomial

WðxÞ ¼ ∏20

i ¼ 1ðx� iÞ

with Bernstein–Bézier representation within the domain interval½0;25� with the same error tolerance ε1 ¼ 10�3. In this case, PQCMcan also generate 20 intervals containing the roots whose lengthsare less than ε1. In other word, it can achieve a comparable resultto that of the cubic clipping method in [15].

6. Conclusions

This paper presents a quadratic tangent method for finding theroots of a polynomial within an interval, which utilizes both thetangent idea and the reparameterization technique in R2 spaceinstead of R1 space in the traditional k-clipping method. It is ableto achieve a convergence rate of 4 for a single root which is thesame as that of a higher order cubic clipping method in [15]. Onthe other hand, the new method tries to avoid the time-consuming computation of the bounding polynomials, which canlead to a much higher computation efficiency. Numerical examplesshow that the convergence rate of the quadratic tangent methodcan be equal to that of the cubic clipping method which is higherthan that of the traditional quadratic clipping method, while thenew tangent method is able to perform much faster than those ofprevious methods in [1,15].

s for future work, several areas can be further addressed. Whenthe parameter interval is too large, though the bounding poly-nomials can bound f(t), the bounding polynomials may fail to haveroots in the interval. In this case, both the methods in [1,15] andthe new quadratic tangent method may fail to obtain a muchsmaller interval. Note that a cubic curve can achieve a betterapproximation effect than a quadratic curve in most cases. In ourfuture work, we will discuss the cubic tangent method which ispromising to achieve higher convergence rate and better approx-imation effect than those of the quadratic tangent one.

Acknowledgments

The research was partially supported by the Research GrantsCouncil of Hong Kong Special Administrative Region, China (Grant

no. CityU 118512), Defense Industrial Technology DevelopmentProgram, the National Science Foundation of China (61003194,61370166 and 61379072).

References

[1] Barton M, Jüttler B. Computing roots of polynomials by quadratic clipping.Comput Aided Geom Des 2007;24:125–41.

[2] Borwein P, Erdelyi T. Polynomials and polynomial inequalities. New York:Springer-Verlag; 1995.

[3] Chen XD, Yong JH, Wang GZ, Paul JC, Xu G. Computing the minimum distancebetween a point and a NURBS curve. Comput-Aided Des 2008;40(10–11):1051–4.

[4] Choi YK, Wang WP, Liu Y, Kim MS. Continuous collision detection for twomoving elliptic disks. IEEE Trans Robot 2006;22(2):213–24.

[5] Collins GE, Akritas AG. Polynomial real root isolation using Descartes's rule ofsigns. In: Proceedings of the third ACM symposium on symbolic and algebraiccomputation. New York, US; 1976. p. 272–5.

[6] Davis PJ. Interpolation and approximation. New York: Dover Publications;1975.

[7] Efremov A, Havran V, Seidel H-P. Robust and numerically stable Bézier clippingmethod for ray tracing NURBS surfaces. In: The 21st Spring conference oncomputer graphics. New York: ACM Press; 2005. p. 127–35.

[8] Elber G, Kim M-S. Geometric constraint solver using multivariate rationalspline functions. In: The sixth ACM/IEEE symposium on solid modeling andapplications. Ann Arbor, Michigan; 2001. p. 1–10.

[9] Floater M. High order approximation of rational curves by polynomial curves.Comput Aided Geom Des 2006;23(8):621–8.

[10] Hook DG, McAree PR. Using Sturm sequences to bracket real roots ofpolynomial equations. In: Glassner AS, editor. Graphics gems I; 1990.p. 416–22.

[11] Isaacson E, Keller HB. Analysis of numerical methods. New York: Wiley; 1966.[12] Jaklič G, Kozak J, Krajnc M, Žagar E. On geometric interpolation by planar

parametric polynomial curves. Math Comput 2007;76(260):1981–93.[13] Jüttler B. The dual basis functions of the Bernstein polynomials. Adv Comput

Math 1998;8:345–52.[14] Lin M, Gottschalk S. Collision detection between geometric models: a survey.

In: Proceedings of the IMA conference on mathematics of surfaces. Birming-ham, UK; 1998. p. 37–56.

[15] Liu LG, Zhang L, Lin BB, Wang GJ. Fast approach for computing roots ofpolynomials using cubic clipping. Comput Aided Geom Des 2009;26:547–59.

[16] McNamee JM. Bibliographies on roots of polynomials. J Comp Appl Math1993–2002;47:391–4 p. 110, 305–306; 142, 433–434, available at: ⟨http://www1.elsevier.com/homepage/sac/cam/mcnamee/⟩.

[17] Mørken K, Reimers M. An unconditionally convergent method for computingzeros of splines and polynomials[J]. Math Comput 2007;76(258):845–65.

[18] Nishita T, Sederberg TW, Kakimoto M. Ray tracing trimmed rational surfacepatches. In: Proceedings of the Siggraph. ACM; 1990. p. 337–45.

[19] Patrikalakis N.M., Maekawa T ,Ko K.H, Mukundan H. Surface to surfaceintersections. Comput.-Aided Des. Appl. 2004, 1 (1-4):449-458.

[20] Reuter M, Mikkelsen T, Sherbrooke E, Maekawa T, Patrikalakis N. Solvingnonlinear polynomial systems in the barycentric Bernstein basis. Vis Comput2007;24(3):187–200.

Fig. 7. Example 5 (a triple root): (a) plots of the curve ðt; f ðtÞÞ in solid black and the reference curves in M2, M3 and Mn, respectively; (b) the error plots between f(t) and thecorresponding reference polynomials.

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–98 97

Page 10: A planar quadratic clipping method for computing a root of a polynomial in an interval

[21] Rouillier F, Zimmermann P. Efficient isolation of polynomial's real roots.J Comput Appl Math 2004;162(1):33–50.

[22] Scherer K. Parametric polynomial curves of local approximation of order 8. In:Cohen A, Rabut C, Schumaker LL, editors. Curve and surface fitting – SaintMalo 1999. Nashville: Vanderbilt University Press; 2000. p. 375–84.

[23] Sederberg TW, Nishita T. Curve intersection using Bézier clipping. Comput-Aided Des 1990;22(9):538–49.

[24] Schulz C. Bézier clipping is quadratically convergent. Comput Aided Geom Des2009;26(1):61–74.

X.-D. Chen, W. Ma / Computers & Graphics 46 (2015) 89–9898