Procedure from library mregular.lib (see mregular_lib).
Usage:
is_nested (i); i monomial ideal
Return:
1 if i is of nested type, 0 otherwise.
(returns -1 if i=(0) or i=(1)).
Assume:
i is a nonzero proper monomial ideal.
Notes:
1. The ideal must be monomial, otherwise the result has no meaning
(so check this before using this procedure).
2. is_nested is used in procedures depthIdeal, regIdeal and satiety.
3. When i is a monomial ideal of nested type of S=K[x(0)..x(n)],
the a-invariant of S/i coincides with the upper bound obtained
using the procedure regIdeal with printlevel > 0.
Theory:
A monomial ideal is of nested type if its associated primes are all
of the form (x(0),...,x(i)) for some i<=n.
(see definition and effective criterion to check this property in
the preprint 'Saturation and Castelnuovo-Mumford regularity' by
Bermejo-Gimenez, 2004).