BivariatePolynomial - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


RootFinding

  

BivariatePolynomial

  

find the solutions of two or more bivariate polynomials

 

Calling Sequence

Parameters

Description

Options

Examples

References

Calling Sequence

BivariatePolynomial(fg, varlist, options)

Parameters

fg

-

set or list of two or more polynomials in two variables

varlist

-

list or set of two names; a list defines the order in the solutions pairs returned, a set requests output in the form {x=..,y=..}

options

-

(optional) equations of the form option=value where option is one of exact, verify, or verifyTol.

Description

• 

The BivariatePolynomial(fg, varlist, options) command solves the bivariate polynomials fg, in the case when there is only a finite number of solutions.  If there are an infinite number of solutions, this routine may fail.

• 

The routine performs a random orthogonal change of coordinates, takes a random linear combination of the two or more input polynomials to produce exactly two polynomials fx,y and gx,y.  It then constructs the Bezout matrix By of fx,y and gx,y with respect to x, and then the Companion matrix pencil of the matrix polynomial By.  It then solves the generalized eigenproblem for eigenvalues and eigenvectors of the pencil; the eigenvalues give the values of y, and the corresponding values of x are deduced from the eigenvectors.

  

If the option verify=true is given (the default), or if there are more than two input polynomials, each putative root is tested on the original polynomials to see if the residual is acceptably small. A residual is judged to be small enough if it is smaller than ilog[10](n+1)*verifyTol times the maxnorm of the polynomial, where n is the number of roots.  By default, verifyTol=Float(1,1-Digits). This default tolerance may be overridden by setting the option verifyTol=... in the call.

• 

The routine assumes that fx,y=gx,y=0 has only isolated simple roots. Multiple roots are, numerically, perturbed into clusters of simple roots by rounding errors in the process. In practice, if the multiplicity of the root is not too high (say not more than three) then the results may be acceptable. If, however, there are an infinite number of roots (i.e. the dimensionality of the variety is higher than zero), then this routine will fail.  Through rounding errors, a higher-dimensional system MAY be perturbed to a zero-dimensional system, and in this case pseudozeros are calculated and some information may be deduced about the true solutions by repeated solving; the differing random combinations will produce different pseudozeros that can be put together to get a partial picture of the higher- dimensional zero set.

• 

Exact solutions are sometimes possible, and may be attempted by specifying the option exact=true. In this case, the random combinations are done over the integers to avoid introducing rounding errors. In the case where the input coefficients are exact and the polynomials are not of too high a degree, this may give exact (though not necessarily useful) answers.

• 

Solutions obtained by BivariatePolynomial may be refined by use of fsolve.  See the examples.

Options

• 

The options argument can contain the following equation.

  

 

  

exact = true or false

  

If exact=true, the command performs the computation exactly (depending on Eigenvectors succeeding with an exact computation).

  

 

  

verify = true or false

  

If verify=true (the default), the command tests that the values of each input polynomial at each computed root is smaller than 10 ulps, where an ulp is a Unit in the Last Place, measured relative to the user's setting of Digits and a vector norm of the polynomial coefficients. If verify=false, this residual test is not performed and infinite and spurious roots are returned along with any genuine roots.

  

 

  

 

  

verifyTol = positive floating-point number for residual tolerance

  

If verifyTol is overridden, the residual test is passed if the residual is less than or equal to ilog[10](n+1)*verifyTol times a vector norm of the polynomial coefficients.

  

 

  

Note: The resultType = data_type option has been superseded by the exact option.

Examples

withRootFinding

Analytic,AnalyticZerosFound,BivariatePolynomial,EnclosingBox,EvaluateAtRoot,HasRealRoots,Homotopy,Isolate,NextZero,Parametric,RefineRoot,WitnessPoints

(1)

Exact answers (not usually useful)

BivariatePolynomial25uv12,u2+v21,u,v,exact=true

35,45,45,35,45,35,35,45

(2)

frandpolyx,y,degree=2,dense

f7x2+22xy94y255x+87y56

(3)

grandpolyx,y,degree=2,dense

g62xy73y2+97x4y83

(4)

Set output, and a large residual tolerance

BivariatePolynomialf,g,x,y,verifyTol=0.000010

x=−3.950351689443605.66623769360476I,y=1.583147105039790.669082838293886I,x=−3.95035168944360+5.66623769360475I,y=1.58314710503979+0.669082838293884I,x=0.2176561046410320.580098578671116I,y=0.2837606910546430.781752717215506I,x=0.217656104641038+0.580098578671126I,y=0.283760691054644+0.781752717215506I

(5)

A higher-degree example

frandpolyx,y,degree=3,dense

f10x3+62x2y+80xy217y382x244xy75y2+71x10y7

(6)

grandpolyx,y,degree=3,dense

g40x3+42x2y+23xy2+6y350x2+75xy+74y292x+72y+37

(7)

solsBivariatePolynomialf,g,x,y,verify=false:

finiteSolsselecttype,mapconvert,sols,set,setcomplexnumeric

