## Is there a nice expression for the number of lattice points on a sphere? [closed]

### Remember to vote up questions/answers you find interesting or helpful (requires 15 reputation points)

Possible Duplicate:
Is there a simple way to compute the number of ways to write a positive integer as the sum of three squares?

Is there a nice expression for the number of points in $\mathbb{Z}^3$ which lie a distance of $\sqrt{n}$ from the origin? Here, $n$ is of course a positive integer.

-

9
Let me rephrase your question as follows: is there a closed form expression for the cube of the theta series, $\bigl(\sum_{n\in\mathbb Z}q^{n^2}\bigr)^3$. The answer is "no", although for a very close cube, $\bigl(\sum_{n\in\mathbb Z}(-1)^nq^{(6n+1)^2/24}\bigr)^3$, one has $\sum_{n=0}^\infty(-1)^n(2n+1)q^{(2n+1)^2/8}$. – Wadim Zudilin Apr 26 2010 at 8:01

6
@Wadim: the poster did not ask for a closed form expression, he asked for a "nice expression". Firstly, can you really assert with confidence that there is no "closed form expression"? And secondly, so much is known about the generating function---it spans the space of level 4 weight 3/2 modular forms, and there are surely by now computer algebra packages which efficiently compute coefficients---that one might argue that "it's the coefficient of q^n in the unique normalised weight 3/2 level 4 modular form, and a lot is known about coeffs of modular forms" is a "nice expression" for the number! – Kevin Buzzard Apr 26 2010 at 9:39

1
@Kevin: another level 4 weight 3/2 modular form, linearly independent with $f(q)$, is $\bigl(\sum_{n\in\mathbb Z}(-1)^nq^{n^2}\bigr)^3$. – Wadim Zudilin Apr 26 2010 at 10:45

6
See my answer mathoverflow.net/questions/3596/… – David Speyer Apr 26 2010 at 11:48

5
@Kevin: since this is an exact duplicate and you already got some very nice answers, I hope you don't mind my voting to close. – Hailong Dao Apr 26 2010 at 20:29
show 4 more comments

## 2 Answers

We (me, Michel, and Venkatesh) write something about this question in the preprint "Linnik's Ergodic method and the distribution of integral points on spheres."

In particular, in section 3 we explain how when n is squarefree and not congruent to 7 mod 8 the solution set of x^2 + y^2 + z^2 = n (up to the natural SO_3(Z) action) is naturally a torsor for a certain class group, so that in particular the size of the set is equal to the size of the class group. None of this is really original to us, I should emphasize! Maybe the use of the word "torsor," at most.

-

### You can accept an answer to one of your own questions by clicking the check mark next to it. This awards 15 reputation points to the person who answered and 2 reputation points to you.

There is one answer to your question that is classical, discovered by Dirichlet. The number of proper representations of $n$ as a sum of three squares can be expressed as a sum of Jacobi symbols, for example $$r_3'(n) = 24\sum_{m \leq n/4}\left(\frac{m}{n}\right)$$ if $n \equiv 1{\;}(4)$. Here $r_3'(n)$ denotes the number of proper representations, where $x,y,z$ in $x^2 + y^2 + z^2 = n$ has no common factor. If $n$ is squarefree then $r_3(n) = r_3'(n)$, otherwise $r_3(n)$ is given by a sum $$r_3(n) = \sum_{d^2|n}r_3'(n/d^2)$$ The above formula strongly suggests that there is no simple closed form expression for $r_3(n)$.

Whether this answer really qualifies as nice is uncertain. It is necessary to separate into cases. The formula looks slightly different when $n \equiv 3{\;}(4)$. How it looks when $n$ is even I do not know.

I should mention that Gauss had expressed the number of proper representations of $n$ as a sum of three squares in terms of class numbers of binary quadratic forms. Dirichlet obtained his formulas for $r_3'(n)$ by applying his class number formula.

-
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 21, "mathjax_display_tex": 2, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0}, "config": {"markdown_headings": true, "markdown_code": false, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 10, "end_threshold": 15, "enable": true}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "github"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "english_confidence": 0.9436512589454651, "perplexity_flag": "head"}