Homotopy - Maple Help

RootFinding

 Homotopy
 find numerical approximations to roots of systems of polynomial equations

 Calling Sequence Homotopy(eqns, options)

Parameters

 eqns - set or list of polynomials options - (optional) equations of the form option=value where option is one of MaxPredictorSteps, MinimumStepSize, or Tolerance; control solution method

Description

 • The Homotopy(eqns, options) function finds isolated non-repeated roots of square systems of polynomial equations (that is, the zeros of the polynomials in eqns), returning them as a list.
 Homotopy attempts to find all isolated multiplicity one roots for the system of equations that are not part of a solution manifold.
 • The basic concepts used by the algorithm are straightforward.
 Computation of the roots is by a homotopy, which is a continuous map from a set of known solutions to the solutions of the input system. The known solutions are generated by Homotopy from a simple random start system.
 For an input system $\left\{{p}_{1}\left({x}_{1},{x}_{2},\phantom{\rule[-0.0ex]{0.5ex}{0.0ex}}\dots ,{x}_{n}\right),\phantom{\rule[-0.0ex]{0.5ex}{0.0ex}}\dots ,{p}_{n}\left({x}_{1},{x}_{2},\phantom{\rule[-0.0ex]{0.5ex}{0.0ex}}\dots ,{x}_{n}\right)\right\}$ and automatically generated random start system $\left\{{q}_{1}\left({x}_{1}\right),\phantom{\rule[-0.0ex]{0.5ex}{0.0ex}}\dots ,{q}_{n}\left({x}_{n}\right)\right\}$, this map is of the form $H\left(x,t\right)=\left\{\left(1-{\left(1-t\right)}^{2}\right){p}_{1}\left({x}_{1},{x}_{2},\phantom{\rule[-0.0ex]{0.5ex}{0.0ex}}\dots ,{x}_{n}\right)-{\left(1-t\right)}^{2}{q}_{1}\left({x}_{1}\right),\phantom{\rule[-0.0ex]{0.5ex}{0.0ex}}\dots ,\left(1-{\left(1-t\right)}^{2}\right){p}_{n}\left({x}_{1},{x}_{2},\phantom{\rule[-0.0ex]{0.5ex}{0.0ex}}\dots ,{x}_{n}\right)-{\left(1-t\right)}^{2}{q}_{n}\left({x}_{n}\right)\right\}$, which is called the homotopy system. When $t=0$, solutions of $H\left(x,0\right)$ are solutions of the generated system, and when $t=1$, solutions of $H\left(x,1\right)$ are solutions of the input system.
 Once this map is created, then follow each path from a known solution to a possible solution of the input system by varying $t$ from 0 to 1.
 Homotopy then differentiates the homotopy system, turning the problem into the integration of an ODE system over $t=0..1$. The path is then followed by discrete steps, using an ODE solution method as a predictor for each step, and an application of Newton's method as a corrector for each step, thus ensuring the computed solution stays on the path.
 • Potential difficulties include paths that are close at some time, or isolated roots that are close. The default for Homotopy is to compute the roots that it can obtain easily, and stop for more expensive roots indicating that the computation becomes too difficult for the current settings. These settings can be controlled through a number of options.
 • MaxPredictorSteps = M controls the maximum number of steps taken from $t=0..1$, and by default has a value of M=400. As an option, M must be in the range $10..\mathrm{\infty }$.
 • MinimumStepSize = m controls the smallest step that can be taken on any path before abandoning it. The default value is $1.×{10}^{-7}$, but can be set in the range $1.×{10}^{-9}..0.001$. The smaller the value, the harder Homotopy works.
 • Tolerance = tol is used as a partial criterion throughout the computation of a path for when the correction steps have sufficiently converged. It also has a second purpose, which is to provide a strict limit for the accuracy of the output isolated roots, in that these should satisfy the normalized input polynomials (that is, each polynomial is divided by the modulus of its largest coefficient) to within a maximum error of tol. The default value is $1.×{10}^{-8}$, but it can be set in the range $1.×{10}^{-14}..0.0001$. There is an additional constraint that the tolerance value $\mathrm{tol}$ must be smaller than 1/10 the minimum step size m.
 • In summary, the default settings are sufficient for many problems, but for difficult problems a combination of increasing the maximum number of predictor steps and decreasing the minimum step size and tolerance may produce the desired solutions when the default values are insufficient.
 • In addition, for cases in which only a few solutions are needed, these can be obtained more efficiently by increasing the minimum step size and tolerance.