finiteSols−8.72546491823764+1.35925353545860×10−17I,−0.804422190778388+3.34994664560768×10−18I,−1.61657845360198+1.76908763026871×10−13I,0.422070508744693+1.19857563106188×10−13I,−0.7865884116822481.14300482684492I,0.6041015492968620.622769842152083I,−0.786588411681959+1.14300482684388I,0.604101549296839+0.622769842152225I,−0.4535547554991601.18516902864060I,−0.278993622119871+1.39562033543789I,−0.453554755498933+1.18516902864131I,−0.2789936221204911.39562033543820I,−0.373755472345027+7.92945549673299×10−15I,0.1569922728185646.72289805687904×10−14I,0.237394982252642+1.13779271541314×10−14I,0.5466288530063229.64664526931731×10−14I,1.197761543057704.99381711787469×10−14I,1.96030291260013+5.12600673966412×10−13I

(8)

Refining the solutions by passing them as initial approximations to fsolve.

finiteSolsBivariatePolynomialf,g,x,y

finiteSols−0.804422190776780+1.46422793108841×10−13I,−8.725464918243241.63996064108809×10−12I,−0.4535547555023991.18516902863964I,−0.278993622115287+1.39562033544011I,−0.453554755497189+1.18516902864016I,−0.2789936221202921.39562033543835I,0.422070508744006+8.37039084916395×10−14I,−1.61657845360167+1.43001714671995×10−14I,−0.786588411674588+1.14300482683918I,0.604101549297744+0.622769842150686I,−0.7865884116757141.14300482684893I,0.6041015492975460.622769842152381I,1.96030291261380+1.18650982072347×10−11I,1.19776154306172+2.06586651483422×10−12I,0.546628853006201+9.53326896881672×10−13I,0.237394982252107+1.65986499189513×10−13I,0.1569922728184331.91316953588403×10−13I,−0.3737554723450413.33107473056885×10−14I

(9)

Digits30

Digits30

(10)

betterfsolvef,g,x=finiteSols51,y=finiteSols52

betterx=−0.804422190778384243337546951432,y=−8.72546491823766479368773875110

(11)

subsbetter,f,g

0.,3.×10−26

(12)

A one-dimensional variety, which causes BivariatePolynomial to fail: Note that many roots are found of the form x=1, y=anything (but not an infinite number), and the isolated roots are lost.

DigitstruncevalhfDigits

Digits15

(13)

fx2+y21x1

fx2+y21x1

(14)

g25xy12x1

g25xy12x1

(15)

BivariatePolynomialf,g,x,y,verifyTol=0.000010

1.00000000000001+0.I,−44.27928292203090.I,0.999999999999998+0.I,8.851575013024920.I,0.9999999999999982.28983498828939×10−16I,−0.352677478474666+1.00257635649826I,0.999999999999998+1.80411241501588×10−16I,−0.3567646308424460.997039491465078I,1.000000000000022.88262252609583×10−16I,0.4815844615935180.00389300631624244I

(16)

Another example, worse in that the multiplicity is higher.

fx32xy6

fx32xy6

(17)

gx32y+1

gx32y+1

(18)

BivariatePolynomialf,g,x,y,verifyTol=0.010

x=1.614449031480440.I,y=0.763898897286967+0.I

(19)

Correct solutions are not always returned. Doing it again may produce different output (because of the randomness)

BivariatePolynomialf,g,x,y,verifyTol=0.010

x=2.738144364359340.725571745406410I,y=1.45312067994126+0.828323525015386I,x=3.297827877201060.409284725291712I,y=1.348030302261280.615234355186775I

(20)

BivariatePolynomialf,g,x,y,verifyTol=0.010

x=3.568999941051811.61302716647830I,y=−0.4305987601494430.0959828272717515I

(21)

BivariatePolynomialf,g,x,y,verifyTol=0.010

x=2.201989346638330.00971969562366036I,y=−8.50553116114323+0.00889436395203620I,x=2.71283424639345+0.0000968297360482233I,y=−5.762725322385800.0000886076010987100I,x=4.18582785348240+0.518458807889304I,y=−0.914609115095914+1.74179987404571I,x=4.185879355135980.519028264653766I,y=−0.9146562435725901.74127877174821I

(22)

BivariatePolynomialf,g,x,y,verifyTol=0.010

x=1.73929994257694+0.212413901689147I,y=−0.554498533677898+1.03622687896322I,x=0.0575672432947175+0.243286301423028I,y=−1.439666974293960.0176580709281279I,x=0.6700623631795500.783148116579887I,y=−0.6420813911401701.17185083506937I

(23)

Digits30

Digits30

(24)

BivariatePolynomialf,g,x,y,verifyTol=0.010

References

  

Barnett, Stephen. Polynomials and Linear Control Systems. Deffer, 1983.

  

Manocha, Dinesh. "Numerical methods for solving polynomial equations, in Applications of Computational Geometry." AMS proceedings of applied mathematics, Vol. 53. 1998.

See Also

fsolve

LinearAlgebra[BezoutMatrix]

LinearAlgebra[CompanionMatrix]

LinearAlgebra[Eigenvectors]

RootFinding

select

solve

type