Compute minimal number of generators of subring
Hi all,
Given a polynomial ring R=k[x1,...,xn] over a field k (say Q) and a list of polynomials p1,..,pn in R, R (homogeneous say), is Sage capable of computing the minimal number of generators of the subring generated by p1,...,pn over k?
Next, suppose I is a homogeneous ideal of R. Can the same approach be used to compute the minimal number of generators of this subring after being projected to R/I ?
Edit: Sorry for the bad formatting (see source), please help me fix it if you can!
Edit2: For example, let R=Q[x,y] and let p1=x2,p2=x2y,p3=x4y. This generates a principal ideal, but as a subring it has 2 generators and it is those 2 generators that I want.
Edit3: In case it is helpful, the case I'm looking at is a ring with an action of a group, and its subring of invariants for which I have generators.
Edit4: Here's a suggested algorithm: sort the generators by degree. Then sequentially add them, and check if they were already in the subring. Does Sage even have suitable subring capabilities?