# Question on calculating character sums

I am wondering if there are any references that would help me with the following problem:

Let $$p>2$$ be a prime number, $$n \in \mathbb{Z}^+$$ odd such that $$(n,p)=1$$, $$\chi$$ an imaginary quadratic character of conductor $$n$$, and $$\omega$$ the Teichmuller character.

I'm trying to calculate the sum $$$$\sum_{a=1}^{(np-1)/2} \chi\omega^{-1}(a)(-1)^a.$$$$

This sum almost reminds me of a quadratic Gauss sum (I know this is a big stretch) which I've seen can be computed using Fourier analysis. From my basic understanding (see Rodgers - Fourier series, Gauss sums, and quadratic reciprocity), the computation relies on the fact that $$$$\sum_{a=0}^{p-1}\left(\frac{a}{p}\right)e^{2\pi i a/p} = \sum_{a=0}^{p-1} e^{2\pi i a^2/p}$$$$ (here $$(a/p)$$ is the Legendre symbol) and defining $$f(x) = \sum_{a=0}^{p-1} e^{2\pi i (a+x)^2/p}$$, which is periodic on $$\mathbb{R}$$, we compute $$\hat{f}(x)$$ and find that $$$$\sum_{a=0}^{p-1}\left(\frac{a}{p}\right)e^{2\pi i a/p}= \sum_{a = -\infty}^{\infty}\hat{f}(a) = \text{a computable integral}.$$$$

In my naive attempt to mimic this process, I think I fail (or just can't see how) to write $$\sum_{a=1}^{(np-1)/2} \chi\omega^{-1}(a)(-1)^a$$ as a sum involving only exponentials and then coming up with a periodic function $$f(x)$$ that is my character sum when evaluated at 0. Because it is quite a stretch to compare my sum to a Gauss sum, I'm now thinking it is a bad idea to try to mimic this computation.

Questions:

• Is there a more general method out there for computing character sums like the one I have using Fourier analysis?

• Are there any other methods/theory that might help me out in calculating this sum?

I would also be happy if I could somehow factor this sum in $$\mathbb{Q}(e^{2\pi i/(p-1)})$$. I'm reminded of Stickelberger's theorem, where part of the proof involves finding the prime factorization of a certain Gauss sum (here I go again with the comparison). I know that the sum I'm looking at will not behave as nicely as the Gauss sum in the proof of Stickelberger's, but I am wondering,

• Is there is a general theory for finding the $$\mathcal{P}$$-adic valuation of a character sum, where $$\mathcal{P}$$ lies above $$p$$ in whatever field the character sum lives in.
• Using the Chinese remainder theorem, doesn't your sum factor into a product of two independent Gauss sums ? Jan 6, 2021 at 17:33
• @HenriCohen Doesn't summing up to $(np-1)/2$ mess up the Chinese remainder theorem since it is an isomorphism from $\mathbb{Z}/p\mathbb{Z} \times \mathbb{Z}/n\mathbb{Z}$ to $\mathbb{Z}/np\mathbb{Z}$? Jan 6, 2021 at 22:50
• Since both $\chi$ and $\omega$ are odd characters, the sum to $np-1$ is twice that up to $(np-1)/2$, or do I misunderstand ? Jan 7, 2021 at 10:16
• @HenriCohen I think the alternating part messes that up since $(-1)^{np-a} = (-1)(-1)^a$, so summing up to $np-1$ gives you zero. Jan 7, 2021 at 17:36
• sorry, indeed since you assume $n$ odd. Jan 7, 2021 at 17:46