Multivariable calculus

Partial Derivatives of x arctan(xy)

For f(x,y) = x arctan(xy), the partial with respect to x is arctan(xy) + xy/(1 + x^2 y^2), and the partial with respect to y is x^2/(1 + x^2 y^2). The x-partial needs the product rule; the y-partial needs only the chain rule on the arctangent.

f(x,y)=xarctan(xy)f(x,y) = x\arctan(xy)
fx=arctan(xy)+xy1+x2y2\frac{\partial f}{\partial x} = \arctan(xy) + \frac{xy}{1 + x^{2}y^{2}}
fy=x21+x2y2\frac{\partial f}{\partial y} = \frac{x^{2}}{1 + x^{2}y^{2}}

Product rule outside, arctangent derivative inside

The rule you need is dduarctanu=11+u2\frac{d}{du}\arctan u = \frac{1}{1+u^{2}}, with u=xyu = xy here so u2=x2y2u^{2} = x^{2}y^{2}. In xx, the function is a product of xx and arctan(xy)\arctan(xy), and both factors depend on xx.

fx=arctan(xy)+xy1+x2y2\frac{\partial f}{\partial x} = \arctan(xy) + x \cdot \frac{y}{1 + x^{2}y^{2}}
fx=arctan(xy)+xy1+x2y2\frac{\partial f}{\partial x} = \arctan(xy) + \frac{xy}{1 + x^{2}y^{2}}

In yy the leading xx is a constant multiplier, so only the arctangent is differentiated. The inner derivative is xx, and multiplying by the outer constant xx produces the square.

fy=xx1+x2y2=x21+x2y2\frac{\partial f}{\partial y} = x \cdot \frac{x}{1 + x^{2}y^{2}} = \frac{x^{2}}{1 + x^{2}y^{2}}

Both partials are defined for every xx and yy, since 1+x2y21 + x^{2}y^{2} is at least 1 and the arctangent accepts every real input. That is what makes arctangent a friendlier inverse trig function than arcsine for problems like this.

The mistake: squaring only one variable in the denominator

The single most common wrong denominator here is 1+xy1 + xy or 1+x2y1 + x^{2}y. The arctangent rule squares its entire argument, and the argument is the product xyxy, so the denominator is 1+(xy)2=1+x2y21 + (xy)^{2} = 1 + x^{2}y^{2}.

  • Square the whole inside, not part of it: (xy)2=x2y2(xy)^{2} = x^{2}y^{2}.
  • The chain rule factor is the derivative of the inside: yy for the xx-partial and xx for the yy-partial.
  • The xx-partial keeps a bare arctan(xy)\arctan(xy) term from the product rule. Losing it is the other frequent error.

Note that fy\frac{\partial f}{\partial y} is never negative, since both x2x^{2} and the denominator are non-negative. So the surface never falls as yy grows, whatever the sign of xx. When xx is negative that takes two sign flips: the inside xyxy decreases, so arctan(xy)\arctan(xy) decreases, and multiplying by the negative outer xx turns the fall back into a rise.

Evaluating where the arctangent is nice

At (1,1)(1,1) the argument is 1, so arctan(1)=π4\arctan(1) = \frac{\pi}{4} and 1+x2y2=21 + x^{2}y^{2} = 2.

fx(1,1)=π4+12,fy(1,1)=12\frac{\partial f}{\partial x}(1,1) = \frac{\pi}{4} + \frac{1}{2}, \qquad \frac{\partial f}{\partial y}(1,1) = \frac{1}{2}

Numerically the xx-partial is about 1.2851.285 and the yy-partial is exactly 0.50.5. The gradient leans strongly toward xx, which is what you expect when xx appears both outside and inside the arctangent.

Frequently asked questions

Why is the y-partial x squared rather than just x?

Two factors of xx appear. One is the constant multiplier out front, which passes through untouched. The other comes from the chain rule, because the inside xyxy has yy-derivative xx. Multiplying them gives x2x^{2}.

What happens to the partials for large xy?

The fraction xy1+x2y2\frac{xy}{1+x^{2}y^{2}} tends to zero as the product xyxy grows, while arctan(xy)\arctan(xy) approaches π2\frac{\pi}{2}. So far out in the first quadrant, fx\frac{\partial f}{\partial x} settles near π2\frac{\pi}{2}, meaning the surface behaves roughly like the plane fπ2xf \approx \frac{\pi}{2}x.