If the sum $$S=\frac14+\frac1{10}+\frac1{82}+\frac1{6562}+\cdots+\frac1{3^{2^{100}}+1}$$ is expressed in the form $\frac pq,$ where $p,q\in\mathbb N$ and $\gcd(p, q) =1.$ Then what is smallest prime factor of $p$ ?
We have: $$S=\sum_{k=0}^{100} \frac1{3^{2^k}+1}.$$ Please give me some hints to evaluate such kind of sums, in general.
Remark.
Since $4$ divides the denominator of the zeroth term ($\frac14$) of $S$, but does not divide the denominator of any other term, we can see that $2\nmid p$.
Note that each term of $S$ is $\equiv 1\pmod{3}$. Therefore, $S\equiv 101\cdot 1\equiv 2\pmod{3}$, so $3\nmid p$.
Since $5$ divides the denominator of the first term ($\frac1{10}$) of $S$, but not the denominator of any other term, we conclude that $5\nmid p$.