Since ##f(x)## is continuous in ##\mathbb R##, it has a primitive function in ##\mathbb R## as well, so we have to define ##F(x)## also for points ## \frac{\pi}{2}+k\pi##.
##\lim_{x \to \left(\frac{\pi}{2}+k\pi \right)^-} F(x) =\frac{\pi}{2}+k\pi -\frac{\pi}{2\sqrt 2}+C_k ##
##\lim_{x \to...