  We study holomorphic function germs under equivalence relations that preserve
an analytic variety. We show that two quasihomogeneous polynomials, not
necessarily with isolated singularities, having isomorphic relative Milnor
algebras are relative right equivalent. Under the condition that the module of
vector fields tangent to the variety is finitely generated, we also show that
the relative Tjurina algebra is a complete invariant for the classification of
arbitrary function germs with respect to the relative contact equivalence. This
is the relative version of a well known result by Mather and Yau.
