Let f (resp. φ) be a C∞
(resp. real-analytic) function germ near the origin in Rn. Assume that f is divisible
by φ in C∞, and that it belongs to a sufficiently regular utradifferentiable class
{ℓ!Mℓ} of Carleman type (for example, one of the Gevrey rings familiar in the theory
of differential equations). What can then be said about the regularity of the quotient
f∕φ? In this paper, we obtain first a complete solution of this problem in the case
n = 2. Namely, it is shown that f∕φ belongs to the Carleman class {ℓ!Mℓd(φ)},
where d(φ) is a suitable Łojasiewicz exponent for the regular separation between the
space R2 and certain components of the complex zero set Zφ of φ. This
number can be explicitely computed by means of Puiseux expansions. We
prove moreover that the division result is sharp for any φ and M. Finally, we
apply it to get a characterization of closed principal ideals generated by
real-analytic functions in Carleman classes of two variables, improving a result
which was known previously only in the case of generators with isolated real
zeros.