Hilbert Series and Graded Rings

The theory of Hilbert series is standard so it is only briefly touched on here. See Matsumura [Mat89] Section 13 for more details (or other any standard textbook on algebra such as Zariski--Samuel or Eisenbud.)

Contents

Hilbert Series and Hilbert Polynomials

Let R = direct-sum Rn, the sum taken over n≥0, be a finitely-generated graded k-algebra with R0=k and grading given by n. The Hilbert polynomial of R is the numerical polynomial p(t) such that dim Rn = p(n) for all n sufficiently large. The Hilbert series of R is the power series

P(R) = ∑n≥0 (dim Rn) tn.

For example, let C⊂PP3 be the twisted cubic defined by the three equations

xz = y2, xt = yz, yt = z2

and let

R = ( (k[x, y, z, t]) /(xz - y2, xt - yz, yt - z2) )

be the homogeneous polynomial ring of C. Then one computes that

P(R) = 1 + 4t + 7t2 + 10t3 + ... as follows. Certainly R0=k, and there are no equations of degree 1 so R1 is the 4-dimensional vector space spanned by x, y, z, t. Now R2 is spanned by the 10 quadrics x2, xy, ..., t2, but these are related by the three equations, so dim R2 = 10 - 3 = 7. And so on. If you are systematic about it, you will discover quickly that the dimension of Rn is 3n + 1 for n≥1. This can be proved by induction. So the Hilbert polynomial of R is p(t)=3t + 1, which determines every coefficient of the Hilbert series P(R) except the constant term.

Consider a bigger example: let C=C10⊂PP(1, 1, 5) be a hyperelliptic curve of genus 4 and degree 2 given by an equation

y2 = f10(x1, x2)

in coordinates x1, x2, y on wps PP(1, 1, 5) where f10 is some general polynomial of degree 10. Again one calculates the Hilbert polynomial as p(t)=2t - 3 and Hilbert series as

P(t) = 1 + 2t + 3t2 + 4t3 + 5t4 + 7t5 + 9t6 + ... .

This power series can also be described as a rational function

P(t) = ((1 - t10)/((1 - t)2(1 - t5)))

from which one can formulate a rule of thumb for relating this expression to the description of the curve as C10⊂PP(1, 1, 5) (or see the answer in Section Making New Databases or [Rei00], Section 3.2).

Now there are other curves in wps that have the same Hilbert polynomial p as this example, but which have a different Hilbert series. To find one, consider modifying early terms of the series

P(t) = 1 + t + 2t2 + 4t3 + 5t4 + 7t5 + 9t6 + ... and attempt to build the curve B in some wps. The coefficient of the term t (which is 1 in this case) implies that there is one linear coordinate x. Then the 2t2 demands one degree 2 coordinate y so that the 2-dimensional space of degree 2 homogeneous functions is spanned by x2, y. In degree 3, x, y generate only a 2-dimensional space < x3, xy >, but the graded piece in degree 3 is 4-dimensional, according to the term 4t3, so there must be two more generators z1, z2. In degree 4 we see x4, x2y, y2, xz1, xz2 which is just right if we assume that these are linearly independent (which we do). Similarly in degree 5 we hit the right number on the nose. But in degree 6 we see 11 monomials:

x6, x4y, x2y2, y3, x3z1, xyz1, x3z2, xyz2, z12, z1z2, z22.

These lie in a 9-dimensional vector space (9 being the coefficient of t6 in P(t)) so there must be two relations between them. We could carry on in this vein, but in fact we have done enough now: it is an exercise in wps to show that the curve

B = B6, 6 ⊂PP(1, 2, 3, 3)

defined by two general polynomials of degree 6 has genus 4 and degree 2 just as in the first example. We will work this example in Magma in the next subsection.

Thus the Hilbert polynomial determines the coefficients of high powers of t in the Hilbert series. So in this case, and more generally for the subcanonical curves of Section Subcanonical Curves, to determine a Hilbert series P one must produce both the Hilbert polynomial p and a sequence V of the early coefficients that are not determined by p.

There is one extra twist that can happen: it is possible that there is not a single Hilbert polynomial p that determines the higher coefficients, but a sequence of polynomials p0, ..., pr - 1 so that the nth coefficient is given by pi(n) where i is the residue of n modulo r. It is easy to generate examples of this using the intrinsics described below. This phenomenon occurs naturally when the RR data includes quotient singularities or fractional divisors, since these tend to make periodic corrections to an otherwise well-determined Hilbert polynomial, and one could rephrase this as above by saying that there is a sequence of Hilbert polynomials. In practice, this is a small distraction that is completely bound up in the main creation intrinsics.

