# help with modular arithmetic please

• December 1st 2011, 03:30 PM
MathFan
Hi all,

$n=((a^2+b^2)(c^2+d^2)(f^2+2ef-e^2))^2+((a^2+b^2)(d^2+2cd-d^2)(e^2+f^2))^2+(b^2+2ab-a^2)(c^2+d^2)(e^2+f^2))^2$

It is known that

$a^2+b^2\equiv 1\ mod\ 4$
$c^2+d^2\equiv 1\ mod\ 4$
$e^2+f^2\equiv 1\ mod\ 4$

from these we can say that if

$a\equiv(0\ mod\ 4)\ or\ (2\ mod\ 4)\ then\ b\equiv\ (1\ mod\ 4)\ or\ (3\ mod\ 4)$ or vice versa.

The same is true for the relationship between (c and d) and (e and f)

I have found that $n\equiv\ 3\ mod\ 4$ by using permutations of the above.

From reasonably extensive computer modelling of n, it also appears that $n\equiv0\ mod\ 3$ but I can't seem to relate that to the above. Is it obvious why and I'm just suffering brain-freeze?

Thanks for helping thaw me out :)
• December 2nd 2011, 12:04 AM
takatok
Re: help with modular arithmetic please
Its pretty late, and I haven't really thought it all the way through but since 12 is the lcm of 3 and 4. Maybe you could convert the entire thing to mod 12.

$a^2+b^2\equiv\ 1,5,9\ mod\ 12$
$c^2+d^2\equiv\ 1,5,9\ mod\ 12$
$e^2+f^2\equiv\ 1,5,9\ mod\ 12$

Then build a relation table for a and b mod 12. Using a computer program you might be able to handle all the permutations, to find out what possible values n can hold mod 12. Of course you are expecting to see:

$n\equiv\ 0,3,6,9\ mod\ 12$
which then proves that:
$n\equiv\ 0\ mod\ 3$
• December 2nd 2011, 02:50 AM
MathFan
Re: help with modular arithmetic please
Thanks takatok, I can do that. I was just hoping for something more elegant.