Skip to main content
3 of 11
added 129 characters in body
Carlo Beenakker
  • 188.2k
  • 18
  • 448
  • 651

For $n$ prime, such quadratic representations have been studied by Christian Elsholtz in A combinatorial approach to sums of two squares and related problems (2010).

For general $n$, the number of representations is calculated by N. Bagis and M.L Glasser in On the Number of Representations of Integers by various Quadratic and Higher Forms (2014), formulas 12 and 13.

Carlo Beenakker
  • 188.2k
  • 18
  • 448
  • 651