1

Let $f : S \subseteq \mathbb{R} \to \mathbb{R}$ be nondifferentiable on $S$, and let $x \in S$. Suppose I want to show that $$ \frac{d}{dy}\bigg|_{y = x}\big[[f(y) - f(x)]^2\big] = 0. $$ The straightforward argument is $$ \frac{d}{dy}\bigg|_{y = x}\big[[f(y) - f(x)]^2\big] = 2[f(y) - f(x)]\,f'(y)\bigg|_{y = x} = 2[f(x) - f(x)]\,f'(x) = 2(0)\,f'(x) = 0, $$ but as far as I can tell, this rests on the false assumption that $f$ is differentiable at $x$. Is this type of reasoning, which symbolically carries the derivative of the function through the calculation to show that it cancels at the end, valid when the function is not differentiable? This would be useful, because then one could simply enter

D[(f[x] - f[y])^2, y] /. y -> x

into Mathematica to verify the identity. Or do I need to use a different line of reasoning to prove this?

Sam Estep
  • 113

1 Answers1

1

You cannot show what you want because, in general, it is not true.

You may compute a derivative only if the function is differentiable. Since $f$ is not so on $S$, neither will be $f - f(x)$ for any $x$, and in principle you cannot deduce anything about $(f - f(x))^2$.

Consider this concrete example: $f : S = (-1, 1) \to \Bbb R$ with $f(y) = \begin{cases} 0, & y \le 0 \\ 1, & y > 0 \end{cases}$ - not differentiable on $S$. Take $x = 0$. Then $(f - f(x))^2 = (f - f(0))^2 = f^2 = f$, which is not differentiable on $S$, therefore you may not talk about $\frac {\Bbb d} {\Bbb d y} [f(y) - f(x)]^2$, and in particular about its value at $y = x$.

Alex M.
  • 35,207
  • Ah, thank you! So the answer is, if I had a different composite function for which the derivative was defined at the point, then I wouldn't be able to use the argument I used in my question above to prove that? I will see if I can come up with a better example that illustrates what I mean. – Sam Estep May 05 '17 at 13:34
  • @SamEstep: If $f$ is not differentiable at $a$, then even if $g$ is differentiable at $f(a)$ you still cannot say anything about the differentiability of $g \circ f$ at $a$. – Alex M. May 05 '17 at 13:54
  • Right, I understand that. What I meant was, if $f$ is not differentiable at $a$ but $g \circ f$ is differentiable at $a$, then I can't use the argument from the question to prove the differentiability of $g \circ f$, correct? – Sam Estep May 05 '17 at 17:24
  • @SamEstep: Indeed, that argument can't be used in such a situation. – Alex M. May 05 '17 at 17:58