Number of zeros of a sum of Shah functions by applying Rice's formula?
This is not a complete answer in that it does not apply Rice's formula although it does derive the formula for the counting function $\mathcal{Z}(T_{max})$.

For $t,t_0,T,T_{max}\in \mathbb{N}$:

$$\frac{1}{T}\sum_{n=1}^{T}\exp\left(\frac{i 2\pi n t}{T}\right)=\cases{1&amp;$T|t$\cr 0 &amp;otherwise\cr}$$
so:

$$S(t,T_{\max})=\sum_{T=1}^{T_{\max}}\frac{1}{T}\sum_{n=1}^{T}\exp\left(\frac{i 2\pi n t}{T}\right)$$
counts the number of divisors of $t$ that are $\le T_{max}$ and $t_0$ is defined to be a zero if it satisfies: 
$$\sum_{T=1}^{T_{\max}}\frac{1}{T}\sum_{n=1}^{T}\exp\left(\frac{i 2\pi n t_0}{T}\right)=\sum_{T=1}^{T_{\max}}\cases{1&amp;$T|t_0$\cr 0 &amp;otherwise\cr}=0 \tag{1}$$
which holds iff $t_0$ is not divisible by any integer $1\le T\le T_{max}$. However $t_0$ is always divisible by $1$ so the sum in $(1)$ must always evaluate to something $\ge1$ for any $T_{max}$. In which case we are forced to say

there are no integers $t_0,\,T_{max}$ such that $(1)$ holds and thus:
$$\mathcal{Z}(T_{max})=0, \,\forall T_{max}\in \mathbb{N}.\tag{2}$$

Alternatively, if we chose to exclude the trivial case in which $1$ divides all integers by beginning the outer sum in $(1)$ at $T=2$ we may find a less trivial outcome. Define $t_0$ with $2\le T_{max}\le  t_0\le T_{max}^2$ to be a solution to the equation:
$$\sum_{T=2}^{T_{\max}}\frac{1}{T}\sum_{n=1}^{T}\exp\left(\frac{i 2\pi n t_0}{T}\right)=0$$
then $\mathcal{Z}$ counts the number of integers $t_0 \in \left[T_{max},T_{max}^2\right]$ such that $T\nmid t_0 \forall\, 2\le T \le T_{max}$, in which case:
$$\mathcal{Z}=\pi(T_{max}^2)-\pi(T_{max}) \tag{3}$$
where $\pi(x)$ is the prime counting function.

Proof

If: $$\exists t_0 \,\, \text{such that} \,\,\,T\nmid t_0 \,\forall\, 2\le T \le T_{max},$$ but $t_0$ is not prime, then: $$\exists k&gt;T_{max}\,\, \text{such that} \,\,k|t_0,$$ and:
 $$\exists n=\dfrac{t_0}{k}&gt;T_{max},n\in \mathbb{N},$$
which implies:
$$t_0=nk&gt;T_{max}^2,$$
from which we conclude that $t_0 \in \left[T_{max},T_{max}^2\right]$ is not a solution when $t_0$ is not prime. It is clear that if $t_0$ $\left(2\le T_{max}\le  t_0\le T_{max}^2\right)$ is prime, it is not divisible by $2\le T \le T_{max}$ and is therefore a solution, unless $T_{max}$ is itself prime. From this we conclude that all $t_0$ are primes such that $T_{max}&lt;t_0\le T_{max}^2$ and $(3)$ follows.