 // Two transversal cusps in (k^3,0):
ring r2 =0,(x,y,z),ds;
ideal i =z21y3+x3y,xz,1xy2+x4,x3z;
resolution rs=mres(i,0); // computes a minimal resolution
rs; // the standard representation of complexes
==> 1 3 2
==> r2 < r2 < r2
==>
==> 0 1 2
==>
list resi=rs; // convertion to a list
print(resi[1]); // the 1st module is i minimized
==> xz,
==> z2y3+x3y,
==> xy2x4
print(resi[2]); // the 1st syzygy module of i
==> z,y2+x3,
==> x, 0,
==> y, z
resi[3]; // the 2nd syzygy module of i
==> _[1]=0
ideal j=minor(resi[2],2);
reduce(j,std(i)); // check whether j is contained in i
==> _[1]=0
==> _[2]=0
==> _[3]=0
size(reduce(i,std(j))); // check whether i is contained in j
==> 0
// size(<ideal>) counts the nonzero generators
// 
// The tangent developable of the rational normal curve in P^4:
ring P = 0,(a,b,c,d,e),dp;
ideal j= 3c24bd+ae, 2bcd+3ad2+3b2e4ace,
8b2d29acd29b2ce+9ac2e+2abde1a2e2;
resolution rs=mres(j,0);
rs;
==> 1 2 1
==> P < P < P
==>
==> 0 1 2
==>
list L=rs;
print(L[2]);
==> 2bcd3ad23b2e+4ace,
==> 3c2+4bdae
// create an intmat with graded Betti numbers
intmat B=betti(rs);
// this gives a nice output of Betti numbers
print(B,"betti");
==> 0 1 2
==> 
==> 0: 1  
==> 1:  1 
==> 2:  1 
==> 3:   1
==> 
==> total: 1 2 1
==>
// the user has access to all Betti numbers
// the 2nd column of B:
B[1..4,2];
==> 0 1 1 0
ring cyc5=32003,(a,b,c,d,e,h),dp;
ideal i=
a+b+c+d+e,
ab+bc+cd+de+ea,
abc+bcd+cde+dea+eab,
abcd+bcde+cdea+deab+eabc,
h5abcde;
resolution rs=lres(i,0); //computes the resolution according LaScala
rs; //the shape of the minimal resolution
==> 1 5 10 10 5 1
==> cyc5 < cyc5 < cyc5 < cyc5 < cyc5 < cyc5
==>
==> 0 1 2 3 4 5
==>
print(betti(rs),"betti"); //shows the Bettinumbers of cyclic 5
==> 0 1 2 3 4 5
==> 
==> 0: 1 1    
==> 1:  1 1   
==> 2:  1 1   
==> 3:  1 2 1  
==> 4:  1 2 1  
==> 5:   2 2  
==> 6:   1 2 1 
==> 7:   1 2 1 
==> 8:    1 1 
==> 9:    1 1 
==> 10:     1 1
==> 
==> total: 1 5 10 10 5 1
==>
dim(rs); //the homological dimension
==> 4
size(list(rs)); //gets the full (nonreduced) resolution
==> 6
minres(rs); //minimizes the resolution
==> 1 5 10 10 5 1
==> cyc5 < cyc5 < cyc5 < cyc5 < cyc5 < cyc5
==>
==> 0 1 2 3 4 5
==>
size(list(rs)); //gets the minimized resolution
==> 6
