Let $f:\mathbb R^d\to [0,\infty)$ be a probability density function: $$\int_{\mathbb R^d} f(x)\,d x =1\,. $$ Suppose $f$ has finite second moment: $$\int_{\mathbb R^d} |x|^2\,f(x)\,d x <\infty\,. $$ I have read that $f$ has then finite entropy: $$\int_{\mathbb R^d} |\log f(x)|\,f(x)\,d x <\infty $$ but I am not sure how to prove this statement. Any help is appreciated.
Edit. I can prove the thesis adding the hypothesis $f(x)\leq c_0\,e^{c_1|x|^2}$ for every $x$. Indeed splitting the integral in three terms: $$ \int_{\{f\geq1\}} \log f(x)\,f(x) \,d x \,\leq\, \log c_0 + c_1\int_{\mathbb R^d}|x|^2\,f(x) \,d x \,,$$ $$ \int_{\{f\leq e^{-|x|}\}} -\log f(x)\,f(x) \,d x \,\leq\, \int_{\mathbb R^d} e^{-\frac{|x|}{2}} \,d x \quad(\textrm{since } -f\,\log f\leq \sqrt{f} \textrm{ for }0\leq f\leq1)\,,$$ $$ \int_{\{e^{-|x|}<f<1\}} -\log f(x)\,f(x) \,d x \,\leq\, \int_{\mathbb R^d} |x|\,f(x)\,d x \;.$$ Is it possible to remove the hypothesis of $f$ being controlled by $e^{|x|^2}$?
As stated, this result is not true. Take $d=1$, and let $f$ be $0$ everywhere except for intervals $[n,n+\epsilon_n]$ ($n=1,2,3\dots$) and let $f$ be equal to a constant $c_n$ on $[n,n+\epsilon_n]$. If say $c_n\epsilon_n=A/n^4$ (with $A=1/\zeta(4)=90/\pi^4$) then the second moment is finite.
If we choose $c_n=\exp(n^3)$ and so $\epsilon_n = A/(n^4\exp(n^3))$, then $\int_{\mathbb R} |\log f(x)|\,f(x)\,d x = \sum_n A/n =\infty$.