# Singular

#### D.15.2.1 autKS

Procedure from library `autgradalg.lib` (see autgradalg_lib).

Usage:
autKS(TOR); TOR: optional list of elementary divisors in case of torsion.

Assume:

Purpose:
Compute the subgroup Aut_K(S) of GL(n) of graded automorphisms of the polynomial ring S (the basering).

Return:
returns a ring S and exports an ideal ideal Iexported in the coordinate ring S = K[Y_ij] of GL(n) such that Aut_K(S) = V(I).

Example:
 ```LIB "autgradalg.lib"; ////////////////// // example: fano 15: intmat Q[1][5] = 3,3,2,2,1; ring R = 0,T(1..5),dp; // attach degree matrix Q to R: setBaseMultigrading(Q); //ideal I = T(1)*T(2) + T(3)^2*T(4) + T(5)^6; def S = autKS(); ==> // coefficients: QQ ==> // number of vars : 50 ==> // block 1 : ordering dp ==> // : names T(1) T(2) T(3) T(4) T(5) Y(1) Y(2) Y(3) Y(\ 4) Y(5) Y(6) Y(7) Y(8) Y(9) Y(10) Y(11) Y(12) Y(13) Y(14) Y(15) Y(16) Y(1\ 7) Y(18) Y(19) Y(20) Y(21) Y(22) Y(23) Y(24) Y(25) Y(26) Y(27) Y(28) Y(29\ ) Y(30) Y(31) Y(32) Y(33) Y(34) Y(35) Y(36) Y(37) Y(38) Y(39) Y(40) Y(41)\ Y(42) Y(43) Y(44) Y(45) ==> // block 2 : ordering C setring S; dim(std(Iexported)); ==> 17 basering; ==> // coefficients: QQ ==> // number of vars : 46 ==> // block 1 : ordering dp ==> // : names Y(1) Y(2) Y(3) Y(4) Y(5) Y(6) Y(7) Y(8) Y(\ 9) Y(10) Y(11) Y(12) Y(13) Y(14) Y(15) Y(16) Y(17) Y(18) Y(19) Y(20) Y(21\ ) Y(22) Y(23) Y(24) Y(25) Y(26) Y(27) Y(28) Y(29) Y(30) Y(31) Y(32) Y(33)\ Y(34) Y(35) Y(36) Y(37) Y(38) Y(39) Y(40) Y(41) Y(42) Y(43) Y(44) Y(45) ==> // block 2 : ordering lp ==> // : names Z ==> // block 3 : ordering C autKSexported; ==> [1]: ==> [1]: ==> _[1,1]=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 ==> _[9,6]=0 ==> _[9,7]=0 ==> _[9,8]=0 ==> _[9,9]=Y(41)^3 ==> [2]: ==> 1 ==> [3]: ==> _[1]=Y(3) ==> _[2]=Y(4) ==> _[3]=Y(5) ==> _[4]=Y(8) ==> _[5]=Y(12) ==> _[6]=Y(13) ==> _[7]=Y(14) ==> _[8]=Y(17) ==> _[9]=Y(19) ==> _[10]=Y(20) ==> _[11]=Y(23) ==> _[12]=Y(24) ==> _[13]=Y(25) ==> _[14]=Y(27) ==> _[15]=Y(28) ==> _[16]=Y(29) ==> _[17]=Y(32) ==> _[18]=Y(33) ==> _[19]=Y(34) ==> _[20]=Y(36) ==> _[21]=Y(37) ==> _[22]=Y(38) ==> _[23]=Y(39) ==> _[24]=Y(40) ==> _[25]=Y(42) ==> _[26]=Y(43) ==> _[27]=Y(44) ==> _[28]=Y(45) ==> _[29]=-Y(2)*Y(10)*Y(22)^2*Y(30)^2*Y(41)^8*Z+Y(1)*Y(11)*Y(22)^2*Y(30\ )^2*Y(41)^8*Z+2*Y(2)*Y(10)*Y(21)*Y(22)*Y(30)*Y(31)*Y(41)^8*Z-2*Y(1)*Y(11)\ *Y(21)*Y(22)*Y(30)*Y(31)*Y(41)^8*Z-Y(2)*Y(10)*Y(21)^2*Y(31)^2*Y(41)^8*Z+Y\ (1)*Y(11)*Y(21)^2*Y(31)^2*Y(41)^8*Z-1 ==> [4]: ==> T(1),T(2),T(3),T(4),T(5),T(3)*T(5),T(4)*T(5),T(5)^2,T(5)^3 getVariableWeights(); ==> 3,3,2,2,1,3,3,2,3,3,3,2,2,1,3,3,2,3,3,3,2,2,1,3,3,2,3,3,3,2,2,1,3,3,2,3,3\ ,3,2,2,1,3,3,2,3,-22 kill S, Q, R; ///////////// // example 3.14 from the paper intmat Q[3][5] = 1,1,1,1,1, 1,-1,0,0,1, 1,1,1,0,0; list TOR = 2; ring R = 0,T(1..5),dp; // attach degree matrix Q to R: setBaseMultigrading(Q); //ideal I = T(1)*T(2) + T(3)^2 + T(4)^2; def S = autKS(); ==> // coefficients: QQ ==> // number of vars : 30 ==> // block 1 : ordering dp ==> // : names T(1) T(2) T(3) T(4) T(5) Y(1) Y(2) Y(3) Y(\ 4) Y(5) Y(6) Y(7) Y(8) Y(9) Y(10) Y(11) Y(12) Y(13) Y(14) Y(15) Y(16) Y(1\ 7) Y(18) Y(19) Y(20) Y(21) Y(22) Y(23) Y(24) Y(25) ==> // block 2 : ordering C ==> // ** redefining adMons ( list adMons;) ==> // ** redefining MONexported ( export(MONexported);) setring S; Iexported; ==> Iexported[1]=Y(23) ==> Iexported[2]=Y(22) ==> Iexported[3]=Y(21) ==> Iexported[4]=Y(18) ==> Iexported[5]=Y(17) ==> Iexported[6]=Y(16) ==> Iexported[7]=Y(15) ==> Iexported[8]=Y(14) ==> Iexported[9]=Y(12) ==> Iexported[10]=Y(11) ==> Iexported[11]=Y(10) ==> Iexported[12]=Y(9) ==> Iexported[13]=Y(8) ==> Iexported[14]=Y(5) ==> Iexported[15]=Y(4) ==> Iexported[16]=Y(3) ==> Iexported[17]=Y(24)*Y(25) ==> Iexported[18]=Y(20)*Y(25) ==> Iexported[19]=Y(6)*Y(25) ==> Iexported[20]=Y(2)*Y(25) ==> Iexported[21]=Y(19)*Y(24) ==> Iexported[22]=Y(7)*Y(24) ==> Iexported[23]=Y(1)*Y(24) ==> Iexported[24]=Y(19)*Y(20) ==> Iexported[25]=Y(7)*Y(20) ==> Iexported[26]=Y(1)*Y(20) ==> Iexported[27]=Y(6)*Y(19) ==> Iexported[28]=Y(2)*Y(19) ==> Iexported[29]=Y(6)*Y(7) ==> Iexported[30]=Y(2)*Y(7) ==> Iexported[31]=Y(1)*Y(6) ==> Iexported[32]=Y(1)*Y(2) ==> Iexported[33]=Y(2)*Y(6)*Y(13)*Y(20)*Y(24)*Z+Y(1)*Y(7)*Y(13)*Y(19)*Y(25)*Z\ -1 ==> Iexported[34]=Y(1)*Y(7)*Y(13)*Y(19)*Y(25)^2*Z-Y(25) ==> Iexported[35]=Y(1)*Y(7)*Y(13)*Y(19)^2*Y(25)*Z-Y(19) ==> Iexported[36]=Y(1)*Y(7)^2*Y(13)*Y(19)*Y(25)*Z-Y(7) ==> Iexported[37]=Y(1)^2*Y(7)*Y(13)*Y(19)*Y(25)*Z-Y(1) print(getVariableWeights()); ==> 1 1 1 1 1 1 1 1 1 1 1 1 \ 1 1 1 1 1 1 1 1 1 1 1 1 \ 1 -5 ==> 1 -1 0 0 1 1 -1 0 0 1 1 -1 \ 0 0 1 1 -1 0 0 1 1 -1 0 0 \ 1 -1 ==> 1 1 1 0 0 1 1 1 0 0 1 1 \ 1 0 0 1 1 1 0 0 1 1 1 0 \ 0 -3 kill S, R, Q; ```