1 Introduction

Domains defined by sums of squares of holomorphic functions constitute a very important class in the field of several complex variables as they connect in a very natural way complex analysis with algebraic geometry. This class of domains was introduced by Kohn in his Acta paper [12] under the term special domains. Kohn’s novel introduction of the technique of subelliptic multiplier ideals to address the local regularity problem paved the way for significant discoveries in several complex variables. In [5, 6], D’Angelo studied the local geometry of real hypersurfaces by assigning to every point on the hypersurface an associated family of ideals of holomorphic functions and exploring various invariants in commutative algebra and algebraic geometry. He established a close connection between the geometry of sums of squares domains and complex algebraic geometry. Further work by Siu in [16] and [17] on sums of squares domains introduced new approaches for generating multipliers for general systems of partial differential equations. Owing to his initial work on sums of squares domains, Siu gave an extension of the special domain approach to real analytic and smooth cases. Kim and Zaitsev in [9] proposed a new class of geometric invariants called the jet-vanishing orders and used them to establish a new selection algorithm in the Kohn’s construction of subelliptic multipliers of sums of squares domains in dimension 3. Also, in a recent paper by the same authors [10], they provide a solution to the effectiveness problem in Kohn’s algorithm for generating multipliers for domains including those defined by sums of squares of holomorphic functions in all dimensions. Other important results pertaining to sums of squares domains can be found in [3, 4, 7, 8, 14].

A key motivation for this paper is to introduce some important tools and techniques necessary for the study of the multitype level set stratification of sums of squares domains. We will focus here on the multitype computations for such domains. Our main tool is an algorithm devised by Kolář in [13] for the computation of the Catlin multitype when it has finite entries. In order to ensure this condition is satisfied, we will assume finite D’Angelo 1-type throughout since the latter bounds from above the last entry of the multitype; see [2].

Owing to the connection between the properties of the associated family of ideals of holomorphic functions and the geometry of sums of squares domains, a natural question is whether or not the multitype could be computed from the corresponding ideals of holomorphic functions. We provide an answer to this question by showing that the multitype of a sum of squares domain can be computed from the related ideal of holomorphic functions via the restatement of the Kolář algorithm at the level of ideals. Besides the fact that working with ideals aligns better with complex algebraic geometry, this restatement also reduces significantly the amount of work involved in computing the Catlin multitype for sums of squares domains.

A sum of squares domain \(\Omega \subset {\mathbb {C}}^{n+1}\) is one of which boundary-defining function r(z) is given by

$$\begin{aligned} r(z) = 2\text {Re}(z_{n+1}) + \sum _{j=1}^{N} |f_j(z_1, \ldots , z_{n+1})|^2, \end{aligned}$$
(1.1)

where \(f_j(z_1, \ldots , z_{n+1})\) for all \(j, 1 \le j \le N\) are holomorphic functions vanishing at the origin in \({\mathbb {C}}^{n+1}\). We shall denote by \(M \subset {\mathbb {C}}^{n+1}\) the hypersurface defined by \(\{ z \in {\mathbb {C}}^{n+1} \ | \ r(z) = 0 \}.\)

The model hypersurface associated to M at the origin is defined as follows:

$$\begin{aligned} M_H = \{z \in {\mathbb {C}}^{n+1}: \; \text {H}(z, {{\bar{z}}}) = 0 \}, \end{aligned}$$
(1.2)

the zero locus of the homogeneous polynomial \(\text {H}(z, {{\bar{z}}})\) consisting of all monomials from the Taylor expansion of the defining function that have weight 1 with respect to the multitype weight. We refer to \(\text {H}(z, {{\bar{z}}})\) as the model polynomial.

Our first main result concerns the form of the model polynomial \(\text {H}(z, {{\bar{z}}})\):

Theorem 1.1

Let \(M \subset {\mathbb {C}}^{n+1}\) be a hypersurface of which defining function is given as follows:

$$\begin{aligned} r(z) = 2\text {Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_{n+1})|^2, \end{aligned}$$

where \(f_1, \ldots , f_N\) are holomorphic functions defined on a neighborhood of the origin and assume that the D’Angelo 1-type of M at the origin is finite. Then the model associated to M is also a sum of squares domain.

In other words, the model polynomial

$$\begin{aligned} \text {H}(z, {{\bar{z}}})= 2\text {Re}(z_{n+1}) + \sum _{j=1}^{N} |h_j(z_1, \ldots , z_n)|^2, \end{aligned}$$
(1.3)

where \(h_j\) is a polynomial consisting of all terms from the Taylor expansion of \(f_j\) of weight 1/2 with respect to the multitype at the origin, \(j=1,\ldots , N.\) Note that the corresponding model hypersurface \(M_H = \{z \in {\mathbb {C}}^{n+1} : \ \text {H}(z, {{\bar{z}}}) = 0 \}\) is a decoupled sum of squares domain since variable \(z_{n+1}\) has weight 1, so no \(h_j\) can depend on it. By Catlin’s results in [2], \(M_H\) has the same multitype at the origin as the original domain. In fact, with respect to multitype computations, every model polynomial is decoupled.

Our second main result answers in the affirmative a question posed by D. Zaitsev during a discussion with the author:

Theorem 1.2

Let \(0\in M \subset {\mathbb {C}}^{n+1}\) be a hypersurface of which defining function is given as follows:

$$\begin{aligned} r(z) = 2\mathrm{Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_{n+1})|^2, \end{aligned}$$

where \(f_1, \ldots , f_N\) are holomorphic functions defined on a neighborhood of the origin and assume that the D’Angelo 1-type of M is finite at the origin.

Then the Catlin multitype is an invariant of the ideal of holomorphic functions defining the domain.

Computing the multitype via the Kolář algorithm requires one to use weighted homogeneous polynomial transformations at each step in order to generate an intermediate weight and a partial model polynomial that depends on a minimal number of variables. How these homogeneous polynomial transformations are obtained was not explicitly described in [13], however. In this paper, we characterize these weighted homogeneous polynomial transformations and explicitly construct them by relating them to elementary row and column operations on the Levi matrix associated to the domain. More specifically, we devise an algorithm for the construction of these homogeneous polynomial transformations, the row reduction algorithm. We call a polynomial change of variables at step j of the Kolář algorithm allowable with respect to variable \(z_k\) if it eliminates the occurrence of variable \(z_k\) from the leading polynomial \(P_j\) and reduces the number of variables in \(P_j\) by at least one. For the correspondence between polynomial changes of variables and elementary row and column operations on the Levi matrix associated to the domain, we introduce a variant of the notion of dependence compared to the standard one in linear algebra as follows: Let \(\text {A}_{P_j}\) be the Levi matrix of the leading polynomial \(P_j\) at step j of the Kolář algorithm. For a given k,  denote by \(R_k\) and \(C_k\) the kth row and the kth column of the matrix \(\text {A}_{P_j}\) respectively. Let \({\mathscr {R}}\) be the set of all rows of the matrix \(\text {A}_{P_j}.\) We call a row \(R_k\) of \({\mathscr {R}}\) dependent if it satisfies the condition:

$$\begin{aligned} R_k = \sum _{\begin{array}{c} l=1 \\ l \ne k \end{array}}^n \alpha _l R_l, \end{aligned}$$

where \(\alpha _l \in {\mathbb {C}}[z], \) \(\alpha _l \ne 0\) for at least one l. In other words, the row \(R_k\) is dependent if it can be written as a linear combination of the other rows with polynomial coefficients. The set \({\mathscr {R}}\) is said to be dependent if at least one of the rows is dependent.

Since the matrix \(\text {A}_{P_j}\) is Hermitian, a similar definition holds for the kth column \( C_k \) of \(\text {A}_{P_j} \) namely

$$\begin{aligned} C_k = \sum _{\begin{array}{c} l=1\\ l \ne k \end{array}}^n {\bar{\alpha }}_l C_l. \end{aligned}$$

Hence, we prove the following:

Proposition 1.3

Assume that the D’Angelo 1-type of the hypersurface M in \({\mathbb {C}}^{n+1}\) at 0 is finite. At step j of the Kolář algorithm for the computation of the multitype at 0, let \(\Lambda _j\) be an intermediate weight, \(P_j\) the leading polynomial, and let \(Q_j\) be the leftover polynomial, which consists of monomials of weighted degree greater than 1 with respect to \(\Lambda _j.\) Let k be given, \(1 \le k \le n.\) There exists an allowable polynomial transformation on \(P_j\) with respect to the variable \(z_k\) if and only if the kth row of \(\text {A}_{P_j}\) is dependent.

Using this characterization of the polynomial transformations and the restatement of the Kolář algorithm in terms of ideals of holomorphic functions, the row reduction algorithm connects nicely the notion of simplifying the Jacobian module associated to a sum of squares domain with elementary row operations on the complex Jacobian matrix of the same domain. By employing this algorithm at every step of the Kolář algorithm for the computation of the multitype, we are able to construct the weighted homogeneous polynomial transformations needed in the Kolář algorithm.

This paper is structured in the following manner: Sect. 2 describes some notation and provides definitions that are pertinent to our discussions in subsequent sections. Section 3 defines the Catlin multitype and provides a thorough description of the Kolář algorithm as introduced in [13]. Section 4 presents a key lemma for the characterization of the multitype entries of the sum of squares domain. Specifically, we establish the fact that each multitype entry can be realized by the modulus square of some monomial of vanishing order at least one in the multivariate ring of polynomials over \({\mathbb {C}}.\) Section 5 contains the proofs of Theorems 1.1 and 1.2. Section 6 presents a modified version of the Kolář algorithm in terms of ideals of holomorphic polynomials. In the same section, a corollary to Theorem 1.1 is stated and proven. Finally, Sect. 7 contains the proof of Proposition 1.3 and also provides a detailed description of the row reduction algorithm for the construction of the weighted homogeneous polynomials required in the Kolář algorithm.

This article constitutes part of the author’s Ph.D thesis at Trinity College Dublin under the supervision of Andreea Nicoara.

2 Definitions and Notation

We present some definitions that we use in the article following the setup of Kolář in [13]. Let M be a hypersurface in \({\mathbb {C}}^{n+1}\) and \(p \in M\) be a Levi-degenerate point. We will assume that p is a point of finite D’Angelo 1-type. Let (zw) be local holomorphic coordinates centered at the point p, where \(w = u +iv\) is the complex non-tangential variable and the complex tangential variables are in the n-tuple \(z = (z_1, \ldots , z_n)\) with \(z_k = x_k + i y_k\). Throughout this paper, we will compute and define weights by considering only the complex tangential variables \(z_1, \ldots , z_n\) as in [13].

Definition 2.1

A weight \(\Lambda = (\mu _1, \ldots , \mu _n)\) is an n-tuple of rational numbers with \(0 \le \mu _j \le \frac{1}{2}\) satisfying

  1. i.

    \(\mu _j \ge \mu _{j+1}\) for \(1 \le j \le n-1;\)

  2. ii.

    For each t, either \(\mu _t = 0\) or there exists a sequence of nonnegative integers \(a_1, \ldots , a_t\) satisfying \(a_t > 0\) such that

    $$\begin{aligned} \sum _{j=1}^t a_j \mu _j = 1. \end{aligned}$$

Let \(\Lambda \) be a weight. If \(\alpha = (\alpha _1, \ldots , \alpha _n)\) is a multiindex, then we define the weighted length of \(\alpha \) by

$$\begin{aligned} |\alpha |_{\Lambda } = \sum _{j=1}^n \alpha _j \mu _j. \end{aligned}$$

Also if \(\alpha = (\alpha _1, \ldots , \alpha _n)\) and \( {\hat{\alpha }} = ({\hat{\alpha }}_1, \ldots , {\hat{\alpha }}_n)\) are multiindices, then the weighted length of the pair \((\alpha , {\hat{\alpha }})\) is defined by

$$\begin{aligned} |(\alpha , {\hat{\alpha }})|_{\Lambda } = \sum _{j=1}^n (\alpha _j + {\hat{\alpha }}_j) \mu _j. \end{aligned}$$

Definition 2.2

A monomial \(A_{\alpha {\hat{\alpha }} l} z^{\alpha } z^{{\hat{\alpha }}} u^l\) is said to be of weighted degree \(\kappa \) if

$$\begin{aligned} \kappa : = l + |(\alpha , {\hat{\alpha }})|_{\Lambda }. \end{aligned}$$

Similarly, we define the weighted order of the differential operator \(D^{\alpha }{\bar{D}}^{{\hat{\alpha }}}D^l\) to equal to \(\kappa : = l + |(\alpha , {\hat{\alpha }})|_{\Lambda }\), where

$$\begin{aligned} D^{\alpha } = \frac{\partial ^{|\alpha |}}{\partial z_1^{\alpha _1} \ldots \partial z_n^{\alpha _n}}, \ \ {\bar{D}}^{{\hat{\alpha }}} = \frac{{\partial }^{\hat{|\alpha |}}}{{\partial } {\bar{z}}_1^{{\hat{\alpha }}_1} \ldots {\partial } {\bar{z}}_n^{{\hat{\alpha }}_n}}, \ \ \text {and} \ \ D^l = \frac{{\partial }^l}{\partial u^l}. \end{aligned}$$

A polynomial \(P(z, {\bar{z}}, u)\) is said to be \(\Lambda \)-homogeneous of weighted degree \(\kappa \) if it is a sum of monomials of weighted degree \(\kappa \).

We shall set the variable w as well as the variables \(u \ \text {and} \ v\) to have a weight of one.

Definition 2.3

A weight \(\Lambda = (\mu _1, \ldots , \mu _n)\) is said to be distinguished if there exist local holomorphic coordinates (zw) mapping p to the origin such that the boundary-defining equation for M in the new coordinates is of the form:

$$\begin{aligned} v= P(z, {\bar{z}}) + o_{\Lambda }(1), \end{aligned}$$
(2.1)

where \(P(z, {\bar{z}})\) is a \(\Lambda \)-homogeneous polynomial of weighted degree 1 without pluriharmonic terms and \(o_{\Lambda }(1)\) denotes a smooth function of which derivatives of weighted order less than or equal to 1 vanish at zero.

We order the weights lexicographically. This means that for the pair of weights \(\Lambda _1 = (\mu _1, \ldots , \mu _n)\) and \(\Lambda _2 = (\mu _1^{'}, \ldots , \mu _n^{'})\), \(\Lambda _1 > \Lambda _2\) if for some t, \(\mu _j = \mu _j^{'}\) for \(j <t\) and \(\mu _t> \mu _t^{'}\).

Definition 2.4

Let \(\Lambda = (\lambda _1, \ldots , \lambda _n)\) be a weight and

$$\begin{aligned} {\tilde{w}} = w + g(z_1, \ldots , z_n, w) \; \text {and} \; {\tilde{z}}_j = z_j + f_j(z_1, \ldots , z_n, w), \end{aligned}$$

for \(1 \le j \le n,\) be a holomorphic change of variables. We say that this transformation is

  1. i.

    \(\Lambda \)-homogeneous if \(f_j\) is a \(\Lambda \)-homogeneous polynomial of weighted degree \(\lambda _j\) and g is a \(\Lambda \)-homogeneous polynomial of weighted degree 1,

  2. ii.

    \(\Lambda \)-superhomogeneous if \(f_j\) has a Taylor expansion consisting of monomials that have weighted degree \(\ge \lambda _j\) and g consists of terms of weighted degree \(\ge 1\),

  3. iii.

    \(\Lambda \)-subhomogeneous if the Taylor expansion of \(f_j\) consists of terms of weighted degree \(\le \lambda _j\) and g consists of weighted degree \(\le 1\).

J. J. Kohn introduced the notion of type of a point on a pseudoconvex hypersurface in \({\mathbb {C}}^2\) in [11]. In [1], Thomas Bloom and Ian Graham generalized Kohn’s notion to \({\mathbb {C}}^n\) and gave a geometric characterization of type of points on real hypersurfaces in \({\mathbb {C}}^n\). There is the definition given by Bloom and Graham: Let \({\mathcal {N}}\) be a real \(C^\infty \) hypersurface defined in an open subset \(U \subset {\mathbb {C}}^n\) with defining function r. Let \({\mathscr {L}}_k\) for \(k \ge 0\) an integer, be the module, over \(C^{\infty }(U)\), of vector fields generated by the tangential holomorphic vector fields to \({\mathcal {N}},\) their conjugates, and commutators of order less than or equal to k of such vector fields.

Definition 2.5

A point \(p \in {\mathcal {N}}\) is of type m if \(\big < \partial r(p), F(p) \big > = 0\) for all \(F \in {\mathscr {L}}_{m-1}\) while \(\big < \partial r(p), F(p) \big > \ne 0\) for some \(F \in {\mathscr {L}}_{m}\).

Here, we denote the contractions between a cotangent vector and a tangent vector by \(\big <, \big>\). We shall refer to the type at a point p as defined above as the Bloom-Graham type.

3 Catlin Multitype and the Kolář Algorithm

In this section, we describe the Catlin multitype and the Kolář algorithm for the computation of the multitype at the origin in [13]. The notion of weights, distinguished weights, and the multitype was introduced by Catlin in [2]. We will follow the notation and definitions as given by Kolář in [13] and further describe some of the tools that M. Kolář introduced:

Definition 3.1

Let M be a hypersurface in \({\mathbb {C}}^{n+1},\) and let \(p \in M.\) Let \(\Lambda ^{*}=(\mu _1,\ldots ,\mu _n)\) be the greatest lower bound with respect to the lexicographic ordering of all the distinguished weights at p. The multitype \({\mathscr {M}}\) at p is defined to be the n-tuple \((m_1,\ldots , m_n)\), where \(m_j = \infty \) if \(\mu _j =0\) and \(m_j= \frac{1}{\mu _j}\) if \(\mu _j \ne 0\). We call the multitype \({\mathscr {M}}\) at p finite, if the last entry \(m_n< \infty \).

The next theorem from [2] clarifies the relationship between the multitype and the D’Angelo type for a pseudoconvex domain:

Theorem 3.1

(Catlin). Let \(\Omega \subset {\mathbb {C}}^{n+1}\) be a pseudoconvex domain smooth boundary. Let \(p_0\in b\Omega \) be a boundary point. If \({\mathscr {M}}(p_0)=(m_1,\ldots , m_n)\) is the multitype at \(p_0\), then for each \(q=1, \ldots , n,\) \(m_{n+1-q} \le \Delta _q(b\Omega , p_0),\) where \( \Delta _q(b\Omega , p_0)\) is the D’Angelo q-type at \(p_0\).

For the purposes of this paper, we shall assume finite D’Angelo 1-type at any point \(p \in M,\) since this assumption by Theorem 3.1 ensures that all the entries of the multitype are finite, which is the exact setting in which the Kolář algorithm works.

For a weight \(\Lambda \), we say the local coordinates on M at p are \(\Lambda \)-adapted if M is described locally to have the form in (2.1), where P is \(\Lambda \)-homogeneous. We shall refer to \(\Lambda ^{*}\)-adapted coordinates as the multitype coordinates given such that P is \(\Lambda ^*\)-homogeneous.

Let \(\gamma _j\), \(j=1, \ldots , c\), be the length of the jth constant piece of the multitype weight given such that c is the number of distinct entries in the multitype. Let \(\sum _{i=1}^j \gamma _i = k_j\), then we have

$$\begin{aligned} \mu _1= \cdots =\mu _{k_1}> \mu _{k_1+1} = \cdots = \mu _{k_2}> \cdots = \mu _{k_{c-1}} > \cdots = \mu _{k_{c-1}+1} = \cdots = \mu _n, \end{aligned}$$

where \(n = k_c.\) We define a monotone sequence of weights \(\Lambda _1, \ldots , \Lambda _c\) which are ordered lexicographically as follows. \(\Lambda _1\) is a constant n-tuple \((\mu _1, \ldots , \mu _1)\) and \(\Lambda _c = \Lambda ^{*}\) is the multitype weight. We then define the weight \(\Lambda _j = (\lambda _1^j, \ldots , \lambda _n^j)\) for \(1< j <c\), by \(\lambda _i^j = \mu _i\) for \(i \le k_{j-1}\) and \(\lambda _i^j = \mu _{k_{j-1}+1}\) for \(i > k_{j-1}\). Note that this construction yields a finite sequence of weights even if \(\Lambda ^*\) has some zero entries.

Definition 3.2

Fix \(\Lambda ^{*}\)-adapted local coordinates. The leading polynomial P is defined as follows:

$$\begin{aligned} P(z, {\bar{z}}) = \sum _{|(\alpha , {\hat{\alpha }})|_{\Lambda ^{*}} = 1} C_{\alpha ,{\hat{\alpha }}} z^{\alpha } {\bar{z}}^{{\hat{\alpha }}}. \end{aligned}$$
(3.1)

