Show that the function $f(x)=x+\sqrt{x}$ is one-to-one Show that the function $f(x)=x+\sqrt{x}$ is one-to-one.
I know that for showing that a function is one-to-one I have to prove that if $f(a)=f(b)$ then $a=b$.
Then I'm trying that in here but I get stuck.
$$f(a)=f(b)$$
$$a+\sqrt{a}=b+\sqrt{b}$$
$$a-b=\sqrt{b}-\sqrt{a}$$
How to do I show from here that $a=b$?
I've tried square both sides, completing the square and haven't worked. :(
I will appreciate a detail to understand, thanks in advance.
 A: You should always state the domain when asking any question about a function.  In this case, however, I think we can assume the domain is non-negative reals.
One easy way to prove $f$ is one-to-one is to note that both $g(x)=x$ and $h(x)=\sqrt x$ are increasing functions (on the non-negative reals) - just think of their graphs - and hence so is their sum $f$.  Therefore $f$ is one-to-one.

If you need more detail: suppose $a\ne b$.  By symmetry we may assume $a<b$.  Therefore $\sqrt a<\sqrt b$, so $a+\sqrt a<b+\sqrt b$.  That is, $f(a)<f(b)$; and hence $f(a)\ne f(b)$.
We have shown: if $a\ne b$, then $f(a)\ne f(b)$.  Equivalently, if $f(a)=f(b)$ then $a=b$.  So $f$ is one-to-one.
IMHO this is better than doing the algebra (at least in this case).  Thinking it through this way should be much faster than writing out all the equations.
A: Picking up from your last step, assuming $ a, b \neq 0$, we have
\begin{align*}
a - b = \sqrt{b} - \sqrt{a} & \iff (a - b)(\sqrt{b} + \sqrt{a}) = b - a \\
& \iff (a - b)(\sqrt{a} + \sqrt{b} + 1) = 0 \\
& \iff a - b = 0 \quad \text{or} \quad \sqrt{a} + \sqrt{b} + 1 = 0 \\
& \iff a = b \quad \text{(Since $ \sqrt{a} + \sqrt{b} + 1 \neq 0 $ for any $ a $ or $ b $)}
\end{align*}
So all in all we have $ f(a) = f(b) $ if and only if $a = b $ or $ a = b = 0$, or we can absorb the latter condition into the former one and says $ f(a) = f(b) $ if and only if $ a = b$.
A: $f(x) = x + \sqrt x$
We have to show that the function $f$ is injective.
let $f(a) = f(b)$
$a + \sqrt a = b + \sqrt b$
$a - b = \sqrt b - \sqrt a $
Think of $a$ as $(\sqrt a)^2$ and same for $b$.
$(\sqrt a)^2 - (\sqrt b)^2 = \sqrt b - \sqrt a$
Use the difference of squares identity.
$(\sqrt a - \sqrt b)(\sqrt a + \sqrt b) = \sqrt b - \sqrt a$
From here, we can split this into $2$ cases.
Case 1 : $(\sqrt a - \sqrt b) \not = 0$
Then we can divide by it on both sides to get
$\sqrt a + \sqrt b = -1$.
But we know that this is not possible.
Hence, we get no solutions from this case.
Case 2 : $(\sqrt a - \sqrt b) = 0$
$\implies \sqrt a = \sqrt b$
$\implies a = b $
So the only solution we get for $f(a) = f(b)$ is $a =b$.
Hence we can say that $f$ is injective.
A: $$a,b >0 \implies \sqrt{a},\sqrt{b}>0$$
Next $$a-b =\sqrt{b}-\sqrt{a} \implies (\sqrt{a}+\sqrt{b})(\sqrt{a}-\sqrt{b})=\sqrt{b}-\sqrt{a}$$
$$\implies (\sqrt{a}-\sqrt{b})(\sqrt{a}+\sqrt{b}+1)=0 \implies (\sqrt{a}-\sqrt{b})=0\implies a=b.$$ As sum of $\sqrt{a}$, $\sqrt{b}$ and 1 cannot be zero.
A: I would approach this by showing the function is increasing. Once you know $f$ is increasing, then suppose $f(a)=f(b)$ and $a\lt b$. But then because $f$ is increasing, $f(a)\lt f(b)$, a contradiction.
And there is a similar contradiction when $f(a)=f(b)$ and $a\gt b$.
So the only conclusion is that when $f(a)=f(b)$, $a$ must equal $b$.

Now how do we know $f$ is increasing? If $a\lt b$, then $a+\sqrt{a}\lt b+\sqrt{a}$. And then as long as we know $x\mapsto \sqrt{x}$ is increasing, we can move on to write $a+\sqrt{a}\lt b+\sqrt{b}$. This is the defintion for $f$ to be increasing.

Now how do we know $x\mapsto\sqrt{x}$ is increasing? I'm not sure how deep down into fundamentals you need to reach. But there are several ways to establish that. I'll leave this answer at this much.
