What I'm trying to solve is the following:

Given that $(a:b) = 2$, prove that $(a^2 + 2b^2+10:20) = 2$.

So, basically, I think that what I need to do is to show that if $d = a^2 + 2b^2 + 10$, then $2\mid d$ and $d \nmid 4, d \nmid 5, d \nmid 10$ and $d \nmid 20$.

So, starting with 2 and 4 is very straightforward: knowing that $(a:b) = 2$, then we can write $a = 2 \cdot k$ and $b = 2 \cdot q$. Following this:

$2 \mid a^2, 2 \mid 2b^2, 2 \mid 10 \Rightarrow 2 \mid d$.

In the other hand, I want to prove that $4 \nmid d$. As we know:

$2 \mid a \Rightarrow 2^2 \mid a^2$, $2 \mid b \Rightarrow 2^2 \mid b^2 \Rightarrow 4 \mid 2b^2$, but $4 \nmid 10$, so it's clear that $4 \nmid d$.

Then, the following steps are proving that $5 \nmid d$ and $10 \nmid d$. But, I'm not quite sure if my statements are correct. I've say the following:

If $a^2 \equiv 0 \pmod{4} \Rightarrow a^2 \equiv 1 \pmod{5}$. And the same with $b^2$, so that it follows that $2b^2 \equiv 2 \pmod{5}$.

But.. are those statements necessarily correct? Or how should I attack this problem?

  • $\begingroup$ You have $4\mid 8^2$ but $5\nmid 8^2-1$. $\endgroup$
    – Arash
    Oct 12, 2013 at 1:19
  • $\begingroup$ @Arash So obvioulsy my statements weren't correct.. any idea from where should I follow then? Thanks! $\endgroup$ Oct 12, 2013 at 1:22
  • $\begingroup$ What does $(a:b)$ mean? $\endgroup$
    – bof
    Oct 12, 2013 at 1:41
  • $\begingroup$ @bof sorry, I think you note it like $(a,b) = d$. It's the greatest common divisor.. $\endgroup$ Oct 12, 2013 at 1:44
  • $\begingroup$ Are you sure its "$d\nmid4,d\nmid5,d\nmid10$ and $d\nmid20$" that you want to show? That $4,5,10$ and $20$ are not divisible by $d$? Not the other way around? $\endgroup$
    – bof
    Oct 12, 2013 at 1:48

2 Answers 2


As you said, from $(a,b)=1$, we may write $a=2a',b=2b'$ with $(a',b')=1$. Thus we get by substitution that $$(4a'^2+8b'^2+10,20)=2(2a'^2+4b'^2+5,10)$$

Whence $d$ has a factor of $2$. It remains to show that neither $2$ nor $5$ are a factor of $2a'^2+4b'^2+5$. The first claim should be clear, for this number is odd, since it is the sum of an even number with an odd number. Thus it remains to show $5$ is not a factor. Working modulo $5$, we would need $$2a'^2+4b'^2\equiv 0\mod 5\\2a'^2\equiv b'^2\mod 5$$

But the squares modulo $5$ are $1,-1$, and in no case (that is, substituting $a',b'$ for possible values $1,-1$) the above equation would hold. Thus $5$ cannot divide $2a'^2+4b'^2+5$.


Your argument is fine for $4\nmid a^2+2b^2+10$. It is enough to prove that $5\nmid a^2+2b^2+10$. Suppose that $5\mid a^2+2b^2+10$. First observe that $5\nmid a$. Because if $5\mid a$ then $5\mid 2b^2+10$ and necessarily $5\mid b$ and hence $5\mid (a,b)=2$ which is not true.

For $a$ such that $5\nmid a$, we can see the following: $$ a^2\equiv -1\quad or\quad 1 \mod 5 $$ The same is true for $b^2$ and hence we have: $$ a^2+2b^2\equiv 3\quad or \quad -1\quad or\quad 1 \quad -3 \mod 5\implies 5\nmid a^2+2b^2. $$ Therefore $ 5\nmid a^2+2b^2+10$ which proves your result.

  • $\begingroup$ Sorry, but I did not follow you on why you say that $5 \nmid a$. I undertand that if $5 \mid a^2 + 2b^2 + 10 \Rightarrow 5 \mid a^2 + 2b^2$. I get that. But, I dont quite understand your reasoning on saying that $5 \mid a$ because that necessarily means that $5 \mid b$ and hence $5 \mid (a,b) = 2$. Could you be more specific? Thanks!:) $\endgroup$ Oct 12, 2013 at 1:34
  • $\begingroup$ basically, i dont understood why the part that $5 \mid a$ implies $5\mid b$, the "hence" I get it.. :) $\endgroup$ Oct 12, 2013 at 1:35
  • $\begingroup$ @pmartelletti, This was supposed to be a proof by contradiction. I edited the answer to make it more understandable. $\endgroup$
    – Arash
    Oct 12, 2013 at 2:33

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .