/////////////////////////////////// // Modifications for Theta Graph // /////////////////////////////////// // The following contains an example for Cell4 combinatorial type of the modified tropical theta graphs in R^3. The curve can be visualized by means of projections. // We use the parameters b5, b4, b34, b2, where b3 = b34+b4, a5 = -b5^2, a4 = b4^2, a3 = b3^2, a2 = b2^2. we use this strategy since the modifications involve square roots. // The parameters w5,w3, w34, w2 satisfy: // PiecesTypeIICone3[1][0].Hrepresentation() // (An equation (0, 0, 1, -1) x + 0 == 0, // An inequality (1, -1, 0, 0) x + 0 >= 0, // An inequality (-1, 2, -1, 0) x + 0 >= 0) // We want cancellation, namely in(b4)^2 = -in(b2)^2. The subdivision will be the same as in the Generic case, with the exception that the x^4 monomial is unmarked. ///////////////////////////// // Case 4: [0, -1, -3, -3] // ///////////////////////////// LIB "all.lib"; LIB "poly.lib"; LIB "tropical.lib"; LIB "elim.lib"; ring rr = (0,t), (b2,b34,b4,b5, x,y,z),dp; poly f=y^2-x*(x+b2^2)*(x-(b4+b34)^2)*(x-b4^2)*(x+b5^2); // f; // -b2^2*b34^2*b4^2*b5^2*x-2*b2^2*b34*b4^3*b5^2*x-b2^2*b4^4*b5^2*x-b2^2*b34^2*b4^2*x^2-2*b2^2*b34*b4^3*x^2-b2^2*b4^4*x^2+b2^2*b34^2*b5^2*x^2+2*b2^2*b34*b4*b5^2*x^2+2*b2^2*b4^2*b5^2*x^2-b34^2*b4^2*b5^2*x^2-2*b34*b4^3*b5^2*x^2-b4^4*b5^2*x^2+b2^2*b34^2*x^3+2*b2^2*b34*b4*x^3+2*b2^2*b4^2*x^3-b34^2*b4^2*x^3-2*b34*b4^3*x^3-b4^4*x^3-b2^2*b5^2*x^3+b34^2*b5^2*x^3+2*b34*b4*b5^2*x^3+2*b4^2*b5^2*x^3-b2^2*x^4+b34^2*x^4+2*b34*b4*x^4+2*b4^2*x^4-b5^2*x^4-x^5+y^2 setring(rr); poly B5 = (1+t^2); poly B4 = (3*t+t^7); poly B34 = (5*t^3); poly B2 = (5*t^3); map P2 = rr, B2, B34, B4, B5, x, y, z; poly ff = P2(f); ring r = (0,t),(x,y),dp; map newP2 = rr, 0,0,0,0,x,y,0; poly f2 = newP2(ff); // f2; // -x5+(2t14+10t10+12t8+29t4+16t2-1)*x4+(-t28-10t24-12t22+25t20-88t18+200t16+162t14+387t12+676t10+267t8-192t6-15t4+18t2)*x3+(-25t34-t32-252t30-311t28-657t26-2259t24-1402t22-3709t20-6298t18-1849t16-4123t14-4886t12-1203t10-396t8-432t6-81t4)*x2+y2+(-25t38-50t36-275t34-800t32-1475t30-3800t28-6475t26-8700t24-15600t22-19950t20-17775t18-20700t16-21150t14-10800t12-2025t10)*x drawTropicalCurve(f2,"max"); /////////////////// // XZ-projection // /////////////////// poly B5 = newP2(B5); poly B4 = newP2(B4); poly B34 = newP2(B34); poly B2 = newP2(B2); poly B3 = B34 + B4; poly g2 = substitute(f2, y, y+B3*B4*B5*x-B5*x^2); // g2; // -x5+(2t14+10t10+12t8+30t4+18t2)*x4+(-t28-10t24-12t22+25t20-90t18+196t16+150t14+355t12+642t10+225t8-270t6-81t4)*x3+(-2t2-2)*x2y+(-25t34-250t30-300t28-625t26-2200t24-1250t22-3450t20-5950t18-1225t16-3325t14-4175t12-375t10+450t8)*x2+(2t16+2t14+10t12+22t10+12t8+30t6+48t4+18t2)*xy+y2+(-25t38-50t36-275t34-800t32-1475t30-3800t28-6475t26-8700t24-15600t22-19950t20-17775t18-20700t16-21150t14-10800t12-2025t10)*x drawTropicalCurve(g2,"max"); /////////////////// // ZY-projection // /////////////////// ring s = (0,t),(x,y,z),dp; map P = r, x,y; poly ff= P(f2); poly B5 = P(B5); poly B4 = P(B4); poly B3 = P(B3); poly B34 = P(B34); ideal I = (ff,z-y+B3*B4*B5*x-B5*x^2); poly fnox= eliminate(I,x)[1]; // Replace z by y and y by x so that the pictures are not flipped. ring r2 = (0,t),(x,y),dp; setring(r2); map PP = s,0,x,y; poly newfnox = PP(fnox); // newfnox; // x5-5*x4y+10*x3y2-10*x2y3+5*xy4-y5+(100t22+100t20+500t18+1100t16+1850t14+2750t12+2400t10+900t8)*x4+(-400t22-402t20-2006t18-4416t16-7444t14-11066t12-9676t10-3720t8-144t6-84t4-18t2)*x3y+(600t22+605t20+3015t18+6640t16+11210t14+16665t12+14594t10+5720t8+400t6+250t4+65t2+4)*x2y2+(-400t22-404t20-2012t18-4432t16-7488t14-11132t12-9756t10-3860t8-328t6-208t4-56t2-4)*xy3+(100t22+101t20+503t18+1108t16+1872t14+2783t12+2439t10+965t8+82t6+52t4+14t2+1)*y4+(-25t52-50t50-400t48-1200t46-1275t44-6075t42+1000t40+18875t38+87875t36+277750t34+639875t32+1300250t30+2185875t28+3022375t26+3445250t24+2926675t22+1520850t20+223050t18-232350t16-133200t14-18225t12)*x3+(75t52+150t50+1200t48+3600t46+3825t44+18025t42-3800t40-59825t38-274825t36-863800t34-1995225t32-4067600t30-6877725t28-9600375t26-11108500t24-9790925t22-5763650t20-1869050t18-217300t16-89550t14-111625t12-30000t10-1800t8)*x2y+(-75t52-150t50-1200t48-3600t46-3825t44-17925t42+4200t40+61425t38+280425t36+879075t34+2033025t32+4151025t30+7037775t28+9867000t26+11494875t24+10296375t22+6364200t20+2469000t18+674475t16+334125t14+194775t12+45000t10+2700t8)*xy2+(25t52+50t50+400t48+1200t46+1275t44+5975t42-1400t40-20475t38-93475t36-293025t34-677675t32-1383675t30-2345925t28-3289000t26-3831625t24-3432125t22-2121400t20-823000t18-224825t16-111375t14-64925t12-15000t10-900t8)*y3+(-625t74-1875t72-14375t70-53125t68-191875t66-645625t64-1822500t62-4916250t60-11949375t58-26671250t56-55264375t54-104845625t52-185914375t50-303043750t48-455396250t46-641016250t44-817056250t42-943533125t40-1014278750t38-961298750t36-753173125t34-492293750t32-247004375t30-26914375t28+111968125t26+129364375t24+74743125t22+24226875t20+3915000t18+202500t16)*x2+(1250t74+3800t72+29000t70+107750t68+390450t66+1316250t64+3731850t62+10098700t60+24644300t58+55270350t56+115111650t54+219798200t52+392530950t50+645651550t48+981474150t46+1399898400t44+1818594050t42+2157659500t40+2397791000t38+2393356600t36+2067832750t34+1601511300t32+1112440600t30+621541400t28+247367050t26+79658200t24+48686100t22+40895100t20+21281400t18+5868450t16+765450t14+36450t12)*xy+(-625t74-1900t72-14500t70-53875t68-195225t66-658125t64-1865925t62-5049350t60-12322150t58-27635175t56-57555825t54-109899100t52-196265475t50-322825775t48-490737075t46-699949200t44-909297025t42-1078829750t40-1198895500t38-1196678300t36-1033916375t34-800755650t32-556220300t30-310770700t28-123683525t26-39829100t24-24343050t22-20447550t20-10640700t18-2934225t16-382725t14-18225t12)*y2+(-625t94-3750t92-25000t90-125000t88-528125t86-2051250t84-7071250t82-22376875t80-65606250t78-177963750t76-451130000t74-1071321250t72-2389171250t70-5020466250t68-9955694375t66-18676474375t64-33170408125t62-55801567500t60-89069163125t58-134778158750t56-193118418750t54-262297353750t52-337059300625t50-408057321875t48-464952050625t46-497685886875t44-496326195000t42-457122082500t40-386911080000t38-297762058125t36-202801117500t34-117367396875t32-55135468125t30-20023858125t28-5303323125t26-942232500t24-97048125t22-4100625t20)*x+(625t94+3750t92+25000t90+125000t88+528125t86+2051250t84+7071250t82+22376875t80+65606250t78+177963750t76+451130000t74+1071321250t72+2389171250t70+5020466250t68+9955694375t66+18676474375t64+33170408125t62+55801567500t60+89069163125t58+134778158750t56+193118418750t54+262297353750t52+337059300625t50+408057321875t48+464952050625t46+497685886875t44+496326195000t42+457122082500t40+386911080000t38+297762058125t36+202801117500t34+117367396875t32+55135468125t30+20023858125t28+5303323125t26+942232500t24+97048125t22+4100625t20)*y drawTropicalCurve(newfnox,"max");