HilbertFunction(p,V) : RngUPolElt, SeqEnum -> UserProgram
HilbertFunction(Q,V) : SeqEnum, SeqEnum -> UserProgram
The Hilbert function determined by a univariate polynomial p (the Hilbert polynomial), or a sequence Q of univariate polynomials, and a sequence of initial values V. The returned object is a function whose domain is the integers.
HilbertSeries(p,V) : RngUPolElt, SeqEnum -> FldFunRatUElt
HilbertSeries(Q,V) : SeqEnum, SeqEnum -> FldFunRatUElt
The Hilbert series determined by a univariate polynomial p (the Hilbert polynomial), or a sequence Q of univariate polynomials, and a sequence of initial values V. The returned object is a rational function in one variable.

Interpreting the Hilbert Numerator

The Hilbert series of a variety X⊂(P)(w0, ..., wN) defined by equations of degrees d1, ..., dr has the form

P(t) = ((1 - td1 - td2 - ... - tdr + te ∓ ... ∓ tk) /((1 - tw0) ... (1 - twN))).

We refer to the numerator of this expression as the Hilbert numerator with respect to the weights w0, ..., wN, or simply Hilbert numerator if the weights are clear.

The aim is to apply a converse statement: if we can manipulate the Hilbert series of a polarised variety into such a form, we guess that it is embedded in (P)(w0, ..., wN) by equations of degrees given by low degree terms with negative coefficients (where the absolute value of the coefficient determines the number of equations of that degree).

This can be taken further: the syzygies, and indeed a free resolution of the ideal of X, are also encoded weakly in the weights and the Hilbert numerator. For more details see [Rei00], Section 3, or [ABR02], Section 4.

HilbertSeriesMultipliedByMinimalDenominator(p,V) : RngUPolElt, SeqEnum -> RngUPolElt, SeqEnum
HilbertSeriesMultipliedByMinimalDenominator(Q,V) : SeqEnum, SeqEnum -> RngUPolElt, SeqEnum
Let h be the Hilbert series determined by a univariate polynomial p, or a sequence Q of univariate polynomials, and a sequence of initial values V. This function produces a rational expression g(t)/Π(1 - td) for h, returning the numerator g as first value and a sequence containing the factors 1 - td of the denominator as second value.
HilbertNumerator(g, D) : FldFunRatUElt, SeqEnum -> FldFunRatUElt
The product g x Π(1 - td) taken over all integers d∈D, assuming the result is a polynomial. This function is typically used when g is a Hilbert series and D is a proposed collection of weights for a variety realising this series.

Example GrdRng_gr-genus4curve (H125E1)

We reproduce the example described in the introduction to this Section Hilbert Series and Graded Rings.
> T<t> := PolynomialRing(Rationals());
> p := 2*t - 3;
> V := [ 1, 2, 3, 4 ];
> h_fun := HilbertFunction(p,V);
> [ h_fun(n) : n in [0..7]];
[ 1, 2, 3, 4, 5, 7, 9, 11 ]
> h := HilbertSeries(p,V);
> h;
(t^5 + 1)/(t^2 - 2*t + 1)
The Hilbert series will be the Hilbert series of a polarised curve C (since the degree of the Hilbert polynomial---the order of growth of the coefficients of the Hilbert series---is one). It is already expressed as a rational function, so we apply a power series ring coercion to see the dimensions of the graded pieces---we could increase the precision if required.
> S<s> := PowerSeriesRing(Rationals(),8);
> S ! h;
1 + 2*s + 3*s^2 + 4*s^3 + 5*s^4 + 7*s^5 + 9*s^6 + 11*s^7 + O(s^8)
The rule of thumb for interpreting Hilbert series as varieties defined by homogeneous polynomials in wps requires one to write the Hilbert series in the form P/Q for polynomials P, Q, where Q is a product of terms 1 - ta (corresponding to the coordinates of weight a). The next line computes the Hilbert series together with the minimal such expression.
> HilbertSeriesMultipliedByMinimalDenominator(p,V);
t^5 + 1
[ -t + 1, -t + 1 ]
One could interpret this return value as a Noether normalisation of the graded ring of C. Instead, we try some values for a new weight a hoping to stumble on the weights of a wps in which C embeds. We start with a=4, then try a=5.
> HilbertNumerator(h,[1,1,4]);
-t^9 + t^5 - t^4 + 1
> HilbertNumerator(h,[1,1,5]);
-t^10 + 1
The first answer made little sense. Having included a generator in degree 4 it demanded an equation of the same degree. That is certainly possible, but assuming the equation involves only the weight 1 variables, it would factorise and the result would not be a variety. However, the final answer is just what we hope for: it suggests that C is realised by a degree 10 curve in PP(1, 1, 5), which makes perfect sense and is what we expected.

