FUNCTION: LieTools/SgHdim
USAGE: SgHdim(Gbasis);
SYNOPSIS: SgHdim calculates the Hilbert dimension of an ideal in S(g) generated
  by the Groebner basis Gbasis.
CAVEATS: requires a previously initialized global Lie algebra environment.
  (See LieTools[gSetup].)
EXAMPLE: 
with(LieTools):gSetup(G,2):
Setting up Gtype = G   rnk = 2
> pbasis := SgMkRepWgtBasis([1,0],3):
> pbasis := [op(pbasis),add(add(BI[i,j]*g[i]*g[j],i=1..dimg),j=1..dimg)]:
> Gbasis := SgGroebnerBasis(pbasis):
> SgHdim(Gbasis);
 
                  10

SEE ALSO: LieTools[SgGroebnerBasis] 
