Calculus – Intuitive Meaning of Differentiating with Respect to g(x)

calculusderivatives

I am very confused with questions such as:

\begin{equation*}
\text{Differentiate}~~f(x)=x, ~x\in\mathbb{R}~~\text{with respect to }x^2
\end{equation*}

I have seen solutions for many similar questions, but they always just apply the usual rules for differentiation such as the chain rule. I am still confused on the "actual meaning of this". I always thought of differentiating $f(x)$ with respect to $x$ as

\begin{equation*}
\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}
\end{equation*}

representing how $f$ changes when $x$ is changed, but how could we determine how $f(x)$ changes based on $x^2$ changing as $x^2$ is not injective? For instance, if we have $x^2 = 16$ initially and we "move it" to $x^2 = 25$, how could we find the corresponding change to $x$ and by extension the change to $f(x)$ if both $x=5$ and $x=-5$ satisfy $x^2=25$? I only understand what this would mean if we restrict the domain for instance to $x\geq 0$ so $x^2$ is injective, and this would clearly represent a change from $x=4$ to $x=5$, and therefore a change of $f(5)-f(4)$ but clearly, this isn't true as we can differentiate $f(x)=x$ with respect to $x^2$, and get that $\dfrac{df}{d(x^2)}=\dfrac{1}{2x}$

Best Answer

It's worth remembering that $$ f'(x) = \lim_{h \rightarrow 0} \frac{f(x+h) - f(x)}{h} $$ is obtained after simplifying from $$ f'(x) = \lim_{h \rightarrow 0} \frac{f(x+h) - f(x)}{(x+h) - x} \text{.} $$ This is the rate of change of $f(x)$ with respect to the function $x \mapsto x$.

The most straightforward thing to do for the given problem is \begin{align*} \frac{\mathrm{d}f(x)}{\mathrm{d}(x^2)} &= \lim_{h \rightarrow 0} \frac{f(x+h) - f(x)}{(x+h)^2 - (x^2)} \\ &= \lim_{h \rightarrow 0} \frac{(x+h) - (x)}{x^2+2xh+h^2 - x^2} \\ &= \lim_{h \rightarrow 0} \frac{h}{2xh+h^2} \\ &= \frac{1}{2x} \text{.} \end{align*}

If the resulting derivatives exist, one can manipulate as \begin{align*} \frac{\mathrm{d}f(x)}{\mathrm{d}g(x)} &= \lim_{h \rightarrow 0} \frac{\Delta f(x)}{\Delta g(x)} \\ &= \lim_{h \rightarrow 0} \frac{ \frac{\Delta f(x)}{\Delta x} }{ \frac{ \Delta g(x)}{ \Delta x} } \\ &= \frac{ \lim_{h \rightarrow 0}\frac{\Delta f(x)}{\Delta x} }{ \lim_{h \rightarrow 0}\frac{ \Delta g(x)}{ \Delta x} } \\ &= \frac{ f'(x) }{ g'(x) } \text{.} \end{align*}

Related Question