I want to find all integer solutions of the equation $9x+5y=77$. This equation obviously has a whole family of solutions which I was also able to see on Wolfram Alpha but I dont know to get to that solution. Can anyone explain how to get there? Thanks a lot!
Asked
Active
Viewed 53 times
-6
-
1Do you know modular arithmetic? – Robert Israel Oct 31 '21 at 14:28
-
yes im familiar with it, that's also something I played around with a little to find a way to solve it but it didn't quite work – Mathman Oct 31 '21 at 14:29
-
Try it mod $5$ or mod $9$. What do you get? – Robert Israel Oct 31 '21 at 14:33
-
then we have $(77-9x)mod5=0$, I dont know where to go from this point – Mathman Oct 31 '21 at 14:35
-
1Can you spot a particular solution $x_0, y_0$? Then $9(x-x_0)+5(y-y_0)=0$. Since 9 and 5 have no factor in common what can you now say about $x-x_0$ and $y-y_0$? – Paul Oct 31 '21 at 14:46
-
It is a linear Diophantine equation. Diophantine equation has a section on its solutions. – Shambhala Oct 31 '21 at 17:01
-
$\bmod 5,$ it reduces to $, -x \equiv 2 \iff x\equiv -2 \equiv 3\iff \color{#c00}{x = 3!+!5n},$ therefore $,y = (77-9\color{#c00}x)/5 = (77-9(\color{#c00}{3!+!5n}))/5 = 10-9n.,$ See the linked dupes for these standard methods. – Bill Dubuque Oct 31 '21 at 19:56
1 Answers
0
Taking the equation mod $5$, you get $$ 4 x \equiv 2 \mod 5$$ so $$ x \equiv 2 \cdot 4^{-1} \equiv 3 \mod 5 $$ Similarly, taking the equation mod $9$, you get $$ y \equiv 5 \cdot 5^{-1} \equiv 1 \mod 9 $$ Now with $x = 3 + 5 s$ and $y = 1 + 9 t$ your equation becomes $$ 32 + 45s + 45t = 77$$ or $$ 45 s + 45 t = 45 $$ Thus $s+t = 1$: the solution can be written as $$ x = 3 + 5 s,\ y = 1 + 9 (1-s) = 10 - 9 s$$ where $s$ is an integer.

Robert Israel
- 448,999
-
-
Please strive not to add more (dupe) answers to dupes of FAQs, cf. recent site policy announcement here. – Bill Dubuque Oct 31 '21 at 19:58