Continuity or not for being invertible [duplicate]
The question is simple : consider the family of monotonic functions ; $m(x) : \mathbb{R} \rightarrow \mathbb{R}$, and the familly of bijective functions ; $b(x) : \mathbb{R} \rightarrow \mathbb{R}$. Are they actually the same? If not, I would like to see some simple counter-examples.
Short answer:
$f(x)=1$
is monotonic, but clearly not bijective.
Longer answer:
You are probably asking about strictly monotonic functions (that way you can get injectivity), but the answer is still no.
$f(x)=e^x$ is monotonic, but not bijective.
$$f(x)=\begin{cases}x & x>0\lor x<-1\\ -x-1 & -1\leq x\leq 0\end{cases}$$
is bijective, but not monotonic.
Even longer answer:
You might mean strictly monotonic continuous functions, in which case the answer is still no ($f(x)=e^x$ is strictly monotonic and continuous, but not bijective), however, it is true that the other type of counterexample cannot be found, i.e.
Every continuous bijective function from $\mathbb R$ to $\mathbb R$ is strictly monotonic.
Edit for the question posed in comments:
You are making a mistake a lot of math students make, and it's usually the fault of the teachers not emphasizing it enough. The thing is:
A FUNCTION IS DEFINED BY THREE THINGS:
- The domain.
- The codomain.
- The "action".
So, if I want to truly mathematically correctly define some function, I can say:
$f$ is the function from $A$ to $B$ defined by $f(x)=...$
Note, it is important to note both from where the function is mapping, to where it is mapping, and how it is mapping.
Example:
- The function $f:\mathbb R\to\mathbb R$ defined by $f(x)=e^x$ is a function.
- The function $g:\mathbb R\to(0,\infty)$ defined by $g(x)=e^x$ is a function.
IMPORTANT:
$f$ and $g$ are not the same function. I cannot stress this enough. $f$ and $g$ map all numbers to the exact same number, but because their codomains are different, they are, by definition, different functions. It is true that if we restrict the codomain of $f$ to $(0,\infty)$, we get $g$, but it is not true that $f$ is the same function as $g$.
Why?
You may think this is unnecessary, but it is very necessary if you want any meaningful definition of the word surjective. Why? Well, remember:
A function $f:A\to B$ is surjective if, for every $b\in B$, there exists some $a\in A$ such that $f(a)=b$.
Now, take any function $h:A\to B$. And define $B'=f(A)=\{f(a)|a\in A\}$. Then, this statement is true:
- For every $b\in B'$, there exists some $a\in A$ such that $h(a)=b$.
So, is $h$ all of a sudden surjective? Just because we restricted its codomain? NO. If we restrict $h$ to $B'$, we get a different function, and the restricted function is surjective, but $h$ may not be.
Similarly, our function $g$ mapping from $\mathbb R$ to $(0,\infty)$ is surjective, but the function $f$ is not.
Let $f: \mathbb{R} \to \mathbb{R}$ be the zero function. It is monotonous yet not injective, since if $x_1 \neq x_2$ does not imply that $f(x_1) \neq f(x_2)$.
I guess you really mean strictly monotone functions, since constant functions are monotone and obviously not bijective. But even so, it is not enough. (Recall: a function $f:X\to Y$ between topological spaces is said to be monotone if $f^{-1}(y)$ is connnected for each $y\in Y$. Monotone functions can have "flat" spots where they are locally constant.)
It's a simple matter to construct a large number of nonbijective monotone functions. If $f:\mathbb R\to\mathbb R$ is monotone, then $E_f:\mathbb R\to\mathbb R$, where $E_f(x)\equiv e^{f(x)}$, is a monotone function which is not surjective (so not bijective).