The polynomial defined in (3.1) is exactly the polynomial that only retains the terms of weight 1. Put differently, it is a \(\Lambda ^{*}\)-homogeneous polynomial of weighted degree 1 with no pluriharmonic terms, where \(\Lambda ^{*}\) is the multitype weight. Following Kolář in [13], we will also denote by leading polynomial the polynomial consisting of all terms of weight 1 with respect to each intermediate weight \(\Lambda _j\) in the Kolář algorithm.

Theorem 3.2

(Kolář) A biholomorphic transformation takes \(\Lambda ^{*}\)-adapted coordinates into \(\Lambda ^{*}\)-adapted coordinates if and only if this transformation is \(\Lambda ^{*}\)-superhomogeneous.

We will now describe the Kolář algorithm for the computation of the multitype and apply this theorem under the assumption that all entries of the multitype are finite.

The Kolář Algorithm We start by considering local holomorphic coordinates in which the leading polynomial in the variables z and \({\bar{z}}\) contains no pluriharmonic terms. The degree of the lowest order monomial in this polynomial is then equal to the Bloom-Graham type of M at p as defined in [1]. This gives the first multitype component \(m_1;\) see [2]. By our assumption, \(1< m_1 < +\infty .\) Let \(m_1 = \frac{1}{\mu _1}\) and set \(\Lambda _1 = (\mu _1, \ldots , \mu _1)\). We then consider all \(\Lambda _1\)-homogeneous transformations and choose one that will make the leading polynomial \(P_1\) to be independent of the largest number of variables. We denote this number by \(d_1.\) So for such coordinates, we get the defining function of M to be of the form:

$$\begin{aligned} v = P_1(z_1, \ldots , z_{n-d_1}, {\bar{z}}_1, \ldots , {\bar{z}}_{n-d_1}) + Q_1(z, {\bar{z}}) + o(u), \end{aligned}$$

where \(P_1\) is \(\Lambda _1\)-homogeneous of weighted degree 1 and \(Q_1\) is \(o_{\Lambda _1}(1)\). We use the result that for any weight \(\Lambda \) which is lexicographically smaller than \(\Lambda _1,\) \(\Lambda \)-adapted coordinates are also \(\Lambda _1\)-adapted coordinates and the fact that \(\Lambda _1\)-homogeneous transformation is linear, to conclude that \(\mu _1 = \cdots = \mu _{n-d_1}\) and \(\mu _{n-d_1+1} < \mu _1\). We define the following important tools:

$$\begin{aligned} \Theta _1 = \left\{ (\alpha , {\hat{\alpha }})| \ C_{\alpha , {\hat{\alpha }}}^1 \ne 0 \; \text {and} \; \sum _{i=1}^{n-d_1} (\alpha _i + {\hat{\alpha }}_i) \mu _i < 1 \right\} , \end{aligned}$$

and also

$$\begin{aligned} Q_1(z, {\bar{z}}) = \sum _{|(\alpha , {\hat{\alpha }})|_{\Lambda _1} > 1} C_{\alpha ,{\hat{\alpha }}}^1 z^{\alpha } {\bar{z}}^{{\hat{\alpha }}}. \end{aligned}$$

For every \((\gamma , {\hat{\gamma }}) \in \Theta _1\),

$$\begin{aligned} W_1(\gamma , {\hat{\gamma }}) = \frac{1 - \sum _{i=1}^{n-d_1}(\gamma _i + {\hat{\gamma }}_i) \mu _i}{\sum _{i=n-d_1+1}^{n}(\gamma _i + {\hat{\gamma }}_i)}. \end{aligned}$$
(3.2)

We define the next weight \(\Lambda _2\) by letting

$$\begin{aligned} \lambda _j^2 = \max _{(\alpha , {\hat{\alpha }}) \in \Theta _1} \text {W}_1(\alpha ,{\hat{\alpha }}) \end{aligned}$$

for \(j > n-d_1\) and \(\lambda _j^2= \mu _1\) for \(j \le n-d_1\). We then complete the second by letting \(P_2\) be the new leading polynomial corresponding to the weight \(\Lambda _2\). \(P_2\) depends on more than \(n-d_1\) variables.

We proceed by induction. At the jth step, for \(j>2,\) using coordinates from the previous step, we consider all \(\Lambda _{j-1}\)-homogeneous transformations and choose one that makes the leading polynomial \(P_{j-1}\) to be independent of the largest number of variables. We fix such coordinates, and let \(d_{j-1}\) be the largest number of variables, which do not show up in \(P_{j-1}\) after this change of variables. By Theorem 3.2, the transformations taking \(\Lambda _{j-1}\)-adapted coordinates into \(\Lambda _{j-1}\)-adapted coordinates are always \(\Lambda _{j-1}\)-superhomogeneous. The number of multitype entries that are added at each step of the computation depends on the difference \((d_{j-2} - d_{j-1})\). Hence, we consider two cases in this step:

  • Case 1 Assume that \(d_{j-2} > d_{j-1}\). Also recall that for any weight \(\Lambda \) that is smaller than \(\Lambda _{j-1}\) with respect to the lexicographic ordering, \(\Lambda \)-adapted coordinates are also \(\Lambda _{j-1}\)-adapted. This implies that we get \((d_{j-2} - d_{j-1})\) multitype entries

    $$\begin{aligned} \mu _{n-d_{j-2}+1} = \cdots = \mu _{n-d_{j-1}} = \lambda _{n- d_{j-2}+1}^{j-1} \end{aligned}$$

    and let \(\lambda _i^j=\mu _i\) for \(i \le n - d_{j-1}- 1\). To obtain \(\lambda _i^j\) for \(j>n-d_{j-1}-1\), we consider

    $$\begin{aligned} v = P_{j-1}(z_1, \ldots , z_{n-d_{j-1}}, {\bar{z}}_1, \ldots , {\bar{z}}_{n-d_{j-1}}) + Q_{j-1}(z, {\bar{z}}) + o(u), \end{aligned}$$

    where \(Q_{j-1}\) is \(o_{\Lambda _{j-1}}(1)\) and \(P_{j-1}\) is \(\Lambda _{j-1}\)-homogeneous of weighted degree 1. We define \(Q_{j-1}\), \(\Theta _{j-1}\), and \(W_{j-1}\) in a similar way as in step two. Thus,

    $$\begin{aligned} \Theta _{j-1} = \left\{ (\alpha , {\hat{\alpha }})| \ C_{\alpha , {\hat{\alpha }}}^{j-1} \ne 0 \; \text {and} \; \sum _{i=1}^{n-d_{j-1}} (\alpha _i + {\hat{\alpha }}_i) \mu _i < 1 \right\} , \end{aligned}$$

    and also

    $$\begin{aligned} Q_{j-1}(z, {\bar{z}}) = \sum _{|(\alpha , {\hat{\alpha }})|_{\Lambda _{j-1}} > 1} C_{\alpha ,{\hat{\alpha }}}^{j-1} z^{\alpha } {\bar{z}}^{{\hat{\alpha }}}. \end{aligned}$$

    For every \((\gamma , {\hat{\gamma }}) \in \Theta _{j-1}\),

    $$\begin{aligned} W_{j-1}(\gamma , {\hat{\gamma }}) = \frac{1 - \sum _{i=1}^{n-d_{j-1}}(\gamma _i + {\hat{\gamma }}_i) \mu _i}{\sum _{i=n-d_{j-1}+1}^{n}(\gamma _i + {\hat{\gamma }}_i)}. \end{aligned}$$
    (3.3)

    So for the remaining multitype entries of \(\Lambda _j\), we let

    $$\begin{aligned} \lambda _i^j = \max _{(\alpha , {\hat{\alpha }}) \in \Theta _{j-1}} W_{j-1}(\alpha ,{\hat{\alpha }}), \end{aligned}$$

    for \(i > n-d_{j-1}\).

  • Case 2 Assume that \(d_{j-1} = d_{j-2}\). There are zero multitype entries computed in this case and so we only determine \(\lambda _i^j\) for \(j > n-d_{j-1}\) using (3.3). This completes the jth step of the computation.

The process terminates after a finite number of steps to give all the entries of the multitype weight \(\Lambda ^{*}\). It is clear that case 1 advances the process. We just need to show that the number of times case 2 occurs where no multitype entries are determined can only happen finitely many times. We claim case 2 can take place at most \(\lceil \frac{1}{\mu _n} \rceil ^{n - d_{j-1} + 1}\) times, where \(\lceil \frac{1}{\mu _n} \rceil \) is the ceiling for the rational number \(\frac{1}{\mu _n}.\) Indeed, it comes down to the number of different values that (3.3) can have. The upper bound for the numerator is given by \(\lceil \frac{1}{\mu _n} \rceil ^{n - d_{j-1}}\) as the \(\mu _i\) entries are decreasing, whereas the upper bound for the denominator is given by \(\lceil \frac{1}{\mu _n} \rceil .\)

Example 1

Let \(M \subset {\mathbb {C}}^4\) be a real hypersurface near the origin given by \(r =0\) with

$$\begin{aligned} r = 2\text {Re}(z_4 ) + |z_1-z_2+z_3^2|^2 + |z_1^2-z_2^2|^2. \end{aligned}$$

Using the Kolář algorithm, we proceed as follows: The Bloom-Graham type is 2, which implies that \(\mu _1 = \frac{1}{2}\) and \(\Lambda _1 = (\frac{1}{2}, \frac{1}{2}, \frac{1}{2})\). Thus, \(P_1=|z_1-z_2|^2.\) We consider all \(\Lambda _1\)-homogeneous transformation and choose

$$\begin{aligned} {\tilde{z}}_1 = z_1 - z_2, \quad \text {and} \quad {\tilde{z}}_j = z_j, \end{aligned}$$

for \(j = 2, 3, 4,\) to obtain a leading polynomial \(P_1\) independent of the variables \(z_2\) and \(z_3\). We write r in the new variables and ignore \(\sim \) when no confusion arises. Then \(P_1 = |z_1|^2\) with \(d_1 = 2.\) The leftover polynomial is

$$\begin{aligned} Q_1 = |z_3^2|^2 + 2\text {Re}(z_1 {\bar{z}}_3^2) + |z_1^2|^2 + 4\text {Re}(z_1^2 {\bar{z}}_1 {\bar{z}}_2) +4|z_1z_2|^2. \end{aligned}$$

\(\Lambda _2 = (\frac{1}{2}, \frac{1}{4}, \frac{1}{4}),\) where the maximum number \(\max (W_1) = \frac{1}{4}\). We consider all \(\Lambda _2\)-homogeneous transformations and choose

$$\begin{aligned} {\tilde{z}}_1 = z_1 + z_3^2 \; \text {and} \; {\tilde{z}}_j = z_j \end{aligned}$$

for \(j = 2,3,4,\) which makes the leading polynomial independent of the variables \(z_2\) and \(z_3\). In the new variables, \(P_2 = |z_1|^2\) with \(d_2 = 2\) and

$$\begin{aligned} \begin{aligned} Q_2&= |z_1^2|^2 + 4|z_1z_3^2|^2 + 4\text {Re}(z_1^2 {\bar{z}}_1{\bar{z}}_3^2) + |z_3^4|^2 + 2\text {Re}(z_1^2 {\bar{z}}_3^4) \\&\quad + 4\text {Re}(z_1z_3^2 {\bar{z}}_3^4) + 4|z_1z_2|^2 + 4\text {Re}(z_1^2 {\bar{z}}_1{\bar{z}}_2) \\&\quad + 8\text {Re}(z_1z_3^2 {\bar{z}}_1{\bar{z}}_2)+ 4\text {Re}(z_3^4 {\bar{z}}_1{\bar{z}}_2) + 4|z_2z_3^2|^2 - 4\text {Re}(z_1^2 {\bar{z}}_2{\bar{z}}_3^2) - 8\text {Re}(z_1z_3^2 {\bar{z}}_2{\bar{z}}_3^2) \\&\quad - 4\text {Re}(z_3^4 {\bar{z}}_2{\bar{z}}_3^2) - 8\text {Re}(z_1z_2 {\bar{z}}_2{\bar{z}}_3^2). \end{aligned} \end{aligned}$$

\(\Lambda _3 = (\frac{1}{2}, \frac{1}{6}, \frac{1}{6})\) with \(\max (W_2)= \frac{1}{6}.\) Here, no \(\Lambda _3\)-homogeneous transformation can make \(P_3\) to be independent of any variables and so \(d_3 = 0.\) Hence,

$$\begin{aligned} P_3 = |z_1|^2 + 4|z_2z_3^2|^2. \end{aligned}$$

4 Squares of Monomials and the Multitype Entries

We will show in this section that the set of monomials that give the maximum W-value at each step of the Kolář algorithm always consists of both squares of moduli of monomials and cross terms. Since the entries in the multitype depend on the maximum W-values, it will suffice to establish that for each entry of the multitype, there is always a square that gives the corresponding multitype entry.

As hinted in the introduction, we rely on the Kolář algorithm for the computation of the multitype in [13] to develop tools to study the stratification by multitype level sets of the boundary of a domain given by a sum of squares of holomorphic functions. We seek a tool that will enable us to effectively interpret our results both geometrically and algebraically. As such, we resort to reducing the problem to the study of the ideal of the holomorphic functions in the sum. For the transition to be effective, we need to establish that a natural modification of the Kolář algorithm still holds at the level of ideals.

The ensuing lemma gives the foundational result we need in order to transition from the sums of squares case to the case of ideals of holomorphic functions in \({\mathbb {C}}^n.\) We use the result from this lemma to prove Theorems 1.1 and 1.2.

Lemma 4.1

Let f and g be monomials with nonzero coefficients from the Taylor expansion of h,  where h is a generator from a sum of squares domain in \({\mathbb {C}}^{n+1}\). Let \(P_t\) for \(t \ge 1\) be the leading polynomial at step t of the Kolář algorithm, and let \(W_t\) be the number computed at the \((t+1)\)th step.

  1. A.

    If \(W_t(|f|^2) = W_t(|g|^2)\), then \(W_t(f{\bar{g}})= W_t(|f|^2) = W_t(|g|^2)\).

  2. B.

    If \(W_t(|f|^2) < W_t(|g|^2)\), then \( W_t(|f|^2)< W_t(f{\bar{g}}) < W_t(|g|^2)\).

  3. C.

    If \(W_t(|f|^2)\) cannot be computed, then

    1. i.

      \(W_t(f{\bar{g}}) \le W_t(|g|^2)\) for any monomial g for which both \(W_t(|g|^2)\) and \(W_t(f{\bar{g}})\) can be computed.

    2. ii.

      \(W_t(f{\bar{g}})\) cannot be computed for any monomial g for which \(W_t(|g|^2)\) cannot be computed.

  4. D.

    If f is such that \(|f|^2\) is in the leading polynomial \(P_t\), then

    1. i.

      For any monomial g for which \(W_t(|g|^2)\) can be computed, \(W_t(f{\bar{g}})= W_t(|g|^2)\).

    2. ii.

      For any monomial g for which \(W_t(|g|^2)\) cannot be computed, \(W_t(f{\bar{g}})\) cannot be computed as well.

Here \(W_t(f):= W_t(\alpha ,{\hat{\alpha }})\) where \((\alpha , {\hat{\alpha }})\) is the pair of multiindices corresponding to the monomial f.

Remark 4.1.1

We shall say the quantity \(W_t(f)\)cannot be computed” if the pair of multiindices \((\alpha , {\hat{\alpha }})\) corresponding to the monomial f is not an element of \(\Theta _t.\) In other words, \(W_t(f)\) cannot be computed if the numerator of the fraction giving \(W_t(f)\) is not positive; see (4.1) below.

Remark 4.1.2

We note here that \(W_t(f{\bar{g}})\) and \(W_t({\bar{f}} g)\) corresponding to the cross terms \(f {{\bar{g}}}\) and \({{\bar{f}}} g\), respectively, are equal.

Proof

Let \(z_1, \ldots , z_c\) be the variables in the leading polynomial \(P_t\), and let the weight \(\Lambda _t = (\mu _1, \ldots ,\mu _c, \mu _{c+1}, \ldots ,\mu _n)\). We begin by recalling that

$$\begin{aligned} W_t(\alpha , {\hat{\alpha }}) = \frac{1 - \sum _{i=1}^{c}(\alpha _i+{\hat{\alpha }}_i)\mu _i}{\sum _{i=c +1}^n(\alpha _i+{\hat{\alpha }}_i)}, \end{aligned}$$
(4.1)

where \((\alpha , {\hat{\alpha }}) = (\alpha _1, \ldots , \alpha _n, {\hat{\alpha }}_1,\ldots , {\hat{\alpha }}_n)\) is the multiindex of the monomial of which \(W_t\) is being computed.

Let \(\Gamma _1\) be the set of all nonzero monomials that consist of only variables not in \(P_t\), let \(\Gamma _2\) be the set of all nonzero monomials which consist of variables both in \(P_t\) as well as variables not in \(P_t\), and let \(\Gamma _3\) be the set of all nonzero monomials which consist of only variables in \(P_t\). If \(W_t(|f|^2)\) can be computed, then \(f \in \Gamma _1\) or \(f \in \Gamma _2\) only. We will now prove f cannot belong to \(\Gamma _3.\) We assume the opposite, namely that \(f \in \Gamma _3\) and that \(W_t(|f|^2)\) can be computed. The monomial \(|f|^2\) has weight \(\ge 1\) with respect to \(\Lambda _t,\) and since \(f \in \Gamma _3,\) it follows that the numerator of \(W_t(|f|^2)\) is \(\le 0.\) Therefore, \(W_t(|f|^2)\) cannot be computed, which is a contradiction. Without loss of generality, we now specify to \(f \in \Gamma _1\) or \(f \in \Gamma _2\) for all parts of the lemma pertaining to the case when \(W_t(|f|^2)\) can be computed (and similarly for g).

Since \(f \in \Gamma _1\) or \(f \in \Gamma _2\), we can write \(f = f_1\, f_2\) where \(f_1\) and \(f_2\) are monomials satisfying \(f_1 \in \) \(\Gamma _3\) and \(f_2 \in \Gamma _1\). Let \(f_1 = z_1^{\alpha _1} \ldots z_c^{\alpha _c},\) where \(z_1, \ldots , z_c\) are the variables in the leading polynomial \(P_t\), and \(f_2= C_f z_{c+1}^{\beta _{c+1}} \ldots z_n^{\beta _n}\) for \(C_f \in {\mathbb {C}}.\) If \(W_t(|f|^2)\) can be computed, by our definition of f, the multiindices \(\alpha \) and \(\beta \) corresponding to monomials \(f_1\) and \(f_2\), respectively, must satisfy \(|\alpha | \ge 0\) and \(|\beta | > 0\). If \(|\alpha | =0\), then \(f \in \Gamma _1,\) and if \(|\alpha | >0\), then \(f \in \) \(\Gamma _2.\) Here \(|\alpha |= \alpha _1 + \cdots + \alpha _c\) as the rest of the entries are zero, and \(|\beta |=\beta _{c+1}+\cdots + \beta _n\) for the same reason. Now, \(|f|^2 = f_1{\bar{f}}_1 f_2{\bar{f}}_2\) with \(|\alpha |=|{\hat{\alpha }}|\) and \(|\beta | = |{\hat{\beta }}|\). Hence,

$$\begin{aligned} W_t(|f|^2) = \frac{1 - \sum _{i=1}^{c}(\alpha _i+{\hat{\alpha }}_i)\mu _i}{|\beta | + |{\hat{\beta }}|} = \frac{\frac{1}{2} - \sum _{i=1}^c \alpha _i\mu _i}{|\beta |}. \end{aligned}$$
(4.2)

Similarly, let \(g = g_1g_2\), where \(g_1 \in \Gamma _3\) and \(g_2 \in \Gamma _1.\) Let \(\gamma \) and \(\tau \) be the multiindices corresponding to monomials \(g_1\) and \(g_2\), respectively. Here \(g_1 = z_1^{\gamma _1} \ldots z_c^{\gamma _c}\) and \(g_2= C_g z_{c+1}^{\tau _{c+1}} \ldots z_n^{\tau _n}\) for \(C_g \in {\mathbb {C}}.\) By a similar computation as carried out above for f

