$\sqrt{x} + \sqrt{y} = \sqrt{333}$ Better way to solve than trial and error

1.1k Views Asked by At

Question: $x$ and $y$ are positive integers and $\sqrt{x} + \sqrt{y} = \sqrt{333}$. Find the numerical value of $x + y$. I know the answer to the question is $185$ and $x$ and $y$ being $37$ and $148$ I got this through making a program that simply calculated it(trial and error) but I want to know is there a better way than this. I have looked around for similar problems like this and came across Diophantine equations on wikipedia but it wasn't particularly helpful.

2

There are 2 best solutions below

0
On BEST ANSWER

In general, square roots of integers are linearly independent over the rationals, e.g., for rationals $a,b,c$ the equation $a\sqrt 2+b\sqrt 3=c\sqrt 5$ holds only if $a=b=c=0$. Then again, we have rational dependencies between square roots such as $2\sqrt 2=\sqrt 8$, but such are true not by some magic diophantine coincidence, but rather "for trivial reasons" only.

Do we suspect or can we at least attempt something similar here? Indeed, check the prime factorization of $333$, which is $3\cdot 3\cdot 37$. So what we really want is some square roots to add up to $3\sqrt{37}$. And of course we do have $$\sqrt{37}+2\sqrt{37}=3\sqrt{37},$$ hence $$\sqrt{37}+\sqrt{148}=\sqrt{333}. $$

0
On

Square both sides: you get $$x+2\sqrt{xy}+y = 333$$ Since $x,y, 2$ and $333$ are all rational, it follows that $\sqrt{xy}$ is rational, so $xy$ is a square number. Writing $x=ab^{2}$ and $y=cd^{2}$ where $a,c$ are square-free (this can always be done), we can see (by contradiction) that $a=c$. Then there is a common factor of $a$ throughout the LHS - indeed, it can be written as $a(b+d)^{2}$. Therefore if we decompose $333$ as we decomposed $x$ and $y$, we will recover $a$ as the square-free factor. By factorisation, $$333 = 3 \cdot 111 = 3^{2} \cdot 37$$ and $37$ is square-free (it's prime), so $a=37$ and $b+d=3$, so $(b,d) = (1,2)$ or $(2,1)$.Then $x+y = a(b^{2}+d^{2}) = 37\cdot 5 = 185$.