# Pre-calculus $\frac 27 = \frac 1a + \frac 1b$

I had this questions from a previous exam that I couldn't answer, I am apologizing for any English mistakes or for any stupid questions, I tried to solve them and I searched the internet and I couldn't find answers.

4-if $\frac 27$ could be written in a unique way in the form of $$\frac 1a +\frac 1b$$ $$a,b \in \mathbb Z^+$$ $$a\neq b$$What is a+b ?
*It seemed so easy maybe I am missing something isn't there infinite values that satisfy this equation?
$7(a+b) = 2ab$

Thanks for taking the time to read the question !

• Hint:$$\frac27=\frac{1+1}7=\dots$$ – Simply Beautiful Art Jul 18 '17 at 0:29
• Hint: the greedy algorithm is always a good place to start. Try taking the largest fraction of the form $\frac 1n$ out of $\frac 27$. – lulu Jul 18 '17 at 0:42
• This is not essential, but if $(a,b)$ is a solution, then so is $(b,a)$. A unique way is impossible ! – Yves Daoust Jul 18 '17 at 0:47
• @YvesDaoust You are assuming $(a,b)\ne(b,a)$? – Simply Beautiful Art Jul 18 '17 at 0:52
• @SimplyBeautifulArt: obviously. – Yves Daoust Jul 18 '17 at 0:56

## 5 Answers

We have to solve $$2ab=7a+7b$$ in the positive integers.

We have $$(2a-7)(2b-7)=4ab-14a-14b+49=2(2ab-7a-7b)+49$$

Because of $2ab=7a+7b$ we get $$(2a-7)(2b-7)=49$$

If $a\ne b$, we can assume $a<b$ WLOG

We have $2a-7=1$ and $2b-7=49$ giving $a=4$ and $b=28$

So, we have $$\frac{2}{7}=\frac{1}{4}+\frac{1}{28}$$ giving $a+b=4+28=32$

• Where did you get (2a -7)(2b-7) ? – user3289743 Jul 18 '17 at 0:57
• Well, this is the standard-trick to solve equations of the form $kab+la+mb=n$, but easier is to subtract $1$,$\frac{1}{2}$ until $\frac{1}{6}$ from $\frac{2}{7}$ and look which differences can be simplified to a positive fraction with numerator $1$ – Peter Jul 18 '17 at 1:05

The given problem boils down to finding lattice points on a hyperbola. The equation $$2ab=7(a+b) \tag{1}$$ is equivalent to $$(2a-7)(2b-7) = 49\tag{2}$$ and $49=7^2$ cannot be written as a product of integers in too many ways. From the assumption $(2a-7)=1$ and $(2b-7)=49$ we get the non-trivial solution $\color{red}{(a,b)=(4,28)}.$

• I do not understand the downvote. Care to explain? – Jack D'Aurizio Jul 18 '17 at 1:08
• It was not me, but if I had to guess, it might be to do with your answer being very similar to Peter's answer (who snuck in a minute before you), but with less detail. Or it might be the fact that you didn't explicitly show your assumption that $a < b$ and call attention that such things could be assumed without loss of generality. – Theo Bendit Jul 18 '17 at 1:25
• @TheoBendit: actually I believe my answer came before Peter's one. – Jack D'Aurizio Jul 18 '17 at 2:06
• I was going by the "answered ___ minutes ago". Yours was 1-2 minutes behind. – Theo Bendit Jul 18 '17 at 2:39

To write ${2\over7}={1\over a}+{1\over b}$ with, say $a\lt b$, it's clear that $1\le a\le6$, since otherwise we would have ${1\over a}+{1\over b}\le{1\over7}+{1\over8}\lt{2\over7}$. It's also easy to see that we must have $a\ge4$, since ${1\over3}\gt{2\over7}$. So this leaves just three possibilities to check: $a=4$, $5$, and $6$. It's easy to see that only $a=4$ works: ${2\over7}-{1\over4}={1\over28}$, so $a+b=4+28=32$.

Express the equation in terms of the desired unknown, $s:=a+b$.

$$\frac1a+\frac1{s-a}=\frac27$$ yields the quadratic equation

$$2a^2-2sa+7s=0$$ with solutions

$$a=\frac{s\pm\sqrt{s^2-14s}}2=\frac{s\pm\sqrt{(s-7)^2-49}}2.$$

Now $s-7$ and $7$ are members of a Pythagorean triple. The only factorization of $7$ is $7\cdot1$, so that the triple must be $7=(4+3)(4-3),24=2\cdot3\cdot4,25=4^2+3^2$.

From this, $s=25+7=\color{green}{32}$ is the only admissible solution (and $a=4$ or $a=28$).

Note that the degenerate Pythagorean triple $49=(7+0)(7-0),0=2\cdot7\cdot0,49=7^2+0^2$ is also possible, giving $s=14$, and $a=b=7$.

If $a=b$ we have $a=b=7$.

Let $a>b$.

Thus, $\frac{2}{7}=\frac{1}{a}+\frac{1}{b}<\frac{2}{b}$, which gives $b<7$.

In another hand, since $\frac{1}{b}<\frac{2}{7}$ we get $b>3.5$.

Id est, $4\leq b\leq6$.

Now, for $b=4$ we get $a=28$ and $b=5$ and $b=6$ they impossible.

Thus, we have three solutions $(7,7)$, $(4,28)$ and $(28,4)$, which gives the answer: $\{14,32\}$.