$$\begin{aligned} W_t(|g|^2) = \frac{\frac{1}{2} - \sum _{i=1}^c\gamma _i\mu _i}{|\tau |}. \end{aligned}$$
(4.3)
  1. A.

    Suppose that \(W_t(|f|^2) = W_t(|g|^2)\) and consider

    $$\begin{aligned} W_t(f{\bar{g}})= & {} \frac{1 - \sum _{i=1}^{c}\alpha _i \mu _i - \sum _{i=1}^c {\hat{\gamma }}_i \mu _i}{|\beta | + |\tau |} \nonumber \\= & {} \frac{\frac{1}{2} - \sum _{i=1}^{c}\alpha _i \mu _i + \frac{1}{2} - \sum _{i=1}^c \gamma _i\mu _i}{|\beta | + |\tau |}\nonumber \\= & {} \frac{|\beta | W_t(|f|^2)+ |\tau | W_t(|g|^2)}{|\beta | + |\tau |} \text {from}\;(4.2)\text { and }(4.3)\text { by cross multiplication.}\nonumber \\= & {} W_t(|f|^2) = W_t(|g|^2) \ \quad \text {by our hypothesis.} \end{aligned}$$
    (4.4)
  2. B.

    Suppose that \(W_t(|f|^2) < W_t(|g|^2)\). Then from (A.) we get that

    $$\begin{aligned} \begin{aligned} W_t(f{\bar{g}})&= \frac{\frac{1}{2} - \sum _{i=1}^{c}\alpha _i \mu _i + \frac{1}{2} - \sum _{i=1}^c \gamma _i\mu _i}{|\beta | + |\tau |}\\&= \frac{|\beta | W_t(|f|^2)+ |\tau | W_t(|g|^2)}{|\beta | + |\tau |} \quad \text {from }(4.2)\text { and }(4.3)\\&< \frac{|\beta | W_t(|g|^2)+ |\tau | W_t(|g|^2)}{|\beta | + |\tau |} \quad \text {since} \; W_t(|f|^2) < W_t(|g|^2)\\&= W_t(|g|^2). \end{aligned} \end{aligned}$$
    (4.5)

    Again

    $$\begin{aligned} \begin{aligned} W_t(f{\bar{g}}) = \frac{|\beta | W_t(|f|^2)+ |\tau | W_t(|g|^2)}{|\beta | + |\tau |} > W_t(|f|^2) \end{aligned} \end{aligned}$$
    (4.6)

    since \(W_t(|f|^2) < W_t(|g|^2)\). Thus, from (4.5) and (4.6), we obtain

    $$\begin{aligned} W_t(|f|^2)< W_t(f{\bar{g}}) < W_t(|g|^2). \end{aligned}$$
  3. C.

    i. Suppose that \(W_t(|f|^2)\) cannot be computed. Then clearly \(f \notin \Gamma _1.\) We know that \(f = f_1f_2\) and that \(|\alpha | > 0\) and \(|\beta | \ge 0\). If \(W_t(|f|^2)\) cannot be computed, then we get that \(\sum _{i=1}^c (\alpha _i + {\hat{\alpha }}_i)\mu _i \ge 1.\) Thus, \(\sum _{i=1}^c \alpha _i \mu _i \ge 1/2\) since \(\alpha _i = {\hat{\alpha }}_i\) for all \(i, \ 1 \le i \le c.\) Let \(g = g_1g_2\), where \(g_1 \in \Gamma _3\) and \(g_2 \in \Gamma _1.\) \(W_t(|g|^2)\) and \(W_t(f{\bar{g}})\) can be computed, and so g cannot belong to \(\Gamma _3,\) which implies the multiindex corresponding to \(g_2\) must satisfy \(|\tau | >0\). Therefore,

    $$\begin{aligned} \begin{aligned} W_t(f{\bar{g}})&= \frac{\frac{1}{2} - \sum _{i=1}^{c}\alpha _i \mu _i + \frac{1}{2} - \sum _{i=1}^c \gamma _i\mu _i}{|\beta | + |\tau |}\\&= \frac{\frac{1}{2} - \sum _{i=1}^{c}\alpha _i \mu _i + |\tau | \, W_t(|g|^2)}{|\beta | + |\tau |} \ \quad \text {from }(4.3)\\&\le \frac{|\tau |}{|\beta | + |\tau |} W_t(|g|^2) \ \quad \text {since} \ \frac{1}{2} - \sum _{i=1}^c \alpha _i \mu _i \le 0\\&\le W_t(|g|^2) \ \quad \text {since} \ \frac{|\tau |}{|\beta | + |\tau |} \le 1. \end{aligned} \end{aligned}$$
    (4.7)
  4. ii.

    From (C.i.) we know that \(f = f_1f_2 \notin \Gamma _1\) and also that \(\sum _{i=1}^c \alpha _i \mu _i \ge 1/2\) since \(\alpha _i = {\hat{\alpha }}_i\) for all \(i, \ 1 \le i \le c.\) Similarly, for \(g = g_1g_2\) it means that \(g \notin \Gamma _1\) and that \(\sum _{i=1}^c \gamma _i \mu _i \ge 1/2\). Thus, \(\sum _{i=1}^c (\alpha _i + \gamma _i)\mu _i \ge 1\), and so the pair of multiindices corresponding to the cross term \(f{\bar{g}}\) is not in the set \(\Theta _t\). Hence, the number \(W_t(f{\bar{g}})\) cannot be computed.

  5. D.

    i. Suppose that f is such that \(|f|^2\) is in the leading polynomial \(P_t\). Then \(f \in \Gamma _3,\) which implies that \(f = f_1f_2\) with \(|\beta | =0\), that is, \(f = C f_1\) for C a nonzero constant. Let \(g = g_1g_2\) be any monomial such that \(W_t(|g|^2)\) can be computed. Clearly, \(g \notin \Gamma _3,\) and so \(|\tau | >0\) whereas \(|\gamma | \ge 0.\) We know from (4.3) that

    $$\begin{aligned} W_t(|g|^2) = \frac{\frac{1}{2} - \sum _{i=1}^c\gamma _i\mu _i}{|\tau |}. \end{aligned}$$

    Given that \(|f|^2\) is a term in \(P_t\), \(\sum _{i=1}^c (\alpha _i+ {\hat{\alpha }}_i)\mu _i = 1\) since \(P_t\) is a \(\Lambda _t\)-homogeneous polynomial of weighted degree 1. Thus, \(\sum _{i=1}^c \alpha _i\mu _i = 1/2\) since \(\alpha _i = {\hat{\alpha }}_i\) for all \(i, \ 1 \le i \le c.\) Now

    $$\begin{aligned} \begin{aligned} W_t(f{\bar{g}})&= \frac{\frac{1}{2} - \sum _{i=1}^{c}\alpha _i \mu _i + \frac{1}{2} - \sum _{i=1}^c \gamma _i\mu _i}{|\beta | + |\tau |}\\&= \frac{\frac{1}{2} - \sum _{i=1}^{c}\alpha _i \mu _i + \frac{1}{2} - \sum _{i=1}^c \gamma _i\mu _i}{|\tau |} \ \quad \text {since} \ |\beta | =0\\&= \frac{\frac{1}{2} - \sum _{i=1}^{c}\gamma _i \mu _i}{|\tau |} \ \quad \text {since} \ \sum _{i=1}^c \alpha _i \mu _i= \frac{1}{2}\\&= W_t(|g|^2). \end{aligned} \end{aligned}$$
    (4.8)
  6. ii.

    Let \(g = g_1g_2\) be any monomial such that \(W_t(|g|^2)\) cannot be computed. From (D.i.) we know that \(\sum _{i=1}^c \alpha _i\mu _i = 1/2\) and from (C.ii.) we know that \(\sum _{i=1}^c \gamma _i\mu _i \ge 1/2\). Thus,

    $$\begin{aligned} \sum _{i=1}^c (\alpha _i + {\hat{\gamma }}_i)\mu _i = \sum _{i=1}^c (\alpha _i + \gamma _i)\mu _i = \frac{1}{2} + \sum _{i=1}^c \gamma _i \mu _i \ge 1. \end{aligned}$$

    Hence the pair of multiindices corresponding to the cross term \(f{\bar{g}}\) does not belong to the set \(\Theta _t\), and so the number \(W_t(f{\bar{g}})\) cannot be computed.

\(\square \)

Remark 4.1.3

The terms that are added to the leading polynomial \(P_t\) at step t of the Kolář algorithm are the terms needed to compute the multitype. Clearly, the maximum \(W_t\) at every step is always assumed by a square of a monomial. All the cross terms that are added to the leading polynomial could be eliminated without changing the multitype. Most importantly, the multitype of M at the origin will not change if:

  1. i.

    All the cross terms are eliminated from the expansion of \(|h|^2,\) where h is a generator of a sum of squares domain and

  2. ii.

    All the squares that do not appear in the final leading polynomial are added to our data.

5 Proofs of the Main Results

We give the proofs of the two main theorems in this section. As hinted in the introduction, we shall use the result from Lemma 4.1 to prove Theorems 1.1 and 1.2. By our convention in this paper, we assume without loss of generality that the domains we work with are decoupled as mentioned in the introduction. We start by proving a more general result than Theorem 1.1.

Theorem 5.1

Let \(0 \in M \subset {\mathbb {C}}^{n+1}\) be a hypersurface of which defining function is given as

$$\begin{aligned} r(z) = 2\mathrm{Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_n)|^2, \end{aligned}$$

where \(f_1, \ldots , f_N\) are holomorphic functions near the origin and assume that the D’Angelo 1-type of M at the origin is finite. Then the leading polynomial \(P_t(z_1,\ldots , z_{n-d_t},{\bar{z}}_1,\ldots , {\bar{z}}_{n-d_t})\) obtained at step t of the Kolář algorithm, for \(t \ge 1,\) is a sum of squares of holomorphic polynomials. In particular, the final leading polynomial \(P(z_1,\ldots , z_n,{\bar{z}}_1,\ldots , {\bar{z}}_n)\) corresponding to the multitype weight is likewise a sum of squares.

Proof

We order the generators \(f_k\) by vanishing order. We truncate each generator \(f_k\) up to order \(\beta =\lceil \Delta _1(M,0) \rceil ,\) the ceiling of the D’Angelo 1-type of M at the origin, and denote it by \(f_k^{\beta }.\) Since a sum of squares domain is pseudoconvex, by Theorem 3.1, no terms of higher order than \(\beta \) ought to come into the computation of the multitype. We order the terms in the truncated generator \(f_k^{\beta }\) by vanishing order and also use the reverse lexicographic ordering to reorder the monomials with the same combined degree. Now let \(f_{k,i} = C_{k,i} z_{1}^{{\alpha }_{1}^{k,i}} \ldots z_{n}^{{\alpha }_{n}^{k,i}}\) be the ith monomial in the generator \(f_k^{\beta }\) after ordering by vanishing order. Let the number of distinct combined degrees in the Taylor expansion \(f_k^{\beta }\) be \(\kappa _k\), and let \(\eta _{k,j}\) be the number of nonzero monomials with the same combined degree \(\nu _{k,j}\) in \(f_k^{\beta }\). Thus,

$$\begin{aligned} |f_k^{\beta }|^2 = |f_{k,1} + \cdots + f_{k,\eta _k}|^2, \;\text {where} \; \eta _k = \sum _{j=1}^{\kappa _k} \eta _{k,j}. \end{aligned}$$

Here \(\eta _k\) is the total number of monomials with nonzero coefficients in the power series expansion of the generator \(f_k\) up to order \(\beta .\) In the expansion of \(|f_k^{\beta }|^2,\) we have two types of terms: squares \(|f_{k,i}|^2\) and cross terms \(\text {2Re}(f_{k,j}{\bar{f}}_{k,i})\). For simplicity sake, for each monomial \(f_{k,i}\) in the generator \(f_k^{\beta },\) we write the terms from the expansion of \(|f_k^{\beta }|^2\) into an expression of the form:

$$\begin{aligned} |f_{k,i}|^2 + \sum _{j=1}^{i-1} \ \text {2Re} (f_{k,j}{\bar{f}}_{k,i}), \end{aligned}$$
(5.1)

for \(i=1,2, \ldots , \eta _k.\)

Define \(P_{t,k}\) for \(t \ge 1\) to be the sum in the leading polynomial \(P_t\) at step t consisting of terms from the expansion of \(|f_k^{\beta }|^2\). We could have \(P_{t,k}=0\) for some \(k, \ 1 \le k \le N,\) and for some \(t \ge 1\) if there are no terms from the expansion of \(|f_k^{\beta }|^2\) in the leading polynomial \(P_t\) after the tth step. Thus, \(P_t = \sum _{k=1}^N P_{t,k}\). In order to show that the final leading polynomial \(P_t\) is a sum of squares, it will suffice to show that each \(P_{t,k}\) obtained at each step of the Kolář algorithm is a sum of squares. Note that trivially 0 is a sum of squares.

The Bloom–Graham type is \(2\nu _1\), where \(\nu _1: = \min _{1 \le k \le N} \{\nu _{k,1}\}=\nu _{1,1}\) since the monomials from the expansion of each \(|f_k^{\beta }|^2\) as well as the generators \(f_k\) are ordered by vanishing order. Thus, the leading polynomial \(P_1\) consists of all terms of combined degree \(2\nu _1\). Clearly, \(P_{1,1}\ne 0\), but \(P_{1,k}=0\) for every k such that \(\nu _{k,1} > \nu _1.\) Let k be such that \(P_{1,k}\ne 0,\) and denote by \(m_k \ge 1\) the number of monomials from the Taylor expansion of \(f_k^{\beta }\) that have combined degree \(\nu _1.\) By writing the terms from the expansion of \(|f_k^{\beta }|^2\) into the form given in (5.1), it is easy to see that the first \(m_k\) squares \(|f_{k,i}|^2\) for \(i= 1, \ldots , m_k\) as well as the \(\begin{pmatrix} m_k \\ 2 \ \end{pmatrix}\) cross terms \(\text {2Re}(f_{k,j}{\bar{f}}_{k,i})\) for \(j<i\) all have combined degree \(2\nu _1\). Thus,

$$\begin{aligned} P_{1,k} = |f_{k,1} + \cdots + f_{k,m_k}|^2, \end{aligned}$$
(5.2)

which is obviously a sum of squares. If \(d_1 = 0\), then we are done and \(P_1\) becomes the leading polynomial with multitype weight \(\Lambda _1\). On the other hand, if \(d_1 = n-c\) for \(c <n\), then we proceed to the next step.

In the second step, we assume without loss of generality that the \(W_1\) value of at least one square in \(\text {Q}_1\) can be computed. Then the maximum \(W_1\) value exists, which further implies that some terms from the expansion of \(|f_k^{\beta }|^2\) for some k will be added to the leading polynomial \(P_1\) in order to obtain \(P_2\). \(P_{2,k}\) might be 0 for some k if no terms from the expansion of \(|f_k^{\beta }|^2\) end up in \(P_2\) after this step. Obviously, the interesting case is when \(P_{2,k}\ne 0\). Consider k such that \(P_{2,k}\ne 0\). Suppose that \(u_k\) squares from the expansion of \(|f_k^{\beta }|^2\) give the maximum \(W_1\) value, and let \(|f_{k,c_l}|^2\) for \(l=1, \ldots , u_k\) be these squares. Here \(c_l\) for \(l=1, \ldots , u_k\) is some positive integer between 1 and \(\eta _k\), and \(c_l < c_{l+1}\) for \(l=1, \ldots , u_k-1\). The argument now splits into two cases:

  • Case 1 \(P_{1,k}=0\). By Lemma 4.1, part A, we get exactly \(\begin{pmatrix} u_k \\ 2 \ \end{pmatrix}\) cross terms \(\text {2Re}(f_{k,c_e}{\bar{f}}_{k,c_l})\), which give the maximal value for \(W_1\) and \(c_e < c_l\) for \(1 \le e,l \le u_k\). Combining the \(u_k\) squares with the \(\begin{pmatrix} u_k \\ 2 \ \end{pmatrix}\) cross terms gives

    $$\begin{aligned} P_{2,k}= |f_{k,c_1} + \cdots + f_{k,c_{u_k}}|^2. \end{aligned}$$
    (5.3)
  • Case 2 \(P_{1,k}\ne 0\). Then from Lemma 4.1, part D(i), we know that for each square \(|f_{k,c_l}|^2\) there are exactly \(m_k\) cross terms \(\text {2Re}(f_{k,j}{\bar{f}}_{k,c_l})\) for all \(j < c_l \ \text {and} \ j = 1, \ldots , m_k\) as well as \(l= 1, \ldots , u_k\) that give the maximal value for \(W_1\). We also know from the first case that there are \(\begin{pmatrix} u_k \\ 2 \ \end{pmatrix}\) cross terms \(\text {2Re}(f_{k,c_e}{\bar{f}}_{k,c_l})\) that give the maximal value for \(W_1\), and so we obtain the result that

    $$\begin{aligned} P_{2,k}= |f_{k,1} + \cdots + f_{k,m_k} + f_{k,c_1} + \cdots + f_{k,c_{u_k}}|^2. \end{aligned}$$
    (5.4)

    In the \((t+1)\)th step, we begin by first assuming that the sum \(P_{t,k}\) for some k is a sum of squares because if \(P_{t,k}=0\) the argument is identical to the one given in Case 1. Thus, let \(P_{t,k}\) be given as \(P_{t,k} = |f_{k,b_1} + \cdots + f_{k,b_{v_k}}|^2\), where \(v_k\) is the total number of squares from the expansion of \(|f_k^{\beta }|^2\) in \(P_t\) after step t with \(b_j < b_{j+1}\) for \(j=1, \ldots , v_k-1\). Let’s assume that the \(W_t\) value of at least one square in \(Q_t\) can be computed. This implies that the maximal value for \(W_t\) exists. Assume that \(s_k\) squares from the expansion of \(|f_k^{\beta }|^2\) give the maximum \(W_t\) value, and let \(|f_{k,a_l}|^2\) for \(l=1, \ldots , s_k\) be these squares. From Lemma 4.1, part D(i), we know that for each square \(|f_{k,a_l}|^2\) there are exactly \(v_k\) cross terms \(\text {2Re}(f_{k,j}{\bar{f}}_{k,a_l})\) for all \(j< a_l\) where \(j = b_1, \ldots , b_{v_k}\) and \(l= 1, \ldots , s_k\), which give the maximal value for \(W_t\). By Lemma 4.1, part A, there are \(\begin{pmatrix} s_k \\ 2 \ \end{pmatrix}\) cross terms \(\text {2Re}(f_{k,a_e}{\bar{f}}_{k,a_l})\) which give the maximal value for \(W_t\), and so we obtain the result that

    $$\begin{aligned} P_{t+1,k}= |f_{k,b_1} + \cdots + f_{k,b_{v_k}} + f_{k,a_1} + \cdots + f_{k,a_{s_k}}|^2. \end{aligned}$$
    (5.5)

    Hence, \(P_{t+1,k}\) is a sum of squares. Since the leading polynomial \(P_t\) at each step is a sum of the \(P_{t,k}\)’s, the leading polynomial at each step and subsequently the final leading polynomial is a sum of squares.

Since every change of variables that is allowed in the Kolář algorithm sends each square to a square and keeps the weight of terms in the leading polynomial \(P_t\) the same, it is easy to see that the leading polynomial is still a sum of squares after any change of variables.

Our assumption of finite D’Angelo 1-type implies that the last entry of the multitype is bounded, and so all entries of the multitype weight will be finite. This means that the Kolář algorithm will definitely terminate after a finite number of steps, and so the above procedure can only occur finitely many times. We conclude, therefore that the final leading polynomial corresponding to the last weight in the procedure, the multitype weight, is always a sum of squares, too. \(\square \)

Proof of Theorem 1.1

We know that the final leading polynomial in the Kolář algorithm for computing the multitype at the origin is the model polynomial. Thus, from Theorem 5.1, we conclude that the model of a sum of squares is a sum of squares. \(\square \)

Before we proof Theorem 1.2 we shall consider the following lemma:

Lemma 5.2

Let \( M \subset {\mathbb {C}}^{n+1}\) with \(0 \in M\) be a hypersurface of which defining function is given by

$$\begin{aligned} r(z) = 2\mathrm{Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_n)|^2, \end{aligned}$$

