# quadratic Gauss sum over a power of 2

Is there a general formula for the generalized quadratic Gauss sum defined by $$G(a,b,c)=\frac{1}{c}\sum_{n=0}^{c-1}e\left(\frac{an^2+bn}{c}\right)$$ where $e(x)=\exp(2\pi ix)$ and $c$ is a power of 2?

• I think this sum is null : $G(a,b,2^k)=0$ Mar 2, 2015 at 23:39
• @Elaqqad For any $a$ and $b$? Mar 3, 2015 at 0:33
• Don't think so, @Ela, e.g., $c=4$, $a=1$, $b=0$, do you get zero as the sum? Mar 3, 2015 at 11:42
• Just when $b$ is odd as it was given in the answer Mar 3, 2015 at 11:45
• Fine, but Dony wants an answer for all $a$ and $b$. Mar 3, 2015 at 11:53

We have $$G\left(a,b,2^{k}\right)=0$$ if $a,b$ are odd (and trivially $\left(a,2^{k}\right)=1$) . You can find a proof on wikipedia http://en.wikipedia.org/wiki/Quadratic_Gauss_sum#Generalized_quadratic_Gauss_sums. If $b$ is even this result is false and if $b=0$ this is the classic quadratic Gauss sum.

• And if $b$ is even? Mar 3, 2015 at 11:43
• If $b$ is even this result is false, you can find easily some counterexamples. Mar 3, 2015 at 11:48
• when $b$ is even we can use the method of completing the square Mar 3, 2015 at 11:49
• What if $b=0$, and the square is already complete? What's the sum then? Mar 3, 2015 at 11:54
• @GerryMyerson If $b=0$ is the classic quadratic Gauss sum. For some details, you can see here en.wikipedia.org/wiki/Quadratic_Gauss_sum Mar 3, 2015 at 11:56

You could probably use the generalized quadratic Gauss sum reciprocity formula, defined for integers $a, b, c$ satisfying $ac \neq 0$ and $ac+b$ even. In this case, we set $\displaystyle S(a,b,c) = \sum_{x=0}^{|c|-1} e\left(\frac{ax^2+bx}{2c}\right)$, and the theorem states \begin{eqnarray*} S(a,b,c) = \left|\frac{c}a\right| e\left(\frac{sgn(ac)-(b^2/ac)}8\right)S(-c,-b,a). \end{eqnarray*}

See Gauss and Jacobi Sums by Berndt, Evans and Williams.

Observe that we can complete the square $ax^2+bx = a(x+\frac{b}{2a})^2-\frac{b^2}{4a}$, so if $2 \mid b$ and $a$ is odd we have $ax^2+bx \equiv a(x+a^{-1}\frac{b}2)^2 - a^{-1}(\frac{b}2)^2 \mod c$. Under these assumptions, we have that \begin{align*} G(a,b,c) &= \sum_{x=0}^{|c|-1} e\left(\frac{a(x+a^{-1}\frac{b}2)^2}c\right) e \left(\frac{- a^{-1}(\frac{b}2)^2}c\right)\\ &= e \left(\frac{- a^{-1}(\frac{b}2)^2}c\right) G(a;|c|) \end{align*} where $G(a;|c|) = (1+\imath^a)\left(\frac{|c|}a\right) \sqrt{|c|}$ is the quadratic Gauss sum when $c = 2^r$ for some integer $r > 1$.