If $Q:\mathbb{Z}^{2k}\to \mathbb{Z}$ is any positive definite integer -valued quadratic form in $2k$ variables, then it is well known, that the $\textbf{theta series}$ $\theta\_Q(z):=\sum\_{m\in\mathbb{Z}^{2k}}q^{Q(m)}\ (q=e^{2\pi i z})$ is a modular form of weight $k$ on the congruence group $\Gamma\_0(N)$ ( for some integer $N$ ) with some character $\chi$ $\bmod$ $N$, i.e. $\theta\_Q \left(\frac{az+b}{cz+d}\right)=\chi(d)(cz+d)^k \theta\_Q(z)$ for all $\big(\begin{smallmatrix}a&b\\c&d\end{smallmatrix}\big)\in \Gamma\_0(N)$. Let us denote the space of modular forms of weight $k$ on $\Gamma\_0(N)$ with character $\chi$ by M$\_k(\Gamma\_0(N),\chi)$. Let S$\_k(\Gamma\_0(N),\chi)$ be the subspace of cusp forms and $\mathcal{E}\_k(\Gamma\_0(N),\chi)$ be the eisenstein subspace. We know
$\text{M}\_k(\Gamma\_0(N),\chi)=\mathcal{E}\_k(\Gamma\_0(N),\chi)\oplus\text{S}\_k(\Gamma\_0(N),\chi)$ and this decomposition is orthogonal under the Petersson inner product. My Question is: Is there any explicit formula for the eisenstein part of the the theta function $\theta\_Q$? Perhaps a simple form, when $\chi$ is the trivial character?!



eisenstein part of the theta function
I believe the formula you're looking for is a formula of Siegel that expresses the $n$th Fourier coefficient of an Eisenstein series as a product of local densities. There are lots of papers giving formulas for these local densities in terms of the arithmetic of $Q$ in the literature. My two favorite sources are


$\bullet$ ''Local densities and explicit bounds for representability by a quadratic form'' by Jonathan Hanke, Duke Math. J. (2004), no. 2, 351-388, and


$\bullet$ ''An explicit formula for local densities of quadratic forms,'' by Tonghai Yang, J. Number Theory 72 (1998), 309-356.


The formulas you get simplify quite a bit if $\chi = 1$, and even more if the integer $n$ you want to represent is coprime to $N$.


