Fordham
    University

Computer code for "The worst 1-PS for rational curves with a unibranch singularity" by Jackson and Swinarski

Example 4: Coordinates of the KKT solution vector \(x\) as rational functions

We study the coordinates of the KKT solution vector \(x\) as rational functions in \(N\).

We work with the semigroup \( \langle 4,9\rangle\) and face \(I = \{7,8,10\}\). Each coordinate of \(x\) should be given by a rational function in \(N\) once \(N \geq \max \{ \operatorname{c.i.}+2, \max(I)+2\}\). We begin by computing the conductor index.

Macaulay2, version 1.24.05
with packages: ConwayPolynomials, Elimination, IntegralClosure, InverseSystems, Isomorphism,
               LLLBases, MinimalPrimes, OnlineLookup, PrimaryDecomposition, ReesAlgebra,
               Saturation, TangentCone, Truncations, Varieties

i1 : load "Worst1PS.m2"

i2 : ci = conductorIndex({4,9})

o2 = 12
We will use \(N=16\) for many of the calculations below. Next, we compute the KKT solution vector \(x\) for the Simplified Problem when \(N=16\).
i3 : x = KKTsolutionVector(16,{4,9},{7,8,10},Simp=>true)

      3847  5258  17396  12452  1210  1520   331     114    54   13  32  320  220   4     18 
o3 = {----, ----, -----, -----, ----, ----, ----, - -----, ---, ---, --, ---, ---, --, - ---,
      3822  1911   5733   5733   637  1911  8673    37583  413  413  59  413  413  59    413 
     --------------------------------------------------------------------------------------------
      41  817
     ---, ---}
     413  413

o3 : List
Next, we compute the common denominator of these rational functions, which is given by the polynomial \[ Q(N) = (-1)^{N+1} \det A(N) \] where \(A(N)\) is the KKT matrix.
i4 : R=QQ[N];

i5 : q=Q({4,9},{7,8,10},R)
Q = -3669120*(N-14)^4-79252992*(N-14)^3-731622528*(N-14)^2-3121687296*(N-14)^1-4684732416*(N-14)^0

               4             3              2
o5 = - 3669120N  + 126217728N  - 1717881984N  + 11035245312N - 27861829632

o5 : R
Here, Macaulay2 prints the Taylor expansion of \(Q\) about \(14 = \{ \operatorname{c.i.}+2, \max(I)+2\} \). The output is the polynomial \(Q\) centered at 0. Next, we compute the polynomial \[ P_j(N) = (-1)^{N+1} \det A(N,j) \] and check that \(P_j/Q =x_3\).
i6 : p3=Pj(3,{4,9},{7,8,10},R)
P_3 = -11133440*(N-14)^4-240482304*(N-14)^3-2220007936*(N-14)^2-9472330752*(N-14)^1-14215176192*(N-14)^0

                4             3              2
o6 = - 11133440N  + 382990336N  - 5212676608N  + 33484934144N - 84542889984

o6 : R

i7 : substitute(p3,{N=>16})/substitute(q,{N=>16})

     17396
o7 = -----
      5733

o7 : QQ

Indeed, this gives the third coordinate of \(x\) shown above. Next, we compute the polynomials \[\begin{array}{rcl} \chi(N) &=& (-1)^{N+1} \det A(N,N-1) \\ \psi(N) &= &(-1)^{N+1} \det A(N,N) \\ \omega(N) &= & (-1)^{N+1} \det A(N,N+1) \end{array} \] and check that they give the numerators of the last three coordinates of \(x\).
i8 : f1=chi({4,9},{7,8,10},R)
chi = 35223552*(N-14)^3+352235520*(N-14)^2+457906176*(N-14)^1-1972518912*(N-14)^0

              3              2
o8 = 35223552N  - 1127153664N  + 11306760192N - 35998470144

o8 : R

i9 : substitute(f1,{N=>16})/substitute(q,{N=>16})

        18
o9 = - ---
       413

o9 : QQ

i10 : f2=psi({4,9},{7,8,10},R)
psi = -52835328*(N-14)^2-405070848*(N-14)^1-422682624*(N-14)^0

                 2
o10 = - 52835328N  + 1074318336N - 5107415040

o10 : R

i11 : substitute(f2,{N=>16})/substitute(q,{N=>16})

       41
o11 = ---
      413

o11 : QQ

i12 : f3=omega({4,9},{7,8,10},R)
omega = -7338240*(N-13)^4-111541248*(N-13)^3-908474112*(N-13)^2-3833496576*(N-13)^1-5494874112*(N-13)^0

                4             3              2
o12 = - 7338240N  + 270047232N  - 3999340800N  + 27723870720N - 73722894336

o12 : R

i13 : substitute(f3,{N=>16})/substitute(q,{N=>16})

      817
o13 = ---
      413

o13 : QQ
Next, we check the formulas for the coefficients of the Taylor expansion of \(\chi\) as given by Lemma 3.11. By the printed formula between i8 and o8 above, this is \[ \chi = 35223552 (N-14)^3+352235520 (N-14)^2+457906176 (N-14)-1972518912. \]
i14 : k=14

o14 = 14

i15 : M = Aprime(k,k-1,{4,9},{7,8,10},Simp=>true)

