# Example of injective function with $f'(x) = 0$ for some $x \in \mathbb{R}$

So in my set theory class today my professor was discussing injectivity and we had an in-class exercise to show that any function, given that $f'(x) \neq 0$, is injective. This was easy enough as one can imagine such a function never switches from increasing to decreasing or decreasing to increasing, i.e., it's slope never switches sign and thus it's always increasing or decreasing and thus is quite easy to show satisfies the definition of an injective function.

He then asked us to think about a function that is injective but also has $f'(x) = 0$ for some $x \in \Bbb{R}$. I was originally thinking constant function (due to the $f'(x) = 0$) but that's obviously not going to work (as it's like the opposite of injectivity -- every element of the domain maps to one element of the codomain). I can't quite think of a function which would satisfy injectivity but also have a point, $x$, where it's slope is zero.

I'm interested to see what people can come up with!

• I see I edited your question while you did. Hope I didn't interrupt too much. – mathreadler Apr 27 '17 at 1:57
• There do exist functions which have derivative equal to zero "almost everywhere" but are monotonic increasing. The example I'm thinking of though won't be injective on the reals though: see the cantor function on wiki. See also singular functions. – JMoravitz Apr 27 '17 at 2:17

$x^3$ is injective and has derivative $3x^2$ which is zero for $x = 0$.
• Oh of course! I think I was getting caught up (for some reason) thinking it needed to be 0 everywhere (hence the constant functions) jeez I feel dumb. This would not be the case for $x^2$ however, as that function sends one number and it's negation to the same image, correct? – Kyle O'Connell Apr 27 '17 at 2:06
• Correct. Any odd power satisfies what you are looking for, Any even power fails for the same reason as $x^2$ – Mortified Through Math Apr 27 '17 at 3:57