derivative of multivariable recursive function

201 Views Asked by At

Given a recursive function $$ f(x,y,z) = f(h(x),g(y,z),z) $$ I want to get the derivative of the function to $z$ $$ {d\over dz } f(x,y,z) = ? $$ My guess is $$ {d \over dz}f(x,y,z) = f'(h(x),g(y,z),z) g'(y,z) {dy \over dz} $$

But I'm not sure if I'm right, especially the last part $dy \over dz$ because the $y$ for the next call of $f$ is $g(y,z)$ and it is affected by $z$.

Am I wrong?

1

There are 1 best solutions below

6
On BEST ANSWER

You need to use the chain rule properly:

if $\phi(x, y, z) = f(h(x), g(y, z))$, we have:

$\frac{d \phi}{dz}(x, y, z) = \frac{\partial f}{\partial g}(h(x), g(y, z)) \frac{\partial g}{\partial z}(y, z)$.