Home Online Manual
Back: sing_lib
Forward: deform
FastBack: qhmoduli_lib
FastForward: spcurve_lib
Up: sing_lib
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

D.6.13.1 codim

Procedure from library sing.lib (see sing_lib).

codim(id1,id2); id1,id2 ideal or module, both must be standard bases

int, which is:
1. the vectorspace dimension of id1/id2 if id2 is contained in id1 and if this number is finite
2. -1 if the dimension of id1/id2 is infinite
3. -2 if id2 is not contained in id1

consider the Hilbert series iv1(t) of id1 and iv2(t) of id2. If codim(id1,id2) is finite, q(t)=(iv2(t)-iv1(t))/(1-t)^n is rational, and the codimension is the sum of the coefficients of q(t) (n = dimension of basering).

LIB "sing.lib";
ring r  = 0,(x,y),dp;
ideal j = y6,x4;
ideal m = x,y;
attrib(m,"isSB",1);  //let Singular know that ideals are a standard basis
codim(m,j);          // should be 23 (Milnor number -1 of y7-x5)
==> 23