Multivariable calculus

Limit of (xy+z^2)/(x^2+y^2+z^2) Does Not Exist

The limit of (xy + z^2)/(x^2 + y^2 + z^2) at the origin in three variables does not exist. Along the x-axis the function is 0, along the line y = x with z = 0 it is 1/2, and along the z-axis it is 1. Three paths give three values, so no limit can exist.

f(x,y,z)=xy+z2x2+y2+z2f(x,y,z) = \frac{xy + z^2}{x^2 + y^2 + z^2}

The limit does not exist

PathLimit along it
along the x-axis0
along y = x in the plane z = 00.5
along the z-axis1

Three variables, same two-path test

Nothing about the method changes in three dimensions. Pick a curve through the origin, substitute, simplify, and take the parameter to zero. Start with the xx-axis, where y=z=0y = z = 0.

f(t,0,0)=0+0t2=0f(t, 0, 0) = \frac{0 + 0}{t^2} = 0

Now the zz-axis, where the numerator is z2z^2 and the denominator is also z2z^2.

f(0,0,t)=t2t2=1f(0, 0, t) = \frac{t^2}{t^2} = 1

That is already two different values, so the limit does not exist. A third path adds a value in between: take y=xy = x inside the plane z=0z = 0.

f(t,t,0)=t22t2=12f(t, t, 0) = \frac{t^2}{2t^2} = \frac{1}{2}

Both numerator and denominator are homogeneous of degree two, so on every ray from the origin the function is constant. That constant depends on the direction, which is the whole problem.

Spherical coordinates give the full picture

Put x=ρsinϕcosθx = \rho\sin\phi\cos\theta, y=ρsinϕsinθy = \rho\sin\phi\sin\theta, z=ρcosϕz = \rho\cos\phi. The denominator is ρ2\rho^2 and the numerator carries ρ2\rho^2 as well, so the radius cancels.

f=sin2ϕcosθsinθ+cos2ϕf = \sin^2\phi\cos\theta\sin\theta + \cos^2\phi

There is no ρ\rho, so the value never changes as you slide toward the origin along a fixed direction. Reading off the special directions is now easy.

  • ϕ=0\phi = 0 points along the zz-axis and gives cos2ϕ=1\cos^2\phi = 1.
  • ϕ=π/2\phi = \pi/2, θ=0\theta = 0 points along the xx-axis and gives 00.
  • ϕ=π/2\phi = \pi/2, θ=π/4\theta = \pi/4 gives 12\tfrac{1}{2}.
  • ϕ=π/2\phi = \pi/2, θ=π/4\theta = -\pi/4 gives 12-\tfrac{1}{2}, the smallest value.

The function takes every value from 12-\tfrac{1}{2} to 11 at points arbitrarily close to the origin.

The mistake: testing only the three coordinate axes

In three variables the reflex is to check the xx-, yy-, and zz-axes and stop. Here that happens to work, because the xx-axis and zz-axis already disagree. But the reflex is dangerous in general: had the numerator been xyxy alone, all three axes would give 00 and you would still need the diagonal y=xy = x to find the value 12\tfrac{1}{2}.

Approaching a point in space means approaching from a two-parameter family of directions, plus every curve. Axes are three of those directions. Treat them as a first probe, never as a proof.

When the axes do agree, switch to spherical coordinates or an inequality. If the ρ\rho-free part still depends on the angles, the limit does not exist; if a positive power of ρ\rho survives in front of a bounded factor, the limit is zero.

Frequently asked questions

Does this function have a limit along any plane through the origin?

Not on the planes you are likely to try. In the plane z=0z = 0 it reduces to xyx2+y2\frac{xy}{x^2+y^2}, which has no limit at the origin, and in the plane y=xy = x the point (t,t,s)(t, t, s) gives t2+s22t2+s2\frac{t^2 + s^2}{2t^2 + s^2}, which is 12\tfrac{1}{2} when s=0s = 0 and 11 when t=0t = 0. A plane still holds a whole family of directions, so the two-path argument runs inside it.

How would the answer change if the numerator were xyz?

Then the numerator is degree three against a degree-two denominator, and xyzρ3|xyz| \leq \rho^3 gives fρ|f| \leq \rho, so the limit would be 00. Mismatched degrees make the limit exist; matched degrees are what let direction matter.