// First example in the notes for the Trieste meeting: // given a curve with parametrization (t^3,t^4,t^5), // determine its singular locus // Step 1: determine the ideal of the curve from the parametrization ring r=0,(t,x,y,z),dp; // ring of char 0 containg variables x,y,z and t ideal Ip=x-t^3,y-t^4,z-t^5; // input of the parametrization ideal Ie=eliminate(Ip,t); // compute ideal of the curve Ie; // Step 2: move the ideal to the correct ring ring r2=0,(x,y,z),dp; // we do not need t any more ideal I=imap(r,Ie); // move the ideal of the curve to this ring //Step 3: compute dimesion of coordinate ring of the curve // dimension of K[x,y,z]/I; 'std' required for int dimA=dim(std(I)); // using command 'dim' dimA; // we already know that it is 1 //Step 4: determine the jacobian matrix matrix Jac=jacob(I); // determine Jacobian matrix print(Jac); // show the matrix //Step 5: the ideal of minors and singular locus ideal J=minor(Jac,3-dimA); // determine the minors ideal sL=J+I; // ideal of singular locus sL; //Step 6: pass to the radical of the ideal sL LIB"primdec.lib"; // the radical is contained in a singular library radical(sL); // which needs to be loaded before using it