Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Given $a,b,n\in \mathbb{N}$. What is the easiest route to find a pair of integers $x,y$ such that $(a^2+b^2)^n = x^2 + y^2$?

share|improve this question

2 Answers 2

up vote 2 down vote accepted

Compute $(a+bi)^n$ and take the real and imaginary parts.

Why it works: The squared norm $\|a+bi\|^2 = a^2+b^2$ is completely multiplicative, so $$\|(a+bi)\|^{2n} = (a^2+b^2)^n = \|(a+bi)^n\|^2.$$

share|improve this answer
    
you are missing a power of 2 on the norm. –  Maesumi Jan 14 '13 at 23:47
    
Right, I want the squared norm. –  user7530 Jan 14 '13 at 23:51
    
I like this one :) –  Drake Jan 15 '13 at 0:04

The easiest is to observe that if $n=2m$ is even, we can use $x=(a^2+b^2)^m$, $y=0$. If $n=2m+1$ is odd, we can use $x=a(a^2+b^2)^m$, $y=b(a^2+b^2)^m$.

share|improve this answer
    
Ha, that is easiest. –  user7530 Jan 14 '13 at 23:45

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.