Let $\xi_{19} \in G_{19}$ be a primitive root of unity. Find $\Re\sum_{k=1}^9\xi_{19}^{k^2}$. Question

Let $\xi_{19} \in G_{19}$ be a primitive root of unity. Find $\Re\sum_{k=1}^9\xi_{19}^{k^2}$.

Attempt
I'm having doubts about how I'm solving this exercise, this is what I did:
$$
\Re\left(\sum_{k=1}^9\xi_{19}^{k^2}\right)=\sum_{k=1}^9\Re\left(\xi_{19}^{k^2}\right)\\
=\Re\xi^1+\Re\xi^4+\Re\xi^9+\Re\xi^{16}+\Re\xi^{25}+\Re\xi^{36}+\Re\xi^{49}+\Re\xi^{64}+\Re\xi^{81}\\
=\Re\xi^1+\Re\xi^4+\Re\xi^9+\Re\xi^{-3}+\Re\xi^{6}+\Re\xi^{-2}+\Re\xi^{-8}+\Re\xi^{7}+\Re\xi^{5}\\
=\Re\xi^1+\Re\xi^4+\Re\xi^9+\Re (\overline\xi)^{3}+\Re\xi^{6}+\Re(\overline\xi)^{2}+\Re(\overline \xi)^{8}+\Re\xi^{7}+\Re\xi^{5}
$$
Also, using $\Re(z)=\Re(\overline z)$, the sum is then simplified to:
$$\Re \sum_{k=1}^{9}\xi^i=\Re \frac {\xi^{10}-\xi}{\xi-1} .$$
Is what I did thus far correct? Can this be simplified further?
 A: I'm not exactly sure how exactly you got rid of the squares in the exponents. That step definitely lacks justification and is probably incorrect.
Here's what you can do:
Let $A = \sum_{k=1}^{9}\xi_{19}^{k^2}$ and $B = \sum_{k=1}^{9}\xi_{19}^{-k^2}$. Note that the exponents in $A$ and $B$ are precisely the sets of all squares and non-squares mod $19$. (Excluding $0$.) Then we can verify that
$$ AB = 9+4\sum_{k=0}^{18}\xi_{19}^{k} = 5,$$
by verifying that the pairwise sums of all squares and non-squares in $\mathbb F_{19}$ will give every $x\neq 0$ precisely $4$ times and $0$ precisely $9$ times.(*)
On the other hand $1+A+B = \sum_{k=0}^{18}\xi_{19}^{k} = 0$. So we may solve the system for $A$ and $B$. We find
$$ A,B = \frac{-1\pm\sqrt{-19}}{2}, $$
and thus $\Re A=\Re B=-1/2$. 

(*) I have checked this fact using the programming language Python, but it is probably not too hard to check it by hand. 

L1 = sorted([(i^2)%19 for i in range(1,10)]])
  L2 = sorted([(-i^2)%19 for i in range(1,10)])
  sorted([(i+j)%19 for i in L1 for j in L2])

