Let P-n = K[x(1), ..., x(n)] be the polynomial algebra over a field K
of characteristic 0. We show that applying an automorphism to a given
polynomial p is an element of P-n is mimicked by Grobner transformatio
ns of a basis of the ideal of P-n generated by partial derivatives of
this polynomial. In the case of P-2, this yields a miraculously simple
algorithm for deciding whether or not a given polynomial from P-2 is
part of a basis. Another application is an algorithm which, given a po
lynomial p is an element of P-2 that is part of a basis, finds a seque
nce of elementary automorphisms that reduces p to x(1). We also specul
ate on how our method may be used for constructing a possible countere
xample to the Jacobian conjecture in higher dimensions. (C) 1997 Acade
mic Press.