# there are some integer pairs $(m,n)$ that satisfy $\frac{m^2+mn+n^2}{m+2n}=\frac{13}{3}$ Find the value of $m + 2n$

there are some integer pairs $$(m,n)$$ that satisfy $$\frac{m^2+mn+n^2}{m+2n}=\frac{13}{3}.$$ Find the value of $$m + 2n.$$

I tried expressing the numerator in terms of $$m+2n$$ but it resulted in nothing remotely useful

hints or suggestions would be appreciated aswell as solutions.

• Well, trial and error yields a pair $(m,n)$ that works pretty quickly...but of course there could be others.
– lulu
Aug 14 '19 at 19:29

We have $$3m^2+(3n-13)m+3n^2-26n=0,$$ which gives $$(3n-13)^2-12(3n^2-26n)\geq0$$ or $$27n^2-234n-169\leq0,$$ which gives not so many cases: $$n\in\{0,1,2,3,4,5,6,7,8,9\}.$$ Can you end it now?

I got only $$n=2$$ gives $$m=5$$ and $$n=7$$ gives $$m=-5.$$

I can rewrite the equation $$\frac{m^2+mn+n^2}{m+2n}=\frac{13}{3}$$ in the form: $$3m^2+3mn+3n^2=13(m+2n)$$ and so $$3m^2+m(3n-13)-26n+3n^2=0$$. Using the quadratic formula: $$m=\frac{-(3n-13)\pm\sqrt{(3n-13)^2-4\cdot3\cdot(3n^2-26n)}}{6}$$

The polynomial $$(3n-13)^2-4\cdot3\cdot(3n^2-26n)$$ is positive only if $$\frac{13}{3}-\frac{\sqrt{26}}{3\sqrt3}\leq x \leq \frac{13}{3}+\frac{\sqrt{26}}{3\sqrt3}$$. The only cases when the polynomial is a square are $$n=2$$ $$\land$$ $$m=5$$ or $$n=7$$ $$\land$$ $$m=-5$$.

Let $$A_1=m_1+2n_1=5+2\cdot 2=9$$ and $$A_2=m_2+2n_2=-3$$.

• $m+2n$ has to be divisible by $3$. Aug 14 '19 at 20:18
• Sorry, my mistake. Corrected. Aug 14 '19 at 20:19
• can you please explain what you did with the $\frac{13}{3}-\frac{\sqrt{26}}{3\sqrt3}\le x \le \frac{13}{3}+\frac{\sqrt{26}}{3\sqrt3}$ I don't understand the reasoning behind it Aug 15 '19 at 14:33
• @Tyrone: simply put: $(3n-13)^2-4\cdot3\cdot(3n^2-26n)\geq0$. Aug 15 '19 at 15:04