I am new to calculus and cannot see the logic of the following question… Any feedback will be really appreciated!

The function $f(x,y,z)$ is differentiable at all points, and satisfies $f(x,y,2x^2+y^2)=4x+5y$.

Point P is defined as (1,2,6).

Unit vector $\mathbf{u}=(\frac{2}{3},\frac{1}{3},\frac{2}{3})$.


Find the gradient for f(x,y,z) at the given point. Give the sum of elements of the gradient you found.


  1. 4
  2. 4.5
  3. 5
  4. 5.5

I am lost at the very beginning: I understand that I need to calculate $f_x,f_y,f_z$ in order to calculate the gradient. $f_x=4$,$f_y=5$, but I am stuck at $f_z$. I have understood that z depends on x and y (but then I don't quite understand why it is included in the definition of the function $f(x,y,z)$, as $z$ is not independent of $x$ and $y$). It does not appear on the right side of $f(x,y,2x^2+y^2)=4x+5y$, so I cannot seem to find a way to find its derivative either.

Can anybody please help out?

  • $\begingroup$ I don't think you can say $f_x = 4$ and $f_y = 5$. It says $f$ is equal to $4x+5y$ only when $z = 2x^2+y^2$. $\endgroup$ – Nick Apr 21 at 16:18
  • $\begingroup$ Also, are you sure the problem says $D_uf(P) = 8$? Is it possible this is a typo, and it should be $\frac{8}{3}$? If it is indeed 8/3, I get the answer 5.5. If it is 8, I get the answer is not one of the 4 choices. $\endgroup$ – Nick Apr 21 at 16:30
  • $\begingroup$ It definitely says 8, but I will check if it's a typo…! $\endgroup$ – dalta Apr 21 at 17:12
  • $\begingroup$ @nick But in the meanwhile, could you tell me how you computed the gradient? $\endgroup$ – dalta Apr 21 at 17:13

Let's say $g(x,y) = 2x^2+y^2$. Then the problem says $f(x,y,g(x,y)) = 4x+5y$. Use the chain rule to differentiate both sides with respect to both $x$ and $y$ to get

$$ f_x + f_z g_x = f_x + 4xf_z = 4 $$

$$ f_y + f_z g_y = f_y + 2yf_z = 5 $$

Plugging in the point $P = (1,2,6)$, you get

$$ f_x + 4f_z = 4 $$

$$ f_y + 4f_z = 5 $$

The fact that $D_uf(P) = 8$ means that $\frac{1}{3} \left( 2f_x + f_y + 2f_z \right) = 8$. Or, multiplying by $3$, you get $2f_x + f_y + 2f_z = 24$. Now you have three equations in three unknowns. You can solve the linear system to get

$$f_x = 8.9 $$ $$f_y = 9.4 $$ $$f_z = -1.1 $$

The reason I think there may be a typo, and it might be $D_uf(P) = \frac{8}{3}$ is that in that case, you instead get $f_x = 2$, $f_y = 3$, $f_z = 0.5$.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.