// Solution to Q2 // Ring Z5[x, y] ring r = 5, (x, y), lp; poly f1 = x^2 + y^2 + 1; poly f2 = x^2*y + 2*x*y + x; ideal J = f1, f2; printf("Compute G = GB(f1, f2). If G ==1, then there are no solutions in the closure."); printf("If G !=1, then there are solutions, somewhere in the closure"); ideal G; G = groebner(J); printf("GB G is:"); groebner(G); printf("Note that since G has non-unit polynomials, there are solutions over the closure"); printf("Now create the ideal of vanishing polyniomials in Z5: ideal J0 = x^5-x, y^5-y"); ideal J0 = x^5 -x, y^5-y; printf("Compute G = GB(J+J0):"); G = groebner(J+J0); G;