Convergence of the series $\sum_{n=0}^\infty \frac{1}{n+1}\sin\bigr(\frac{p\pi u_n}{q}\bigl)$ 
Let $(u_n)_{n\in \mathbb{N}}$ defined by :  $u_0=1, u_1=1$ and for all integer $u_{n+1}=3u_n-u_{n-1}$
Study the convergence of $$\displaystyle\sum_{n=0}^\infty  \frac{1}{n+1}\sin\left(\frac{p\pi u_n}{q}\right)$$ with   $p,q \in \mathbb{N}^*$

I have $ S_N = \sum_{n=0}^N \frac{1}{n+1} \sin \left( \frac{2 \pi p u_n}{q} \right)
       = \frac{a_N}{N+1} - \sum_{n=0}^{N-1} \frac{a_n}{(n+1)(n+2)}$
where $$a_n = \sum_{k=0}^n \sin \left( \frac{2 \pi p u_k}{q} \right)$$
Now If I shows that $a_n$ is bounded, then
$$\frac{a_N}{N+1} \xrightarrow[N \to \infty]{} 0 \mbox{ and } \frac{a_n}{(n+1)(n+2)} \underset{n \to \infty}{=} \mathcal{O} \left( \frac{1}{n^2} \right)$$
Unfortunately I was not managed to prove it.
I try an another method :
$$\forall n \in \mathbb{N}, \left(
  \begin{array}{c}
    u_n \\ u_{n+1}
  \end{array}
\right) =
  A \left(
    \begin{array}{c}
      u_{n-1} \\ u_n
    \end{array}
  \right)$$
with
$$
A = \left[
  \begin{array}{ c c }
    0  & 1 \\
    -1 & 3
  \end{array} \right]
$$
Then,
$$
\forall n \in \mathbb{N}, \left(
  \begin{array}{c}
    u_n \\ u_{n+1}
  \end{array}
  \right)
  =
  A^n \left(
    \begin{array}{c}
      0 \\ 1
    \end{array}
  \right)
$$
As before I don't see how can I continue
Thank you in advance
 A: When $u$ is an integer, $\sin(u\pi/q)$ only depends on the value of $u$ modulo $2q$. So in your case, only the value of $u_n$ modulo $2q$ is important.
If you look at the sequence $v_n = u_n \pmod {2q}$, since we still have $v_{n+1} = 3v_n - v_{n-1}$ (as well as $v_{n-1} = 3v_n - v_{n+1}$), and because $v_n$ can only take $2q$ different values, the sequence $v_n$ has to be periodic, and so is the sequence $\sin(\frac{p\pi u_n}q)$.
Let $T$ be the period of the sequence and let $S = \sum_{n=1}^{T} \sin (\frac {p\pi u_n} q)$.
If $S \neq 0$ then $\sum_{n=a}^{a+T-1} \frac 1 {n+1} \sin(\frac {p\pi u_n} q) \sim \frac S n$ when $n \to \infty$, so the sequence diverges.
If $S = 0$ then $\sum_{n=a}^{a+T-1} \frac 1 {n+1} \sin(\frac {p\pi u_n} q) = O(\frac 1 {n^2})$ when $n \to \infty$, so the sequence converges.
A: At this point, just diagonalize $A$, obtaining $A=PDP^{-1}$ where $P$ is the changing base matrix and $D$ is the diagonal matrix obtained the eigenvalues in the diagonal. Next notice that $A^n=PD^nP^{-1}$. In this way you'll find that (as for Fibonacci) that $u_n=\frac{1}{\sqrt5}(\lambda_1^n-\lambda_2^n)$ where $\lambda_{1}=\frac{3+\sqrt5}{2},\lambda_2=\frac{3-\sqrt5}{2}$ are eigenvalues of $A$ (and then the element of the diagonal of $D$).
