In general, if a continuous function $g(x)$ is defined on the interval $[-\pi,\pi]$, can I say it is definitely possible to extend this function to be a $2\pi$-period function? I think we need to make sure the endpoints match? Functions are $2\pi$-period on the real line are also called functions on a circle in Fourier analysis. But what about $$g(x) = x \\on\ [-\pi,\pi]$$
This is clearly continuous, but $g(-\pi) \ne g(\pi)$. How can I still extend this function to a continuous $2\pi$-period function? Or do I have some conceptual misunderstandings?
Thanks so much for your help.
If the values at the endpoints don't match, you can't extend to a continuous function. But you can perform Fourier analysis even with functions admitting some discontinuities. Pretty much any periodic function which is not completely insane admits a Fourier expansion (of course the type and rate of convergence depends on regularity of the function; if you insist on some particular type of convergence, e.g. uniform convergence, then my statement is strictly speaking false).