where \(f_1, \ldots , f_N\) are holomorphic functions near the origin. Let \(M' \subset {\mathbb {C}}^{n+1}\) be another hypersurface of which defining function is given as

$$\begin{aligned} u(z) = 2\mathrm{Re}(z_{n+1}) + \sum _{j=1}^{l-1}|f_j|^2 + |h_lf_l - \sum _{c \ne l} h_c f_c|^2 + \sum _{j=l+1}^{N}|f_j|^2, \end{aligned}$$

for some fixed l, where \(h_j\) is a holomorphic function near the origin for every \(j=1,\ldots ,N.\) Assume that the D’Angelo 1-type of M is finite at the origin. Then the multitype obtained by applying Kolář algorithm to both r(z) and u(z) is the same provided that \(\langle f_1, \ldots , f_N \rangle \) and

$$\begin{aligned} \left\langle f_1, \ldots ,f_{l-1},h_lf_l - \sum _{c \ne l} h_c f_c,f_{l+1},\ldots f_N \right\rangle \end{aligned}$$

represent the same ideal in the ring \({\mathcal {O}}.\)

Remark 5.2.1

Modifying only one generator at a time makes the bookkeeping in the computation of the multitype easier to follow.

Remark 5.2.2

Assume that there exist some l such that \(1 \le l \le N\) and holomorphic functions near the origin \(h_1, \ldots , h_{l-1}, h_{l+1}, \ldots , h_N\) such that \(\displaystyle f_l = \sum _{c \ne l} h_c f_c.\) It is clear that \(\langle f_1, \ldots , f_N \rangle \) and \(\langle f_1, \ldots ,f_{l-1},f_{l+1},\ldots f_N \rangle \) represent the same ideal in \({\mathcal {O}}.\) Therefore, applying Lemma 5.2 with \(h_l \equiv 1\) shows that adding in the square \(|f_l|^2 \) or taking it away makes absolutely no difference as far as the multitype computation goes. This observation will be crucial in the proof of Theorem 1.2.

Proof

We will show that the multitype obtained by applying the Kolář algorithm to both r(z) and u(z) is the same. Let \(\beta =\lceil \Delta _1(M,0) \rceil \) be the ceiling of the D’Angelo 1-type of M at the origin. We truncate each generator \(f_k\) as well as each holomorphic function \(h_k\) at the order \(\beta \) and denote them by \(f_k^{\beta }\) and \(h_k^{\beta }\), respectively. Denote by \(f_{k,i}\) the ith monomial from the Taylor expansion of \(f_k^{\beta }\) after ordering by vanishing order and reverse lexicographic order for the monomials with the same vanishing order.

By Lemma 4.1, we know that each entry of the multitype is realized by a square. If no square from the expansion of \(|f_l^{\beta }|^2\) contributes to the entries of the multitype, then the multitype entries for both defining functions r(z) and u(z) are the same, and there is nothing to prove. We, thus, assume that there exists at least one square from the expansion of \(|f_l^{\beta }|^2\) that contributes to the entries of the multitype and that no nonzero multiple of that square exists in any of the expansions of \(|f_1^{\beta }|^2, \ldots , |f_{l-1}^{\beta }|^2, |f_{l+1}^{\beta }|^2, \ldots , |f_N^{\beta }|^2.\)

Next, we claim that if \(h_l (0)=0,\) then no square from the expansion of \(|h_l^{\beta }f_l^{\beta }|^2\) can contribute to the entries of the multitype. Indeed, let \(h_{l,i}\) be the ith monomial from the Taylor expansion of \(h_l^{\beta }\) after ordering by vanishing order and reverse lexicographic order for the monomials with the same vanishing order. For every monomial \(f_{l,j}\) in \( f_l^{\beta },\) the monomial \(h_{l,i}f_{l,s}\) in \( h_l^{\beta }f_l^{\beta }\) has greater combined degree than that of \(f_{l,j}\) for every \(i\ge 1.\) As a result, \(|h_{l,i}f_{l,j}|^2\) cannot give the Bloom-Graham type since the combined degree of \(|f_{l,j}|^2\) is strictly less than the combined degree of \(|h_{l,i}f_{l,j}|^2\). Furthermore, \(W_t(|h_{l,i}f_{l,j}|^2)\) cannot be computed if \(W_t(|f_{l,j}|^2)\) gives the maximum \(W_t\)-value. By the same argument, if \(f_l=\sum _{c \ne l} g_c f_c,\) for \(g_c\) with \(c=1,\ldots , l-1, l+1, \ldots , N\) holomorphic functions near the origin, then no square from the expansion of \(|f_l^{\beta }|^2\) can contribute to the entries of the multitype unless it is the square of the nonzero constant term of some \(g_c\) multiplied by a monomial of \(f_c\) that in itself gives that same multitype entry. Since we assumed the contrary, \(f_l\) cannot be written in terms of the other generators. By our hypothesis, however, \(\langle f_1, \ldots , f_N \rangle \) and \(\langle f_1, \ldots ,f_{l-1},h_lf_l - \sum _{c \ne l} f_ch_c,f_{l+1},\ldots f_N \rangle \) represent the same ideal in the ring \({\mathcal {O}}.\) Putting these two facts together along with our assumption that there exists at least one square from the expansion of \(|f_l^{\beta }|^2\) that contributes to the entries of the multitype and that no nonzero multiple of that square exists in any of the expansions of \(|f_1^{\beta }|^2, \ldots , |f_{l-1}^{\beta }|^2, |f_{l+1}^{\beta }|^2, \ldots , |f_N^{\beta }|^2,\) we conclude that \(h_l (0) \ne 0.\) Without loss of generality, assume \(h_l \equiv 1.\) We shall show that modifying the function \(f_l^{\beta }\) in the sum of squares by the sum \(\sum _{c \ne l} f_c^{\beta }h_c^{\beta }\) does not alter the multitype. We further assume that the sum \(\sum _{c \ne l} f_c^{\beta }h_c^{\beta } \ne 0.\) By Lemma 4.1, it suffices to focus on how the omission of some squares of monomials from the term \(|f_l^{\beta } - \sum _{c \ne l}h_c^{\beta }f_c^{\beta }|^2\) in the defining function u(z) affects our results. We now break our argument into two cases:

  1. Case 1

    Assume that there exists a monomial m in \(f_l^{\beta }\) of which square \(|m|^2\) from the expansion of \(|f_l^{\beta }|^2\) gives the Bloom-Graham type. We consider two subcases here:

  2. i.

    Assume that m is in the expression \(f_l^{\beta } - \sum _{c \ne l}h_c^{\beta }f_c^{\beta }\). Then no monomial in the sum \(\sum _{c \ne l}h_c^{\beta }f_c^{\beta }\) cancels out m. Clearly, the weights obtained at the first step of the Kolář algorithm are the same for both r(z) and u(z) since \(|m|^2\) belongs to both defining functions.

  3. ii.

    Assume that m is not in the expression \(f_l^{\beta } - \sum _{c \ne l}h_c^{\beta }f_c^{\beta }\). Hence, m gets canceled out in the expression \(f_l^{\beta } - \sum _{c \ne l}h_c^{\beta }f_c^{\beta }\) and so does not appear in u(z). Let \(\psi \) be the monomial in the sum \(\sum _{c \ne l} h_c^{\beta }f_c^{\beta }\) that cancels out m,  and write \(\psi = h_{c,i}f_{c,j}\) for some \(c \ne l,\) where \(h_{c,i}\) is some monomial in \(h_c^{\beta }\) and \(f_{c,j}\) is some monomial in \(f_c^{\beta }\). By our assumption, \(\psi \) equals m,  and its square \(|\psi |^2\) gives the Bloom-Graham type as well. The monomial \(h_{c,i}\) cannot have vanishing order 1 or higher; otherwise, \(f_{c,j}\) must have combined degree less than that of \(\psi ,\) which contradicts the fact that \(|\psi |^2\) gives the Bloom-Graham type. Thus, \(h_{c,i} =h_{c,1} \in {\mathbb {C}}\) and \(m = h_{c,1} f_{c,j}.\) Hence, the square \(|f_{c,j}|^2\) gives the Bloom-Graham type as well. Even though there is the cancellation in u(z),  the weight obtained at the first step having applied the Kolář algorithm to r(z) and u(z) is the same. More specifically, the squares \(|f_{c,j}|^2\) and \(|m|^2\) appear in the expansions of \(|f_c^{\beta }|^2\) and \(|f_l^{\beta }|^2\), respectively.

  4. Case 2

    Assume that there exists a monomial m in \(f_l^{\beta }\) of which square \(|m|^2\) from the expansion of \(|f_l^{\beta }|^2\) gives the maximum \(W_t\)-value at the \((t+1)\)th step for \(t \ge 1.\)

  5. i.

    Assume that m is in the expression \(f_l^{\beta } - \sum _{c \ne l}h_c^{\beta }f_c^{\beta }\). Then no monomial in the sum \(\sum _{c \ne l}h_c^{\beta }f_c^{\beta }\) cancels out m,  and so the weights obtained at the \((t+1)\)th step are the same for both r(z) and u(z) since \(|m|^2\) belongs to both defining functions.

  6. ii.

    Assume that m is not in the expression \(f_l^{\beta } - \sum _{c \ne l}h_c^{\beta }f_c^{\beta }\). Then m gets canceled out by some monomial \(\psi \) in the sum \(\sum _{c \ne l} f_c^{\beta }h_c^{\beta }.\) Let \(\psi = h_{c,s}f_{c,j}\) for some s and j,  where \(h_{c,s}\) is some monomial in \(h_c^{\beta }\) and \(f_{c,j}\) is some monomial in \(f_c^{\beta }\). This implies that \(m = \psi \) and \(|\psi |^2\) gives the maximal \(W_t\)-value at step \(t+1\) as well. Now let’s assume that \(h_{c,s} \notin {\mathbb {C}}.\) Then the combined degree of \(f_{c,j}\) is less than that of \(\psi \). If \(W_t(|f_{c,j}|^2)\) cannot be computed, then \(W_t(|\psi |^2)\) cannot be computed, which gives a contradiction. Therefore, we assume that \(W_t(|f_{c,j}|^2)\) can be computed.

At this point let us recall the definition of \(\Gamma _1,\) \(\Gamma _2,\) and \(\Gamma _3\) as given in the proof of Lemma 4.1. Let \(\Gamma _1\) be the set of all nonzero monomials that consist of only variables not in \(\text {P}_t\), let \(\Gamma _2\) be the set of all nonzero monomials which consist of variables both in \(P_t\) as well as variables not in \(P_t\), and let \(\Gamma _3\) be the set of all nonzero monomials which consist of only variables in \(P_t\). Also, recall that for any monomial f if \(W_t(|f|^2)\) can be computed, then \(f \in \Gamma _1\) or \(f \in \Gamma _2\) only. Again, we shall write any monomial f in the form \(f = \gamma _1\, \gamma _2\) where \(\gamma _1\) and \(\gamma _2\) are monomials satisfying \(\gamma _1 \in \Gamma _3\) and \(\gamma _2 \in \Gamma _1.\) Recall that

$$\begin{aligned} W_t(|f|^2) = \frac{1 - \sum _{i=1}^{\kappa }(\alpha _i+{\hat{\alpha }}_i)\mu _i}{\sum _{i=\kappa +1}^n(\alpha _i+{\hat{\alpha }}_i)}, \end{aligned}$$

where \((\alpha _1, \ldots , \alpha _n, {\hat{\alpha }}_1,\ldots , {\hat{\alpha }}_n)\) is the multiindex of the monomial \(|f|^2\) of which \(W_t\) is being computed, \(\kappa \) is the number of variables in the leading polynomial \(P_t\), and \(W_t(|f|^2)\) is the \(W_t\)-value of the term \(|f|^2\).

We shall now consider the number \(W_t(|\psi |^2)\) given that \(W_t(|f_{c,j}|^2)\) can be computed. From Lemma 4.1, \(f_{c,j} \in \Gamma _1\) or \(\Gamma _2.\) Since the monomial \(h_{c,s}\) can belong to \(\Gamma _1,\) \(\Gamma _2,\) or \(\Gamma _3,\) we shall consider three subcases below and assume that \(f_{c,j} \in \Gamma _1\) or \(\Gamma _2\) in each case:

  1. a.

    Assume that \(h_{c,s} \in \Gamma _1.\) Clearly, \(W_t(|f_{c,j}|^2)\) and \(W_t(|\psi |^2)\) both have the same numerator and the denominator of \(W_t(|\psi |^2)\) is greater than that of \(W_t(|f_{c,j}|^2)\) because \(h_{c,s} \in \Gamma _1.\) Thus, \(W_t(|f_{c,j}|^2)\) is greater than \(W_t(|\psi |^2),\) which is a contradiction to our hypothesis that \(W_t(|\psi |^2)\) is maximal at step \(t+1.\)

  2. b.

    Assume that \(h_{c,s} \in \Gamma _2.\) Here, the numerator of \(W_t(|\psi |^2)\) is smaller than the numerator of \(W_t(|f_{c,j}|^2)\) since \(h_{c,s}\) contains a monomial in \(\Gamma _3.\) Also, the denominator of \(W_t(|\psi |^2)\) is greater than the denominator of \(W_t(|f_{c,j}|^2)\) because \(h_{c,s}\) contains a monomial in \(\Gamma _1.\) Thus, \(W_t(|f_{c,j}|^2)\) is greater than \(W_t(|\psi |^2)\), which is again a contradiction.

  3. c.

    Assume that \(h_{c,s} \in \Gamma _3.\) Then \(W_t(|f_{c,j}|^2)\) is always greater than \(W_t(|\psi |^2)\) for \(f_{c,j} \in \Gamma _1\) or \(\Gamma _2\) since the denominators of both numbers are equal and the numerator of \(W_t(|\psi |^2)\) is less than that of \(W_t(|f_{c,j}|^2).\) This gives a contradiction since \(W_t(|\psi |^2)\) is maximal at step \(t+1.\) From cases (a), (b), and (c) we can see that if \(h_{c,s} \notin {\mathbb {C}}\), then \(W_t(|\psi |^2)\) cannot be the maximum at step \(t+1,\) and so we have a contradiction to our hypothesis in all three cases. Hence, \(h_{c,s} \in {\mathbb {C}}\) and so \(m = h_{c,s} f_{c,j}.\) Clearly, \(W_t(|f_{c,j}|^2)\) gives the maximal value at step \(t+1,\) too. This implies that if we apply the Kolář algorithm to both r(z) and u(z),  then the multitype entry at the \((t+1)\)th step will be the same for both defining functions. The squares \(|f_{c,j}|^2\) and \(|m|^2\) appear in the expansions of \(|f_c^{\beta }|^2\) and \(|f_l^{\beta }|^2\), respectively. We see that regardless of the cancellation in u(z),  the weight obtained at the \((t+1)\)th step remains unchanged.

Clearly, the case when \(h_l(0)\ne 0\) combines the analysis for the cases when \(h_l \equiv 1\) and \(h_l (0)=0.\) \(\square \)

Proof of Theorem 1.2

Let \(M \subset {\mathbb {C}}^{n+1}\) with \(0 \in M\) be a hypersurface of which defining function is given by

$$\begin{aligned} r(z) = \text {2Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_n)|^2, \end{aligned}$$
(5.6)

where \(f_1, \ldots , f_N\) are holomorphic functions near the origin. We begin by letting \(M' \subset {\mathbb {C}}^{n+1}\) be another hypersurface of which defining function is given as

$$\begin{aligned} u(z) = \text {2Re}(z_{n+1}) + \sum _{j=1}^{S}|g_j(z_1, \ldots , z_n)|^2, \end{aligned}$$
(5.7)

where \(g_1, \ldots , g_S\) are also holomorphic functions near the origin, and show that the multitype obtained by applying the Kolář algorithm to both r(z) and u(z) is the same provided that \(\langle f_1, \ldots , f_N \rangle \) and \(\langle g_1, \ldots ,g_S \rangle \) represent the same ideal in the ring \({\mathcal {O}}.\)

Let the ideals associated to the hypersurfaces M and \(M'\) be given by \(\langle f \rangle = \langle f_1, \ldots , f_N \rangle \) and \(\langle g \rangle = \langle g_1, \ldots , g_S \rangle \), respectively, and suppose that \(\langle f \rangle = \langle g \rangle .\) By Remark 5.2.2 following the statement of Lemma 5.2, we know that adding in the square of any element of the ideal \(\langle f_1, \ldots , f_N \rangle \) does not modify the multitype because that element can be written in terms of the generators \(f_1, \ldots , f_N\) with coefficients in \({\mathcal {O}}.\) Since \(\langle f_1, \ldots , f_N \rangle =\langle g_1, \ldots , g_S \rangle ,\) each \(g_j\) is an element of \(\langle f_1, \ldots , f_N \rangle \) and can be written in terms of \(f_1, \ldots , f_N\) with coefficients in \({\mathcal {O}}.\) Therefore, (5.6) has the same multitype at the origin as

$$\begin{aligned} r_1(z) = \text {2Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_n)|^2+|g_1(z_1, \ldots , z_n)|^2, \end{aligned}$$

and inductively, the same multitype at the origin as

$$\begin{aligned} r_S(z) = \text {2Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_n)|^2+ \sum _{k=1}^{S}|g_k(z_1, \ldots , z_n)|^2. \end{aligned}$$

Now, we apply the argument in reverse. Since \(\langle g_1, \ldots , g_S \rangle =\langle f_1, \ldots , f_N \rangle ,\) each \(f_j\) is an element of \(\langle g_1, \ldots , g_S \rangle \) and can be written in terms of \(g_1, \ldots , g_S\) with coefficients in \({\mathcal {O}}.\) Therefore, by Remark 5.2.2, (5.7) has the same multitype at the origin as

$$\begin{aligned} u_1(z) = \text {2Re}(z_{n+1}) + \sum _{k=1}^{S}|g_k(z_1, \ldots , z_n)|^2+|f_1(z_1, \ldots , z_n)|^2, \end{aligned}$$

and inductively, as

$$\begin{aligned}r_S(z) = \text {2Re}(z_{n+1}) + \sum _{k=1}^{S}|g_k(z_1, \ldots , z_n)|^2+ \sum _{j=1}^{N}|f_j(z_1, \ldots , z_n)|^2. \end{aligned}$$

We conclude that r(z) and u(z) have the same multitype at the origin, namely that the multitype is an invariant of the ideal of generators. \(\square \)

6 An Ideal Restatement of the Kolář Algorithm

In this section, we give the ideal restatement of the Kolář algorithm for the multitype computation for sum of squares domains in \({\mathbb {C}}^{n+1}.\) Before that, we shall consider the following:

Let \(M \subset {\mathbb {C}}^{n+1}\) be a hypersurface given by \(r =0\) with

$$\begin{aligned} r = \text {2Re}(z_{n+1}) + \sum _{k=1}^{N}|f_k(z_1, \ldots , z_n)|^2, \end{aligned}$$

where \(f_1, \ldots , f_N\) are holomorphic functions defined on a neighborhood of the origin. Assume that the D’Angelo 1-type is finite at the origin and that \(\beta =\lceil \Delta _1(M,0) \rceil ,\) the ceiling of the D’Angelo 1-type of M at the origin. We truncate each holomorphic function \(f_k\) at the order \(\beta \) and let \(f_{k,i}\) be the ith monomial of the generator \(f_k^{\beta }\) after ordering by vanishing order. The ideal corresponding to the defining function r is given as \({\mathcal {I}}=(z_{n+1}, f_1^{\beta }, \ldots , f_N^{\beta })\). We know that the term \(z_{n+1}\) has weight 1. Following the original algorithm of Kolář, we shall ignore the term \(z_{n+1}\) and work with the corresponding ideal \({\mathcal {I}}=(f_1^{\beta }, \ldots , f_N^{\beta })\).

From Theorem 1.1 we know that all leading polynomials produced are sums of squares. Therefore, any leading polynomial \(P_j\) can be written in the form:

$$\begin{aligned} P_j = \sum _{k=1}^N \Big |\sum _{i = 1}^{v_k} f_{k,a_i} \Big |^2, \end{aligned}$$
(6.1)

where the \(f_{k,a_i}\)’s are the monomials from the generator \(f_k^{\beta }\) of weighted degree \(\frac{1}{2}\) with respect to \(\Lambda _j\). We will associate to every leading polynomial \(P_j\) the ideal \({\mathcal {I}}_{P_j}\) given by

$$\begin{aligned} {\mathcal {I}}_{P_j} = \Bigg (\sum _{i = 1}^{v_1} f_{1,a_i}, \ldots , \sum _{i = 1}^{v_N} f_{N,a_i} \Bigg ). \end{aligned}$$
(6.2)

It is convenient to introduce notation for each square in \(P_j.\) Let \(P_{j,k} = \Big |\sum _{i = 1}^{v_k} f_{k,a_i} \Big |^2\). Then its associated ideal \({\mathcal {I}}_{P_{j,k}}\) can be expressed as

$$\begin{aligned} {\mathcal {I}}_{P_{j,k}} = \Bigg (\sum _{i = 1}^{v_k} f_{k,a_i} \Bigg ) = (f_{k,a_1}+\cdots + f_{k,a_{v_k}}) \end{aligned}$$
(6.3)

Clearly,

$$\begin{aligned} {\mathcal {I}}_{P_j} = \sum _{k=1}^N {\mathcal {I}}_{P_{j,k}}. \end{aligned}$$
(6.4)

Recall also that each monomial in every leading polynomial is of weighted degree one with respect to the corresponding weight. As a result, the weighted degree of any monomial \(f_{k,a_i}\) is exactly one half with respect to the corresponding weight.

Thus, given \({\mathcal {I}}_{P_{j,k}} = (f_{k,a_1} +\cdots + f_{k,a_{v_k}})\), the \(f_{k,a_i}\)’s are exactly the monomials from the generator \(f_k^{\beta }\) of weighted degree \(\frac{1}{2}\) with respect to \(\Lambda _j\).

Set the ideal \({\mathcal {I}} = {\mathcal {I}}_0.\) For \(j \ge 1\), the ideals \({\mathcal {I}}_{P_j}, \ {\mathcal {I}}_j, \ \text {and} \ {\mathcal {I}}_{P_{j,k}}\) can be described as follows:

  1. 1.

    \({\mathcal {I}}_{P_j}\) is the ideal of which generators are precisely the terms from the generators of the ideal \({\mathcal {I}}_{j-1}\) having weighted order exactly \(\frac{1}{2}\) with respect to the weight \(\Lambda _j.\) We refer to the ideal \({\mathcal {I}}_{P_j}\) as the leading polynomial ideal.

  2. 2.

    The ideal \({\mathcal {I}}_j\) is the ideal obtained after applying the chosen \(\Lambda _j\)-homogeneous transformation, which makes the generators of \({\mathcal {I}}_{P_j}\) to be independent of the largest number of variables, to \({\mathcal {I}}_{j}\). Simply put, \(I_j\) is the ideal obtained after changing variables in the ideal \({\mathcal {I}}_{j-1}\).

  3. 3.

    \({\mathcal {I}}_{P_{j,k}}\) is the principal ideal of which generator is the sum of monomials in the generator \(f_k^{\beta }\) with weighted degree exactly \(\frac{1}{2}\) with respect to the weight \(\Lambda _j.\) The ideal \({\mathcal {I}}_{P_{j,k}}\) is the zero ideal if no monomial in the generator \(f_k^{\beta }\) has weighted degree \(\frac{1}{2}\) with respect to the weight \(\Lambda _j.\)

The Kolář Algorithm (Ideal Version) Set the ideal \({\mathcal {I}} = {\mathcal {I}}_0,\) and compute the vanishing order at the origin of \({\mathcal {I}}_0\), which is the same as the degree \(\nu _1\) of the lowest order monomial in \({\mathcal {I}}_0\). We define the Bloom-Graham type as twice the vanishing order of \({\mathcal {I}}_0\). This gives the first entry of the multitype \(m_1 \) and so let \(m_1 = 1/\mu _1,\) where \(\mu _1 = 2\nu _1\). Set the first weight to be \(\Lambda _1 = (\mu _1, \ldots , \mu _1)\).

In the second step, consider all \(\Lambda _1\)-homogeneous transformations, and choose one that will make the set of all generators of the leading polynomial ideal \({\mathcal {I}}_{P_1}\) to be independent of the largest number of variables. Denote this number by \(d_1\). In the local coordinates after such a \(\Lambda _1\)-homogeneous transformation, we obtain that \({\mathcal {I}}_{P_1}\) is the ideal of which generators consist of those monomials in the variables \(z_1, \ldots , z_{n-d_1}\), which are of weighted degree 1/2 with respect to \(\Lambda _1.\) Apply the chosen \(\Lambda _1\)-homogeneous transformation to the ideal \({\mathcal {I}}_0\) to obtain the ideal \({\mathcal {I}}_1\). The rest of the terms from the generators in \({\mathcal {I}}_1,\) which are not in \({\mathcal {I}}_{P_1},\) have weighted degrees strictly greater than \(\frac{1}{2}\) with respect to \(\Lambda _1\).

We shall now give a slightly modified version of Kolář’s \(\Theta _1\) and \(W_1\). If \(\alpha ^{k,j} = (\alpha _1^{k,j}, \ldots , \alpha _n^{k,j})\) is the multiindex of a monomial \(f_{k,j}\) from any generator of \({\mathcal {I}}_1\), which is not in \({\mathcal {I}}_{P_1},\) then \(f_{k,j}\) is of the form:

$$\begin{aligned} f_{k,j} = C_{k,j}^1 z^{\alpha ^{k,j}} \ \ \text {and} \ \ \ |\alpha ^{k,j}|_{\Lambda _1} > \frac{1}{2}. \end{aligned}$$

Let

$$\begin{aligned} \Theta _1 = \left\{ \alpha ^{k,j}\;\Bigg |C_{k,j}^1 \ne 0 \; \text {and} \; \sum _{i=1}^{n-d_1} \alpha _i^{k,j} \mu _i < \frac{1}{2} \right\} . \end{aligned}$$

For every \(\alpha ^{k,j} \in \Theta _1\),

$$\begin{aligned} W_1(\alpha ^{k,j}) = \frac{\frac{1}{2} - \sum _{i=1}^{n-d_1} \alpha _i^{k,j} \mu _i}{\sum _{i=n-d_1+1}^{n} \alpha _i^{k,j}}. \end{aligned}$$
(6.5)

The next weight \(\Lambda _2\) is defined by letting

$$\begin{aligned} \lambda _i^2 = \max _{\alpha ^{k,j} \in \Theta _1} W_1(\alpha ^{k,j}) \end{aligned}$$

for \(i > n-d_1\), and \(\lambda _i^2= \mu _1\) for \(i \le n-d_1\). To complete the second step, we let \({\mathcal {I}}_{P_2}\) be the second leading polynomial ideal corresponding to the weight \(\Lambda _2\). The generators of \({\mathcal {I}}_{P_2}\) depend on more than \(n-d_1\) variables.

We proceed by induction. At the step t,  for \(t>2,\) we consider all \(\Lambda _{t-1}\)-homogeneous transformations and choose one that makes the generators of the leading polynomial ideal \({\mathcal {I}}_{P_{t-1}}\) to be independent of the largest number of variables. Denote this number by \(d_{t-1}\). Apply this \(\Lambda _{t-1}\)-homogeneous transformation to the previous ideal \({\mathcal {I}}_{t-2}\) in the \((t-1)\)th step to obtain the ideal \({\mathcal {I}}_{t-1}\). We know from the Kolář algorithm that the number of multitype entries that are added at each step of the computation depends on the difference \((d_{t-2} - d_{t-1})\). We consider two cases:

  • Case 1: Assume that \(d_{t-2} > d_{t-1}\). Again recall that for any weight \(\Lambda \) that is smaller than \(\Lambda _{t-1}\) with respect to the lexicographic ordering, \(\Lambda \)-adapted coordinates are also \(\Lambda _{t-1}\)-adapted. This implies that we get \((d_{t-2} - d_{t-1})\) multitype entries

    $$\begin{aligned} \mu _{n-d_{t-2}+1} = \cdots = \mu _{n-d_{t-1}} = \lambda _{n- d_{t-2}+1}^{t-1} \end{aligned}$$

    and let \(\lambda _i^t = \mu _i\) for \(i \le n - d_{t-2}\). Here, \({\mathcal {I}}_{P_{t-1}}\) is the ideal of which generators are sums of monomials in the variables \(z_1, \ldots , z_{n-d_{t-1}}\) that are \(\Lambda _{t-1}\)-homogeneous of weighted degree \(\frac{1}{2}.\) To obtain \(\lambda _i^t\) for \(i>n-d_{t-1}\), we consider the rest of the monomials from the generators in \({\mathcal {I}}_{t-1}\) that are not in \({\mathcal {I}}_{P_{t-1}}\). Using these monomials that have weighted degree strictly greater than \(\frac{1}{2}\) with respect to \(\Lambda _{t-1}\), we define \(\Theta _{t-1}\) and compute \(W_{t-1}\) in a similar way as in step two. Such monomials are of the form \(f_{k,j} = C_{k,j}^{t-1} z^{\alpha ^{k,j}}\) for multiindex \(\alpha ^{k,j} = (\alpha ^{k,j}_1, \ldots , \alpha ^{k,j}_n)\) satisfying \(|\alpha ^{k,j}|_{\Lambda _{t-1}} > \frac{1}{2}.\) Thus,

    $$\begin{aligned} \Theta _{t-1} = \left\{ \alpha ^{k,j} \;\Bigg |C_{k,j}^{t-1}\ne 0 \; \text {and} \; \sum _{i=1}^{n-d_{t-1}} \alpha _i^{k,j} \mu _i < \frac{1}{2} \right\} . \end{aligned}$$

    For every \(\alpha ^{k,j} \in \Theta _{t-1}\),

    $$\begin{aligned} W_{t-1}(\alpha ^{k,j}) = \frac{\frac{1}{2} - \sum _{i=1}^{n-d_{t-1}} \alpha _i^{k,j} \mu _i}{\sum _{i=n-d_{t-1}+1}^{n} \alpha _i^{k,j}}. \end{aligned}$$
    (6.6)

    So for the remaining multitype entries of \(\Lambda _j,\) we let

    $$\begin{aligned} \lambda _i^t = \max _{\alpha ^{k,j} \in \Theta _{t-1}} W_{t-1}(\alpha ^{k,j}), \end{aligned}$$

    for \(i > n-d_{t-1}\).

  • Case 2 Assume that \(d_{t-1} = d_{t-2}\). There are zero multitype entries computed in this case, and so we only determine \(\lambda _i^t\) for \(t > n-d_{t-1}\) using (6.6). This completes the step t of the algorithm.

We can, thus, establish a one-to-one correspondence between the leading polynomial \(P_t\) for \(t \ge 1\) and the intermediate ideal \({\mathcal {I}}_{P_t}\) introduced above. Since working with ideals of holomorphic functions is often easier than with real-valued polynomials, the restatement of the Kolář algorithm simplifies multitype computations for a sum of squares domain. We work with considerably fewer terms in the case of the ideals as compared to sums of squares. In particular, for each modulus square of a generator consisting of m monomials, Kolář’s original algorithm involves working with m squares plus \( \begin{pmatrix} m\\ 2 \ \end{pmatrix}\) cross terms, whereas this restatement in terms of ideals involves computations for only m monomials.

We give a corollary to Theorem 1.1:

Corollary 6.0.1

Let \(M \subset {\mathbb {C}}^{n+1}\) be a hypersurface given by \(r=0\) with

$$\begin{aligned} r = 2\mathrm{Re}(z_{n+1}) + \sum _{j=1}^{N}|f_j(z_1, \ldots , z_n)|^2, \end{aligned}$$

where \(f_1, \ldots , f_N\) are holomorphic functions defined on a neighborhood of the origin and assume that the D’Angelo 1-type of M at the origin is finite. Then for \(\ell \ge 1\), each monomial from every generator of the leading polynomial ideal \({\mathcal {I}}_{P_{\ell }}\) obtained at the \(\ell \)th step of the Kolář algorithm has weighted degree \(\frac{1}{2}\) with respect to the weight \(\Lambda _{\ell }\).

Proof

Let \(f_k^{\beta }\) be the Taylor expansion of the holomorphic function \(f_k\) to the order \(\beta \), where \(\beta \) is the ceiling of the D’Angelo 1-type. We order the generators by vanishing order and let \({\mathcal {I}} = (f_1^{\beta }, \ldots , f_N^{\beta })\). Now assume that the vanishing order of the ideal \({\mathcal {I}}\) is \(\nu >0.\) Then the Bloom-Graham type is precisely \(2\nu \) and the weight \(\mu _1 = \frac{1}{2\nu }\) with \(\Lambda _1 = (\frac{1}{2\nu }, \ldots , \frac{1}{2\nu }).\) Thus, \({\mathcal {I}}_{P_1}\) is not the zero ideal.

For every k such that \({\mathcal {I}}_{P_{1,k}}\) is not the zero ideal,

$$\begin{aligned} {\mathcal {I}}_{P_{1,k}} = (f_{k,1}, \ldots , f_{k,m_k}), \end{aligned}$$

where each monomial \(f_{k,i}\), for \(1 \le i \le m_k,\) has weighted degree \(\frac{1}{2}\) with respect to the weight \(\Lambda _1.\) Next, assume that in the second step, the ideal \({\mathcal {I}}_{P_{1,k}}\) is the same as the ideal \({\mathcal {I}}_{P_{2,k}}\). We know that the entries corresponding to each variable in the monomial \(f_{k,i},\) for \(1 \le i \le m_k,\) are the same in both weights \(\Lambda _1\) and \(\Lambda _2.\) Therefore, each monomial from the generator \(\sum _{i=1}^{m_k}f_{k,i}\) has weighted degree \(\frac{1}{2}\) with respect to \(\Lambda _2\) as well. Assume that the principal ideal \({\mathcal {I}}_{P_{2,k}}\) is generated by the sum \(\sum _{i=1}^{m_k}f_{k,i} + \sum _{j=1}^{\gamma _k}f_{k,b_j}.\) Since the new sum \(\sum _{j=1}^{\gamma _k}f_{k,b_j}\) corresponds to the new weight \(\Lambda _2\), each monomial \(f_{k,b_j}\) has weighted degree \(\frac{1}{2}\) with respect to \(\Lambda _2.\) Therefore, every monomial in the generator of the ideal \({\mathcal {I}}_{P_{2,k}}\) has weighted degree \(\frac{1}{2}\) with respect to \(\Lambda _2.\)

Next, we assume that for \(\ell \ge 2\)

$$\begin{aligned} {\mathcal {I}}_{P_{\ell ,k}} = (f_{k,a_1} + \cdots + f_{k,a_{v_k}}), \end{aligned}$$

where each monomial \(f_{k,a_i}\), for \(1 \le i \le v_k,\) has weighted degree exactly equal to \(\frac{1}{2}\) with respect to the weight \(\Lambda _{\ell }.\)

Now, assume that at step \(\ell +1\), the ideal \({\mathcal {I}}_{P_{{\ell +1},k}}\) is the same as the ideal \({\mathcal {I}}_{P_{\ell ,k}}.\) Every monomial in the generator of \({\mathcal {I}}_{P_{{\ell +1},k}}\) also has weighted degree equal to \(\frac{1}{2}\) with respect to the weight \(\Lambda _{\ell +1}\) because even though \(\Lambda _{\ell }\) is not the same as \(\Lambda _{\ell +1},\) the weight corresponding to each variable in \(f_{k,a_{v_k}}\) is the same in both weights \(\Lambda _{\ell }\) and \(\Lambda _{\ell +1}\).

Next, assume that at step \(\ell +1\) the sum \(\sum _{i=1}^{u_k}f_{k,b_{u_k}}\) is added to the sum \(\sum _{i=1}^{v_k}f_{k,a_{v_k}}\) to obtain the generator of the ideal

$$\begin{aligned} {\mathcal {I}}_{P_{{\ell +1},k}} = (f_{k,a_1} + \cdots + f_{k,a_{v_k}}+ f_{k,b_1} + \cdots + f_{k,b_{u_k}}). \end{aligned}$$

This implies that each monomial \(f_{k,b_{u_k}}\) has weighted degree \(\frac{1}{2}\) with respect to the weight \(\Lambda _{\ell +1}\). Again, each monomial \(f_{k,a_{v_k}}\) is of weighted degree \(\frac{1}{2}\) with respect to the weight \(\Lambda _{\ell +1}\) since the weight corresponding to each variable in \(f_{k,a_{v_k}}\) is the same in both weights \(\Lambda _{\ell }\) and \(\Lambda _{\ell +1}\). Thus, every monomial from the generator of the ideal \({\mathcal {I}}_{P_{{\ell +1},k}}\) has weighted degree \(\frac{1}{2}\) with respect to the weight \(\Lambda _{\ell +1}.\) \(\square \)

The example that follows is the ideal restatement of the Kolář algorithm applied to the defining function given in Example 1.

Example 2

Let \(M \subset {\mathbb {C}}^{4}\) be a sum of squares domain given by the defining function

$$\begin{aligned} r = \text {2Re}(z_4) + |z_1-z_2+z_3^2|^2 + |z_1^2-z_2^2|^2. \end{aligned}$$

The associated ideal then becomes

$$\begin{aligned} {\mathcal {I}}=(z_1 - z_2 + z_3^2, z_1^2-z_2^2)= {\mathcal {I}}_0. \end{aligned}$$

The vanishing order here equals one, and so the Bloom-Graham type is 2, which implies that \(\mu _1 = \frac{1}{2}\) and \(\Lambda _1= (\frac{1}{2}, \frac{1}{2}, \frac{1}{2})\). Hence,

$$\begin{aligned} {\mathcal {I}}_{P_1} = (z_1-z_2) = {\mathcal {I}}_{P_{1,1}}. \end{aligned}$$

So \({\mathcal {I}}_{P_{1,2}}\) is the zero ideal. We consider all \(\Lambda _1\)-homogeneous transformations and choose

$$\begin{aligned} {\tilde{z}}_1 = z_1 - z_2 \quad {\tilde{z}}_j = z_j, \quad j=2,3,4 \end{aligned}$$

to make \({\mathcal {I}}_{P_1}\) independent of the largest number of variables. We shall ignore \(\sim \) where no confusion arises. Thus, in the new coordinates,

$$\begin{aligned} {\mathcal {I}}_{P_1} = (z_1) = {\mathcal {I}}_{P_{1,1}} \end{aligned}$$

with \(d_1 = 2,\) and so \({\mathcal {I}}_0\) becomes \({\mathcal {I}}_1 = (z_1+z_3^2, z_1^2 + 2z_1z_2).\) The maximum of \(W_1\) obtained by computing \(W_1\) for each monomial in the generators of \({\mathcal {I}}_1\) is \(\frac{1}{4}\) and \(\Lambda _2 = (\frac{1}{2}, \frac{1}{4}, \frac{1}{4})\). Hence,

$$\begin{aligned} {\mathcal {I}}_{P_2} =(z_1 + z_3^2), \end{aligned}$$

where \({\mathcal {I}}_{P_{2,1}}= {\mathcal {I}}_{P_2}\) and \({\mathcal {I}}_{P_{2,2}}\) is the zero ideal. Next, consider all \(\Lambda _2\)-homogeneous transformations and choose

$$\begin{aligned} {\tilde{z}}_1 = z_1 + z_3^2 \quad {\tilde{z}}_j = z_j, \quad j=2,3,4, \end{aligned}$$

which makes \({\mathcal {I}}_{P_2}\) to be dependent on only the variable \(z_1\). Again, we shall ignore \(\sim \) where no confusion arises. In the new coordinates,

$$\begin{aligned} {\mathcal {I}}_{P_2} =(z_1) \end{aligned}$$

with \(d=2.\) The ideal \({\mathcal {I}}_{P_{2,1}}= {\mathcal {I}}_{P_2},\) and \({\mathcal {I}}_{P_{2,2}}\) is the zero ideal. \({\mathcal {I}}_1\) in the new coordinates becomes

$$\begin{aligned} {\mathcal {I}}_2 = (z_1, z_1^2+ 2z_1z_3^2 + z_3^4 + 2z_1z_2 - 2z_2z_3^2). \end{aligned}$$

Computing \(W_2\) for each monomial in the generators of \({\mathcal {I}}_2\) yields the set of numbers \(\left\{ \frac{1}{6}, \frac{1}{8} \right\} \) of which maximum, \(\max W_2,\) is \(\frac{1}{6},\) and so \(\Lambda _3=(\frac{1}{2}, \frac{1}{6}, \frac{1}{6})\). Also,

$$\begin{aligned} {\mathcal {I}}_{P_3} = (z_1, -2z_2z_3^2) = (z_1, 2z_2z_3^2). \end{aligned}$$

Here \({\mathcal {I}}_{P_{3,1}}= (z_1)\) and \({\mathcal {I}}_{P_{3,2}} =(2z_2z_3^2)\). No \(\Lambda _3\)-homogeneous transformation can make \({\mathcal {I}}_{P_3}\) to be independent of any variables, and so \(d_3=0\). Thus, the multitype weight \(\Lambda ^{*} = \Lambda _3,\) and the final leading polynomial ideal is

$$\begin{aligned} {\mathcal {I}}_{P_3} = (z_1, z_2z_3^2). \end{aligned}$$

7 Changes of Variables in the Kolář Algorithm

We now give an explicit construction of the polynomial transformations that are performed in the Kolář algorithm. We begin this construction by first relating the weighted homogeneous polynomial transformations to pairs of row-column operations on the Levi matrix of a sum of squares domain. More specifically, we show that each polynomial transformation corresponds to some finite sequence of row and column operations. Lemma 7.1 below establishes this correspondence.

Throughout this section, we shall assume the following:

Let \(M \subset {\mathbb {C}}^{n+1}\) be the boundary of a sum of squares domain defined by \(\{ r <0\}\), where

$$\begin{aligned} r = \text {2Re}(z_{n+1}) + \sum _{j=1}^N |f_j(z_1, \ldots , z_n)|^2, \end{aligned}$$

and \(f_1, \ldots , f_N\) are holomorphic functions in the neighborhood of the origin. Let

$$\begin{aligned} r_0 = \text {2Re}(z_{n+1}) + \text {P}(z,{\bar{z}}) \end{aligned}$$

be the defining function of the model hypersurface \(M_0\) of M,  where \(P(z,{{\bar{z}}})\) is a polynomial of weighted degree 1 with respect to the multitype weight at the origin \(\Lambda ^{*}\) of M. Let A be the \(n \times n\) Levi matrix of the model \(M_0 \subset {\mathbb {C}}^{n+1},\) where we ignore the contribution of the \((n+1)^{st}\) coordinate as the holomorphic polynomials in the sum of squares do not depend on it as mentioned in the introduction.

Lemma 7.1

Assume that the D’Angelo 1-type of the hypersurface M in \({\mathbb {C}}^{n+1}\) at 0 is finite. Let \(i \in \{1, \ldots , n \}\) be fixed, and let \(h \in {\mathbb {C}}[z]\) for \(z = (z_1, \ldots , z_n)\) be a nonzero monomial independent of \(z_i.\) Let \(h_{\ell }\) denote the derivative of h with respect to the variable \(z_{\ell },\) which is \(\partial _{z_{\ell }} h\) with \(l \in \{1, \ldots , n \}\setminus {\{i \}}.\) Furthermore, let \(h_{\ell }(\tau )\) denote \(h_{\ell }\) with every factor of \(z_l\) replaced by a factor of \(\tau .\) Performing the elementary row and column operations \(\text {R}_{\ell } - h_{\ell } \text {R}_i \rightarrow \text {R}_{\ell }\) and \( \text {C}_{\ell } - {\bar{h}}_{\ell }\text {C}_i \rightarrow \text {C}_{\ell }\) on the Levi matrix A of \(r_0\) for all variables \(z_{\ell }\) in h corresponds to the polynomial transformation

$$\begin{aligned} {\tilde{z}}_i = z_i + \int _0^{z_{\ell }}h_{\ell }(\tau ) \ \mathrm{d}\tau = z_i + h; \; \quad {{\tilde{z}}}_{\omega }=z_{\omega } \; \text {for} \; \omega \ne i \end{aligned}$$

in the sense that the new matrix \({\tilde{A}}\) obtained after these elementary operations is Hermitian and is the Levi matrix of the new defining function of the sum of squares domain after the change of variables \(z_{\omega } \rightarrow {{\tilde{z}}}_{\omega }\) for \(\omega =1, \ldots , n+1\) has taken place.

Remark 7.1.1

The reader should note that while only variables \(z_1, \ldots , z_n\) play a role in the behavior of the Levi matrix, \({\mathbb {C}}^{n+1}\) is the underlying space, so all changes of variables described in this section will take place in \({\mathbb {C}}^{n+1}\) and leave \(z_{n+1}\) unchanged.

Proof

Suppose that the defining function \(r_0\) of the model hypersurface \(M_0\) is of the form:

$$\begin{aligned} r_0 = \text {2Re}(z_{n+1}) + \sum _{t=1}^N |g_t|^2, \end{aligned}$$

where \(P(z,{{\bar{z}}}) = \sum _{t=1}^N |g_t|^2\) and \(g_t = \sum _{l=1}^{b_t} m_{t,l}\) is a polynomial consisting of monomials \(m_{t,l}\) in the variables \(z_1, \ldots , z_n\) since \(P(z, {{\bar{z}}})\) cannot depend on the variable \(z_{n+1}.\) Let \(m_{t,l} = C_{t,l} \prod _{\delta = 1}^n z_{\delta }^{{\alpha }^{t,l}_{\delta }}\) with \(C_{t,l} \in {\mathbb {C}}.\) For each t and for \(l_1, l_2 \in \{1, \ldots , b_t \},\) every monomial from the expansion of \(|g_t|^2\) can be written as

$$\begin{aligned} m_{t,l_1}{\overline{m}}_{t,l_2} = C_{t,l_1} {\overline{C}}_{t,l_2} \prod _{\delta =1}^n z_{\delta }^{{\alpha }^{t,l_1}_{\delta }} {{\bar{z}}}_{\delta }^{{\hat{\alpha }}^{t,l_2}_{\delta }}. \end{aligned}$$

By writing each term \(m_{t,l_1}{\overline{m}}_{t,l_2}\) for all t in the new coordinates, we obtain \(P(z, {\bar{z}})\) in the new coordinates. Hence, it suffices to show that applying the specified elementary row and column operations to the Levi matrix of the monomial \(m_{t,l_1}{\overline{m}}_{t,l_2}\) corresponds to the polynomial transformation \({\tilde{z}}_i = z_i + h; \; {{\tilde{z}}}_{\omega }=z_{\omega } \; \text {for} \; \omega \ne i.\)

Denote by D the (ijku) submatrix of the Levi matrix of the monomial \(m_{t,l_1}{\overline{m}}_{t,l_2},\) and let \(\text {D} = (d_{e {\bar{\kappa }}})_{e,\kappa = i,j,k,u},\) where \(d_{e {\bar{\kappa }}}\) is given by

$$\begin{aligned} d_{e {\bar{\kappa }}} = C_{t,l_1} {\overline{C}}_{t,l_2} \alpha _{e}^{t,l_1} {\hat{\alpha }}_{\kappa }^{t,l_2} z_{e}^{{\alpha }^{t,l_1}_{e} -1} {{\bar{z}}}_{e}^{{\hat{\alpha }}^{t,l_2}_{e}} z_{\kappa }^{{\alpha }^{t,l_1}_{\kappa }} {{\bar{z}}}_{\kappa }^{{\hat{\alpha }}^{t,l_2}_{\kappa } - 1} \prod _{\begin{array}{c} \delta = 1 \\ \delta \ne e, \kappa \end{array}}^n z_{\delta }^{{\alpha }^{t,l_1}_{\delta }} {{\bar{z}}}_{\delta }^{{\hat{\alpha }}^{t,l_2}_{\delta }}. \end{aligned}$$

Let \(h = C z_{a_1}^{{\beta }_{a_1}}, \ldots , z_{a_s}^{{\beta }_{a_s}},\) where \(C \in {\mathbb {C}},\) \(\beta = (\beta _1, \ldots , \beta _n)\) is a multiindex, and \(a_1,\ldots , a_s \in \{1, \ldots , n \}\setminus {\{i \}}.\) Now, assume that \(j,k \in \{a_1, \ldots , a_s\}\) with \(j \ne k\) and \(u \notin \{a_1, \ldots , a_s\}.\) Perform the elementary operations \(\text {R}_{\ell } - h_{\ell } \text {R}_i \rightarrow \text {R}_{\ell }\) and \( \text {C}_{\ell } - {\bar{h}}_{\ell }\text {C}_i \rightarrow \text {C}_{\ell }\) for all variables \(z_{\ell }\) in h on D to get

$$\begin{aligned} \begin{pmatrix} d_{i {\bar{\imath }}} &{} d_{i {\bar{\jmath }}} - {{\bar{h}}}_j d_{i {\bar{\imath }}} &{} d_{i {\bar{k}}} - {{\bar{h}}}_k d_{i {\bar{\imath }}} &{} d_{i {{\bar{u}}}} \\ d_{j {\bar{\imath }}} - h_j d_{i {\bar{\imath }}} &{}d_{j {\bar{\jmath }}} - h_j d_{i {\bar{\jmath }}}- {{\bar{h}}}_j d_{j {\bar{\imath }}}+ |h_j|^2 d_{i {\bar{\imath }}} &{} d_{j {\bar{k}}} - h_j d_{i {\bar{k}}}- {{\bar{h}}}_k d_{j {\bar{\imath }}}+ h_j {{\bar{h}}}_k d_{i {\bar{\imath }}} &{} d_{j {\bar{u}}} - h_j d_{i {\bar{u}}} \\ d_{k {\bar{\imath }}} - h_k d_{i {\bar{\imath }}} &{} d_{k {\bar{\jmath }}} - {\bar{h}}_jd_{k {\bar{\imath }}}- h_k d_{i {\bar{\jmath }}}+ {{\bar{h}}}_jh_k d_{i {\bar{\imath }}} &{} d_{k {\bar{k}}} - h_k d_{i {\bar{k}}}- {{\bar{h}}}_k d_{k {\bar{\imath }}}+ |h_k|^2 d_{i {\bar{\imath }}}&{} d_{k {\bar{u}}} - h_k d_{i {\bar{u}}} \\ d_{u {\bar{\imath }}} &{} d_{u {\bar{\jmath }}} - {{\bar{h}}}_j d_{u {\bar{\imath }}} &{} d_{u {\bar{k}}} - {{\bar{h}}}_k d_{u {\bar{\imath }}} &{} d_{u {\bar{u}}} \end{pmatrix}. \end{aligned}$$

The matrix above is the Levi matrix for the monomial in the new coordinates

$$\begin{aligned} {{\tilde{m}}}_{l_1} \overline{{{\tilde{m}}}}_{l_2} = C_{t,l_1} {\overline{C}}_{t,l_2} ({{\tilde{z}}}_i - h )^{{\alpha }^{t,l_1}_e} (\bar{{{\tilde{z}}}}_i - {{\bar{h}}})^{{\hat{\alpha }}^{t,l_2}_e} \prod _{\delta \ne i} z_{\delta }^{{\alpha }^{t,l_1}_{\delta }} {{\bar{z}}}_{\delta }^{{\hat{\alpha }}^{t,l_2}_{\delta }}, \end{aligned}$$

which is obtained after applying the polynomial transformation \({\tilde{z}}_i = z_i + h; \; {{\tilde{z}}}_{\omega }=z_{\omega }\) for \(\omega \ne i\) to \(m_{t,l_1}{\overline{m}}_{t,l_2}.\)

We now prove that the matrix \(\tilde{\text {A}}\) is Hermitian. Since the matrix A is Hermitian, we will show that applying the operation \(\text {R}_{\ell } - h_{\ell } \text {R}_i \rightarrow \text {R}_{\ell }\) and \( \text {C}_{\ell } - {\bar{h}}_{\ell }\text {C}_i \rightarrow \text {C}_{\ell }\) to A gives a matrix that is Hermitian as well. Let \(\text {A}=(a_{k {\bar{l}}})_{1 \le k,l \le n}\) be the Levi matrix. Apart from row \(\ell \) and column \(\ell ,\) there is no change to A, which is Hermitian. Let \(a_{\ell {\bar{k}}}\) be an entry in row \(\ell .\) Then the entry \(a_{k {\bar{\ell }}}\) is in column \(\ell \) and satisfies the property that \(a_{\ell {\bar{k}}} = {\bar{a}}_{k {\bar{\ell }}}.\) Performing the elementary operations \(\text {R}_{\ell } - h_{\ell } \text {R}_i \rightarrow \text {R}_{\ell }\) and \( \text {C}_{\ell } - {\bar{h}}_{\ell }\text {C}_i \rightarrow \text {C}_{\ell }\) on A gives a new matrix \(\tilde{\text {A}}\) with \(a_{\ell {\bar{k}}} - h_{\ell } a_{i {\bar{k}}}\) in row \(\ell \) and \(a_{k {\bar{\ell }}} - {\bar{h}}_{\ell } a_{k {\bar{\imath }}}\) in column \(\ell \). Now

$$\begin{aligned} a_{\ell {\bar{k}}} - h_{\ell } a_{i {\bar{k}}} = {\bar{a}}_{k {\bar{\ell }}} - \bar{{\bar{h}}}_{\ell } {\bar{a}}_{k {\bar{\imath }}} = \overline{a_{k {\bar{\ell }}} - {\bar{h}}_{\ell } a_{k {\bar{\imath }}}}. \end{aligned}$$

Thus, the new matrix \(\tilde{\text {A}}\) is Hermitian as well. \(\square \)

Proposition 1.3 stated in the introduction provides a general condition for the existence of an allowable polynomial transformation via the elementary row and column operations performed on the Levi matrix of a leading polynomial at some step of the Kolář algorithm. It turns out that the restrictive definition of dependency mentioned in the introduction is a necessary and sufficient condition for the existence of allowable polynomial transformations. At this point, we give the proof of Proposition 1.3 and remark that the proof is constructive in the sense that we will show the allowable polynomial transformation on \(P_j\) arises as a composition of polynomial transformations corresponding to elementary row and column operations on \(\text {A}_{P_j}.\)

Proof of Proposition 1.3

Let k be given, and denote by \(R_k\) and \(C_k\) the kth row and kth column of the matrix \(\text {A}_{P_j}\), respectively. Suppose that the kth row of \(\text {A}_{P_j}\) is dependent. This implies that \(C_k\) must also be dependent since \(\text {A}_{P_j}\) is Hermitian. Hence, we can write both \(R_k\) and \(C_k\), respectively, as follows:

$$\begin{aligned} R_k = \sum _{\begin{array}{c} l=1 \\ l \ne k \end{array}}^n \beta ^l R_l \ \text {and} \ C_k = \sum _{\begin{array}{c} l=1 \\ l \ne k \end{array}}^n {\bar{\beta }}^l C_l, \end{aligned}$$
(7.1)

where \(\beta ^l \in {\mathbb {C}}[z]\) for every l, \(1 \le l \le n.\) As proven in Theorem 1.1, the leading polynomial \(P_j\) is a sum of squares, and so we write \(P_j = \sum _{s=1}^m |\phi ^s|^2,\) where each \(\phi ^s\) is a nonzero polynomial with vanishing order greater than or equal to 1. Denote by \(a_{k {{\bar{t}}}}\) the entry in the \((k, {{\bar{t}}})\) position of the matrix \(\text {A}_{P_j},\) for \(t = 1, \ldots , n.\) Therefore, for \(k\ne l\) the entries in \(R_k\) and \(R_l\) are given by

$$\begin{aligned} a_{k {{\bar{t}}}} = \sum _{s=1}^m \phi ^s_k {\bar{\phi }}^s_t \quad \text {and} \quad a_{l {{\bar{t}}}} = \sum _{s=1}^m \phi ^s_l {\bar{\phi }}^s_t, \end{aligned}$$
(7.2)

and the entries in \(C_k\) and \(C_l\) are given by

$$\begin{aligned} a_{t {{\bar{k}}}} = \sum _{s=1}^m \phi ^s_t {\bar{\phi }}^s_k \quad \text {and} \quad a_{t {{\bar{l}}}} = \sum _{s=1}^m \phi ^s_t {\bar{\phi }}^s_l \end{aligned}$$
(7.3)

respectively, where \(\displaystyle \phi ^s_j=\frac{\partial \phi ^s}{\partial z_j}.\)

We will show that there exist some elementary row and column operations that make \(R_k\) to be identically zero and also make every monomial in \(\text {A}_{P_j}\) to be independent of the variable \(z_k.\)

To that end, we see from (7.1) that every pair \(\text {R}_k - \beta ^l \text {R}_l; \ \text {C}_k - {\bar{\beta }}^l \text {C}_l\) for which the polynomial \(\beta ^l\) is nonzero requires corresponding elementary row and column operations in the exact form expressed in the pair. If \(\beta ^l = 0\) or \(R_l \equiv 0,\) then no elementary row or column operation is required. Therefore, assume that \(\beta ^l\) is nonzero and that \(R_l\) is not identically zero. Let \(\beta ^l(\zeta _k)\) be \(\beta ^l\) with each factor of \(z_k\) replaced by a factor of \(\zeta _k.\) Then \(\displaystyle \int _0^{z_k} \beta ^l (\zeta _k) \ \text {d} \zeta _k\) must contain the variable \(z_k\) together with all the other variables in \(\beta ^l.\) Recall that \(\beta ^l \in {\mathbb {C}}[z],\) so \(\beta ^l\) does not depend on any variable \({{\bar{z}}}_\nu .\) Hence, we shall investigate all monomials in \(\text {A}_{P_j}\) containing the variable \(z_k.\)

We recall at this point that by applying the operator \(\partial _{z_k}\partial _{{{\bar{z}}}_t}\) to \(P_j,\) we obtain in row \(R_k\) the derivatives of all monomials containing the variable \(z_k.\) Let \(a_{k {{\bar{t}}}}\) be an entry in row \(R_k.\) Now, because \(R_k\) is dependent, every monomial u in \(a_{k {{\bar{t}}}}\) arises as the product of a monomial p in \(\beta ^l\) for some l with a monomial q in entry \(a_{l {{\bar{t}}}}.\) So \(u = pq,\) but since u comes from differentiation by \(\partial _{z_k}\partial _{{{\bar{z}}}_t},\) \(P_j\) must contain a monomial \( m = u z_k {{\bar{z}}}_t.\) If \(u \in {\mathbb {C}},\) then no entries in \(\text {A}_{P_j},\) except for those in \(R_k,\) contain derivatives from m. If u has positive vanishing order, then u depends on at least one variable \(z_{\nu }\) or \({{\bar{z}}}_\nu \) for some \(\nu .\) Since \(P_j\) is real valued, it contains both m and \({\bar{m}}.\) Therefore, without loss of generality, we can assume u depends on \(z_\nu ;\) otherwise, we work with \({\bar{u}}.\) Since u depends on \(z_\nu ,\) the entry \(a_{\nu {{\bar{t}}}}\) in the \(\nu \)th row \(R_{\nu }\) contains the monomial \(\partial _{z_{\nu }} \partial _{{{\bar{z}}}_t} m \ne 0,\) which has at least one factor of \(z_k.\) We seek to eliminate all such monomials containing variable \(z_k\) from the matrix \(\text {A}_{P_j}.\)

Set \(\displaystyle \gamma ^l = \int _0^{z_k} \beta ^l(\zeta _k) \ \text {d} \zeta _k,\) and let \(\gamma ^l = \sum _{b=1}^e m^{l,b},\) where \(m^{l,b}\) is a nonzero monomial containing the variable \(z_k\) for all \(b \ge 1.\) We recall from Lemma 7.1 that for any nonzero monomial m in the leading polynomial, if we perform the pair of elementary operations \(\text {R}_{\nu } - \partial _{z_{\nu }} m \text {R}_{\ell } \rightarrow \text {R}_{\nu }\) and \( \text {C}_{\nu } - \partial _{{{\bar{z}}}_{\nu }} {{\bar{m}}} \text {C}_{\ell } \rightarrow \text {C}_{\nu }\) for all variables \(z_{\nu }\) in m,  then this pair corresponds to the polynomial transformation \(\displaystyle {{\tilde{z}}}_{\ell } = z_{\ell } + \int _0^{z_\nu } \partial _{\tau } m(\tau ) \ \mathrm{d}\tau = z_{\ell } + m; \; {{\tilde{z}}}_{\omega } = z_{\omega }\) for \( \omega \ne \ell ,\) where \(\partial _{\tau } m(\tau )\) is \(\partial _{z_{\nu }} m\) with each factor of \(z_\nu \) replaced by a factor of \(\tau .\)

Now, for each monomial \(m^{l,b}\) in \(\gamma ^l, \ b= 1, \ldots , e,\) we perform the elementary row and column operations \(\text {R}_{\nu } - \partial _{z_{\nu }} m^{l,b} \text {R}_l \rightarrow \text {R}_{\nu }\) and \( \text {C}_{\nu } - \partial _{{{\bar{z}}}_{\nu }} {\bar{m}}^{l,b} \text {C}_l \rightarrow \text {C}_{\nu }\) for every variable \(z_{\nu }\) in \(m^{l,b}.\) The composition of all of these polynomial transformations \({\mathcal {S}}\) is given by \({\tilde{z}}_l = z_l + \gamma ^l\) for every l such that \(\beta ^l \ne 0\) and \({{\tilde{z}}}_{\omega } = z_{\omega }\) for all \(\omega \ne l,\) where \(1\le \omega \le n+1.\) Note that (7.1) implies that \(\gamma ^l\) has the same weight as \(z_l\) in \(\Lambda _j\) because \(P_j\) only contains terms of weight 1 with respect to \(\Lambda _j,\) so \({\mathcal {S}}\) is \(\Lambda _j\)-homogeneous as needed.

After all the elementary row and column operations corresponding to the polynomial transformation \({\mathcal {S}}\) have taken place, the entries in \(R_k\) are

$$\begin{aligned} a^{'}_{k {{\bar{t}}}} = \sum _{s=1}^m \phi ^s_k {\bar{\phi }}^s_t - \sum _{l=1}^n \beta ^l \Big ( \sum _{s=1}^m \phi ^s_l {\bar{\phi }}^s_t \Big ) = a_{k {{\bar{t}}}} - \sum _{l=1}^n \beta ^l a_{l {{\bar{t}}}}\equiv 0 \end{aligned}$$
(7.4)

as a consequence of (7.1). A similar argument holds for the entries in \(C_k,\) which we denote by \(a^{'}_{t {{\bar{k}}}},\) namely (7.1) implies that \(a^{'}_{t {{\bar{k}}}} \equiv 0.\) Therefore, all entries in the kth row and column of the matrix \(\text {A}_{P_j}\) are identically zero after the change of variables \({\mathcal {S}}\) has been performed. Now, assume that the leading polynomial \(P_j\) still contains the variable \(z_k\) after the given change of variables has been performed on it and some cancellation occurs. Since the leading polynomial \(P_j\) is a sum of squares, in the expansion of \(P_j\) besides the cross terms, which could possibly cancel each other, we would have at least two squares of monomials containing \(z_k.\) From the above discussion, it is clear that by performing these elementary row and column operations on \(\text {A}_{P_j},\) all monomials containing the variable \(z_k\) in any of its entries will have been eliminated including any contribution from those squares. Thus, \(P_j\) could not possibly have contained the variable \(z_k,\) so \({\mathcal {S}}\) is an allowable polynomial transformation with respect to the variable \(z_k.\)

Conversely, suppose that there exists an allowable polynomial transformation on \(P_j\) with respect to the variable \(z_k,\) and let \({\mathcal {T}}\) be this polynomial transformation, which we shall express as follows:

$$\begin{aligned} {{\tilde{z}}}_i = z_i + \gamma ^i, \end{aligned}$$
(7.5)

for \(i= 1, \ldots , n+1,\) where some of the \(\gamma ^i\) may be zero. We note here that the transformation \({\mathcal {T}}\) is a \(\Lambda _j\)-homogeneous transformation, and so \(\gamma ^i\) has the same weight with respect to \(\Lambda _j\) as \(z_i.\) Furthermore, we note that any \(\Lambda _j\)-homogeneous transformation can be written in this form.

We will prove that the kth row \(R_k\) is dependent by showing that it satisfies the condition given in (7.1). Assume that the variable \(z_k\) is contained in \(\gamma ^i\) for some \(i \in \{1, \ldots , d\}\) with \(d \le n.\) We know that each \({{\tilde{z}}}_i\) corresponds to the row and column operations:

$$\begin{aligned} \text {R}_k - \gamma ^i_k \text {R}_i \rightarrow \text {R}_k \quad \text {and} \quad \text {C}_k - {\bar{\gamma }}^i_k \text {C}_i \rightarrow \text {C}_k, \end{aligned}$$
(7.6)

respectively, for \(i= 1, \ldots , d,\) where \(\gamma ^i_k = \partial _{z_k} \gamma ^i \ne 0.\) Let \({{\tilde{P}}}_j\) be the leading polynomial \(P_j\) after the polynomial transformation \({\mathcal {T}}\) is applied to it. Since \({{\tilde{P}}}_j\) does not contain the variable \(z_k,\) the entries \({{\tilde{h}}}_{k {{\bar{t}}}}\) of \(R_k\) and \({{\tilde{h}}}_{t {{\bar{k}}}}\) of \(C_k\) of the matrix \(\text {A}_{{\tilde{P}}_j}\) for all \(t= 1, \ldots , n\) are zero entries.

Now, by simply reversing the signs involved in the elementary operations in (7.6), we can restore \(R_k\) and \(C_k\) to their previous forms before the transformation \({\mathcal {T}}\) was applied to \(P_j.\) Hence, by performing the elementary row and column operations

$$\begin{aligned} \text {R}_k + \gamma ^i_k \text {R}_i \rightarrow \text {R}_k \quad \text {and} \quad \text {C}_k + {\bar{\gamma }}^i_k \text {C}_i \rightarrow \text {C}_k \end{aligned}$$

for all \(i = 1, \ldots , d\) on the matrix \(\text {A}_{{\tilde{P}}_j},\) the entries in \(R_k\) and \(C_k\) become

$$\begin{aligned} h_{k {{\bar{t}}}} = \sum _{i=1}^d \gamma ^i_k h_{i {{\bar{t}}}} \quad \text {and} \quad h_{t {{\bar{k}}}} = \sum _{i=1}^d {\bar{\gamma }}^i_k h_{t {\bar{\imath }}}, \end{aligned}$$
(7.7)

where \(h_{i {{\bar{t}}}}\) and \(h_{t {\bar{\imath }}}\) are the entries in the ith row \(R_i\) and ith column \(C_i\), respectively. Finally, we obtain that

$$\begin{aligned} h_{k {{\bar{t}}}} = \sum _{i=1}^n \gamma ^i_k h_{i {{\bar{t}}}} \quad \text {and} \quad h_{t {{\bar{k}}}} = \sum _{i=1}^n {\bar{\gamma }}^i_k h_{t {\bar{\imath }}}, \end{aligned}$$
(7.8)

where \(\gamma ^i_k = 0\) for all \(i = d+1, \ldots , n.\) Thus, both \(R_k\) and \(C_k\) are dependent, proving the statement. \(\square \)

It is important to note that for any k,  if the diagonal \((k, {{\bar{k}}})\) entry of \(A_{P_j}\) is the only nonzero entry in its kth row, then the kth row cannot be dependent, where \(A_{P_j}\) is the Levi matrix of the leading polynomial \(\text {P}_j.\) This statement holds because we are working with a sum of squares domain and \(A_{P_j}\) is Hermitian.

Lemma 7.2

Let \(\Gamma \) be the set of \(n \times n\) matrices with coefficients in the ring \({\mathbb {C}}[z, {\bar{z}}].\) Let \(\text {H} \in \Gamma \) be Hermitian. For some given i and k,  let \(\text {B}\) be the matrix obtained from H after the elementary row and column operations \(\text {R}_k + \alpha \text {R}_i \rightarrow \text {R}_k\) and \( \text {C}_k + {\bar{\alpha }} \text {C}_i \rightarrow \text {C}_k,\) for some \(\alpha \in {\mathbb {C}}[z],\) are performed on it. Then \(\det (\text {B}) = \det (\text {H}).\)

Proof

Let E be the matrix obtained from H by the elementary row operation \(\text {R}_k + \alpha \text {R}_i \rightarrow \text {R}_k.\) Then \(\text {B}\) is the matrix obtained from E by the elementary column operation \( \text {C}_k + {\bar{\alpha }} \text {C}_i \rightarrow \text {C}_k.\) It is obvious from the properties of the determinant that \(\det (\text {H}) = \det (\text {E})\) and that \(\det (\text {E}) = \det (\text {B}).\) \(\square \)

Lemma 7.3

Assume that the D’Angelo 1-type of \(M \subset {\mathbb {C}}^{n+1}\) at 0 is finite. At step j of the Kolář algorithm for the computation of the multitype at 0, let \(\text {P}_j\) be the leading polynomial and let \(\text {Q}_j\) be the leftover polynomial.

If the determinant of \(\text {A}_{P_j}\) is nonzero, then \(P_j\) is independent of the largest number of variables, and no polynomial transformation needs to be performed on it before the next step in the Kolář algorithm.

Proof

We shall give a proof of the contrapositive of the statement of this lemma, which states that if there exists an allowable transformation, and hence, one of the rows of \(\text {A}_{P_j}\) is dependent by Proposition 1.3, then the determinant of \(\text {A}_{P_j}\) is zero. Suppose that \({\mathscr {R}} = \{R_1, \ldots , R_n \},\) the set of all rows of the matrix \(\text {A}_{{P}_j},\) is dependent and that none of the rows is identically equal to zero. Thus, for some k,  we can write

$$\begin{aligned} R_k = \sum _{\begin{array}{c} l=1\\ l \ne k \end{array}}^n \alpha _l R_l, \end{aligned}$$

where \(\alpha _l \in {\mathbb {C}}[z] \ \text {and} \ R_l\) is the lth row of \(\text {A}_{P_j}.\) From the proof of Proposition 1.3, we know that there must exist some elementary row and column operations that transform \(\text {A}_{{P}_j}\) into the matrix \(\tilde{\text {A}}_{P_j}\) of which kth row and column have all zero entries. Since the matrix \(\tilde{\text {A}}_{P_j}\) has at least one row with all entries equal to zero, its determinant is equal to zero. From Lemma 7.2, we know that \(\det (\tilde{\text {A}}_{P_j}) = \det (\text {A}_{{P}_j}).\)

Thus, \(\det (\text {A}_{{P}_j}) = 0,\) which is the result we need. \(\square \)

Given the way the leading polynomial \(P_j\) and its Levi matrix \(\text {A}_{P_j}\) are constructed, it is possible that \(P_j\) could be independent of at least one of the variables. If that is the case, then the determinant of the Levi matrix corresponding to the leading polynomial \(P_j\) will always be zero since it will have at least one row that is identically zero. Therefore, we need a way to determine when a subset of all nonzero rows of \(\text {A}_{P_j}\) is independent. To address this situation, we shall consider the following:

Let \(\text {A}_{P_j} = (a_{i {{\bar{l}}}})_{1 \le i,l \le n}\) be the Levi matrix of the leading polynomial \(P_j\) at step j of the Kolář algorithm. Let m be the number of nonzero rows of the matrix \(\text {A}_{P_j}.\) Denote by \(\text {A}_{P_j|m}\) the principal submatrix obtained from \(\text {A}_{P_j}\) by removing all zero rows and columns to get precisely m rows and columns, for some \(m \le n.\) Put differently, \(\text {A}_{P_j|m}\) is the submatrix consisting only of all nonzero rows and columns of \(\text {A}_{P_j}.\) If \(m = n,\) then none of the rows and columns are identically zero.

Also, via the elementary row and column operations, \(\text {A}_{P_j|m}\) can be transformed into a leading principal submatrix of \(\text {A}_{P_j},\) where the first m rows and columns are the ones that remain. In this case, \(\text {A}_{P_j|m} = (a_{i {{\bar{l}}}})_{1 \le i,l \le m}.\)

Let \({\mathscr {R}} = \{R_1, \ldots , R_n \}\) be the set of all rows of the matrix \(\text {A}_{{P}_j}\) and let \({\mathscr {S}}= \{R_{b_1}, \ldots , R_{b_m} \}\) be a subset of \({\mathscr {R}},\) for \(b_e \in \{1, \ldots , n \}, \ e = 1, \ldots , m\) such that each element \(R_{b_e}\) is not identically zero. Then \({\mathscr {S}}\) is the set of all non zero rows of the submatrix \(\text {A}_{P_j|m}.\)

We now restate Proposition 1.3 and Lemma 7.3 as follows:

Proposition 7.4

Assume that the D’Angelo 1-type of \(M \subset {\mathbb {C}}^{n+1}\) at 0 is finite. At step j of the Kolář algorithm for the computation of the multitype at 0, let \(P_j\) be the leading polynomial, and let \(Q_j\) be the leftover polynomial.

There exists an allowable polynomial transformation on \(P_j\) with respect to the variable \(z_k\) via the elementary row and column operations if and only if the kth row of \(\text {A}_{\text {P}_j|m}\) is dependent.

Lemma 7.5

Assume that the D’Angelo 1-type of \(M \subset {\mathbb {C}}^{n+1}\) at 0 is finite. At step j of the Kolář algorithm for the computation of the multitype at 0, let \(P_j\) be the leading polynomial, and let \(Q_j\) be the leftover polynomial.

If the determinant of \(\text {A}_{P_j|m}\) is nonzero, then \(P_j\) is independent of the largest number of variables, and no polynomial transformation needs to be performed on it before the next step in the Kolář algorithm.

The proofs of Proposition 7.4 and Lemma 7.5 are identical to the proofs given for Proposition 1.3 and Lemma 7.3, respectively, since the latter do not depend on rows being identically equal to zero. We also note here that the converses of Lemmas 7.3 and 7.5 do not hold. The reason is that the notion of dependency given in (7.1) is more restrictive than the standard notion of dependency in linear algebra, so there might not exist a row that is dependent according to our definition, but the set of rows may satisfy the standard notion of dependency, in which case the determinant of the Levi matrix would be identically equal to zero.

Now, the natural question to ask at this point is this: Given a Levi matrix of a leading polynomial with zero determinant, how can we tell whether or not it has dependent rows? Also, if there exist dependent rows, how can we identify such rows in order to determine the allowable polynomial transformations corresponding to these dependent rows? The answers to these questions lie in the formulation of an algorithm, which we will describe in the next subsection.

7.1 Jacobian Modules and Gradient Ideals

A study of the elementary row and column operations on the Levi matrix reveals that a row (column) operation on the Levi matrix is performed by a multiplication on the left (right) of the Levi matrix by an elementary row (column) matrix. The Levi matrix of a sum of squares domain can always be decomposed as the product of the complex Jacobian matrix of the holomorphic functions that generate the domain and its conjugate transpose. Therefore, every row operation on the Levi matrix could be performed on the complex Jacobian matrix, while every column operation on the Levi matrix is performed on the conjugate transpose of the complex Jacobian matrix. Let A be an \(n \times n\) Levi matrix of a domain given by the sum of squares of N holomorphic functions. Then elementary matrices are \(n \times n\) matrices, while the complex Jacobian matrix and its conjugate transpose must be \(n \times N\) and \(N \times n\) matrices, respectively.

In our study of elementary row and column operations performed on the Levi determinant of a sum of squares domain, one particular property of the Levi matrix of a square of one of the generators drew our attention: All entries of any given column (row) have the same anti-holomorphic (holomorphic) parts, and so a study of the relationship between these entries narrows down to a study of the relationship between their holomorphic (anti-holomorphic) parts. In other words, we expect that the study of the Levi matrix will be much easier if we transition from the sum of squares to the underlying ideal of holomorphic functions that generate the domain as we already saw was the case for the computation of the multitype.

We start with a couple of definitions that we specialize to complex polynomials since those are the objects that appear in the Kolář algorithm when it is applied to a sum of squares domain instead of the full holomorphic generators:

Definition 7.1

Let \(f \in {\mathbb {C}}[z_1, \ldots , z_n]\) be polynomial in the variables \(z_1, \ldots , z_n\) with coefficients in \({\mathbb {C}}.\) As in [15], we define the gradient ideal of f as the ideal generated by the partial derivatives of f : 

$$\begin{aligned} {\mathcal {I}}_\mathrm{grad}(f) = \langle \nabla f \rangle = \Bigg \langle \frac{\partial f}{\partial z_1}, \ldots , \frac{\partial f}{\partial z_n} \Bigg \rangle . \end{aligned}$$
(7.9)

Definition 7.2

Given the ideal \(\langle f \rangle = \langle f_1, \ldots , f_N \rangle \subset {\mathbb {C}}[z_1, \ldots , z_n],\) we define the Jacobian module of f as

$$\begin{aligned} {\mathfrak {J}}_{\langle f \rangle } = \left[ \frac{\partial f}{\partial z_1}, \ldots , \frac{\partial f}{\partial z_n} \right] , \end{aligned}$$
(7.10)

where each \(\frac{\partial f}{\partial z_j}\) is a vector. \({\mathfrak {J}}_{\langle f \rangle }\) is a module over the polynomial ring \({\mathbb {C}}[z_1, \ldots , z_n].\)

To every Jacobian module \({\mathfrak {J}}_{\langle f \rangle },\) we associate the complex Jacobian matrix \(\text {J}(f)\) given by

$$\begin{aligned} \text {J}(f) = \begin{pmatrix} \frac{\partial f_1}{\partial z_1} &{} \frac{\partial f_2}{\partial z_1}&{} \cdots &{} \frac{\partial f_N}{\partial z_1}\\ \vdots &{} \vdots &{} \ddots &{} \vdots \\ \frac{\partial f_1}{\partial z_n} &{} \frac{\partial f_2}{\partial z_n} &{} \cdots &{} \frac{\partial f_N}{\partial z_n} \end{pmatrix}. \end{aligned}$$
(7.11)

Likewise, to each gradient ideal \({\mathcal {I}}_\mathrm{grad}(f_i) = \langle \frac{\partial f_i}{\partial z_1}, \ldots , \frac{\partial f_i}{\partial z_n} \rangle \) of the generator \(f_i \in {\mathbb {C}}[z_1, \ldots , z_n]\) of \(\langle f \rangle ,\) we associate the ith column of \(\text {J}(f)\) for \(1 \le i \le n.\) The reader should note that row operations on \(\text {J}(f)\) are precisely operations on the module \({\mathfrak {J}}_{\langle f \rangle }.\)

Now, let \(\langle f \rangle = \langle f_1, \ldots , f_N \rangle \subset {\mathbb {C}}[z_1, \ldots , z_n]\) be the leading polynomial ideal at some step of the Kolář algorithm. Then we are particularly interested in simplifying the Jacobian module \({\mathfrak {J}}_{\langle f \rangle }\) such that it is generated by the minimal number of generators. Every generator that is eliminated is a linear combination of some partial derivatives of f with coefficients in \({\mathbb {C}}[z_1, \ldots , z_n].\) Since every generator of the Jacobian module represents a row of the complex Jacobian matrix, every eliminated generator represents a dependent row in the complex Jacobian matrix. Owing to this connection, from every eliminated generator, we can construct a sequence of elementary row operations that corresponds to the linear combination of some partial derivatives of f as described in Proposition 1.3. Hence, we obtain polynomial transformations corresponding to these row operations.

It is easy to observe this relationship if \(N=1.\) Then reducing the number of generators of \({\mathfrak {J}}_{\langle f \rangle },\) if possible, reduces the number of nonzero rows of the associated complex Jacobian matrix. Thus, the minimal number of generators required to generate the Jacobian module is precisely the number of independent rows of the complex Jacobian matrix, which is the same as the number of variables on which the corresponding leading polynomial ideal \(\langle f \rangle \) is dependent by Proposition 1.3 after the corresponding change of variables. Hence, the number \(d_j\) at step j of the Kolář algorithm is given by \(d_j=n -\#f ,\) where \(\#f\) is the minimal number of generators generating the Jacobian module \({\mathfrak {J}}_{\langle f \rangle },\) n is the number of variables in the polynomial ring \({\mathbb {C}}[z_1, \ldots , z_n],\) and \(d_j\) is the largest number of variables of which the leading polynomial at step j is independent. This gives an algebraic characterization of the number \(d_j\) in the Kolář algorithm.

In the more general case where \(N > 1,\) reducing the number of generators of the Jacobian module implies reducing the generators of all gradient ideals by the same operations. Thus, \(\frac{\partial f}{\partial z_{\ell }},\) for some \(\ell ,\) is a generator that is eliminated in the Jacobian module \({\mathfrak {J}}_{\langle f \rangle }\) if and only if the generator \(\frac{\partial f_i}{\partial z_{\ell }}\) of the gradient ideal \({\mathcal {I}}_\mathrm{grad}(f_i)\) for all \(i = 1, \ldots , N\) is eliminated, namely reduced to 0.

Clearly, if there exists at least one gradient ideal \({\mathcal {I}}_\mathrm{grad}(f_i)\) with minimal number of generators equal to n,  then the Jacobian module \({\mathfrak {J}}_{\langle f \rangle }\) cannot have fewer than n generators, i.e., no reduction via row operations is possible.

In this setup, all elementary pairs of row-column operations on the Levi matrix reduce to just elementary row operations on the complex Jacobian matrix.

7.2 Row Reduction Algorithm

We shall now devise an algorithm that constructs explicitly the polynomial transformations required at each step of the Kolář algorithm when applied to the complex Jacobian matrix of the leading polynomial ideal.

The algorithm gives the conditions for characterizing the required elementary row operations that correspond to the polynomial transformations needed in the Kolář algorithm. The application of the algorithm to the complex Jacobian matrix corresponding to a given leading polynomial ideal will eliminate all dependent rows, if they exist, from the complex Jacobian matrix.

Now, for any \(j\ge 1,\) let \(\text {J}_{P_j}\) be the complex Jacobian matrix corresponding to the leading polynomial \(P_j\) at step j of the Kolář algorithm.

Let \(P_j = \sum _{i=1}^N |h_i|^2.\) Then the leading polynomial ideal is given by \({\mathcal {I}}_{P_j} := \langle h \rangle = \langle h_1, \ldots , h_N \rangle ,\) and the gradient ideal of \(h_i\) is \({\mathcal {I}}_\mathrm{grad}(h_i) = \left\langle \frac{\partial h_i}{\partial z_1}, \ldots , \frac{\partial h_i}{\partial z_n} \right\rangle , \ i = 1, \ldots , N.\) Note that the complex Jacobian matrix of \(P_j\) is given by \(\text {J}_{P_j}=\text {J}({\mathcal {I}}_{P_j})=\text {J}(h)\) and the Levi matrix \(\text {A}_{P_j}\) of \(P_j\) is the product of the complex Jacobian matrix of \(P_j\) with its conjugate transpose \(\text {J}^*(h):\) \(\text {A}_{P_j} = \text {J}(h)\text {J}^*(h).\) We shall reduce, if possible, the number of generators of each gradient ideal one at a time and control the changes that occur in other gradient ideals as a result of these reduction operations. By control, we mean setting appropriate conditions on the reduction operations used.

If \(\det \text {A}_{P_j}= \det \left( \text {J}(h)\text {J}^*(h) \right) \) is nonzero, then no change of variables is required by Lemma 7.3. Thus, assume that \(\det \left( \text {J}(h)\text {J}^*(h)\right) = 0.\) Then:

  1. 1.

    We begin the process by first considering the gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_i) = \left\langle \frac{\partial h_i}{\partial z_1}, \ldots , \frac{\partial h_i}{\partial z_n} \right\rangle \) for any i. Simplify the gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_i)\) such that it consists of the minimal number of generators. Assume that

    $$\begin{aligned} \frac{\partial h_i}{\partial z_k} = \sum _{u = 1}^v \gamma _{c_u} \frac{\partial h_i}{\partial z_{c_u}}, \end{aligned}$$
    (7.12)

    for some \(k, \ c_u \ne k, \ v < n,\) and \(\gamma _{c_u}\) a nonzero polynomial in \({\mathbb {C}}[z_1, \ldots , z_n].\) Then perform the following elementary row operations on the complex Jacobian matrix \(\text {J}(h):\)

    $$\begin{aligned} \text {R}_{\ell } - \frac{\partial \zeta _{c_u}}{\partial z_{\ell }} \text {R}_{c_u} \rightarrow \text {R}_{\ell }, \end{aligned}$$
    (7.13)

    for all \(u=1, \ldots , v\) and for all variables \(z_{\ell }\) in \(\zeta _{c_u} = \int _0^{z_k} \gamma _{c_u}(t) \ \text {d}t.\) By Lemma 7.1, the row operations in (7.13) correspond to the polynomial transformation given by

    $$\begin{aligned} {\tilde{z}}_{c_u} = z_{c_u} + \int _0^{z_k} \gamma _{c_u}(t) \; \text {d}t; \; {{\tilde{z}}}_{\omega } = z_{\omega }, \end{aligned}$$
    (7.14)

    for all \(\omega \ne c_u\) and for all \(u=1, \ldots , v.\) The generator \(\frac{\partial h_i}{\partial z_k}\) vanishes in \({\mathcal {I}}_\mathrm{grad}(h_i)\) after the row operations in (7.13) are performed on \(\text {J}(h).\) We say row \(\text {R}_{c_u}\) is used as a central row in the sequence of row operations and the generator \(\frac{\partial h_i}{\partial z_{c_u}}\) is used as a central generator in the simplification of the gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_i)\) for all i. We remark here that for all subsequent row operations performed on the complex Jacobian matrix, the row \(\text {R}_{c_u}\) cannot be used as a central row and \(\frac{\partial h_e}{\partial z_{c_u}}\) cannot be used as a central generator in the simplification of any other gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_e)\) for \(e \ne i.\) This condition is imposed due to Proposition  1.3, which is an equivalence. Reusing a central row or a central generator might reintroduce a variable that has been eliminated from the leading polynomial.

  2. 2.

    Next, consider another gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_s) = \left\langle \frac{\partial h_s}{\partial z_1}, \ldots , \frac{\partial h_s}{\partial z_n} \right\rangle \) for \(s \ne i.\) Clearly, the kth generator of this gradient ideal is

    $$\begin{aligned} \frac{\partial h_s}{\partial z_k} - \sum _{u = 1}^v \gamma _{c_u} \frac{\partial h_s}{\partial z_{c_u}} \end{aligned}$$
    (7.15)

    due to the row operations given in (7.13). We simplify the ideal \({\mathcal {I}}_\mathrm{grad}(h_s)\) such that it has the minimal number of generators while ensuring that the generators \(\frac{\partial h_s}{\partial z_{c_u}}\) for \(u = 1, \ldots , v\) are not used as central generators in the simplification of \({\mathcal {I}}_\mathrm{grad}(h_s).\) Perform the related row operations.

  3. 3.

    Proceed similarly by considering other gradient ideals different from the previous ones. Since there are only finitely many gradient ideals and finitely many generators that generate each of them, the process will terminate after a finite number of steps.

