# testIdeal -- compute a test ideal in a Q-Gorenstein ring

## Synopsis

• Usage:
testIdeal(R)
testIdeal(t, f)
testIdeal(tList, fList)
• Inputs:
• R, a ring, a $\mathbb{Q}$-Gorenstein ring
• f, , the element in a pair
• t, , the formal exponent to which f is raised
• fList, a list, consisting of ring elements f_1,\ldots,f_n, for a pair
• tList, a list, consisting of formal exponents t_1,\ldots,t_n for the elements of fList
• Optional inputs:
• AssumeDomain => , default value false, assumes the ring is an integral domain
• FrobeniusRootStrategy => , default value Substitution, selects the strategy for internal frobeniusRoot calls
• MaxCartierIndex => an integer, default value 10, sets the maximum $\mathbb{Q}$-Gorenstein index to search for
• QGorensteinIndex => an integer, default value 0, specifies the $\mathbb{Q}$-Gorenstein index of the ring
• Outputs:
• an ideal, the test ideal \tau(R), \tau(R,f^{t}), or \tau(R,f_1^{t_1}\ldots f_n^{t_n}), depending on the arguments passed

## Description

Given a normal $\mathbb{Q}$-Gorenstein ring $R$, testIdeal(R) simply computes the test ideal \tau($R$).

 i1 : R = ZZ/5[x,y,z]/(x^3 + y^3 + z^3); i2 : testIdeal(R) o2 = ideal (z, y, x) o2 : Ideal of R
 i3 : S = ZZ/5[x,y,z,w]; i4 : T = ZZ/5[a,b]; i5 : f = map(T, S, {a^3, a^2*b, a*b^2, b^3}); o5 : RingMap T <--- S i6 : R = S/(ker f); i7 : testIdeal(R) o7 = ideal 1 o7 : Ideal of R

Given a nonnegative rational number $t$ and an element $f$ of a normal $\mathbb{Q}$-Gorenstein ring $R$, testIdeal(t,f) computes the test ideal \tau($R$, $f^{ t}$).

 i8 : R = ZZ/5[x,y,z]; i9 : f = y^2 - x^3; i10 : apply({1/2, 4/5, 5/6, 1}, t -> testIdeal(t, f) ) 3 2 o10 = {ideal 1, ideal (y, x), ideal (y, x), ideal(x - y )} o10 : List i11 : R = ZZ/7[x,y,z]; i12 : f = y^2 - x^3; i13 : apply({1/2, 4/5, 5/6, 1}, t -> testIdeal(t, f) ) 3 2 o13 = {ideal 1, ideal 1, ideal (y, x), ideal(x - y )} o13 : List

The ring $R$ need not be a polynomial ring, as the next example illustrates.

 i14 : R = ZZ/11[x,y,z]/(x^2 - y*z); i15 : testIdeal(1/2, y) o15 = ideal (y, x) o15 : Ideal of R i16 : testIdeal(1/3, y) o16 = ideal 1 o16 : Ideal of R

Given nonnegative rational numbers $t_1, t_2, \ldots$ and ring elements $f_1, f_2, \ldots$, testIdeal(\{t_1,t_2,\ldots\},\{f_1,f_2,\ldots\}) computes the test ideal \tau($R$, $f_1^{t_1} f_2^{t_2}\cdots$).

 i17 : R = ZZ/7[x,y]; i18 : L = {x, y, x + y}; i19 : f = x*y*(x + y); i20 : testIdeal({2/3, 2/3, 2/3}, L) o20 = ideal (y, x) o20 : Ideal of R i21 : testIdeal(2/3, f) o21 = ideal (y, x) o21 : Ideal of R i22 : testIdeal({3/4, 2/3, 3/5}, L) o22 = ideal (y, x) o22 : Ideal of R

It is often more efficient to pass a list, as opposed to finding a common denominator and passing a single element, since testIdeal can do things in a more intelligent way for such a list.

 i23 : time testIdeal({3/4, 2/3, 3/5}, L) -- used 0.114079 seconds o23 = ideal (y, x) o23 : Ideal of R i24 : time testIdeal(1/60, x^45*y^40*(x + y)^36) -- used 0.178814 seconds o24 = ideal (y, x) o24 : Ideal of R

The option AssumeDomain (default value false) is used when finding a test element. The option FrobeniusRootStrategy (default value Substitution) is passed to internal frobeniusRoot calls.

When working in a $\mathbb{Q}$-Gorenstein ring $R$, testIdeal looks for a positive integer $N$ such that $N K_R$ is Cartier. The option MaxCartierIndex (default value $10$) controls the maximum value of $N$ to consider in this search. If the smallest such $N$ turns out to be greater than the value passed to MaxCartierIndex, then testIdeal returns an error.

The $\mathbb{Q}$-Gorenstein index can be specified by the user through the option QGorensteinIndex; when this option is used, the search for $N$ is bypassed, and the option MaxCartierIndex ignored.