# Partial derivative of tan(x + y)

1. Apr 12, 2009

1. The problem statement, all variables and given/known data

$$f(x, y) = \tan(x + y) \\ f_x = ?$$

2. Relevant equations

$$\frac{dy}{dx}\tan(x)= \sec^2 x$$

3. The attempt at a solution

I set y as constant, so I said derivative of y = 0 then took derivative of tan as above. However the answer should be
$$f_x = \sec^2(x + y)$$

Why is y included?

2. Apr 12, 2009

### tiny-tim

Because it's in g(x,y) in the chain rule … ∂f(g(x,y))/∂x = ∂f(g(x,y))/∂g ∂g(x,y))/∂x

3. Apr 12, 2009

### HallsofIvy

The fact that the derivative of y is 0 does not mean that y itself is 0 and replacing tan(x+y) with tan(x) is saying y= 0.

What is the derivative of tan(x+ a) for constant a?

4. Apr 12, 2009

Well, what if you asked, what is derivative of $$tan(2x + a)$$... I would say $$2 \sec^2(2x + a)$$. So if that is correct then the derivative of $$\tan(x + a)$$ would be $$\sec^2(x + a)$$. Is this correct?
Now considering the partial derivative with respect to x, we want y as a constant so replace a with y and we get $$f_x = \sec^2(x + y)$$