We will show in the lemma that follows that the polynomial transformation in (7.14) corresponding to the row operations given in (7.13) is \(\Lambda _j\)-homogeneous. Thus, we state the following:

Lemma 7.6

Assume that the D’Angelo 1-type of \(M \subset {\mathbb {C}}^{n+1}\) at 0 is finite. At step j of the Kolář algorithm for the computation of the multitype at 0,  let \(\Lambda _j\) be the weight, \(P_j\) the leading polynomial, and \({\mathcal {I}}_{P_j}\) the corresponding leading polynomial ideal. Let \({\mathcal {I}}_\mathrm{grad}(\psi )\) be the gradient ideal of some generator \(\psi \) of the ideal \({\mathcal {I}}_{P_j}.\) Assume that

$$\begin{aligned} \frac{\partial \psi }{\partial z_k} = \sum _{u = 1}^v \gamma _{c_u} \frac{\partial \psi }{\partial z_{c_u}}, \end{aligned}$$
(7.16)

for some k,  where \(k \ne c_u, \ v < n,\) and \(\gamma _{c_u}\) is a nonzero polynomial in \({\mathbb {C}}[z_1, \ldots , z_n].\) Let \(\zeta _{c_u} = \int _0^{z_k} \gamma _{c_u}(t) \ \text {d}t.\)

