How do I prove that whenever $|y − x| ≤ 1/2$ it follows that $|f(y) − f(x)| \leq f(|y − x|)$ given $f(x)=-x\log_2 x$?
where $x,y\in[0,1]$
The graph of $f(x)=-x\log_2 x$ function is
$$ f'(x)=-\log x-\frac{x}{x\ln 2}=-\log x-\frac{1}{\ln 2}=0\implies \log x=-\frac{1}{\ln 2}\\ \frac{\ln x}{\ln 2}=-\frac{1}{\ln 2}\implies \ln x=-1\implies x=1/e\approx 0.3679 $$
I was only able to write the following proof:
When $0\le x\le y\le 1$,
\begin{align} |f(x)-f(y)|&=|-x\log x+y\log y|\\ &=|-x\log x+\frac{x}{\ln 2}+y\log {y}-\frac{y}{\ln 2}+\frac{y}{\ln 2}-\frac{x}{\ln 2}|\\ &\leq |-(x\log x-\frac{x}{\ln 2})+(y\log y-\frac{y}{\ln 2})|+\frac{|y-x|}{\ln 2}\\ &=|\int_x^y \log tdt|+\frac{|y-x|}{\ln 2}=-\int_x^y \log tdt+\frac{|y-x|}{\ln 2}\\ &=-\int_x^{x+(y-x)} \log tdt+\frac{|y-x|}{\ln 2}\\ &\leq -\int_0^{y-x} \log tdt+\frac{|y-x|}{\ln 2}\\ &=-\Big(t\log t-t\Big)_0^{y-x}+\frac{|y-x|}{\ln 2}\\ &=-(y-x)\log(y-x)+(y-x)+\frac{|y-x|}{\ln 2}\\ &=f(|y-x|)+|y-x|+\frac{|y-x|}{\ln 2} \end{align}
My Attempt
Thanks @Balajisb for the hint.
If $f$ is a concave function then $f(a+b)\leq f(a)+f(b)$ for all $a,b>0$ $$ -y\log y=-(y-x+x)\log(y-x+x)\le-(y-x)\log(y-x)-x\log x\\ -y\log y-(-x\log x)\le -(y-x)\log(y-x)\\ f(y)-f(x)\le f(y-x) $$ $$ D_{\log x}\in(0,\infty]\implies x,y,y-x\geq 0\implies 1\ge y>x>0\\ $$ $$ 1>y-x>0\implies -(y-x)\log(y-x)>0 $$ $$ f(y)-f(x)\le f(|y-x|) \;\forall\;(x,y)\;|\;y>x>0\\f(x)-f(y)\le f(|y-x|) \;\forall\;(x,y)\;|\;x>y>0 $$ Therefore, $$ |f(y)-f(x)|\le f(|y-x|) \;\forall\;(x,y)\;|\;y>x>0\;\&\;f(y)>f(x)\\|f(y)-f(x)|\le f(|y-x|) \;\forall\;(x,y)\;|\;y<x<0\;\&\;f(y)<f(x) $$
In order to prove $|f(y)-f(x)|\le f(|y-x|) \;\forall\;x,y>0$ we need to also consider the cases $y>x>0\;\&\;f(y)<f(x)$ and $x>y>0\;\&\;f(x)<f(y)$. So I think that's where the condition $y-x\leq 1/2$ lies in.
Case 1 : $y>x>0\;\&\;f(y)<f(x)$ $$ -y\log y<-x\log x\implies y\log y>x\log x\\ x\log x-y\log y<0\\x\log x-\frac{x}{\ln 2}-y\log y+\frac{y}{\ln 2}-\frac{y-x}{\ln 2}<0\\ \int_y^x \log t dt-\frac{y-x}{\ln 2}>0\\ y-x<\ln 2\int_y^x \log t dt=-\ln 2\int_x^y \log t dt=-\ln 2\int_x^y \frac{\ln t}{\ln 2}dt=-\int_x^y \ln t dt\\ <-\int_0^1 \log t dt=-1\times -1=1 $$
How do I obtain the condition $y-x\leq 1/2$ in this case ?