o15 = | -4 0  0  0  0  0  34 36 0  42 0  0  4  52 2 |
      | 8  -1 0  0  0  0  26 28 0  34 0  0  12 44 2 |
      | -4 5  -3 0  0  0  18 20 0  26 0  0  6  36 2 |
      | 0  -4 4  -1 0  0  16 18 0  24 0  0  4  34 2 |
      | 0  0  -1 4  -3 0  10 12 0  18 0  0  4  28 2 |
      | 0  0  0  -3 4  -1 8  10 0  16 0  0  4  26 2 |
      | 0  0  0  0  -1 4  2  4  0  10 0  0  4  20 2 |
      | 0  0  0  0  0  -3 0  2  0  8  0  0  0  18 2 |
      | 0  0  0  0  0  0  0  0  -1 6  0  0  2  16 2 |
      | 0  0  0  0  0  0  0  0  3  2  0  0  2  12 2 |
      | 0  0  0  0  0  0  0  0  -2 0  -2 0  0  10 2 |
      | 0  0  0  0  0  0  0  0  0  0  3  -1 2  8  2 |
      | 0  0  0  0  0  0  0  0  0  0  -1 3  2  4  2 |
      | 0  0  0  0  0  0  0  0  0  0  0  -2 0  2  2 |
      | 0  0  0  0  0  0  0  0  0  0  0  0  0  0  2 |

               15       15
o15 : Matrix QQ   <-- QQ

i16 : 1/3*(-1)^(k+1)*(2*del({k,k+1},{k,k+1},M)+2*del({k-1,k+1},{k,k+1},M))

o16 = 35223552

o16 : QQ

i17 : (-1)^(k+1)*(4*del({k,k+1},{k,k+1},M)+2*del({k-1,k+1},{k,k+1},M))

o17 = 352235520

o17 : QQ

i18 : 1/3*(-1)^(k+1)*(-14*del({k,k+1},{k,k+1},M)-8*del({k-1,k+1},{k,k+1},M)-6*del({k+2},{k+1},Aprime(k+1,k,{4,9},{7,8,10},Simp=>true)))

o18 = 457906176

o18 : QQ

i19 : (-1)^(k+1)*det(M)

o19 = -1972518912

o19 : QQ
We check the formulas for the coefficients of the Taylor expansion of \(\psi\) as given by Lemma 3.11. By the printed formula between i10 and o10 above, this is \[ \psi = -52835328 (N-14)^2-405070848 (N-14)-422682624. \]
i20 : k=14

o20 = 14

i21 : M = Aprime(k,k,{4,9},{7,8,10},Simp=>true)

o21 = | -4 0  0  0  0  0  34 36 0  42 0  0  0  4  2 |
      | 8  -1 0  0  0  0  26 28 0  34 0  0  0  12 2 |
      | -4 5  -3 0  0  0  18 20 0  26 0  0  0  6  2 |
      | 0  -4 4  -1 0  0  16 18 0  24 0  0  0  4  2 |
      | 0  0  -1 4  -3 0  10 12 0  18 0  0  0  4  2 |
      | 0  0  0  -3 4  -1 8  10 0  16 0  0  0  4  2 |
      | 0  0  0  0  -1 4  2  4  0  10 0  0  0  4  2 |
      | 0  0  0  0  0  -3 0  2  0  8  0  0  0  0  2 |
      | 0  0  0  0  0  0  0  0  -1 6  0  0  0  2  2 |
      | 0  0  0  0  0  0  0  0  3  2  0  0  0  2  2 |
      | 0  0  0  0  0  0  0  0  -2 0  -2 0  0  0  2 |
      | 0  0  0  0  0  0  0  0  0  0  3  -1 0  2  2 |
      | 0  0  0  0  0  0  0  0  0  0  -1 3  -1 2  2 |
      | 0  0  0  0  0  0  0  0  0  0  0  -2 2  0  2 |
      | 0  0  0  0  0  0  0  0  0  0  0  0  -1 0  2 |

               15       15
o21 : Matrix QQ   <-- QQ

i22 : (-1)^(k+1)*(del({k+1},{k+1},M)+del({k},{k+1},M))

o22 = -52835328

o22 : QQ

i23 : (-1)^(k+1)*(3*del({k+1},{k+1},M)+del({k},{k+1},M))

o23 = -405070848

o23 : QQ

i24 : (-1)^(k+1)*det(M)

o24 = -422682624

o24 : QQ
We check the statement of Lemma 3.12.
i25 : (1/2)*leadCoefficient(f1)==-(1/3)*leadCoefficient(f2)

o25 = true
We also illustrate Lemma 3.13.
i26 : p14=Pj(14,{4,9},{7,8,10},R)
P_14 = 58705920*(N-15)^4+516612096*(N-15)^3+575318016*(N-15)^2-1009741824*(N-15)^1-1127153664*(N-15)^0

               4              3               2
o26 = 58705920N  - 3005743104N  + 56580765696N  - 462086037504N +
      ---------------------------------------------------------------------
      1371886903296

o26 : R

i27 : p14 == (N-14)*(N-14+1)*(1/2*f1+1/3*(N-14-1)*f2)

o27 = true
Finally, we use the same semigroup, but a different set of corners, to illustrate Proposition 5.5.
i28 : g1=chi({4,9},{7,8,10,20},R)
chi = 7021228032*(N-22)^3+42127368192*(N-22)^2+77233508352*(N-22)^1+42127368192*(N-22)^0

                 3                2
o28 = 7021228032N  - 421273681920N  + 8418452410368N - 56029399695360

o28 : R

i29 : factor(g1)

o29 = (N - 21)(N - 20)(N - 19)(7021228032)

o29 : Expression of class Product

i30 : g2=psi({4,9},{7,8,10,20},R)
psi = -10531842048*(N-22)^2-52659210240*(N-22)^1-63191052288*(N-22)^0

                    2
o30 = - 10531842048N  + 410741839872N - 4002099978240

o30 : R

i31 : factor(g2)

o31 = (N - 20)(N - 19)(-10531842048)

o31 : Expression of class Product

i32 : (1/2)*leadCoefficient(g1)==-(1/3)*leadCoefficient(g2)

o32 = true
Indeed, the polynomials \(\chi\) and \(\psi\) factor as claimed in Proposition 5.5.