Yet Another Ideal Decomposition Algorithm - Semantic Scholar

2 downloads 0 Views 195KB Size Report
M an example from the Macaulay2 tutorial: (−a3d + b4, −a3c + ab3, −ac3d + ad4 + bc4 − bcd3, −bc3d2 + bd5 + c6 − c3d3, ac5 − ac2d3 − b2c3d + b2d4,. −a3d3 + ...
Yet Another Ideal Decomposition Algorithm Massimo Caboara1 , Pasqualina Conti2 and Carlo Traverso1? 1

2

1

Dipartimento di Matematica, Pisa Dipartimento di Matematica applicata, Pisa

Introduction

The problem of decomposing an ideal into pure-dimensional components (resp. reduced pure-dimensional components) is a key step in several basic algorithms of commutative algebra. The computation of the radical can be performed as intersection of the reduced components (but we wonder why you should really perform this intersection that throws away additional insight in the structure of the ideal), and the primary or the irreducible reduced decomposition can be more easily obtained from a pure-dimensional decomposition. Moreover this step can be performed independently of the ground field —at least if it is perfect— while the primary and irreducible decompositions require factorization, that depends on the ground field. Several algorithms have been proposed for this computation, and fall mainly into two classes: the family of projection algorithms, whose prototype is the primary decomposition algorithm of [15], and the direct, syzygy-based algorithms, like [11], see also [23]. The superiority of one type of algorithms over the other has not been settled; in [11] it is argued that the direct methods are superior since for projection methods “sufficiently generic” projections are needed. This assertion is only marginally true for the current literature — already in [3] “generic linear combinations” are needed only for finding a single univariate polynomial, through linear algebra and a variation of [13], and the algorithms of [19] and [17] compute triangular decompositions through characteristic sets without changes of coordinates. Moreover projection algorithms do not have the limitation to large characteristics of [11], in particular the example of D. Jaffe in [11] can be easily handled by our algorithm (and indeed by all projection algorithms). In this paper we describe algorithms for equidimensional decompositions, that can be seen as a marginal modification of an algorithm of [3], but that completely avoid generic or random projections, and does not need lexicographic Gr¨ obner bases or characteristic sets, hence can be a candidate to a best competitor against direct algorithms. Some tests seem to support the belief that our algorithms are much faster than direct algorithms.

?

E-mail: {caboara,conti,traverso}@posso.dm.unipi.it The authors acknowledge the support of ESPRIT reactive LTR project 21024 FRISCO

We describe three types of equidimensional decomposition: – Strict equidimensional decomposition, I = ∩Ij , where each Ij is puredimensional; √ – Reduced equidimensional decomposition, I = ∩Ij , where each Ij is puredimensional and reduced; – Iso-radical equidimensional decomposition, I ⊆ I 0 = ∩Ij , where each Ij is √ √ 0 pure-dimensional, and I = I . The strict equidimensional decomposition is a step towards primary decomposition; the reduced equidimensional decomposition is a strong form of radical computation; and the iso-radical decomposition is simpler and sometimes sufficient, and already exhibits the main features. Moreover it is possible to recover the primary decomposition from an iso-radical decomposition, as shown in [21] and [18]. The basic computational tools used in this paper are Gr¨obner bases with respect to suitable orderings, and ideal saturation, i.e. affine variety difference. We stress again that no projection in generic (or random) direction, addition of random linear forms, etc. are used. Computation of the dimension and of the multiplicity are used to guide some steps of the algorithms. The relation of flatness with variation of staircases, that is our main proof tool, has already been considered in [4]; specialization of Gr¨obner bases is already a main tool in [15], see also [14] and [16].

2

Splitting Techniques

The basic technique that we use to decompose an ideal I ⊆ A is to split according to whether an element a ∈ A is zero or not. √ A splitting √ √ of an ideal I is a pair of ideals (I1 , I2 ) containing I such that I = I1 ∩ I2 ; it is called a strict splitting if I = I1 ∩ I2 . A splitting is proper if both I1 and I2 contain I properly. The basic operation on ideals that we use to split is the saturation. Consider ideals I, J ⊆ A = k[X]. We want to compute the closure of the set difference of the locus of I and the locus of J. This is accomplished through the ideal saturation. The transporter I : J is defined as {x ∈ A | xJ ⊆ I}. The saturation I :∗ J is the common value of I : J n for sufficiently large n. Indeed, if I : J r = I : J r+1 then it is also equal to I : J n for all n ≥ r. Computing transporter and saturation is simpler if J is a principal ideal. Efficient algorithms exist for transporter and saturation. They consist in a suitable Gr¨ obner basis computation. See [8] for a nice geometric introduction. The basic splitting tool, that is already the key step of [15], is the following lemma: Lemma 1. Let I be an ideal of a ring R, a ∈ R, and assume that I :∗ (a) = I : (an ); then I = (I : (an )) ∩ (I + (an )).

The proof of the lemma is is quite easy: if b = x + an y ∈ I with x ∈ I, y ∈ R, and ban ∈ I, then a2n y ∈ I, √ hence p an y ∈ I, and p b ∈ I. As a corollary we have that I = I : (a) ∩ I + (a). A geometric interpretation of Lemma 1 can be given using the following lemma (see e.g. [2]): Lemma 2. Let P be a prime ideal, Q a P -primary ideal of a ring R; then Q : (a) 1. is Q if a ∈ /P 2. is P -primary if a ∈ /Q 3. is R if a ∈ Q Consider now a primary decomposition of an ideal I, and compare it with primary decompositions of I : (an ) and I +(an ) for sufficiently large n; in I : (an ) appear those associated primes of I that do not contain a, and in I + (a) appear primes associated to I that contain a, and possibly other components embedded in components of (I : (an )). To avoid these extraneous components one may saturate: consider, instead of I + (an ), the ideal I :∗ (I : an ) (that contains I + (an )), but thus we risk discarding some of the embedded components of I. This is not important if we want just to compute the radical, or an iso-radical decomposition, but is not allowed for strict splittings. It is not clear moreover if it is practically more convenient to avoid the extraneous components, or to avoid the more complicated saturation I :∗ (I : an ); experiments are needed to decide the issue. A plausible generalization of Lemma 1 to non-principal divisors is unfortunately not true: may happen that I : J = I : J 2 but (I : J)∩(I +J) 6= I. But it √ it p is true that I = (I :∗ J) ∩ (I + J), since it is true that if Q is P -primary and J 6⊆ Q then Q :∗ J is P -primary: it is intersection of P -primary ideals because of Lemma 2 and because I : (J + K) = (I : J) ∩ (I : K). This provides us with another form of non-strict splitting. To complete our bag of tools, remark that there is a very simple splitting possibility if we discover that ab ∈ I and neither a ∈ I nor b ∈ I: consider separately I + (a) and Ip+ (b). Indeed, I 2 ⊆ √ (I + (a))(I + (b)) ⊆ I, hence p (I + (a)) ∩ (I + (b)) = (I + (a))(I + (b)) = I. A very special case is when a = bn ; in this case splitting just means adding one element a of the radical. For strict splittings √ it is not sufficient to find ab ∈ I, a ∈ / I, b ∈ / I to find a proper splitting; if a ∈ I, then I :∗ (a) = (1), and I + (an ) = I for sufficiently large n, hence the splitting is not proper. But otherwise the splitting is proper. We summarize now all the splittings that we can use: Strict: I → (I : (a), I + (a)) when I : (a) = I :∗ (a); Loose: I → (I :∗ J, I + J) Bi-saturating: I → (I :∗ J, I :∗ (I :∗ J)); Factoring: I → (I + (a), I + (b)) when ab ∈ I Radical: I → (I + (a)) when an ∈ I

Factored Gr¨ obner Whenever one is interested to a question that can be solved decomposing an algebraic variety into pieces, like the description of the set of solutions, the equidimensional decompositions, or the radical, it is convenient to adopt the paradigm of factored Gr¨ obner basis computation. This consists in computing instead of an unique Gr¨obner basis, a set of Gr¨ obner bases of ideals such that the union of their locus is the locus of the original ideal; or equivalently, of ideals such that their intersection has the same radical as the original basis. The factored Gr¨ obner basis algorithm consists in maintaining a list of ideals, and computing the Gr¨ obner basis of each of them with the following pattern: whenever we compute a new polynomial belonging to the ideal and we find that is reducible, consider its distinct factors and split the ideal into as many ideals as there are different factors, adding to each one of them one of the factors. And insert these ideals in the list in place of the original ideal. There are at least three main possible interpretations of “finding” that a polynomial is reducible: – actively try to factor any polynomial (maybe only at selected points of the algorithm) with a general-purpose factorizer that can exhibit any existing factorization; – rely on GCD for discovering factorizations: maintain a list of test polynomials (they may be e.g. the variables, or the list of basis elements, etc.) and try the GCD of them with any new polynomial; if the GCD is non-trivial, try to factor as much as possible the polynomial; – try a factorization only if you stump into it: whenever something happens that cannot happen if a polynomial is irreducible, or an ideal is prime, (like e.g. having to invert an element that happens to be a zero-divisor) patch the situation with a splitting. We will usually adopt this latter attitude in the description of our algorithms; however the other approaches are often viable too. The problem is usually that a lot of time is spent in trying to factor irreducible polynomials, but whenever a factorization is found the savings are very large. For this type of factorizations an heuristic irreducibility test is very useful. See [9] for an account.

3 3.1

Staircases and flatness Staircase; Multiplicity, Dimension, Independent Variables

Assume that we have a term ordering in k[X]; for every polynomial f ∈ k[X] the initial power product In(f ) is the largest power product appearing in f ; if I is an ideal, then In(I) is the monomial ideal generated by the In(f ), f ∈ I; the staircase of I is the set of power products of k[X] that are not in In(I), and is a vector space basis of k[X]/I.

The computation of the dimension and of the multiplicity of an affine algebraic variety is done through the Hilbert function, that is computed from the staircase of the defining ideal (the generators of the initial ideal) with respect to any ordering. See e.g. [6]. In particular the codimension is computed finding the minimum cardinality of a set C of variables such that any generator of the initial ideal has positive degree in one of them. Remark that this implies that for every element of C there is a generator of the initial ideal such that no other variable of C appears in it with positive degree — otherwise we could delete this variable from C. Any complementary set of variables is a set of algebraically independent variables in k[X]/I. We may assume, up to a reordering, that C is composed of the first c variables. In particular, k[X]/I is zero-dimensional if and only if for every variable an element of the G¨obner basis exists beginning with a pure power of this variable. 3.2

Families of Gr¨ obner Bases, Block Orderings

Consider a partition of the variables of a polynomial ring into two subsets; to simplify notations we call these two subsets X and Y . A term ordering on k[X, Y ] is called a strong elimination ordering for X, or a block ordering for the decomposition (X, Y ) if X α Y β > X γ Y δ if and only if X α > X γ or α = γ and Y β > Y δ . With such an ordering, k[X, Y ] can be naturally seen as (k[Y ])[X], i.e. polynomials in X with coefficients in k[Y ]. If I is an ideal of k[X, Y ], and I1 = I∩k[Y ], we can see k[X, Y ]/I = (k[Y ]/I1 )[X]/(I/I1 ). If in particular I1 is a prime ideal, we can see the polynomials of k[X, Y ] as polynomials with coefficients in the quotient field Q(k[Y ]/I1 ) of k[Y ]/I1 ; hence the question arises if the image of a reduced Gr¨ obner basis is still a Gr¨obner basis, and the answer is affirmative. Consider the map φ : k[X, Y ] → k[X, Y ]/I1 = k[X, Y ] ⊗k[Y ] k[Y ]/I1 → k[X, Y ] ⊗k[Y ] k[Y ]/I1 = Q(k[Y ]/I1 )[X]; this means considering f ∈ k[X, Y ] as a polynomial in X with coefficients in k[Y ] that are considered mod I1 . A polynomial f ∈ k[X, Y ], f = cX α Y β + . . . can be written as polynomial in (k[Y ])[X], i.e. f = X α g(Y ), and In(g) = Y β . Theorem 1. Let k[X, Y ] have a block ordering eliminating X, and let I be an ideal such that I1 = I ∩ k[Y ] is prime; let G be a Gr¨ obner basis of I; then the image of G in (k[Y ]/I1 )[X] is a Gr¨ obner basis. Proof. We may assume that G is irredundant. This means that if we have f ∈ G, f = X α g(Y ), α 6= 0, we have g ∈ / I1 , otherwise g would be reducible by an element of I1 , hence by another element of G; this implies that for elements of G if In(f ) = X α Y β , then In(φ(f )) = X α . Recall that a set G of elements of an ideal is a Gr¨obner basis if and only if every syzygy between the initial power product of two elements of G can be extended to a syzygy between the elements of G. Extending a syzygy means to find a syzygy beginning with the same monomials in the standard syzygy

ordering induced by the ordering of the current ring. (This is just a rephrasing of the criterion that a set of generators is a Gr¨obner basis if and only if every S-polynomial is reducible to 0). Let now σ ¯ be a syzygy between In(φ(fi )) and In(φ(fj )), fi , fj ∈ G; this identifies a syzygy σ between In(fi ) and In(fj ) obtained multiplying by suitable powers of some Y variables. This syzygy can be lifted to a syzygy Σ of G, since ¯ of φ(G) that lifts σ G is a Gr¨ obner basis, and identifies a syzygy Σ ¯ . This proves that φ(G) is a Gr¨ obner basis. Remark that in the proof the key point is that In(f ) and In(φ(f )) only differ by the power product in Y ; and one can remark that this is not necessary to be true for all the elements of G, but that before checking it, one can delete redundancies in φ(G). A geometric point y of a ring A is a field that is an A-module, and if B is another A-module and f ∈ B, then f (y) is f ⊗ 1 in B ⊗A y. In particular, a prime ideal P of A (i.e. an element of Spec(A)) defines a geometric point being the quotient field of A/P . In particular, if A is a domain, the 0 ideal identifies a geometric point (the generic point), and Theorem 1 says that if I1 is prime then the image of a Gr¨ obner basis at the generic point is still a Gr¨obner basis. We can put the thesis of Theorem 1 as a question for the geometric points of Spec(k[Y ]/I1 ), i.e. consider a prime ideal J ⊇ I1 , J ⊆ k[Y ] instead of I1 , and I + J instead of I. The answer is that for an open subset of Spec(k[Y ]/I1 ) the Gr¨ obner basis of I is still a Gr¨obner basis (usually redundant). If I1 is prime this set is non-empty since it contains the generic point. It is computed as follows: If f is a non-zero polynomial, define its reduced initial power product InX (f ) being its initial power-product from which the variables Y are deleted. Expressing f as polynomial in X with coefficients in Y , we have f = InX (f )g(Y ) + h, all the monomials of h being smaller than InX (f ). We denote CX (f ) = g(Y ). Let G be the reduced Gr¨obner basis G of I; extract from G a minimal set G0 of polynomials, not in I1 , such that every other element f of G not in I1 is such that InX (f ) is multiple of InX (f 0 ) for a suitable element f 0 ∈ G0 . The set G0 may be not unique. For each element of hi ∈ G0 consider hi = gi InX (hi ) + h0i , where gi ∈ k[Y ] and the power products of h0i are smaller than InX (hi ). The hi are non-zero in k[Y ]/I1 since they are reduced modulo the Gr¨obner basis of I1 . Remark that, because of the reduction hypothesis on G, no gi is in I (otherwise one could reduce gi through elements of G \ G0 ). For each geometric point y of I1 for which no gi (y) vanishes, we have that G0y = {f (y) | f ∈ G0 } is a Gr¨obner basis, with the same proof given for Theorem 1. If I1 is prime, since each of the gi does not vanish on the locus of I1 , there is a dense open subset of Spec(k[Y ]/I1 ) where no gi vanishes, and in this open set G specializes to a Gr¨ obner basis. Q Usually we don’t know if I1 is prime, but we may check if the product gi √ is in I1 . If this is the case, we have discovered that IQ 1 is not prime, and we can split I1 (and I) into smaller components. Otherwise gi does not vanish on a

non-empty open subset of Spec(k[Y ]/I1 ) even without the primality assumption. In this case we have found a non-empty open subset such that on it a Gr¨obner basis specializes. Remark that every different choice of G0 gives a (possibly different) open subset where the staircase is constant; and it is even possible that the Gr¨obner basis specializes to a Gr¨ obner basis with a different staircase. The situation is more complicated when I1 is not reduced, since it may happen that some gi vanishes identically, and we might not be allowed to split I1 since we are looking for strict splittings. The situation will be further discussed. 3.3

Staircase Variation and Flatness

Consider the following situation: we have an ideal I ⊆ k[X, Y ] and J = I ∩ k[Y ]; consider the projection morphism between the corresponding algebraic varieties, induced by the map k[Y ]/J → k[X, Y ]/I. We want to find an open subset where the map is flat. We have seen in the previous section how to find an open subset where the staircase is constant, and either this subset is non empty or we find a splitting (except a special case that will be discussed separately). If we have a map Spec(k[X, Y ]/I) → Spec(k[Y ]/J) and the Gr¨obner basis of the fiber has constant staircase in an open subset, then the map is flat on the same subset. This can be easily seen e.g. if the generic fiber is finite (i.e. the staircase is closed) since flatness is implied by finiteness and constant k-dimension of the fiber; and this dimension is computed through the staircase (it is the multiplicity). In the higher dimensional case, one goes through homogenization (with respect to a suitable weight, such that the Gr¨obner basis is still Gr¨obner with respect to an ordering compatible with the weight) and considering the filtration induced by the grading; then the Hilbert function is constant, and this proves the flatness (see e.g. [20], or [10]). We want to be more precise, generalizing the result that the staircase freely generates the quotient. As in the previous section, let G be the reduced Gr¨obner basis of an ideal I ⊆ k[X, Y ]; extract from G a minimal set {hi } = H of polynomials, not in I1 = I ∩ k[Y ], such that every other element f of G not in I1 is such that InX (f ) is multiple of InX (hi ) for a suitable element hi , and let hi = gi InX (hi ) + h0i . Let E be the open subset of Spec(k[Y ] where the gi do not vanish (it may be empty). Consider the X-staircase S of I, being the set of X-power products that are not multiple of some InX (f ), f ∈ I (or, equivalently, f ∈ G). We have seen that S is the staircase of I(y) for every geometric point y of E. Theorem 2. If E is not empty, then the X-staircase S is a set of free generators of k[X, Y ]E as k[Y ]E -module. Proof. On E the gi are invertible, and the hi /gi are monic in X, hence S generates k[X, Y ]E ; and S is linearly independent on k[Y ]/I1 since G is a Groebner basis, hence linearly independent on (k[Y ]/I1 )E by the flatness of localization.

This proves that k[X, Y ]/I is k[Y ]/I1 -flat on E; changing E through a different choice of H (or even through different term-orderings) one can find other open subsets where k[X, Y ]/I is flat. The flatness is important because of the following remark: Lemma 3. Let A be a pure-dimensional ring, and B a finite flat A-algebra. Then B is pure-dimensional. Proof. Consider a prime Q of B associated to (0), and let b ∈ B be an element annihilated by Q; because of flatness, Q∩A is a prime of A associated to (0), and because of the finiteness hypothesis the dimension of Q is equal to the dimension of Q ∩ A.

4

Projecting to an Hypersurface

Consider an ideal I ⊆ k[x1 , . . . , xn ], and the corresponding affine variety V ; assume that V has dimension d. Our algorithm, like the algorithm of [3], projects V into a subspace of dimension d + 1; but unlike [3] we do not choose a “sufficiently generic” projection, but a very special one, i.e. a projection along coordinates. The first step requires hence to compute the dimension d of V ; the computation of the dimension requires usually the computation of a Gr¨obner basis with respect to an ordering whatsoever, (this preliminary computation can be used in the following steps, through the use of an Hilbert-driven Buchberger algorithm, see [22]). The computation of the dimension has often as a sub-product the identification of those subsets of the variables that are algebraically independent, and we choose a subset Y of d + 1 variables that contain an algebraically independent set. We assume that these are the last d + 1 variables. Let c = n − d be the codimension, Y = (xc , . . . , xn ), X = (x1 , . . . , xc−1 ). Consider now a block ordering for the first c − 1 variables, compute the Gr¨ obner basis of I with respect to it, and the elimination ideal I 0 = I ∩ k[Y ]. The ideal I 0 describes an affine variety V 0 that is the projection of V If the ideal I is in “general position”, then the map from V to V 0 is generically 1-1, irreducible components of V and V 0 are in 1-1 correspondence, the dimension of the components is preserved, and it is impossible that V 0 is reduced if V is not reduced; hence in particular V is pure-dimensional and reduced if and only if V 0 is pure dimensional and reduced, i.e. I 0 is generated by a squarefree polynomial g. If not, consider the squarefree GCD g of a system of generators of I 0 ; we can add g to I to discard the lower-dimensional components and at least a part of nilpotents.

With a special projection, like the ones to which we are bound, several phenomena can happen: 1. 2. 3. 4. 5.

some components of V may be projected into smaller dimension, some components of V may disappear inside other components, the map may be of degree > 1 on some components, some embedded components may disappear altogether, some non-reduced components may have reduced image.

We can take care of all these phenomena through flatness, except the last one, that is important only for the reduced decomposition.

5

The Main Algorithm

Now we describe the algorithms. We have three variants, for strict, iso-radical and reduced equidimensional decomposition. The algorithm for iso-radical decomposition can be seen as the main one; it has some optional steps, that are probably useful for the iso-radical decomposition, are necessary for the reduced decomposition, and forbidden for the strict decomposition. Moreover, for the strict decomposition all the splittings have to be strict, for the other decompositions we can choose other splittings. And for the reduced decomposition there is a final step that will be described separately. The algorithm proceeds inductively, finding for every ideal I either a proof that it is equidimensional (and reduced in the reduced decomposition variant) or a proper splitting into two ideals (a special case being the addition to an ideal of a root of one element). In the case of the algorithm for a strict decomposition, the splittings are strict. The algorithm terminates by noetherianity; but indeed one can also remark that in every splitting that we consider either the dimension or the multiplicity or the number of associated primes decreases for each factor. We describe the algorithm in steps, in which a splitting might be discovered (and hence we have to repeat from the first step for each of the components). At the end of all the steps we have found one component of the sought decomposition. When we have all the components, we still have (optionally) to eliminate redundancies. Step 1 Compute the dimension d of I, c = n − d, and if needed reorder the variables in such a way that the last d are algebraically independent mod I. Compute a Gr¨ obner basis with respect to a block ordering for the first c − 1 variables, thus computing I 0 = I ∩ k[Y ]. If I 0 is not a principal ideal, then let g be the GCD of its generators, and split I along g; otherwise go to the next step. Step 2 If we are in the strict decomposition algorithm, or if g is square-free, go to the next step; otherwise split g through a square-free decomposition, and split I accordingly. This step is optional for the iso-radical decomposition.

Let G be the reduced Gr¨obner basis of I (with respect to the current block ordering), and erase g from G; extract from G a minimal set G0 of polynomials such that given h ∈ G exists h0 ∈ G0 , and InX (h0 ) divides InX (h) (the set G0 may be not unique). For each element of hi ∈ G0 consider hi = gi InX (hi ) + h0i , where gi ∈ k[Y ] and the power products of h0i are smaller than InX (hi ). Clearly no gi is multiple of g, since every hi is in normal form with respect to g. Step 3 If some gi has a common factor with g, split along gi . Special care has to be taken here if we are in the case of strict decomposition; in that case it may happen that gi is in the radical of I 0 , hence no strict splitting can be done; if this happens look at the next subsection. Q We assume now that no gi has a factor in common with g. Define g 0 = gi . Then g 0 is not in I. Step 4 Compute I 00 = I :∗ (g 0 ); if I 00 6= I split along g 0 . Now the map Spec(k[X, Y ]/I) → Spec(k[Y ]/(g)) is flat where g 0 does not vanish; this means that in these points the dimension is d, and since I is saturated with respect to g 0 this means that no associated prime contains g 0 ; hence I is of pure dimension d. Step 5 Conclusion: I is pure-dimensional An alternative for step 4 is to split for each of the gi separately; this is probably more convenient, since each transporter is easier, and it is usually a good technique to have several easier steps instead of an harder one. Another alternative, if we are not interested in strict splittings, consists in avoiding the arbitrary choice of the hi ; more precisely, erase from G0 = G \ {g} all the elements h such that InX (h) is a proper multiple of InX (h0 ) for another h0 ∈ G0 ; then partition G0 into classes Hi of elements having the same InX , and for each class consider the ideal Ji generated by the CX (h), h ∈ Hi . Then we can use loose or bi-saturating splittings with the Ji . A further possibility is to try to factor all the elements of G, and split with every possible factor, either with factoring splittings or with strict splittings if needed. Special Case for the Strict Decomposition. We have left aside the case in which the step 3 cannot produce a splitting since we are looking for strict splittings, and gi is in the radical of I1 , i.e. a power of gi is a multiple of g. In this case k[X, Y ]/I is not generically flat over k[Y ]/I1 . Assume now that the first of the Y (let it be y1 ) is algebraically dependent from the others in k[Y ]/I1 , i.e. that y1 appears in g (one can always assume that, up to a permutation of the variables). Let Y 0 = Y \ {y1 }, X 0 = X ∪ {y1 } and change the ordering to a block ordering eliminating X 0 . Recompute the Gr¨obner basis of I. Clearly I ∩ k[Y 0 ] = (0).

We now can proceed as in the main algorithm: find a polynomial g 0 in k[Y 0 ] such that the map k[X, Y ]/I → k[Y 0 ] is flat outside of the locus of g 0 , (g 0 ∈ / I since I ∩ k[Y 0 ] = (0)) and continue with step 4. The reason not to use this kind of procedure in general is twofold: it does not allow to discover and eliminate nilpotents, (hence it cannot be used for the reduced decomposition) and eliminating one further variable makes the computations more difficult. Conclusion of the Algorithm for the Reduced Decomposition. This concludes the matter if we are looking for iso-radical or strict decompositions (in the second case provided that we have used strict splittings). In the case that we are looking for a reduced decomposition, we have not finished, since I might still have nilpotents. This cannot happen if the multiplicity of I is equal to the multiplicity (the degree) of g; but this cannot be assured in general. Before going to the last step, that might be time-consuming, we might try with an heuristic reduction test. We describe one such test, that relies on a reduction test for zero-dimensional ideals. In dimension zero testing reduction is easy, for example one can compute the quadratic form (x, y) → T r(xy) and prove that its associated matrix has full rank. The heuristic reduction test runs as follows: assume that g has degree m; because of the generic constance of the staircase, the multiplicity of V is a multiple rm of m, where m is the multiplicity of the generic fiber. Find a line (a subvariety of k[Y ] defined by d − 1 polynomials of degree 1) on which g has m distinct zeros (this is always possible unless the ground field is very small), add the defining equations to I, and check if the resulting zero-dimensional ideal J is reduced of multiplicity rm. If so, then I is reduced. For special lines it may happen that J is not reduced even if I is reduced; computing with generic lines (lines with indeterminate equations) is however costly and contrary to the philosophy of our algorithm. Another possible reduction test uses jacobians. Smooth points are reduced; find through jacobians the singular locus of I (find J adding to I the determinants of the d × d minors of the jacobian matrix of a set of generators of I). If g∈ / J then the generic fiber of the projection is smooth, hence reduced. This test might be inconclusive in small characteristics, since the jacobian locus might be larger than the singular locus. In any case, computing the jacobian matrix might be very expensive. These tests are however contaminations from [3] and [11] respectively, and in any case, it may be that I has nilpotents, and we want to kill them; and for this our algorithm requires to change the order of the variables. It is not sure that this is the best way, but at least it is not too bad: we might have to repeat the algorithm for at most n times, and this does not increase qualitatively the complexity of an algorithm that is at least exponential.

We need the following trivial remarks: Lemma 4. If φ : V → W is an affine variety morphism, the Zariski tangent space of P ∈ V is mapped into the Zariski tangent space of φ(P ). Lemma 5. If in the lemma above φ is induced by a projection, the Zariski tangent space of P is contained in the sum of the tangent space at φ(P ) plus the space parallel to the projection direction. Corollary 1. If V embedded in an affine space of pure dimension d has a singular point P , then exists a projection π along a coordinate space into an affine space of dimension d + 1 such that πP is singular. Indeed, the Zariski tangent space, that has dimension > d, cannot project noninjectively in every direction. With these remarks we can try different directions, and either find one that allows to proceed inductively, or prove that Vˆ is not only pure-dimensional, but also generically non-singular, hence reduced. The conclusion can be obtained when the intersection of the projection directions is empty. In some cases this can be a very expensive part; for example, if I is the ideal (x2i −xi )2i=1...n we need n projections to find the radical. But in this case also the other known algorithms are quite expensive. If I is of dimension d in a polynomial ring with n variables in general we need m ≥ n/(d + 1) different projections, since every computation with a different choice of independent variables decreases of a dimension d + 1 the directions in which nilpotents are concealed. Primary Decomposition. When we have a strict equidimensional decomposition, the remaining step to obtain a primary decomposition is reduced to factorization, either through projections or through direct methods. It would be nice to be able to complete the algorithms of this paper showing how to compute the primary decomposition through coordinate projections. The conjectural algorithm consists in projecting in codimension 1 in many coordinate directions, and factoring the resulting polynomial, splitting along the factors, relying on a conjecture stating that if an affine variety is reducible, the same is true for some projection in a coordinate direction. Unfortunately the conjecture is false; consider the following counterexample: I = (x2 y 2 z 2 − 1, x2 + y 2 + z 2 − 1) is clearly reducible, since the first equation is (xyz + 1)(xyz − 1). A Gr¨ obner basis is (y 4 z 2 + y 2 z 4 − y 2 z 2 + 1, x2 + y 2 + z 2 − 1) and the first polynomial is irreducible. The situation is symmetric for permutation of the variables. We thank Rita Pardini for providing the counterexample.

6

Tests

We have tested the algorithm in some non trivial cases through semi-automatic computations, computing the Gr¨obner bases with the PoSSo solver and the GCD and factorizations with Maple; the algorithm seems to be pretty efficient. A first complete experimental implementation has been made in CoCoA, using the high-level language CoCoAL, (in particular the GCD is implemented through Gr¨ obner basis computations). The implementation is much less efficient since it does not include all the heuristics and simplifications that are natural in a semi-automatic computation. One such simplification that has proved very valuable, is the following: assume that we know an upper bound on the codimension of the associated primes, for example from the number of generators of the input ideal. Then in the algorithm we may discard all the ideals that are of codimension higher than the limit, since it is sure that they will be redundant in the final decomposition. We have compared both approaches with the implementation of direct methods in Macaulay2, and the comparison shows that both the semi-automatic tests and the experimental implementation are more effective on a series of complicated tests. There is no established benchmark for decomposition and radical computations, hence we propose some of our tests, that are “natural examples”, existing in the literature. All the examples are contained in the POSSO test suite. G Gerdt example, see [5]; B Butcher example, see [5]; H2,H3 Two examples of Hietarinta, coming from theoretical physics problems; they are contained, as Hietarinta-1 and Hietarinta-3 in the POSSO test suite (the Hietarinta-2 problem is a trivial ideal). C The hypothesis of Ceva theorem, corresponding to a configuration of 7 points in the plane with 6 alignment relations: consider points A, B, C, O, X, Y , Z, each with two coordinates; the equations are C(A, B, X), C(B, C, Y ), C(A, C, Z), C(C, O, X), C(A, O, Y ), C(B, O, Z), where C(A, B, X) is the equation a1 b2 + b1 x2 + x1 a2 − a2 b1 − b2 x1 − x2 a1 and denotes collinearity. We add the equations A = (0, 0), B = (1, 0) that correspond to a choice of coordinates. 83 The hypothesis of the Maclane 83 theorem: (C + cE − eC − E, F − C, E − G, eF + f H + hE − f E − hF − eH, f G − gF , gH + G − hG − H, cH − hC): see [7] where (substantially) the real radical of this ideal is computed. E2,E3 Two examples of Amrhein-Gloor-K¨ uchlin, see [1]; they are of dimension zero, hence are interesting only for the computation of the radical. E2 (x+3xy 3 +y 4 +yz 2 , −x2 z+2y 3 z+z 2 +2yz 2 +3xyz 2 , 3x3 +xy 2 +yz 2 −2xz 3 ), E3 (x2 +y 4 +x3 z+yz−2xz 3 , −x2 y 2 −y 3 z−z 3 −3yz 3 , y 4 −x2 z+2y 2 z−2xyz 2 ). L An example of Logar (personal communication): (2ahi+bh2 +2cdj−cei−cgh− deh, ai2 +2bhi+2cf j −cgi+d2 j −dei−dgh−ef h, bi2 +2df j −dgi−ef i−f gh, f (f j − gi)).

H An example of Hawes (communicated by B. Trager): (x + 5y 4 + 3y 2 a + 2yz + 2yc, x+5Y 4 +3Y 2 a+2Y Z +2Y c, 20y 3 +6ya+2z +2c, 20Y 3 +6Y a+2Z +2c, y 2 + 3z 2 + b, Y 2 + 3Z 2 + b). For this example the choice of an adequate initial ordering is crucial: the best choice is an ordering eliminating x, b, c. Otherwise the Gr¨ obner basis computation is very hard. O Oaku’s G3 (see [21]): (((12y + 8)x2 + (2y + 2)x)ηξ + ((−15y 2 − 4y)x − 4y 2 − y)η 2 , −xξ 2 +((−12y−8)x+2y)ηξ+(15y 2 +4y)η 2 , (81y 4 x2 +(−54y 3 −12y 2 )x− 12y 3 − 3y 2 )η 3 , (−24yx + 6y 2 − 6y)η 2 ξ + (−81y 4 x + 81y 3 + 24y 2 )η 3 , (48x2 + (−30y + 12)x − 6y)η 2 ξ + ((81y 3 − 54y 2 − 24y)x − 21y 2 − 6y)η 3 , (−96yx − 18y 3 + 18y 2 − 24y)η 2 ξ + (243y 5 x − 243y 4 + 72y 3 + 48y 2 )η 3 , 6yη 2 ξ 2 + ((576y + 384)x2 +(−81y 3 −306y 2 −168y +96)x+81y 2 −18y)η 3 ξ +((−720y 2 −192y)x+ 450y 3 − 60y 2 − 48y)η 4 ). M an example from the Macaulay2 tutorial: (−a3 d + b4 , −a3 c + ab3 , −ac3 d + ad4 + bc4 − bcd3 , −bc3 d2 + bd5 + c6 − c3 d3 , ac5 − ac2 d3 − b2 c3 d + b2 d4 , −a3 d3 + a2 c4 − a2 cd3 + b3 d3 , −a3 d3 + b3 c3 , −a3 cd2 + ab2 c3 − ab2 d3 + b3 cd2 , −a3 c2 d + a2 bc3 − a2 bd3 + b3 c2 d, −a3 bd2 + a3 c3 , a4 c2 − a3 b2 d). All these computations are fairly simple with our algorithm, both for the strict and the reduced decomposition. However sometimes the efficiency of the algorithm depends on some details like the choice of the variable ordering, of the sequence of the operations, etc; and some additional criteria (like an upper bound on the codimension of the associated primes given by the length of the input) have sometimes been used; this might account for some of the difficulties of the CoCoA implementation. Here is a table with some results. The PoSSo line reports the timings for the semi-automatic computation; the timings correspond to the sum of all the Gr¨obner basis computations that were performed, the time for GCD and factorizations made with Maple being negligeable. The computation is for the strict and the reduced decomposition, except for the examples of Gerdt and Logar, for which the strict decomposition was not completed being too long, and we computed instead the strict decompositions of an initial non-strict decomposition obtained factoring the input polynomials. Even in these cases apparently there is no serious obstacle to the computation of the strict decomposition. The machine used is a i486 66MHz with 32 MB RAM, with Linux 1.2.13. The CoCoA line reports computations mod 32003, with the radical being computed through a preliminary strict decomposition. In the cases of Gerdt, Logar and Butcher a preliminary factorization of the input has been performed. The examples of Maclane, Hawes and Ceva were infeasible. The computations were performed on a Pentium Pro 200 MHz with 96MB with Linux 2.0.27; this is approximately 10 times faster than the previous machine. The Macaulay line reports the computations of the radical function, on the same machine on which the PoSSo tests were performed. The function uses direct methods. The examples had to be adapted, since radical is only available for homogeneous input, and preferably in finite characteristics. Hence we attempted the computations with the homogenized DegRevLex basis that was previously

computed, and in finite characteristics. Only three examples could be computed, and always with execution times much larger than with PoSSo; also three of the four pieces in which Gerdt can be split were computed (in 2 minutes) but the third one was not completed in 30 minutes. All the other computations were interrupted either after 30 minutes or when the memory used exceeded 30 MB. G B H1 H3 PoSSo 2 17 420 3 CoCoA 52 66 1294 89 Macaulay * * * 35

C 83 27 511 * 1700 * *

E2 58 46 *

E3 L 76 36 37 3152 * *

H 5 * *

O 4 11 26

M 4 1 18

Remark that in Hiet1 400 out of 420 seconds of the computation were used in the preliminary Gr¨ obner basis computation with DegRevLex ordering.

7

An Example

We show how our algorithm behaves to find the radical of the example of D. Jaffe, reported in [11], in which the direct algorithm fails in characteristics 7. The example, that can be generalized in any characteristics, is (z 7 − xyt5 , y 4 − x3 t). The ideal is of dimension 2, hence it is a complete intersection, and pure dimensional, but we want to forget it and compute the example completely. We will use block orderings, and DegRevLex in every block. The set of generators is already Gr¨obner with respect to several orderings (DegRevLex, Lex with z > y > x > t, etc.). We have to choose a variable to eliminate; if we choose z, then the ideal is already Gr¨ obner, and g = y 4 −x3 t, hence no progress is made. If nilpotents exist, they are along the z direction. Then we change elimination variable; if we choose x, (but with other variables it is not much different) then a Gr¨obner basis consists of (x3 t − y 4 , xyt5 − z 7 , x2 z 7 − y 5 t4 , xz 14 − y 6 t9 , z 21 − y 7 t14 ) hence g = z 21 − y 7 t14 = (z 3 − yt2 )7 , and its radical is z 3 − yt2 . Compute now the Gr¨ obner basis of (z 7 −xyt5 , y 4 −x3 t, z 3 −yt2 ). It is composed of 17 elements, but we just need two: g = z 3 − yt2 and h1 = xyt5 − y 2 zt4 (we use the notations of section 3.2). We have g1 = yt5 . Now we saturate (z 7 − xyt5 , y 4 − x3 t, z 3 − yt2 ) with respect to yt5 , and we obtain (z 3 − yt2 , xt − yz, x2 z − y 3 , xz 2 − y 2 t). We know now that this is the top-dimensional reduced component. If we saturate (z 7 − xyu5 , y 4 − x3 u) with it, we obtain 1, hence no other component exists. The radical is hence (z 3 − yt2 , xt − yz, x2 z − y 3 , xz 2 − y 2 t). Remark that in this binomial ideal all the computations have been with binomials; any other algorithm with any form of generic (or random) projection direction would have destroyed the format. At least for binomial ideals the advantage over algorithms using changes of coordinates is obvious. See [12] for more informations on binomial ideals.

References 1. B. Amrhein, O. Gloor, W. K¨ uchlin, Walking faster, DISCO 1996, LNCS (1996) 2. M.F. Atiyah, I.G. Macdonald, Introduction to Commutative Algebra, AddisonWesley, (1969) 3. M. Alonso, T. Mora, M. Raimondo, Local decomposition algorithms, ISSAC 1990, LNCS (1990) 4. D. Bayer, A. Galligo, M. Stillman, Gr¨ obner bases and extensions of scalars, in: D. Eisenbud, L. Robbiano, Computational methods in Algebraic Geometry and Commutative Algebra, Symposia Mathematica 24 (1993) 5. W. Boege, R. Gebauer, H. Kredel, Some examples for solving systems of algebraic equations by calculating Gr¨ obner bases, J. Symb. Comp. 2, 83–89 6. A. Bigatti, P. Conti, L. Robbiano, C. Traverso, A “Divide and Conquer” approach to the computation of the Hilbert-Poincar´e series. AAECC-10, (1993) 7. P. Conti, C. Traverso, A Case of Automatic Theorem Proving in Euclidean Geometry: the Maclane 83 Theorem, Proc. AAECC-11, 1995, LNCS 948, 183–193 8. D. Cox, J. Little, D. O’Shea, Ideals, Varieties, and Algorithms, Springer-Verlag, (1992) 9. J.H. Davenport, Polynomial factorization, MEGA-96, to appear on J. Pure Appl. Algebra 10. D. Eisenbud, Commutative Algebra, with a view towards Algebraic Geometry, Springer Verlag, (1994) 11. D. Eisenbud, C. Huneke, W. Vasconcelos, Direct methods for primary decomposition, Inventiones Math, 110, (1992), p. 207–235. 12. D. Eisenbud, B. Sturmfels, Binomial ideals, Duke Math. J. 84, 1–45 (1996). 13. J.C. Faug`ere, P. Gianni, D. Lazard, T. Mora, Efficient computation of zero– dimensional Gr¨ obner bases by change of ordering, J. Symb. Comp. 16(4), 329–344 (1993) 14. P. Gianni, Properties of Gr¨ obner bases under specialization, Eurocal 1987, LNCS (1988) 15. P. Gianni, B. Trager, G. Zacharias, Gr¨ obner bases and primary decomposition of polynomial ideals, J. Symb. Comp. 6, 149–167 (1988) 16. M. Kalkbrener, Solving systems of algebraic equations by using Gr¨ obner bases, Eurocal 1987, LNCS (1988) 17. M. Kalkbrener, A generalized euclidean algorithm for computing triangular representations of algebraic varieties, J. Symb. Comp., 15:143–167, 1993. 18. M. Kalkbrener, Prime decomposition of radicals in polynomial rings, J. Symb. Comp. 18, 365–372, (1994) 19. D. Lazard, A new method for solving algebraic systems of positive dimension, Discr. App. Math, 33:147-160, (1991) 20. D. Mumford, Lectures on Curves on an Algebraic Surface, Annals of Math. Studies, (1966) 21. T. Shimoyama, K. Yokoyama, Localization and primary decomposition of polynomial ideals, J. Symbolic Computation 22, 247-277 (1996). 22. C. Traverso, Hilbert functions and the Buchberger algorithm, J. Symb. Comp. (1996) 23. W.V. Vasconcelos, Jacobian matrices and constructions in Algebra, AAECC-9, LNCS 539, (1991)