# doubling -- implement the doubling construction

## Synopsis

• Usage:
doubling(d, I)
• Inputs:
• d, an integer, the degree of the map
• I, an ideal, homogeneous, in a singly graded polynomial ring $S$
• Optional inputs:
• Count => an integer, default value 10, number of random maps to generate before giving up and returning null
• Outputs:
• an ideal, an ideal $J$ containing $I$ such that the canonical module of $S/I$ is $J/I \otimes S(-d)$, or null, if either one doesn't exist or one cannot be found

## Description

Let $R = S/I$, and $w_R = \operatorname{Ext}^c(R, S^{-n-1})$, where $c$ is the codimension of $I$ and $n+1$ is the number of variables of the polynomial ring $S$.

If there exists an injective homomorphism $f \colon w_R \to R$ of degree $d$, this function returns the ideal defining the cokernel of a random such map. If none exist, null is returned. If after trying the number of trials given by the optional argument Count, none that are injective can be found (this is very unlikely), null is also returned. Setting the global variable debugLevel to a positive value will let you know how many times it took to find one (if it didn't find it right away).

If $S/I$ is arithmetically Cohen-Macaulay of codimension $c$, then the cokernel of $f$ will be arithmetically Gorenstein of codimension $c+1$.

See section 2.5 of [QQ] for more details and references.

 i1 : S = ZZ/101[a..d]; i2 : I = pointsIdeal randomPoints(S, 6) 2 2 2 o2 = ideal (a*c - 14b*c + 43c + 31a*d - 28b*d - 17c*d + 28d , b + 11b*c + ------------------------------------------------------------------------ 2 2 2 37c - 40a*d - 45b*d - 10c*d - 23d , a*b + 35b*c - 18c - 31a*d - 38b*d ------------------------------------------------------------------------ 2 2 2 2 + 7c*d - 35d , a + 49b*c + 40c - 4a*d - 22b*d - 45c*d - 5d ) o2 : Ideal of S i3 : betti res I 0 1 2 3 o3 = total: 1 4 5 2 0: 1 . . . 1: . 4 2 . 2: . . 3 2 o3 : BettiTally i4 : doubling(5, I) i5 : J = doubling(8, I) 2 2 2 o5 = ideal (a*c - 14b*c + 43c + 31a*d - 28b*d - 17c*d + 28d , b + 11b*c + ------------------------------------------------------------------------ 2 2 2 37c - 40a*d - 45b*d - 10c*d - 23d , a*b + 35b*c - 18c - 31a*d - 38b*d ------------------------------------------------------------------------ 2 2 2 2 2 + 7c*d - 35d , a + 49b*c + 40c - 4a*d - 22b*d - 45c*d - 5d , c d - ------------------------------------------------------------------------ 2 2 2 3 2 2 2 3 28a*d + 9b*d + 50c*d + 50d , b*c*d - 15a*d + 39b*d - 26c*d - d ) o5 : Ideal of S i6 : betti res J 0 1 2 3 4 o6 = total: 1 6 10 6 1 0: 1 . . . . 1: . 4 2 . . 2: . 2 6 2 . 3: . . 2 4 . 4: . . . . 1 o6 : BettiTally

Here are some doublings of the Veronese surface

 i7 : S = ZZ/101[x_0..x_5]; i8 : M = genericSymmetricMatrix(S, 3) o8 = | x_0 x_1 x_2 | | x_1 x_3 x_4 | | x_2 x_4 x_5 | 3 3 o8 : Matrix S <--- S i9 : I = trim minors(2, M) 2 2 2 o9 = ideal (x - x x , x x - x x , x x - x x , x - x x , x x - x x , x - 4 3 5 2 4 1 5 2 3 1 4 2 0 5 1 2 0 4 1 ------------------------------------------------------------------------ x x ) 0 3 o9 : Ideal of S i10 : doubling(4, I) -- no such map exists i11 : betti res doubling(6,I) 0 1 2 3 4 o11 = total: 1 9 16 9 1 0: 1 . . . . 1: . 9 16 9 . 2: . . . . 1 o11 : BettiTally i12 : betti res doubling(7,I) 0 1 2 3 4 o12 = total: 1 9 16 9 1 0: 1 . . . . 1: . 6 8 3 . 2: . 3 8 6 . 3: . . . . 1 o12 : BettiTally i13 : betti res doubling(8,I) 0 1 2 3 4 o13 = total: 1 9 16 9 1 0: 1 . . . . 1: . 6 8 3 . 2: . . . . . 3: . 3 8 6 . 4: . . . . 1 o13 : BettiTally i14 : J = doubling(8, I); o14 : Ideal of S i15 : (dim J, degree J) o15 = (2, 14) o15 : Sequence i16 : (dim I, degree I) o16 = (3, 4) o16 : Sequence
 i17 : S = ZZ/101[x_0..x_8]; i18 : M = genericMatrix(S, 3, 3) o18 = | x_0 x_3 x_6 | | x_1 x_4 x_7 | | x_2 x_5 x_8 | 3 3 o18 : Matrix S <--- S i19 : I = trim minors(2, M) o19 = ideal (x x - x x , x x - x x , x x - x x , x x - x x , x x - x x , 5 7 4 8 2 7 1 8 5 6 3 8 4 6 3 7 2 6 0 8 ----------------------------------------------------------------------- x x - x x , x x - x x , x x - x x , x x - x x ) 1 6 0 7 2 4 1 5 2 3 0 5 1 3 0 4 o19 : Ideal of S i20 : betti res doubling(8,I) 0 1 2 3 4 5 o20 = total: 1 10 25 25 10 1 0: 1 . . . . . 1: . 10 16 9 . . 2: . . 9 16 10 . 3: . . . . . 1 o20 : BettiTally i21 : J = doubling(8, I); o21 : Ideal of S i22 : (dim J, degree J) o22 = (4, 12) o22 : Sequence i23 : (dim I, degree I) o23 = (5, 6) o23 : Sequence