Homepage › Solution manuals › Ivan Niven › An Introduction to the Theory of Numbers › Exercise 3.6.6 (Number of ordered pairs $(x,y)$ of relatively prime positive integers for which $x^2 + y^2 = n$)
Exercise 3.6.6 (Number of ordered pairs $(x,y)$ of relatively prime positive integers for which $x^2 + y^2 = n$)
Suppose that . Show that the number of ordered pairs of relatively prime positive integers for which is .
Answers
Proof. As in Problem 5, there are as many primitive solutions of in the four quadrants. If (or ) is a solution on the or axes, they are not primitive solutions, because (since ). So the number of ordered pairs of relatively prime positive integers for which is given by
The number of ordered pairs of relatively prime positive integers for which is . □