V = ( xz-y2=0 , xw-yz=0 , yw-z2=0 )
ring r=0,(x,y,z,w),dp;
ideal i=xz-y2,xw-yz,yw-z2;
i=std(i);
hilb(i);
==> 1 t^0
==> -3 t^2
==> 2 t^3
==>
==> 1 t^0
==> 2 t^1
==> codimension = 2
dimension = 2
degree = 3
1st Hilbert series: Q(t) =
1-3t2+2t2 ,
2nd Hilbert series: P(t) = 1+2t .
This result can be used to compute the Hilbert polynomial H of
M = K[x,y,z,w] / I :
intvec a=hilb(i,2);
ring s=0,t,ls;
poly h; int j;
for (j=1; j<=size(a);
j=j+1){h=h+a[j]*(t-j+2);} h;
==> 1+3t
Hilbert polynomial: H(t) = 1+3t .