Then the polynomial transformation given by \({\tilde{z}}_{c_u} = z_{c_u} + \zeta _{c_u}; \; {{\tilde{z}}}_{\omega } = z_{\omega }\) for all \(\omega \ne c_u\) corresponding to the elementary row operations \(\text {R}_{\ell } - \frac{\partial \zeta _{c_u}}{\partial z_{\ell }} \text {R}_{c_u} \rightarrow \text {R}_{\ell }\) for all variables \(z_{\ell }\) in \(\zeta _{c_u}\) and for all \(u=1, \ldots , v\) performed on the complex Jacobian matrix \(\text {J}_{P_j}\) is \(\Lambda _j\)-homogeneous for all \(u = 1, \ldots , v.\)

Proof

We start the proof by recalling from Theorem 1.1 that the leading polynomial is a sum of squares at every step of the Kolář algorithm. Hence, \(P_j\) is a sum of squares. Let \(\Lambda _j=(\lambda _1, \ldots , \lambda _n).\) Since variables are not ordered in increasing weight order, we let \(\phi : \{1,\ldots , n\} \rightarrow \{1,\ldots , n\}\) be the bijection \(\phi =(\phi _1, \ldots , \phi _n)\) such that the variable \(z_i, \ 1 \le i \le n,\) has weight \(\lambda _{\phi _i}.\)

