Q.
Let $S=\{\theta \in[0,2 \pi): \tan (\pi \cos \theta)+\tan (\pi \sin \theta)=0\}$.
Then $\displaystyle\sum_{\theta \in s } \sin ^2\left(\theta+\frac{\pi}{4}\right)$ is equal to _______
Solution: