Multivariable calculus

Partial Derivatives of arctan(x/(1 + y^2))

For f = arctan(x/(1 + y^2)), the partials are f_x = (1 + y^2)/((1 + y^2)^2 + x^2) and f_y = -2xy/((1 + y^2)^2 + x^2). The outer derivative 1/(1 + u^2) at u = x/(1 + y^2) clears to (1 + y^2)^2 over that common denominator, and the inner partials then cancel most of it away.

f(x,y)=arctan ⁣(x1+y2)f(x,y) = \arctan\!\left(\frac{x}{1 + y^2}\right)
fx=1+y2(1+y2)2+x2\frac{\partial f}{\partial x} = \frac{1 + y^2}{(1 + y^2)^2 + x^2}
fy=2xy(1+y2)2+x2\frac{\partial f}{\partial y} = \frac{-2xy}{(1 + y^2)^2 + x^2}

Clear the compound fraction first

Write u=x1+y2u = \frac{x}{1 + y^2}. The outer derivative is 11+u2\frac{1}{1 + u^2}, and substituting uu leaves a fraction inside a fraction. Multiply top and bottom by (1+y2)2(1 + y^2)^2 once, at the start, and everything after it stays readable.

11+u2=11+x2(1+y2)2=(1+y2)2(1+y2)2+x2\frac{1}{1 + u^2} = \frac{1}{1 + \dfrac{x^2}{(1 + y^2)^2}} = \frac{(1 + y^2)^2}{(1 + y^2)^2 + x^2}

Now the xx partial. Holding yy fixed makes uu a constant multiple of xx, with constant 11+y2\frac{1}{1 + y^2}, so one factor of 1+y21 + y^2 cancels.

fx=(1+y2)2(1+y2)2+x211+y2=1+y2(1+y2)2+x2\frac{\partial f}{\partial x} = \frac{(1 + y^2)^2}{(1 + y^2)^2 + x^2}\cdot\frac{1}{1 + y^2} = \frac{1 + y^2}{(1 + y^2)^2 + x^2}

For yy the inner partial needs the power rule on x(1+y2)1x(1 + y^2)^{-1}, which gives 2xy(1+y2)2\frac{-2xy}{(1 + y^2)^2}. That denominator cancels the (1+y2)2(1 + y^2)^2 above it completely, which is why the final answer is so much simpler than the working.

fy=(1+y2)2(1+y2)2+x22xy(1+y2)2=2xy(1+y2)2+x2\frac{\partial f}{\partial y} = \frac{(1 + y^2)^2}{(1 + y^2)^2 + x^2}\cdot\frac{-2xy}{(1 + y^2)^2} = \frac{-2xy}{(1 + y^2)^2 + x^2}

The outer factor is not 1 over 1 plus x squared

The commonest wrong answer is 11+x2\frac{1}{1 + x^2}, which substitutes xx for uu instead of the actual inner function. Take (2,1)(2,1): there u=22=1u = \frac{2}{2} = 1, so f=arctan1=π4f = \arctan 1 = \frac{\pi}{4}, the denominator is (1+1)2+4=8(1+1)^2 + 4 = 8, and the true fx=28=0.25f_x = \frac{2}{8} = 0.25. The wrong version gives 15=0.2\frac{1}{5} = 0.2.

The second slip is stopping after the outer derivative and never multiplying by ux\frac{\partial u}{\partial x}. That leaves (1+y2)2(1+y2)2+x2\frac{(1+y^2)^2}{(1+y^2)^2 + x^2}, which at (2,1)(2,1) is 48=0.5\frac{4}{8} = 0.5, too big by the factor 1+y2=21 + y^2 = 2.

Both survive a test at y=0y = 0, where 1+y2=11 + y^2 = 1 and all three versions collapse to 11+x2\frac{1}{1 + x^2}. A test point with a zero in it proves nothing here, which is the general reason to check somewhere both variables are doing something.

A gradient that never vanishes

The xx partial has numerator 1+y211 + y^2 \ge 1 over a denominator that is always positive, so fx>0f_x > 0 at every point of the plane. This function has no critical points at all, and it strictly increases as you move right along any horizontal line.

The yy partial carries the sign of xy-xy, so the surface tilts downhill in yy in the first and third quadrants and uphill in the second and fourth. It is zero on both axes, and those are the only places where the gradient is purely horizontal.

Bounds finish the sanity check. The arctangent keeps ff strictly between π2-\frac{\pi}{2} and π2\frac{\pi}{2}, and both partials tend to zero far from the origin in any direction. A candidate partial that grows without limit as you move outward is wrong before you evaluate it anywhere.

Frequently asked questions

Can the denominator ever be zero?

No. (1+y2)2(1 + y^2)^2 is at least 11 and x2x^2 is never negative, so the common denominator (1+y2)2+x2(1+y^2)^2 + x^2 is at least 11 everywhere. The inner fraction never divides by zero either, so both partials are defined and continuous on the whole plane.

Would the quotient rule work on the inner function?

Yes, and it lands in the same place. With numerator xx and denominator 1+y21 + y^2, differentiating with respect to yy gives 0(1+y2)x2y(1+y2)2=2xy(1+y2)2\frac{0 \cdot (1+y^2) - x\cdot 2y}{(1+y^2)^2} = \frac{-2xy}{(1+y^2)^2}. The negative power form x(1+y2)1x(1+y^2)^{-1} is shorter, but nothing is lost by using the quotient rule if you prefer it.