Consider a function of the following form $f=f(x,g(x))$. For the derivative of this function, we do the following. $$ \frac{df}{dx} = \frac{df}{dx} \bigg\rvert_{g}+\frac{df}{dg} \frac{dg}{dx} $$ I have the following question about the above equation.
- Since $g$ itself is a function of $x$, does it even make sense to say "$f$ is a function of $x$ and $g$"?
- Does the first term of the equation read "derivative of $f$ with respect to $x$ at a fixed $g$"? If so, how does this make sense since if $x$ is changed, $g$ also changes and the derivative is no longer calculated at a fixed $g$.
Please let me know if you need me to make myself more clearer. Thank you for answering.