############################################################################################################################################################### # Calculation of the 5 nodal points associated to potential tropical lines meeting the interior of a tropical cubic del Pezzo (smooth with no Eckardt points) # ############################################################################################################################################################### # The following script allows to compute the quintuples of nodal points in TX tr opicalizing to the bundary points of potential tropical lines meeting the interior of Trop X. # The algorithm makes use of the projective 3-dimensional span of X and computes the coordinates of each node as a rational function in the Yoshidas. Each entry is either 0 or a Laurent monomial in the Yoshidas and Cross functions. Each entry contains at least one Cross factor. # We first convert the basis of the P^3 span of X from rational functions in the ds to rational functions in the Yoshidas. The required functions are coded in "OperatorsOnYoshidas.sage" load("OperatorsOnYoshidas.sage") ###################################### # Span of P^3 in Yoshida coordinates # ###################################### # We compute the solution space to the 270 equations as a rational function in the Yoshidas. # The calculation takes about 20 minutes on a 2.4 GHz Intel(R) Core 2 Duo with 3MB cache and 2GB RAM. # YoshidaIntegerMM = {} # for i in range(0,4): # print i # for j in range(0,45): # print j # if ModIntegerMM[i][j] == 0: # YoshidaIntegerMM[(i,j)] = 0 # else: # YoshidaIntegerMM[(i,j)] = DtoY(basering(ModIntegerMM[i][j]).factor()) # # Since DtoY is correct up to sign, we have to go back and check the sign. # # We record the output as a sage object: # save(YoshidaIntegerMM, "../Output/YoshidaIntegerMM.sobj") # We load the precomputed file: MMInYoshidas = load("../Output/YoshidaIntegerMM.sobj") # # We record the output as a plain text file: # f = file("../Output/YoshidaIntegerMM.txt", 'w') # f.write('{') # for i in range(0,4): # for j in range(0,45): # if (i,j) == (3,44): # f.write(str((i,j)) + ':' + str(MMInYoshidas[i][j]) + '}') # else: # f.write(str((i,j)) + ':' + str(MMInYoshidas[i][j]) + ',') # f.close() ################################################################################ # We use the action of W(E6) to compute the 5 intersection points associated to the potential non-boundary tropical lines associated to the 27 extremal curves. Our computation starts with the line associated to G2. # ############################################################################### # The following script contains the action of W(E6) on all variables and the relevant action on the Ds that send each (-1)-curve to the desired one. load("OperatorsOnYoshidas.sage") roots = load("Input/rootsE6.sobj") # This dictionary corresponds to the standard non-permutation element of W(E6). We use it to generate the intersection points via the W(E6)-action: exc_switch_dict = {d6: -2/3*d4 - 2/3*d5 + 1/3*d6, d5: -2/3*d4 + 1/3*d5 - 2/3*d6, d4: 1/3*d4 - 2/3*d5 - 2/3*d6, d3: d3 + 1/3*d4 + 1/3*d5 + 1/3*d6, d2: d2 + 1/3*d4 + 1/3*d5 + 1/3*d6, d1: d1 + 1/3*d4 + 1/3*d5 + 1/3*d6} exc_switch = basering.hom([basering(exc_switch_dict[var(x)]) for x in basering.gens()]) ################# # POINTS FOR G2 # ################# # We compute the 5 points at infinity corresponding to a potential tropical line indexed by G2. These 5 points are the points pi2 of intersection of the pairs of extremal curves that form an anticanonical triangle with G2, namely Ei and Fi2 (for i=1,3,4,5,6). The coordinates of these points are polynomials in the Yoshida functions. We compute the point p12 and then use the action of S6 to compute the remaining 4 points. We record these points as pdi2_yoshidas. # Coordinates of the points p_j2 = E_j \cap F_j2. # Computation of pd12 (commented since the output has been stored) # load("OperatorsOnYoshidas.sage") # pd12 = pd(1,2) # pd12_yoshidas = {} # for x in pd12.keys(): # if pd12[x] == 0: # pd12_yoshidas[x] = 0 # else: # pd12_yoshidas[x] = DtoY(basering(pd12[x]).factor()) #save(pd12_yoshidas, "../Output/pd12_yoshidas.sobj") pd12_yoshidas = load("../Output/pd12_yoshidas.sobj") # We use the action of suitable elements of the permutation group S6 to determine the remaining four points pdi2_yoshidas = "intersection of Ei and Fi2" for i=3,4,5,6. #The function takes the sign of the permutation into consideration: if the key changes sign, we incorporate the sign into the value at that coordinate. def new_pds(old_pds, dictionary): answer = {} for k in old_pds.keys(): newK = S(SR(k).substitute(dictionary)) if newK in pd12_yoshidas.keys(): sign = 1 elif -newK in pd12_yoshidas.keys(): sign = -1 newK = -1 * newK else: print "Error. Key (or its negative) not found: " + str(newK) answer_for_newK = sign * YField(SR(expand(old_pds[k])).substitute(dictionary)) if answer_for_newK == 0: answer[newK] = 0 else: answer[newK] = answer_for_newK.factor() return answer # We use the following elements in W(E6), computed in "OperatorsOnYoshidas.sage." # a13 = Permutation([3,2,1,4,5,6]) pd32_yoshidas = new_pds(pd12_yoshidas, a13) # a14 = Permutation([4,2,3,1,5,6]) pd42_yoshidas = new_pds(pd12_yoshidas, a14) # a15 = Permutation([5,2,3,4,1,6]) pd52_yoshidas = new_pds(pd12_yoshidas, a15) # a16 = Permutation([6,2,3,4,5,1]) pd62_yoshidas = new_pds(pd12_yoshidas, a16) # We record the 5 points corresponding to G2 computed above and use the action of W(E6) to find the 5 tuples of points corresponding to the remaining 26 extremal curves. We use suitable actions of elements in W(E6), computed in "OperatorsOnYoshidas.sage." pds = {} pds[G2] = [pd12_yoshidas,pd32_yoshidas,pd42_yoshidas,pd52_yoshidas,pd62_yoshidas] # Go from G2 to G1 pds[G1] = [new_pds(pd, a12) for pd in pds[G2]] # Go from G2 to G3 pds[G3] = [new_pds(pd, a23) for pd in pds[G2]] # From G2 to G4 pds[G4] = [new_pds(pd, a24) for pd in pds[G2]] # From G2 to G5 pds[G5] = [new_pds(pd, a25) for pd in pds[G2]] # From G2 to G6 pds[G6] = [new_pds(pd, a26) for pd in pds[G2]] # From G2 to F13 pds[F13] = [new_pds(pd, exc) for pd in pds[G2]] # From F13 to F12 pds[F12] = [new_pds(pd, a23) for pd in pds[F13]] # From F13 to F14 pds[F14] = [new_pds(pd, a34) for pd in pds[F13]] # From F13 to F15 pds[F15] = [new_pds(pd, a35) for pd in pds[F13]] # From F13 to F16 pds[F16] = [new_pds(pd, a36) for pd in pds[F13]] # From F13 to F23 pds[F23] = [new_pds(pd, a12) for pd in pds[F13]] # From F23 to F24 pds[F24] = [new_pds(pd, a34) for pd in pds[F23]] # From F23 to F25 pds[F25] = [new_pds(pd, a35) for pd in pds[F23]] # From F23 to F26 pds[F26] = [new_pds(pd, a36) for pd in pds[F23]] # From F24 to F34 pds[F34] = [new_pds(pd, a23) for pd in pds[F24]] # From F25 to F35 pds[F35] = [new_pds(pd, a23) for pd in pds[F25]] # From F26 to F36 pds[F36] = [new_pds(pd, a23) for pd in pds[F26]] # From F35 to F45 pds[F45] = [new_pds(pd, a34) for pd in pds[F35]] # From F36 to F46 pds[F46] = [new_pds(pd, a34) for pd in pds[F36]] # From F46 to F56 pds[F56] = [new_pds(pd, a45) for pd in pds[F46]] pds[E4] = [new_pds(pd, exc) for pd in pds[F56]] # From E4 to E1 pds[E1] = [new_pds(pd, a14) for pd in pds[E4]] # From E4 to E2 pds[E2] = [new_pds(pd, a24) for pd in pds[E4]] # From E4 to E3 pds[E3] = [new_pds(pd, a34) for pd in pds[E4]] # From E4 to E5 pds[E5] = [new_pds(pd, a45) for pd in pds[E4]] # From E4 to E6 pds[E6] = [new_pds(pd, a46) for pd in pds[E4]] # We record the output on the folder for Computing lines, since we will be using it then. # save(pds, "../../ComputeLines/Scripts/Input/AllPds_signed_ordered_permutedCols.sobj.sobj") # save(pds, "../Output/AllPds_signed_ordered_permutedCols.sobj") ################################################## # Commands used to get the 27 plain text outputs # ################################################## # We save the output as plain texts in the Output folder of the Yoshida folder: # for k in pds.keys(): # f=file('../Output/AllPds_'+str(k)+'_signed_ordered_permutedCols.txt','w') # f.write( str(pds[k])) # f.close()