Dirichlet Conditions and Fourier Analysis. I read in my text book that the Dirichlet conditions are sufficient conditions for a real-valued, periodic function $f(x)$ to be equal to the sum of its Fourier series at each point where $f$ is continuous. 
However, it further stated that although the conditions are sufficient but they are NOT necessary.
Why are the Dirichlet conditions "not necessary" ?
Example : One of the Dirichlet conditions state that the function can not have infinite discontinuities. Hence we can not express, a function like $ tan x $  in terms of a Fourier series since (as it appears) violates one of the conditions. So, why is that they are 'not necessary'?
P.S.: The Wikipedia Link to the Dirichlet conditions. 
 A: The conditions are "not necessary" because no one proved a theorem that if the Fourier series of a function $f(x)$ converge pointwise then the function satisfies the Dirichlet conditions. 
Some general information: the issues of the pointwise converges of Fourier series are very delicate matter. As far as I understand we still do not have the exact condition to fully identify the class of functions whose Fourier series converge. It was proved, as @chaohuang pointed in another answer, that if $f\in L^2$, then the Fourier series converge. On the other hand, A. Kolmogorov provided an example of a function $f\in L^1$ whose Fourier series do not converge at any point. I am sure you can find much more information on these issues in any serious text on Fourier analysis.   
A: Another sufficient condition is $f(x) \in \mathbb{L}_2(-\frac{1}{2}L,\frac{1}{2}L)$.
A: One of the conditions that is not necessary in general to have a Fourier series that converges back to the original function, yet is in Dirichlet's conditions, is that the function has finitely many local maxima/minima.
For instance, if we consider $f(x) = x^n\sin\left(\frac{1}{x}\right)$ on $[-\pi, \pi]$ for $n \geq 3$, we see that $f$ is ${\mathcal C}^1$ and hence its Fourier series converges to $f$. Also, to make $f$ have any degree of smoothness, we can just make $n$ sufficiently large.
So, we see that $f$ has a Fourier series that converges to $f$, yet has local minima/maxima at $x = \frac{1}{(2k + 1)\pi}$, where $k$ is an integer.