Examples

 > $\mathrm{with}\left(\mathrm{RootFinding}\right)$
 $\left[{\mathrm{Analytic}}{,}{\mathrm{AnalyticZerosFound}}{,}{\mathrm{BivariatePolynomial}}{,}{\mathrm{EnclosingBox}}{,}{\mathrm{EvaluateAtRoot}}{,}{\mathrm{HasRealRoots}}{,}{\mathrm{Homotopy}}{,}{\mathrm{Isolate}}{,}{\mathrm{NextZero}}{,}{\mathrm{Parametric}}{,}{\mathrm{RefineRoot}}{,}{\mathrm{WitnessPoints}}\right]$ (1)

Intersection points of a hyperbola and circle:

 > $\mathrm{Homotopy}\left(\left[25xy-11,{x}^{2}+{y}^{2}-1\right]\right)$
 $\left[\left[{x}{=}{-0.5123603793}{-}{0.}{}{I}{,}{y}{=}{-0.8587705408}{+}{0.}{}{I}\right]{,}\left[{x}{=}{-0.8587705415}{-}{0.}{}{I}{,}{y}{=}{-0.5123603786}{+}{0.}{}{I}\right]{,}\left[{x}{=}{0.8587705415}{+}{0.}{}{I}{,}{y}{=}{0.5123603786}{-}{0.}{}{I}\right]{,}\left[{x}{=}{0.5123603793}{+}{0.}{}{I}{,}{y}{=}{0.8587705408}{-}{0.}{}{I}\right]\right]$ (2)

Random system:

 > $\mathrm{sys}≔\left\{\mathrm{randpoly}\left(\left[u,v\right],\mathrm{degree}=2\right),\mathrm{randpoly}\left(\left[u,v\right],\mathrm{degree}=3\right)\right\}$
 ${\mathrm{sys}}{≔}\left\{{-}{62}{}{{u}}^{{2}}{+}{97}{}{u}{}{v}{-}{73}{}{{v}}^{{2}}{-}{56}{}{u}{+}{87}{,}{71}{}{{u}}^{{3}}{-}{17}{}{u}{}{{v}}^{{2}}{+}{80}{}{{u}}^{{2}}{-}{44}{}{{v}}^{{2}}{+}{62}{}{u}{-}{82}{}{v}\right\}$ (3)
 > $\mathrm{sols1}≔\mathrm{Homotopy}\left(\mathrm{sys}\right)$
 ${\mathrm{sols1}}{≔}\left[\left[{u}{=}{-0.2140065340}{-}{0.7500992223}{}{I}{,}{v}{=}{-1.406179676}{-}{0.6741681736}{}{I}\right]{,}\left[{u}{=}{0.8468475365}{-}{0.}{}{I}{,}{v}{=}{1.062243147}{-}{0.}{}{I}\right]{,}\left[{u}{=}{-0.2140065344}{+}{0.7500992219}{}{I}{,}{v}{=}{-1.406179676}{+}{0.6741681732}{}{I}\right]{,}\left[{u}{=}{-1.069439412}{+}{0.}{}{I}{,}{v}{=}{-1.953758199}{+}{0.}{}{I}\right]{,}\left[{u}{=}{-1.064544629}{-}{0.8455148939}{}{I}{,}{v}{=}{0.6487441050}{-}{0.5933444492}{}{I}\right]{,}\left[{u}{=}{-1.064544629}{+}{0.8455148939}{}{I}{,}{v}{=}{0.6487441050}{+}{0.5933444492}{}{I}\right]\right]$ (4)
 > $\mathbf{for}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}i\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathbf{in}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathrm{sols1}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathbf{do}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{\mathrm{evalf}}_{20}\left(\mathrm{eval}\left(\mathrm{sys},i\right)\right)\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathbf{end do}$
 $\left\{{-6.465266131}{×}{{10}}^{{-8}}{-}{2.0357009682}{×}{{10}}^{{-8}}{}{I}{,}{3.6448225044}{×}{{10}}^{{-8}}{+}{1.8841671843}{×}{{10}}^{{-8}}{}{I}\right\}$
 $\left\{{-4.9664346603}{×}{{10}}^{{-8}}{+}{0.}{}{I}{,}{3.20577096702}{×}{{10}}^{{-7}}{+}{0.}{}{I}\right\}$
 $\left\{{4.75657086}{×}{{10}}^{{-9}}{+}{1.0616556201}{×}{{10}}^{{-8}}{}{I}{,}{8.1478504576}{×}{{10}}^{{-8}}{-}{1.5266867773}{×}{{10}}^{{-8}}{}{I}\right\}$
 $\left\{{-1.770939873}{×}{{10}}^{{-8}}{+}{0.}{}{I}{,}{-1.358429716}{×}{{10}}^{{-8}}{+}{0.}{}{I}\right\}$
 $\left\{{1.21639664}{×}{{10}}^{{-9}}{+}{1.31210215858}{×}{{10}}^{{-7}}{}{I}{,}{6.664198762}{×}{{10}}^{{-8}}{+}{2.3924219086}{×}{{10}}^{{-8}}{}{I}\right\}$
 $\left\{{1.21639664}{×}{{10}}^{{-9}}{-}{1.31210215858}{×}{{10}}^{{-7}}{}{I}{,}{6.664198762}{×}{{10}}^{{-8}}{-}{2.3924219086}{×}{{10}}^{{-8}}{}{I}\right\}$ (5)