We will show that the term \(\gamma _{c_u}\) in the polynomial transformation is of weighted degree \((\lambda _{\phi _{c_u}} - \lambda _{\phi _k}).\) Let \(\nu \) be the weighted degree of \(\gamma _{c_u}\) with respect to the weight \(\Lambda _j.\) By our hypothesis, the weighted degrees of \(\frac{\partial \psi }{\partial z_{c_u}}\) and \(\frac{\partial \psi }{\partial z_k} \) are \(\frac{1}{2} - \lambda _{\phi _{c_u}}\) and \(\frac{1}{2} - \lambda _{\phi _k}\), respectively, since all generators of the leading polynomial ideal \({\mathcal {I}}_{P_j}\) are of weighted degree \(\frac{1}{2}\) with respect to \(\Lambda _j.\) The weighted degree of the right hand side of the expression given in (7.16) is \(\nu + \frac{1}{2} - \lambda _{\phi _{c_u}}.\) Hence solving the equation in (7.16) for \(\nu \) gives \(\nu = \lambda _{\phi _{c_u}} - \lambda _{\phi _k}.\) Thus, the weighted degree of \(\zeta _{c_u} = \int _0^{z_k} \gamma _{c_u}(t)\; \text {d}t\) is \(\lambda _{\phi _{c_u}}\) as required.

