For an ideal or K-subalgebra E of K[X1, . . . , Xn], consider subfields k ⊂ K, where E is generated – as ideal or K-subalgebra – by polynomials in k[X1, . . . , Xn]. It is a standard result for ideals that there is a smallest such k. We give an algorithm to find it. We also prove that there is a smallest such k for K-subalgebras. The ideal results use reduced Gröbner bases. For the subalgebra r...