Tighter tolerance:

 > $\mathrm{sols2}≔\mathrm{Homotopy}\left(\mathrm{sys},\mathrm{Tolerance}=1.{10}^{-12}\right)$
 ${\mathrm{sols2}}{≔}\left[\left[{u}{=}{-0.2140065347}{+}{0.7500992219}{}{I}{,}{v}{=}{-1.406179677}{+}{0.6741681731}{}{I}\right]{,}\left[{u}{=}{-1.064544629}{+}{0.8455148939}{}{I}{,}{v}{=}{0.6487441050}{+}{0.5933444492}{}{I}\right]{,}\left[{u}{=}{-1.069439412}{+}{0.}{}{I}{,}{v}{=}{-1.953758199}{+}{0.}{}{I}\right]{,}\left[{u}{=}{0.8468475356}{-}{0.}{}{I}{,}{v}{=}{1.062243147}{+}{0.}{}{I}\right]{,}\left[{u}{=}{-0.2140065347}{-}{0.7500992219}{}{I}{,}{v}{=}{-1.406179677}{-}{0.6741681731}{}{I}\right]{,}\left[{u}{=}{-1.064544629}{-}{0.8455148939}{}{I}{,}{v}{=}{0.6487441050}{-}{0.5933444492}{}{I}\right]\right]$ (6)
 > $\mathbf{for}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}i\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathbf{in}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathrm{sols2}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathbf{do}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{\mathrm{evalf}}_{20}\left(\mathrm{eval}\left(\mathrm{sys},i\right)\right)\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}\mathbf{end do}$
 $\left\{{-5.5873201710}{×}{{10}}^{{-8}}{+}{2.33098301}{×}{{10}}^{{-10}}{}{I}{,}{-1.333952708}{×}{{10}}^{{-8}}{-}{8.54076131}{×}{{10}}^{{-10}}{}{I}\right\}$
 $\left\{{1.21639664}{×}{{10}}^{{-9}}{-}{1.31210215858}{×}{{10}}^{{-7}}{}{I}{,}{6.664198762}{×}{{10}}^{{-8}}{-}{2.3924219086}{×}{{10}}^{{-8}}{}{I}\right\}$
 $\left\{{-1.770939873}{×}{{10}}^{{-8}}{+}{0.}{}{I}{,}{-1.358429716}{×}{{10}}^{{-8}}{+}{0.}{}{I}\right\}$
 $\left\{{2.510011687}{×}{{10}}^{{-9}}{+}{0.}{}{I}{,}{2.2617168569}{×}{{10}}^{{-8}}{-}{0.}{}{I}\right\}$
 $\left\{{-5.5873201710}{×}{{10}}^{{-8}}{-}{2.33098301}{×}{{10}}^{{-10}}{}{I}{,}{-1.333952708}{×}{{10}}^{{-8}}{+}{8.54076131}{×}{{10}}^{{-10}}{}{I}\right\}$
 $\left\{{1.21639664}{×}{{10}}^{{-9}}{+}{1.31210215858}{×}{{10}}^{{-7}}{}{I}{,}{6.664198762}{×}{{10}}^{{-8}}{+}{2.3924219086}{×}{{10}}^{{-8}}{}{I}\right\}$ (7)

References

 Allgower, E.L., and Georg, K.  "Numerical path following." Handbook of Numerical Analysis, Vol. 5. North-Holland, 1997.
 Verschelde, J. "Algorithm 795: PHCpack: A general-purpose solver for polynomial systems by homotopy continuation." Transactions on Mathematical Software, Vol. 25, No. 2 (1999): 251-276.