-- This program calculates the product and intersection of three ideals I, J, K. -- In the ring R,the polynomial ring in three variables over the finite field -- of 31991 elements. -- It verifies that the radical of the product is the intersection. It varifies that -- the intersection is I and hence we 'probably' got the components of Z(I). -- In fact, Macaulay2 (that you run from prism by writing the commant M2), -- can find the components directly. Use the command 'decompose I' for that. -- To execute this file you use input "filename" -- The should be placed in the appropriate directory. Experiment! R=ZZ/31991[x, y, z]; I = ideal(x*z - x, x^2-y*z); J= ideal(x, y); K=ideal(x, z); L =ideal(z - 1, x^2 - y*z); M1=J*K*L M2=radical(M1) M1==M2 M3=intersect(J, K, L) M2==M3 decompose I t = x^3 - y*z; t % I s = x^2*(x*z - x) + z^3*(x^2 - y*z); s%I