Solving Polynomial Equations and Applications
Solving Polynomial Equations and Applications
Simon Telen
arXiv:2210.04939v1 [math.AG] 10 Oct 2022
Abstract
These notes accompany an introductory lecture given by the author at the workshop
on solving polynomial equations & applications at CWI Amsterdam in the context of the
2022 fall semester programme on polynomial optimization & applications. We introduce
systems of polynomial equations and the main approaches for solving them. We also
discuss applications and solution counts. The theory is illustrated by many examples.
1
Figure 1: Algebraic curves in the plane (n = 2) and an algebraic surface (n = 3).
Pn
Example 1.2 (Linear equations). When fi = j=1 aij xj − bi are given by affine-linear
functions, (1) is a linear system of the form Ax = b, with A ∈ K s×n , b ∈ K s .
Examples 1.1 and 1.2 show that, after a trivial rewriting step, the univariate and affine-
linear cases are reduced to a linear algebra problem. Here, we are mainly interested in the
case where n > 1, and some equations are of higher degree in the variables x. Such systems
require tools from nonlinear algebra [34]. We proceed with an example in two dimensions.
Example 1.3 (Intersecting two curves in the plane). Let K = Q and n = s = 2. We work
in the ring R = Q[x, y] and consider the system of equations f (x, y) = g(x, y) = 0 where
Geometrically, we can think of f (x, y) = 0 as defining a curve in the plane. This is the red
curve shown in Figure 1. The curve defined by g(x, y) = 0 is shown in blue. The set of
2
solutions of f = g = 0 consists of points (x, y) ∈ Q satisfying f (x, y) = g(x, y) = 0. These
2
are the intersection points of the two curves. There are seven such points in Q , of which
two lie in Q2 . These are the points (0, 0) and (1, 1). Note that all seven solutions are real.
replacing Q by K = R, we count as many solutions over K as over K = C.
The set of solutions of the polynomial system (1) is called an affine variety. We denote
n
this by VK (f1 , . . . , fs ) = {x ∈ K | f1 (x) = · · · = fs (x) = 0}, and replace K by K in this
notation to mean only the solutions over the ground field. Examples of affine varieties are
the red curve VK (f ) and the set of black dots VK (f, g) in Example 1.3. In the case of VK (f ),
Figure (1) only shows the real part VK (f ) ∩ R2 of the affine variety.
2
Example 1.4 (Surfaces in R3 ). Let K = R and consider the affine variety V = VC (f ) where
Its real part VR (f ) is the surface shown in the right part of Figure 1. The variety V is called
the Clebsch surface. It is a cubic surface because it is defined by an equation of degree three.
Note that f is invariant under permutations of the variables, i.e. f (x, y, z) = f (y, x, z) =
f (z, y, x) = f (x, z, y) = f (z, x, y) = f (y, z, x). This reflects in symmetries of the surface
VR (f ). Many polynomials from applications have similar symmetry properties. Exploiting
this in computations is an active area of research, see for instance [28].
More pictures of real affine varieties can be found, for instance, in [16, Chapter 1, §2],
or in the algebraic surfaces gallery hosted at https://homepage.univie.ac.at/herwig.
hauser/bildergalerie/gallery.html.
We now briefly discuss commonly used fields K. In many engineering applications, the
coefficients of f1 , . . . , fs live in R or C. Computations in such fields use floating point
arithmetic, yielding approximate results. The required quality of the approximation depends
on the application. Other fields show up too: polynomial systems in cryptography often
use K = Fq , see for instance [39]. Equations of many prominent algebraic varieties have
integer coefficients, i.e. K = Q. Examples are determinantal varieties (e.g. the variety of
all 2 × 2 matrices of rank ≤ 1), Grassmannians in their Plücker embedding [34, Chapter 5],
discriminants and resultants [44, Sections 3.4, 5.2] and toric varieties obtained from monomial
maps [45, Section 2.3]. In number theory, one is interested in studying rational points
VQ (f1 , . . . , fs ) ⊂ VQ (f1 , . . . , fs ) on varieties defined over Q. Recent work in this direction
for del Pezzo surfaces can be found in [35, 17]. Finally, in tropical geometry, coefficients
come from valued fields such as the p-adic numbers Qp or Puiseux series C{{t}} [32]. Solving
over the field of Puiseux series is also relevant for homotopy continuation methods, see [44,
Section 6.2.1]. We end the section with two examples highlighting the difference between
VK (f1 , . . . , fs ) and VK (f1 , . . . , fs ).
Example 1.5 (Fermat’s last theorem). Let k ∈ N \ {0} be a positive integer and consider
the equation f = xk + y k − 1 = 0. For any k, the variety VQ (f ) has infinitely many solutions
2
in Q . For k = 1, 2, there are infinitely many solutions in Q2 . For k ≥ 3, the only solutions
in Q2 are (1, 0), (0, 1) and, when k is even, (−1, 0), (0, −1).
Example
√ 1.6 (Computing
√ real solutions). The variety VC (x2 + y 2 ) consists of the two lines
x + −1 · y = 0 and x − −1 · y = 0 in C . However, the real part VR (x2 + y 2 ) = {(0, 0)} has
2
only one point. If we are interested only in this real solution, we may replace x2 + y 2 by the
two polynomials x, y, which have the property that VR (x2 + y 2 ) = VR (x, y) = VC (x, y). An
algorithm that computes all complex solutions will still recover only the interesting solutions,
after this replacing step. It turns out that such a ‘better’ set of equations can always be
computed. The new polynomials generate the real radical ideal associated to the original
equations [34, Section 6.3]. For recent computational progress, see for instance [1].
3
2 Applications
Polynomial equations appear in many fields of science and engineering. Some examples are
molecular biology [22], computer vision [29], economics and game theory [42, Chapter 6],
topological data analysis [9] and partial differential equations [42, Chapter 10]. For an
overview and more references, see [14, 10]. In this section, we present a selection of other
applications in some detail. Much of the material is taken from [44, Section 1.2].
min g(x1 , . . . , xk ),
x∈Rk (4)
subject to h1 (x1 , . . . , xk ) = · · · = h` (x1 , . . . , xk ) = 0.
Y = {x ∈ Rk | h1 = · · · = h` = 0}.
Consider the optimization problem (4) given by these data. The solution x∗ is the point on
Y that’s closest to y. The number of complex solutions of (5) is called the Euclidean distance
degree of Y [19]. For a summary and examples, see [43, Section 2].
Example 2.2 (Parameter estimation for system identification). System identification is an
engineering discipline that aims at constructing models for dynamical systems from measured
data. A model explains the relation between input, output, and noise. It depends on a set of
model parameters, which are selected to best fit the measured data. A discrete time, single-
input single-output linear time invariant system with input sequence u : Z → R, output
sequence y : Z → R and white noise sequence e : Z → R is often modeled by
B1 (q) C1 (q)
A(q) y(t) = u(t) + e(t).
B2 (q) C2 (q)
4
Here A, B1 , B2 , C1 , C2 ∈ C[q] are unknown polynomials of a fixed degree in the backward
shift operator q, acting on s : Z → R by qs(t) = s(t − 1). The model parameters are the
coefficients of these polynomials, which are to be estimated. Clearing denominators gives
Suppose we have measured u(0), . . . , u(N ), y(0), . . . , y(N ). Then we can find algebraic rela-
tions among the coefficients of A, B1 , B2 , C1 , C2 by writing (6) down for t = d, d + 1, . . . , N
where d = max(dA + dB2 + dC2 , dB1 + dC2 , dB2 + dC1 ) and dA , dB1 , dB2 , dC1 , dC2 are the degrees
of our polynomials. The model parameters are estimated by solving
A+B
κ1
31
κ
2
κ2
1
κ23
D C
The parameters κ12 , κ21 , κ31 , κ23 ∈ R>0 are the reaction rate constants. Let xA , xB , xC , xD
denote the time dependent concentrations of the species A, B, C, D respectively. The law of
mass action gives the relations
dxA dxB
fA = = −κ12 xA xB + κ21 xC + κ31 xD , fB = = −κ12 xA xB + κ21 xC + κ31 xD ,
dt dt
dxC dxD
fC = = κ12 xA xB − κ21 xC − κ23 xC , fD = = κ23 xC − κ31 xD .
dt dt
The set {(xA , xB , xC , xD ) ∈ (R>0 )4 | fA = fB = fC = fD = 0} is called the steady state
variety of the chemical reaction network. By the structure of the equations, for given initial
concentrations, the solution (xA , xB , xC , xD ) cannot leave its stoichiometric compatibility
class, which is an affine subspace of (R>0 )4 . Adding the affine equations of the stoichiometric
compatibility class to the system, we get the set of all candidate steady states. In this
application, we are interested in positive solutions, rather than real solutions. It is important
to characterize parameter values for which there is a unique positive solution, see [37].
5
Figure 2: The two configurations of a robot arm are the intersection points of two circles.
2.3 Robotics
We present a simple example of how polynomial equations arise in robotics. Consider a
planar robot arm whose shoulder is fixed at the origin (0, 0) in the plane, and whose two arm
segments have fixed lengths L1 and L2 . Our aim is to determine the possible positions of
the elbow (x, y), given that the hand of the robot touches a given point (a, b). The situation
is illustrated in Figure 2. The Pythagorean theorem gives the identities
3 Number of solutions
It is well known that a univariate polynomial f ∈ C[x] of degree d has at most d roots in C.
Moreover, d is the expected number of roots, in the following sense. Consider the family
of polynomials of degree at most d. There is an affine variety ∇d ⊂ Cd+1 , such that all
f ∈ F(d) \ ∇d have precisely d roots in C. Here ∇d = VC (∆d ), where ∆d is a polynomial in
the coefficients ai of f ∈ F(d). Equations for small d are
∆1 = a1 ,
∆2 = a2 · (a21 − 4 a0 a2 ),
∆3 = a3 · (a21 a22 − 4 a0 a32 − 4 a31 a3 + 18 a0 a1 a2 a3 − 27 a20 a23 ),
∆4 = a4 · (a21 a22 a23 − 4 a0 a32 a23 − 4 a31 a33 + 18 a0 a1 a2 a33 + · · · + 256 a30 a34 ).
6
Notice that ∆d = ad · ∆ e d , where ∆
e d is the discriminant for degree d polynomials. There
exist similar results for families of polynomial systems with n > 1, which bound the number
of isolated solutions from above by the expected number. This section states some of these
results. The field K = K is algebraically closed throughout the section.
Rd = {f ∈ R : deg(f ) ≤ d}, d ≥ 0.
Theorem 3.1 (Bézout). For any F = (f1 , . . . , fn ) ∈ F(d1 , . . . , dn ), the number of isolated
solutions of f1 = · · · = fn = 0, i.e., the number of isolated points in VK (F ), is at most
d1 · · · dn . Moreover, there exists a proper subvariety ∇d1 ,...,dn ( K D such that, when F ∈
F(d1 , . . . , dn ) \ ∇d1 ,...,dn , the variety VK (F ) consists of precisely d1 · · · dn isolated points.
The proof of this theorem can be found in [21, Theorem III-71]. As in our univariate
example, the variety ∇d1 ,...,dn can be described using discriminants and resultants. See for
instance the discussion at the end of [44, Section 3.4.1]. Theorem 3.1 is an important result
and gives an easy way to bound the number of isolated solutions of a system of n equations
in n variables. The bound is almost always tight, in the sense that the only systems with
fewer solutions lie in ∇d1 ,...,dn . Unfortunately, many systems coming from applications lie
inside ∇d1 ,...,dn . For instance, the system (7) with K = C lies in ∇2,2 , by the fact that the
two real solutions seen in 2 are the only complex solutions, and 2 < d1 · d2 = 4. One also
checks that for f, g as in Example 1.3, we have (f, g) ∈ ∇3,3 ⊂ F(3, 3) (use K = Q).
Remark 3.2. Bézout’s theorem more naturally counts solutions in projective space PnK , and
it accounts for solutions with multiplicity > 1. More precisely, if fi ∈ H 0 (PnK , OPnK (di )) is a
homogeneous polynomial in n + 1 variables of degree di , and f1 = · · · = fn = 0 has finitely
many solutions in PnK , the number of solutions (counted with multiplicity) is always d1 · · · dn .
We encourage the reader who is familiar with projective geometry to check that (7) defines
two solutions at infinity, when each of the equations is viewed as a global section of OP2C (2).
7
3.2 Kushnirenko’s theorem
An intuitive consequence of Theorem 3.1 is that random polynomial systems given by poly-
nomials of fixed degree always have the same number of solutions. Looking at f and g from
Example 1.3, we see that they do not look so random, in the sense that some monomials
of degree ≤ 3 are missing. For instance, x3 and y 3 do not appear. Having zero coefficients
standing with some monomials in F(d1 , . . . , dn ) is sometimes enough to conclude that the
system lies in ∇d1 ,...,dn . That is, the system isPnot random in the sense of Bézout’s theorem.
The (monomial) support supp(f ) of f = α cα xα is the set of exponents appearing in f :
!
X
supp cα xα = {α : cα 6= 0} ⊂ Nn .
α
This subsection considers families of polynomial systems whose equations have a fixed sup-
port. Let A ⊂ Nn be a finite subset of exponents in Nn of cardinality |A|. We define
8
y2 xy 2
y xy x2 y
x x2
Remark 3.6. The analogue of Remark 3.2 for Theorem 3.3 is that vol(A) counts solutions on
the projective toric variety XA associated to A. It equals the degree of XA in its embedding
|A|−1
in PK (after multiplying with a lattice index). When A is as in Example 3.4, we have
XA = Pn . A toric proof of Kushnirenko’s theorem and examples are given in [45, Section 3.4].
Remark 3.7. The convex polytope Conv(supp(f )) is called the Newton polytope of f . Its
importance goes beyond counting solutions: it is dual to the tropical hypersurface defined
by f , which is a combinatorial shadow of VK (f ) ∩ (K \ {0})n [32, Proposition 3.1.6].
where D = |A1 | + · · · + |An |. The number of solutions is characterized by the mixed volume
of A1 , . . . , An , which we now define. The Minkowski sum S + T of two sets S, T ⊂ Rn is
{s + t : s ∈ S, t ∈ T }, where s + t is the usual addition of vectors in Rn . For a nonnegative
real number λ, the λ-dilation of S ⊂ Rn is λ · S = {λ · s : s ∈ S}, where λ · s is the usual
scalar multiplication in Rn . Each of the supports Ai gives a convex polytope Conv(Ai ) as
in (9). The function Rn≥0 → R≥0 given by
is a homogeneous polynomial of degree n, meaning that all its monomials have degree n [15,
Chapter 7, §4, Proposition 4.9]. The mixed volume MV(A1 , . . . , An ) is the coefficient of that
polynomial standing with λ1 · · · λn . Note that MV(A, . . . , A) = vol(A).
Theorem 3.8 (Bernstein-Kushnirenko). For any F = (f1 , . . . , fn ) ∈ F(A1 , . . . , An ), the
number of isolated solutions of f1 = · · · = fn = 0 in (K \ {0})n , i.e., the number of isolated
points in VK (F ) ∩ (K \ {0})n , is at most MV(A1 , . . . , An ). Moreover, there exists a proper
9
Figure 4: The green area counts the solutions to equations with support in P1 , P2 .
subvariety ∇A1 ,...,An ⊂ K D such that, when F ∈ F(A1 , . . . , An )\∇A1 ,...,An , VK (F )∩(K \{0})n
consists of precisely MV(A1 , . . . , An ) isolated points.
This theorem was originally proved by Bernstein for K = C in [6]. The proof by Kush-
nirenko in [30] works for algebraically closed fields. Several alternative proofs were found by
Khovanskii. Theorem 3.8 is sometimes called the BKK theorem, after the aforementioned
mathematicians. Like Kushnirenko’s theorem, Theorem 3.8 can be adapted to count roots
in K n rather than (K \ {0})n [27], and if 0 ∈ Ai for all i, one may replace (K \ {0})n by K n .
f = a0 + a1 x3 y + a2 xy 3 , g = b0 + b1 x 2 + b2 y 2 + b3 x 2 y 2 .
Theorem 3.8 provides an upper bound on the number of isolated solutions to any system
of polynomial equations with n = s. Although it improves significantly on Bézout’s bound for
many systems, it still often happens that the bound is not tight for systems in applications.
That is, one often encounters systems F ∈ ∇A1 ,...,An . Even more refined root counts exist,
such as those based on Khovanskii bases. In practice, with today’s computational methods
(see Section 4), we often count solutions reliably by simply solving the system. Certification
methods provide a proof for a lower bound on the number of solutions [11]. The actual
number of solutions is implied if one can match this with a theoretical upper bound.
10
4 Computational methods
We give a brief introduction to two of the most important computational methods for solving
polynomial equations. The first method uses normal forms, the second is based on homotopy
continuation. We keep writing F = (f1 , . . . , fs ) = 0 for the system we want to solve. We
require s ≥ n, and assume finitely many solutions over K. All methods discussed here
compute all solutions over K, so we will assume that K = K is algebraically closed. An
important distinction between normal forms and homotopy continuation is that the former
works over any field K, while the latter needs K = C. If the coefficients are contained in
a subfield (e.g. R ⊂ C), a significant part of the computation in normal form algorithms
can be done over this subfield. Also, homotopy continuation is most natural when n = s,
whereas s > n is not so much a problem for normal forms. However, if K = C and n = s,
continuation methods are extremely efficient and can compute millions of solutions.
11
δ × δ matrix. Such matrices are called multiplication matrices. The eigenvalue relation in
the proof of Theorem 4.1 reads more familiarly as wi> Mg = g(zi ) · wi> . Theorem 4.1 suggests
to break up the task of computing VK (I) = {z1 , . . . , zδ } into two parts:
(A) Compute multiplication matrices Mg and
These are the coefficients in the unique expansion of [f ] = δj=1 cj (f ) · [bj ] in our basis. The
P
K-linear map N : R → B which sends f to δj=1 cj (f ) · bj is called a normal form. Its key
P
property is that N projects R onto B along I, meaning that N ◦N = N (N|B is the identity),
and ker N = I. The multiplication map Mg : B → B is simply given by Mg (b) = N (g · b).
More concretely, the i-th column of the matrix representation of Mg contains the coefficients
cj (g · bi ), j = 1, . . . , δ of N (g · bi ). Here is a familiar example.
Example 4.2. Let I = hf i = hc0 + c1 x + · · · + cd xd i be the ideal generated by the univariate
polynomial f ∈ K[x] in Example 1.1. For general ci , there are δ = d roots with multiplicity
one, hence I is radical. The dimension dimK K[x]/I equals d, and a canonical choice of basis
is {[1], [x], . . . , [xd−1 ]}. Let us construct the matrix Mx in this basis. That is, we set g = x.
We compute the normal forms N (x · xi−1 ), i = 1, . . . , d:
One checks this by verifying that xi −N (xi ) ∈ hf i. The coefficient vectors cj (xi ), j = 1, . . . , d
of the N (xi ) are precisely the columns of the companion matrix Cf . We conclude that
Mx = Cf and Theorem 4.1 confirms that the eigenvalues of Cf are the roots of f .
Computing normal forms can be done using linear algebra on certain structured matrices,
called Macaulay matrices. We illustrate this with an example from [47].
Example 4.3. Consider the ideal I = hf, gi ⊂ Q[x, y] given by f = x2 + y 2 − 2, g = 3x2 −
y 2 − 2. The variety VQ (I) = VQ (I) consists of four points {(−1, −1), (−1, 1), (1, −1), (1, 1)},
12
as predicted by Theorem 3.1. We construct a Macaulay matrix whose rows are indexed by
f, xf, yf, g, xg, yg, and whose columns are indexed by all monomials of degree at most 3:
x3 x2 y xy 2 y3 x2 y2 1 x y xy
f 1 1 −2
xf 1
1 −2
yf 1 1 −2
M= .
g
3 −1 −2
xg 3 −1 −2
yg 3 −1 −2
The first row reads f = 1 · x2 + 1 · y 2 − 2 · 1. A basis for Q[x, y]/I is {[1], [x], [y], [xy]}. These
monomials index the last four columns. We now invert the leftmost 6 × 6 block and apply
this inverse from the left to M :
x3 x2 y xy 2 y3 x2 y2 1 x y xy
x3 −x 1 −1
x2 y−y
1 −1
xy 2 −x 1 −1
M̃ = .
y 3 −y
1 −1
x2 −1 1 −1
y 2 −1 1 −1
The rows of M̃ are linear combinations of the rows of M, so they represent polynomials in
I. The first row reads x3 − 1 · x ∈ I. Comparing this with (10), we see that we have found
that the normal form of x3 is x. Using the information in M̃ we can construct Mx and My :
[x] [x2 ] [xy] [x2 y] [y] [xy] [y 2 ] [xy 2 ]
[1] 0 1 0 0 [1] 0 0 1 0
[x] 1 0 0 0 [x] 0 0 0 1
Mx =
0
, My = .
[y] 0 0 1 [y] 1 0 0 0
[xy] 0 0 1 0 [xy] 0 1 0 0
Remark 4.4. The entries of a Macaulay matrix M are the coefficients of the polynomials
f1 , . . . , fs . An immediate consequence of the fact that normal forms are computed using
linear algebra on Macaulay matrices, is that when the coefficients of fi are contained in a
subfield K̃ ⊂ K, all computations in step (A) can be done over K̃. That is assuming the
polynomials g for which we want to compute Mg have coefficients in K̃.
As illustrated in Example 4.3, to compute the matrices Mg it is sufficient to determine
the restriction of the normal form N : R → B to a finite dimensional K-vector space V ⊂ R,
containing g · B. The restriction N|V : V → B is called a truncated normal form, see [46]
and [44, Chapter 4]. The dimension of the space V counts the number of columns of the
Macaulay matrix.
Usually, one chooses the basis elements bj of B to be monomials, and g to be a coordinate
function xi . The basis elements may arise, for instance, as standard monomials from a
Gröbner basis computation. We briefly discuss this important concept.
13
4.1.1 Gröbner bases.
Gröbner bases are a powerful tool for symbolic computations in algebraic geometry. A nice
way to motivate their definition is by thinking of Euclidean division as a candidate for a
normal form map. In the case n = 1 from Example 4.2, this rewrites g ∈ K[x] as
Clearly [g] = [r] in K[x]/hf i, and r ∈ B = spanK (1, x, . . . , xd−1 ) implies that N (g) = r.
To generalize this to n > 1 variables, we fix a monomial order on R = K[x1 , . . . , xn ]
and write LT(f ) for the leading term of f with respect to . The reader who is not familiar
with monomial orders can consult [16, Chapter 2, §2]. As above, let I = hf1 , . . . , fs i ⊂ R be
a radical ideal such that |VK (I)| = δ < ∞. As basis elements b1 , . . . , bδ of B ' R/I, we use
the δ –smallest monomials which are linearly independent modulo our ideal I. They are
also called standard monomials. By [16, Chapter 9, §3, Theorem 3], there exists an algorithm
which, for any input g ∈ R, computes q1 , . . . , qs , r ∈ R such that
g = q1 · f1 + · · · + qs · fs + r, where LT(fi ) does not divide any term of r, for all i. (12)
This algorithm is called multivariate Euclidean division. Note how the condition “LT(fi )
does not divide any term of r, for all i” generalizes deg(r) < d in (11). From (12), it is clear
that [g] = [r]. However, we do not have r ∈ B in general. Hence, unfortunately, sending g to
its remainder r is usually not a normal form. . . but it is when f1 , . . . , fs is a Gröbner basis!
A set of polynomials g1 , . . . , gk ∈ I forms a Gröbner basis of the ideal I if the leading
terms LT(g1 ), . . . , LT(gk ) generate the leading term ideal hLT(g) : g ∈ Ii. We point out
that no finiteness of VK (I) or radicality of I is required for this definition. The remainder
r in g = q1 · g1 + · · · + qk · gk + r where LT(fi ) does not divide any term of r, for all i, now
satisfies [g] = [r] and r ∈ B. This justifies the following claim:
is generated by those elements of our Gröbner basis which involve only the first j variables,
see [16, Chapter 3, §1, Theorem 2]. In our case, a consequence is that one of the gi is
univariate in x1 , and its roots are the x1 -coordinates of z1 , . . . , zδ . The geometric counterpart
of computing the j-th elimination ideal is projection onto a j-dimensional coordinate space:
the variety VK (Ij ) ⊂ K j is obtained from VK (I) ⊂ K n by forgetting the final n−j coordinates
(x1 , . . . , xn ) 7→ (x1 , . . . , xj ) and taking the closure of the image. Here are two examples.
14
Example 4.5. To the right we show a blue curve in
R3 defined by an ideal I ⊂ R[x, y, z]. Its Gröbner basis
with respect to the lex ordering x ≺ y ≺ z contains
g1 ∈ R[x, y], which generates I2 . The variety VR (I2 ) =
VR (g1 ) ⊂ R2 is the orange curve seen in the picture.
Example 4.6. In [35], the authors study del Pezzo surfaces of degree 4 in P4 with defining
equations x0 x1 − x2 x3 = a0 x20 + a1 x21 + a2 x22 + a3 x23 + a4 x24 = 0. We will substitute x4 =
1 − x0 − x1 − x2 − x3 to reduce to the affine case. It is claimed that the smooth del Pezzo
surfaces of this form are those for which the parameters a0 , . . . , a4 lie outside the hypersurface
H = {a0 a1 a2 a3 a4 (a0 a1 − a2 a3 ) = 0}. This hypersurface is the projection of the variety
( 3 3
)
2
X X
(a, x) ∈ Q5 × Q4 : x0 x1 − x2 x3 = ai x2i + a4 1 −
xi = 0 and rank(J) < 2
i=0 i=0
onto Q5 . Here J is the 2 × 4 Jacobian matrix of our two equations with respect to the 4
variables x0 , x1 , x2 , x3 . The defining equation of H is computed in Macaulay2 [24] as follows:
R = QQ[x_0..x_3,a_0..a_4]
x_4 = 1-x_0-x_1-x_2-x_3
I = ideal( x_0*x_1-x_2*x_3 , a_0*x_0^2 + a_1*x_1^2 + a_2*x_2^2 + a_3*x_3^2 + a_4*x_4^2 )
M = submatrix( transpose jacobian I , 0..3 )
radical eliminate( I+minors(2,M) , {x_0,x_1,x_2,x_3} )
Remark 4.7. In a numerical setting, it is better to use border bases or more general bases
to avoid the amplification of rounding errors. Border bases use basis elements bi for B whose
elements satisfy a connectedness property, see for instance [36] for details. They do not
depend on a monomial order. For a summary and comparison between Gröbner bases and
border bases, see [44, Sections 3.3.1, 3.3.2]. Recently, in truncated normal form algorithms,
bases are selected adaptively by numerical linear algebra routines, such as QR decomposition
with optimal column pivoting or singular value decomposition. This often yields a significant
improvement in terms of accuracy. See for instance Section 7.2 in [47].
15
10
Im(x)
0
−5
−10
1
0.5
0 15 10 5 0 −5
t
Re(x)
More formally, if H(x; t) = (h1 (x; t), . . . , hn (x; t)) is a homotopy with t ∈ [0, 1], the
solutions describe continuous paths x(t) satisfying H(x(t); t) = 0. Taking the derivative
with respect to t gives the Davidenko differential equation
dH(x(t), t) ∂H ∂hj
= Jx · ẋ(t) + (x(t), t) = 0, with Jx = . (13)
dt ∂t ∂xi j,i
16
method. This typically leads to a discretization of the solution path, see the blue dots in
Figure 5. The solutions of the target system f1 = · · · = fn = 0 are obtained by evaluating
the solution paths at t = 1. The following are important practical remarks.
Avoid the discriminant. Each of the families seen in Section 3 has a subvariety ∇F ⊂ F
consisting of systems with non-generic behavior in terms of their number of solutions. This
subvariety is sometimes referred to as the discriminant of F, for reasons alluded to in the
beginning of Section 3. When the homotopy H(x; t) crosses ∇F , i.e. H(x; t∗ ) ∈ ∇F for some
t∗ ∈ [0, 1), two or more solution paths collide at t∗ , or some solution paths diverge. This
is not allowed for the numerical solution of (13). Fortunately, crossing ∇F can be avoided.
The discriminant ∇F has complex codimension at least one, hence real codimension at least
two. Since the homotopy t 7→ H(x; t) describes a one-real-dimensional path in F, it is always
possible to go around the discriminant. See for instance [41, Section 7]. When the target
system F belongs to the discriminant, end games are used to deal with colliding/diverging
paths at t = 1 [41, Section 10]. Note that this discussion implies that the number of paths
tracked in a homotopy algorithm equals the generic number of solutions of the family F. In
that sense, results like Theorems 3.1, 3.3 and 3.8 characterize the complexity of homotopy
continuation in the respective families.
Predict and correct. Naively applying ODE methods for solving the Davidenko equation
(13) is not the best we can do. Indeed, we have the extra information that the solution
paths x(t) satisfy the implicit equation H(x(t), t) = 0. This is typically used to improve
the accuracy of the ODE solver in each step. Given an approximation of x(t∗ ) at any fixed
t∗ ∈ [0, 1) and a step size 0 < ∆t 1, one approximates x(t∗ + ∆t) by x̃ using, for
instance, a step of Euler’s method. This is called the predictor step. Then, one refines x̃ to a
satisfactory approximation of x(t∗ + ∆t) by using x̃ as a starting point for Newton iteration
on H(x, t∗ + ∆t) = 0. This is the corrector step. The two-step process is illustrated in Figure
6 (predict in orange, correct in green, solution paths x(t) in blue). In the right part of the
figure, the predict-correct procedure goes wrong: because of a too large step size ∆t in the
predictor step, the Newton correction converges to a different path. This phenomenon is
called path jumping, and to avoid it one must choose the stepsize ∆t carefully and adaptively.
Recent work in this direction uses Padé approximants, see [48, 49].
Start systems in practice. There are recipes for start systems in the families F from
Section 3. For instance, we use G = (xd11 − 1, . . . , xdnn − 1) for F(d1 , . . . , dn ). The d1 · · · dn
solutions can easily be written down. Note that G ∈ / ∇d1 ,...,dn by Theorem 3.1. For the
families F(A) and F(A1 , . . . , An ), an algorithm to solve start systems was developed in [26].
For solving start systems of other families, one may use monodromy loops [20].
17
Figure 6: Predictor and corrector steps in numerical continuation. Beware of path jumping.
homotopy continuation to compute lines on the Clebsch surface from Example 1.4. This
particular surface is famous for the fact that all its 27 lines are real. Let f (x, y, z) be as in
(3). A line in R3 parameterized by (a1 + t · b1 , a2 + t · b2 , a3 + t · b3 ) is contained in our Clebsch
surface if and only if f (a1 + t · b1 , a2 + t · b2 , a3 + t · b3 ) ≡ 0. The left hand side evaluates to
a cubic polynomial in t with coefficients in the ring Z[a1 , a2 , a3 , b1 , b2 , b3 ] = Z[a, b]:
f ( a1 + t · b1 , a2 + t · b2 , a3 + t · b3 ) = f1 (a, b) · t3 + f2 (a, b) · t2 + f3 (a, b) · t + f4 (a, b).
The lines contained in the Clebsch surface satisfy
f1 (a, b) = f2 (a, b) = f3 (a, b) = f4 (a, b) = 0. (14)
We further reduce this to a system of s = 4 equations in n = 4 unknowns by removing
the redundancy in our parameterization of the line: we may impose a random affine-linear
relation among the ai and among the bi . We choose to substitute
a3 = −(7 + a1 + 3a2 )/5, b3 = −(11 + 3b1 + 5b2 )/7.
Implementations of Gröbner bases are available, for instance, in Maple [33] and in msolve
[7], which can be used in julia via the package msolve.jl. This is also available in the
package Oscar.jl [38]. The following snippet of Maple code constructs our system (14) and
computes a Gröbner basis with respect to the graded lexicographic monomial ordering with
a1 a2 b1 b2 . This basis consists of 23 polynomials g1 , . . . , g23 .
> f := 81*(x^3 + y^3 + z^3) - 189*(x^2*y + x^2*z + x*y^2 + x*z^2 + y^2*z + y*z^2)
+ 54*x*y*z + 126*(x*y + x*z + y*z) - 9*(x^2 + y^2 + z^2) - 9*(x + y + z) + 1:
> f := expand(subs({x = t*b[1] + a[1], y = t*b[2] + a[2], z = t*b[3] + a[3]}, f)):
> f := subs({a[3] = -(7 + a[1] + 3*a[2])/5, b[3] = -(11 + 3*b[1] + 5*b[2])/7}, f):
> ff := coeffs(f, t):
> with(Groebner):
> GB := Basis({ff}, grlex(a[1], a[2], b[1], b[2]));
> nops(GB); ----> output: 23
The set of standard monomials is the first output of the command NormalSet. It consists
of 27 elements, and the multiplication matrix with respect to a1 in this basis is constructed
using MultiplicationMatrix:
18
Figure 7: Two views on the Clebsch surface with three of its 27 lines.
This is a matrix of size 27 × 27 whose eigenvectors reveal the solutions (Theorem 4.1).
We now turn to julia and use msolve to compute the 27 lines on {f = 0} as follows:
using Oscar
R,(a1,a2,b1,b2) = PolynomialRing(QQ,["a1","a2","b1","b2"])
I = ideal(R, [-189*b2*b1^2 - 189*b2^2*b1 + 27*(11 + 3*b1 + 5*b2)*b1^2 + ...
A, B = msolve(I)
We have drawn three of these lines on the Clebsch surface in Figure 7 as an illustration. Other
software systems supporting Gröbner bases are Macaulay2 [24], Magma [8] and Singular [25].
Homotopy continuation methods provide an alternative way to compute our 27 lines.
Here we use the julia package HomotopyContinuation.jl [12].
using HomotopyContinuation
@var x y z t a[1:3] b[1:3]
f = 81*(x^3 + y^3 + z^3) - 189*(x^2*y + x^2*z + x*y^2 + x*z^2 + y^2*z + y*z^2)
+ 54*x*y*z + 126*(x*y + x*z + y*z) - 9*(x^2 + y^2 + z^2) - 9*(x + y + z) + 1
fab = subs(f, [x;y;z] => a+t*b)
E, C = exponents_coefficients(fab,[t])
F = subs(C,[a[3];b[3]] => [-(7+a[1]+3*a[2])/5; -(11+3*b[1]+5*b[2])/7])
R = solve(F)
The output is shown in Figure 8. There are 27 solutions, as expected. The last line indicates
that a :polyhedral start system was used. In our terminology, this means that the system
was solved using a homotopy in the family F(A1 , . . . , A4 ) from Section 3.3. The number
of tracked paths is 45, which is the mixed volume MV(A1 , . . . , A4 ) of this family. The
discrepancy 27 < 45 means that our system F lies in the discriminant ∇A1 ,...,A4 . The 18
‘missing’ solutions are explained in [4, Section 3.3]. The output also tells us that all solutions
have multiplicity one (this is the meaning of non-singular) and all of them are real.
Other software implementing homotopy continuation are Bertini [2] and PHCpack [50].
Numerical normal form methods are used in EigenvalueSolver.jl [5].
19
Figure 8: The julia output when computing 27 lines on the Clebsch surface.
Acknowledgements
The author was supported by a Veni grant from the Netherlands Organisation for Scientific
Research (NWO).
References
[1] L. Baldi and B. Mourrain. Computing real radicals by moment optimization. In Proceedings of the 2021
on International Symposium on Symbolic and Algebraic Computation, pages 43–50, 2021.
[2] D. J. Bates, A. J. Sommese, J. D. Hauenstein, and C. W. Wampler. Numerically solving polynomial
systems with Bertini. SIAM, 2013.
[3] K. Batselier. A numerical linear algebra framework for solving problems with multivariate polynomials.
PhD thesis, Faculty of Engineering, KU Leuven (Leuven, Belgium), 2013.
[4] M. Bender and S. Telen. Toric eigenvalue methods for solving sparse polynomial systems. Mathematics
of Computation, 91(337):2397–2429, 2022.
[5] M. R. Bender and S. Telen. Yet another eigenvalue algorithm for solving polynomial systems. arXiv
preprint arXiv:2105.08472, 2021.
[6] D. N. Bernstein. The number of roots of a system of equations. Functional Analysis and its applications,
9(3):183–185, 1975.
[7] J. Berthomieu, C. Eder, and M. Safey El Din. msolve: A library for solving polynomial systems. In
Proceedings of the 2021 on International Symposium on Symbolic and Algebraic Computation, pages
51–58, 2021.
[8] W. Bosma, J. Cannon, and C. Playoust. The Magma algebra system. I. The user language. J. Symbolic
Comput., 24(3-4):235–265, 1997. Computational algebra and number theory (London, 1993).
[9] P. Breiding. An algebraic geometry perspective on topological data analysis. arXiv preprint
arXiv:2001.02098, 2020.
[10] P. Breiding, T. Ö. Çelik, T. Duff, A. Heaton, A. Maraj, A.-L. Sattelberger, L. Venturello, and O. Yürük.
Nonlinear algebra and applications. arXiv preprint arXiv:2103.16300, 2021.
[11] P. Breiding, K. Rose, and S. Timme. Certifying zeros of polynomial systems using interval arithmetic.
arXiv preprint arXiv:2011.05000, 2020.
[12] P. Breiding and S. Timme. HomotopyContinuation.jl: A package for homotopy continuation in Julia.
In International Congress on Mathematical Software, pages 458–465. Springer, 2018.
[13] C. Conradi, E. Feliu, M. Mincheva, and C. Wiuf. Identifying parameter regions for multistationarity.
PLoS computational biology, 13(10):e1005751, 2017.
[14] D. A. Cox. Applications of polynomial systems, volume 134. American Mathematical Soc., 2020.
20
[15] D. A. Cox, J. B. Little, and D. O’Shea. Using algebraic geometry, volume 185. Springer Science &
Business Media, 2006.
[16] D. A. Cox, J. B. Little, and D. O’Shea. Ideals, varieties, and algorithms: an introduction to compu-
tational algebraic geometry and commutative algebra. Springer Science & Business Media, corrected
fourth edition edition, 2018.
[17] J. Desjardins and R. Winter. Density of rational points on a family of del Pezzo surfaces of degree one.
Advances in Mathematics, 405:108489, 2022.
[18] A. Dickenstein. Biochemical reaction networks: An invitation for algebraic geometers. In Mathematical
congress of the Americas, volume 656, pages 65–83. Contemp. Math, 2016.
[19] J. Draisma, E. Horobeţ, G. Ottaviani, B. Sturmfels, and R. R. Thomas. The euclidean distance degree
of an algebraic variety. Foundations of computational mathematics, 16(1):99–149, 2016.
[20] T. Duff, C. Hill, A. Jensen, K. Lee, A. Leykin, and J. Sommars. Solving polynomial systems via
homotopy continuation and monodromy. IMA Journal of Numerical Analysis, 39(3):1421–1446, 2019.
[21] D. Eisenbud and J. Harris. The geometry of schemes, volume 197. Springer Science & Business Media,
2006.
[22] I. Z. Emiris and B. Mourrain. Computer algebra methods for studying and computing molecular
conformations. Algorithmica, 25(2):372–402, 1999.
[23] J.-C. Faugère. A new efficient algorithm for computing Gröbner bases (F4). Journal of pure and applied
algebra, 139(1-3):61–88, 1999.
[24] D. R. Grayson and M. E. Stillman. Macaulay2, a software system for research in algebraic geometry.
Available at http://www.math.uiuc.edu/Macaulay2/.
[25] G.-M. Greuel, G. Pfister, and H. Schönemann. Singular—a computer algebra system for polynomial
computations. In Symbolic computation and automated reasoning, pages 227–233. AK Peters/CRC
Press, 2001.
[26] B. Huber and B. Sturmfels. A polyhedral method for solving sparse polynomial systems. Mathematics
of computation, 64(212):1541–1555, 1995.
[27] B. Huber and B. Sturmfels. Bernstein’s theorem in affine space. Discrete & Computational Geometry,
17(2):137–141, 1997.
[28] E. Hubert and E. Rodriguez Bazan. Algorithms for fundamental invariants and equivariants. Mathe-
matics of Computation, 91(337):2459–2488, 2022.
[29] Z. Kukelova, M. Bujnak, and T. Pajdla. Automatic generator of minimal problem solvers. In European
Conference on Computer Vision, pages 302–315. Springer, 2008.
[30] A. G. Kushnirenko. Newton polytopes and the Bézout theorem. Functional analysis and its applications,
10(3):233–235, 1976.
[31] M. Laurent. Sums of squares, moment matrices and optimization over polynomials. In Emerging
applications of algebraic geometry, pages 157–270. Springer, 2009.
[32] D. Maclagan and B. Sturmfels. Introduction to tropical geometry, volume 161. American Mathematical
Society, 2021.
[33] Maplesoft, a division of Waterloo Maple Inc.. Maple.
[34] M. Michałek and B. Sturmfels. Invitation to nonlinear algebra, volume 211. American Mathematical
Soc., 2021.
[35] V. Mitankin and C. Salgado. Rational points on del Pezzo surfaces of degree four. arXiv preprint
arXiv:2002.11539, 2020.
21
[36] B. Mourrain. A new criterion for normal form algorithms. In International Symposium on Applied
Algebra, Algebraic Algorithms, and Error-Correcting Codes, pages 430–442. Springer, 1999.
[37] S. Müller, E. Feliu, G. Regensburger, C. Conradi, A. Shiu, and A. Dickenstein. Sign conditions for
injectivity of generalized polynomial maps with applications to chemical reaction networks and real
algebraic geometry. Foundations of Computational Mathematics, 16(1):69–97, 2016.
[38] Oscar – open source computer algebra research system, version 0.9.0, 2022.
[39] M. Sala. Gröbner bases, coding, and cryptography: a guide to the state-of-art. In Gröbner Bases,
Coding, and Cryptography, pages 1–8. Springer, 2009.
[40] A. J. Sommese, J. Verschelde, and C. W. Wampler. Numerical decomposition of the solution sets of
polynomial systems into irreducible components. SIAM Journal on Numerical Analysis, 38(6):2022–
2046, 2001.
[41] A. J. Sommese, C. W. Wampler, et al. The Numerical solution of systems of polynomials arising in
engineering and science. World Scientific, 2005.
[42] B. Sturmfels. Solving systems of polynomial equations. Number 97. American Mathematical Soc., 2002.
[43] B. Sturmfels. Beyond linear algebra. arXiv preprint arXiv:2108.09494, 2021.
[44] S. Telen. Solving Systems of Polynomial Equations. PhD thesis, KU Leuven, Leuven, Belgium, 2020.
available at https://simontelen.webnode.page/publications/.
[45] S. Telen. Introduction to toric geometry. arXiv preprint arXiv:2203.01690, 2022.
[46] S. Telen, B. Mourrain, and M. Van Barel. Solving polynomial systems via truncated normal forms.
SIAM Journal on Matrix Analysis and Applications, 39(3):1421–1447, 2018.
[47] S. Telen and M. Van Barel. A stabilized normal form algorithm for generic systems of polynomial
equations. Journal of Computational and Applied Mathematics, 342:119–132, 2018.
[48] S. Telen, M. Van Barel, and J. Verschelde. A robust numerical path tracking algorithm for polynomial
homotopy continuation. SIAM Journal on Scientific Computing, 42(6):A3610–A3637, 2020.
[49] S. Timme. Mixed precision path tracking for polynomial homotopy continuation. Advances in Compu-
tational Mathematics, 47(5):1–23, 2021.
[50] J. Verschelde. Algorithm 795: Phcpack: A general-purpose solver for polynomial systems by homotopy
continuation. ACM Transactions on Mathematical Software (TOMS), 25(2):251–276, 1999.
[51] C. W. Wampler and A. J. Sommese. Numerical algebraic geometry and algebraic kinematics. Acta
Numerica, 20:469–567, 2011.
Author’s address:
Simon Telen, CWI Amsterdam simon.telen@cwi.nl
22