Now consider the modified Hilbert series of the second example of Section Hilbert Series and Graded Rings in which we changed the early coefficients from V=[1, 2, 3, 4] to [1, 1, 2, 4], but kept the Hilbert polynomial p.

> h1 := HilbertSeries(p,[1,1,2,4]);
> S ! h1;
1 + s + 2*s^2 + 4*s^3 + 5*s^4 + 7*s^5 + 9*s^6 + 11*s^7 + O(s^8)
> HilbertNumerator(h1,[1,1,5]);
-t^10 + t^9 - t^8 - t^7 + t^6 - t^4 + t^3 + t^2 - t + 1
This implies that there is an equation in degree 1. Such an equation immediately eliminates one of the two degree 1 coordinates which would be daft, so we eliminate this redundancy right at the beginning by trying instead
> HilbertNumerator(h1,[1,5]);
t^9 + t^7 + 2*t^6 + t^5 + t^4 + 2*t^3 + t^2 + 1
In short, this suggests a new variable in degree 2 and two new variables in degree 3: this could be done methodically by considering one generator at a time.
> HilbertNumerator(h1,[1,2,3,3,5]);
-t^17 + t^12 + 2*t^11 - 2*t^6 - t^5 + 1
Now examining this Hilbert numerator, we see that the first equation is in degree 5. But there is a variable of degree 5. Although that is not a problem, we could try to remove the degree 5 variable, as we would, in practice, if we knew that it appeared linearly in the equation.
> HilbertNumerator(h1,[1,2,3,3]);
t^12 - 2*t^6 + 1
Finally, this suggests B6, 6⊂PP(1, 2, 3, 3), and again it is an easy exercise in wps to confirm that such a curve really does exist with the predicted properties.
FindFirstGenerators(g) : FldFunRatUElt -> SeqEnum
This intrinsic function returns a sequence containing the results of a first attempt to deduce plausible weights of generators for the variety with Hilbert series g. The method used proceeds by advancing through the coefficients of g, in order of increasing degree, adding generators of that degree for each positive coefficient. The algorithm stops when it first finds a negative coefficient.

Example GrdRng_gr-grfirstgens (H125E2)

We first make a Hilbert series which has initial terms 1 + 2t + 3t2 + 4t3.
> T<t> := PolynomialRing(Rationals());
> p := 2*t - 3;
> V := [ 1, 2, 3, 4 ];
> h := HilbertSeries(p,V);
> h;
(t^5 + 1)/(t^2 - 2*t + 1)
> S<s> := PowerSeriesRing(Rationals(),4);
> S ! h;
1 + 2*s + 3*s^2 + 4*s^3 + O(s^4)
This h is, in fact, the Hilbert series of a graded ring generated by three elements in degrees 1,1,5.
> FindFirstGenerators(h);
[ 1, 1, 5 ]
There is no guarantee that this intrinsic will always find suitable weights, but it does return a subset of the weights that must occur for any variety that realises the given Hilbert series.
ApparentCodimension(f) : RngUPolElt -> RngIntElt
ApparentEquationDegrees(f) : RngUPolElt -> RngIntElt
ApparentSyzygyDegrees(f) : RngUPolElt -> RngIntElt
If f=f(t) is a polynomial of the form

f = 1 - ∑i=1N0 a0, i ti + ∑k=N0 + 1N1 a1, i ti - ... + ( - 1)k - 1 ∑_(i=Nk - 2 + 1)Nk - 1 ak - 1, i ti + ( - 1)k tNk

then the apparent codimension is k, the apparent equation degrees are those i for which a0, i is nonzero (with a0, i equations having that degree i) and the apparent syzygy degrees are those i for which a1, i is nonzero.

V2.28, 13 July 2023