TITLE: If $a+\sqrt{b}=c+\sqrt{d}$, is it true that $a=c$ and $b=d$?
QUESTION [7 upvotes]: Assume that $a,b,c,d$ are all positive integers. If $a+\sqrt{b}=c+\sqrt{d}$, is it true that $a=c$ and $b=d$?

I am grading some problems and I don't think this true, but all of a sudden I am doubting myself.

REPLY [8 votes]: If $a+\sqrt{b}=c+\sqrt{d}$, then $(a-c)+\sqrt{b}=\sqrt{d}$, so it clearly suffices to study when is it possible to have 
$$a+\sqrt{b}=\sqrt{d}.$$
If $b,d$ are arbitrary positive real numbers, then given any $a$ and $b$ such that $a+\sqrt{b}\geq 0$, then there is a $d\geq 0$, namely $d=(a+\sqrt{b})^2$, such that $\sqrt{d}=a+\sqrt{b}$. So I will assume from now on that the OP meant $a\in\mathbb{Q}$ and $b,d\in \mathbb{Q}^{\geq 0}$.
Suppose $a+\sqrt{b}=\sqrt{d}$ holds. Then, by squaring both sides we obtain
$$a^2+2a\sqrt{b} + b = d,$$
If $a=0$, then $b=d$. Otherwise, if $a\neq 0$, then
$$\sqrt{b}=\frac{d-a^2-b}{2a}\in \mathbb{Q}.$$
In particular, $b$ must be a perfect square, and $a+\sqrt{b}\geq 0$. 
Conversely, if $b$ is a perfect square, say $b=B^2$ for some $B\geq 0$, so that $B=\sqrt{b}\in \mathbb{Q}$, and $a+\sqrt{b}=a+B\geq 0$, then one can take $d=(a+B)^2$, so that 
$$a+\sqrt{b}=a+B=\sqrt{d}.$$
Hence, $a+\sqrt{b}=\sqrt{d}$ has a solution if and only if $b$ is a perfect square, $b=B^2$ for some $B\geq 0$, and $a+B\geq 0$, or $a=0$ and $b=d$.
Thus, $a+\sqrt{b}=c+\sqrt{d}$ has a solution if and only if $b$ is a perfect square, $b=B^2$ for some $B\geq 0$, and $(a-c)+B\geq 0$ (so that $d=((a-c)+B)^2$ is also a perfect square), or $a=c$ and $b=d$.
Example: In the example by David Mitra in the comments, 
$$1+\sqrt{4}=2+\sqrt{1}$$
we have $b=4=2^2$, so $B=2$, and $(1-2)+2=1\geq 0$.