\(\square \)

Remark 7.6.1

The polynomial \(\gamma _{c_u}\) cannot depend on the variable \(z_{c_u}\) because if it were to depend on \(z_{c_u},\) then its weighted degree would satisfy \(\nu \ge \lambda _{\phi _{c_u}},\) but \(\nu = \lambda _{\phi _{c_u}} - \lambda _{\phi _k},\) which gives a contradiction because \(\lambda _{\phi _k} >0.\)

Lemma 7.7

Assume that the D’Angelo 1-type of M in \({\mathbb {C}}^{n+1}\) at 0 is finite. At step j of the Kolář algorithm for the computation of the multitype at 0,  let \(\text {P}_j\) be the leading polynomial, and let \({\mathcal {I}}_{P_j} = \langle h \rangle \subset {\mathbb {C}}[z_1, \ldots , z_n]\) be the corresponding leading polynomial ideal.

If the Row Reduction algorithm is applied to the complex Jacobian matrix \(\text {J}(h),\) then every dependent row of \(\text {J}(h)\) vanishes. In other words, the leading polynomial ideal \({\mathcal {I}}_{P_j}\) is independent of the largest number of variables after the Row Reduction algorithm is applied to \(\text {J}(h).\)

Proof

From Theorem 1.1 the leading polynomial \(P_j\) is a sum of squares, and so let \(P_j = \sum _{i=1}^N |h_i|^2.\) Then the leading polynomial ideal \({\mathcal {I}}_{\text {P}_j}\) is \(\langle h \rangle = \langle h_1, \ldots , h_N \rangle ,\) and let the gradient ideal of each generator \(h_i\) be \({\mathcal {I}}_\mathrm{grad}(h_i) = \langle \frac{\partial h_i}{\partial z_1}, \ldots , \frac{\partial h_i}{\partial z_n} \rangle .\)

Now, assume that \(R_k,\) the kth row of \(\text {J}(h)\) is dependent. We will show that the generator \(\frac{\partial h}{\partial z_k}\) of the Jacobian module given by \({\mathfrak {J}}_{\langle h \rangle } = \left[ \frac{\partial h}{\partial z_1}, \ldots , \frac{\partial h}{\partial z_n} \right] \) vanishes after applying the Row Reduction algorithm on the complex Jacobian matrix \(\text {J}(h).\) Since \(R_k\) is dependent, we can write the generator \(\frac{\partial h}{\partial z_k}\) as

$$\begin{aligned} \frac{\partial h}{\partial z_k} = \sum _{u =1}^{v} \gamma _{c_u} \frac{\partial h}{\partial z_{c_u}}, \end{aligned}$$
(7.17)

for some \(k, \ c_u \ne k, \ v < n,\) and \(\gamma _{c_u}\) a nonzero polynomial in \({\mathbb {C}}[z_1, \ldots , z_n]\) for every u. Hence, every generator \(\frac{\partial h_i}{\partial z_k}\) of the gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_i)\) can be written as

$$\begin{aligned} \frac{\partial h_i}{\partial z_k} = \sum _{u = 1}^{v} \gamma _{c_u} \frac{\partial h_i}{\partial z_{c_u}}, \end{aligned}$$
(7.18)

for \(i = 1, \ldots , N\) and the same polynomial coefficients \(\gamma _{c_u}.\) Thus, it suffices to show that \(\frac{\partial h_i}{\partial z_k}\) vanishes at the termination of the algorithm for every \(i = 1, \ldots , N.\) Consider the ideal \({\mathcal {I}}_\mathrm{grad}(h_i)\) for some \(i \in \{1, \ldots , N \}.\) If the generator \(\frac{\partial h_i}{\partial z_k}\) is zero, then there is nothing to be done, and so we move to a different gradient ideal. Hence, suppose that \(\frac{\partial h_i}{\partial z_k}\) is nonzero. Then at least one of the generators \(\frac{\partial h_i}{\partial z_{c_u}}\) is nonzero for some u. Suppose that \(\frac{\partial h_i}{\partial z_{c_u}} \ne 0\) for all \(u \in \{1, \ldots , w\}\) for \(w \le v.\) Since it satisfies the condition in (7.18), we perform the elementary row operations \(\text {R}_{\ell } - \frac{\partial \zeta _{c_u}}{\partial z_{\ell }} \text {R}_{c_u} \rightarrow \text {R}_{\ell },\) for all variables \(z_{\ell }\) in \(\zeta _{c_u} = \int _0^{z_k} \gamma _{c_u}(t) \ \text {d}t\) and for all \(u=1, \ldots , w.\) This eliminates the term \(\sum _{u = 1}^w \gamma _{c_u} \frac{\partial h_e}{\partial z_{c_u}},\) from the ideal \({\mathcal {I}}_\mathrm{grad}(h_i).\) The generator \(\frac{\partial h}{\partial z_k}\) of the Jacobian module becomes

$$\begin{aligned} \frac{\partial h}{\partial z_k} = \sum _{u = w+1}^v \gamma _{c_u} \frac{\partial h}{\partial z_{c_u}} \end{aligned}$$
(7.19)

after the row operations have been performed on \(\text {J}(h).\) Note here that the generator \(\frac{\partial h_e}{\partial z_{c_u}},\) for all \(e \ne i\) and \(u=1, \ldots ,w\) cannot be central in any simplification process in the gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_e)\) after the row operations.

Next, consider another gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_e)\) for \(e \ne i.\) Then its kth generator after the reduction operation is

$$\begin{aligned} \frac{\partial h_e}{\partial z_k} - \sum _{u = 1}^{w} \gamma _{c_u} \frac{\partial h_e}{\partial z_{c_u}} = \sum _{u = w+1}^{v} \gamma _{c_u} \frac{\partial h_e}{\partial z_{c_u}}. \end{aligned}$$
(7.20)

If the expression in (7.20) equals zero, then there is nothing left to be done. If the expression in (7.20) is nonzero, then \(\frac{\partial h_e}{\partial z_{c_u}} \ne 0\) for some \(u = w+1, \ldots , q\) with \(q \le v.\) Perform the elementary row operations \(\text {R}_{\ell } - \frac{\partial \zeta _{c_u}}{\partial z_{\ell }} \text {R}_{c_u} \rightarrow \text {R}_{\ell },\) for all variables \(z_{\ell }\) in \(\zeta _{c_u} = \int _0^{z_k} \gamma _{c_u}(t) \ \text {d}t\) and for all \(u=w+1, \ldots , q\) to eliminate the term \(\sum _{u = w+1}^q \gamma _{c_u} \frac{\partial h_e}{\partial z_{c_u}},\) where \(q \le v.\) We follow this process through in each of the distinct gradient ideals until all gradient ideals have been considered. The expression in (7.19) becomes zero at some point; otherwise, we get a contradiction to \(R_k\) being dependent. \(\square \)

Example 3

Let the hypersurface \(M \subseteq {\mathbb {C}}^5 \) be given by \(r=0\) with

$$\begin{aligned} r = \text {2Re}(z_{5}) + |(z_1 + z_2 z_4 )^2+ z_2^4|^2 + |(z_1 + z_2 z_3^2)^2 |^2 + |z_2^9|^2 + |z_3^{10}|^2 + |z_4^{12}|^2. \end{aligned}$$

Let \(B = 2(z_1+ z_2 z_4), \ C = 2(z_1 + z_2 z_3^2),\) and let the ideal associated to the domain M be \(\langle h \rangle = \langle (z_1 + z_2 z_4 )^2+ z_2^4, (z_1 + z_2 z_3^2)^2, z_2^9, z_3^{10}, z_4^{12} \rangle .\) The complex Jacobian matrix is given by

$$\begin{aligned}\text {J}(h)= \begin{pmatrix} B &{} C &{} 0&{} 0 &{} 0 \\ z_4B+4z_2^3 &{} z_3^2 C &{} 9z_2^8 &{} 0 &{} 0 \\ 0&{} 2z_2z_3C &{} 0&{} 10z_3^9 &{} 0 \\ z_2B &{} 0 &{} 0&{} 0 &{} 12z_4^{11} \end{pmatrix} .\end{aligned}$$

The Bloom-Graham type is 4, \({\mathcal {I}}_{P_1} = \langle z_1^2, z_1^2 \rangle ,\) and \(\Lambda _1= (\frac{1}{4}, \frac{1}{4}, \frac{1}{4}, \frac{1}{4}).\) The maximum \(\text {W}_1 = \frac{1}{8},\) the leading polynomial ideal \({\mathcal {I}}_{P_2} = \langle (z_1 + z_2 z_4 )^2+z_2^4, z_1^2 \rangle ,\) and \(\Lambda _2= (\frac{1}{4}, \frac{1}{8}, \frac{1}{8}, \frac{1}{8}).\) The maximum \(\text {W}_2 = \frac{1}{16},\) \({\mathcal {I}}_{P_3} = \langle (z_1 + z_2 z_4 )^2 +z_2^4, (z_1 + z_2 z_3^2 )^2 \rangle ,\) and \(\Lambda _3= (\frac{1}{4}, \frac{1}{8}, \frac{1}{8}, \frac{1}{16}).\) The complex Jacobian matrix corresponding to \({\mathcal {I}}_{P_3}\) is given by

$$\begin{aligned}\text {J}(h_1, h_2)= \begin{pmatrix} B &{} C \\ z_4B+4z_2^3 &{} z_3^2 C \\ 0&{} 2z_2z_3C \\ z_2B &{} 0 \end{pmatrix} .\end{aligned}$$

Consider the gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_1) = \langle B, z_4B+4z_2^3, 0, z_2B \rangle .\) Since \( \frac{\partial h_1}{\partial z_4} = z_2 \frac{\partial h_1}{\partial z_1},\) its simplification is \({\mathcal {I}}_\mathrm{grad}(h_1) = \langle B, 4z_2^3 \rangle .\) We perform the elementary row operations \(\text {R}_2 - z_4 \text {R}_1 \rightarrow \text {R}_2\) and \(\text {R}_4 - z_2\text {R}_1 \rightarrow \text {R}_4\) on the matrix \(\text {J}(h).\) The matrices above become

$$\begin{aligned}\text {J}(h)= \begin{pmatrix} B &{} C &{} 0 &{} 0 &{} 0 \\ 4z_2^3 &{} (z_3^2-z_4)C &{} 9z_2^8 &{} 0 &{} 0 \\ 0 &{} 2z_2z_3C&{} 0 &{} 10z_3^9 &{} 0 \\ 0 &{} -z_2C&{} 0&{} 0 &{} 12z_4^{11} \end{pmatrix} \quad \text {and} \quad \text {J}(h_1, h_2)=\begin{pmatrix} B &{} C \\ 4z_2^3 &{} (z_3^2-z_4)C \\ 0 &{} 2z_2z_3C \\ 0 &{} -z_2C \end{pmatrix}. \end{aligned}$$

These operations correspond to the polynomial transformation \({{\tilde{z}}}_1 = z_1 + z_2z_4: \; {{\tilde{z}}}_{\omega } = z_{\omega }\) for \(\omega \ne 1,\) and now \(B = 2{{\tilde{z}}}_1 \) and \(C = 2({{\tilde{z}}}_1 + {{\tilde{z}}}_2({{\tilde{z}}}_3^2 - {{\tilde{z}}}_4)).\) The generator \(\frac{\partial h_2}{\partial z_1}\) cannot be a central generator in the simplification of \({\mathcal {I}}_\mathrm{grad}(h_2),\) and row 1 cannot be used as a central row in any subsequent elementary row operations. Consider the next gradient ideal \({\mathcal {I}}_\mathrm{grad}(h_2) = \langle C, ({{\tilde{z}}}_3^2 - {{\tilde{z}}}_4)C, 2{{\tilde{z}}}_2 {{\tilde{z}}}_3C, - {{\tilde{z}}}_2C \rangle .\) Here the generator \(-{{\tilde{z}}}_2 C\) in the fourth component is the only central generator in \({\mathcal {I}}_\mathrm{grad}(h_2).\) Thus, \( \frac{\partial h_2}{\partial z_3} = - 2{{\tilde{z}}}_3 \frac{\partial h_2}{\partial z_4},\) and its simplification is \(\langle C, ({{\tilde{z}}}_3^2 - {{\tilde{z}}}_4)C, - {{\tilde{z}}}_2C \rangle .\)

We perform the elementary row operations \(\text {R}_3 + 2z_3 \text {R}_4 \rightarrow \text {R}_3\) on the matrix \(\text {J}(h).\) The matrices become

$$\begin{aligned}\text {J}(h)= \begin{pmatrix} B &{} C &{} 0 &{} 0 &{} 0 \\ 4z_2^3 &{} (z_3^2-z_4)C &{} 9z_2^8 &{} 0 &{} 0 \\ 0 &{} 0&{} 0 &{} 10z_3^9 &{} 24z_3z_4^{11} \\ 0 &{} -z_2C&{} 0&{} 0 &{} 12z_4^{11} \end{pmatrix} \quad \text {and} \quad \text {J}(h_1, h_2)=\begin{pmatrix} B &{} C \\ 4z_2^3 &{} (z_3^2-z_4)C \\ 0 &{} 0 \\ 0 &{} -z_2C \end{pmatrix}. \end{aligned}$$

This operation corresponds to the polynomial transformation \(\dot{z}_4 = {{\tilde{z}}}_4 - {{\tilde{z}}}_3^2; \; \dot{z}_{\omega } = {{\tilde{z}}}_{\omega }\) for \(\omega \ne 4,\) and now \(B = 2\dot{z}_1 \) and \(C = 2(\dot{z}_1 - \dot{z}_2\dot{z}_4).\) The leading polynomial ideal \({\mathcal {I}}_{P_3} = \langle \dot{z}_1^2 + \dot{z}_2^4, (\dot{z}_1 - \dot{z}_2 \dot{z}_4 )^2 \rangle .\) The maximum \(W_3 = \frac{1}{20},\) and \(\Lambda _4 = \left( \frac{1}{4}, \frac{1}{8}, \frac{1}{8}, \frac{1}{20}\right) .\)