## zmudz one year ago Find all $$x$$ for which $$\left| x - \left| x-1 \right| \right| = \lfloor x \rfloor$$ The answer is suppose to be in a range, but when I put in that it can be all real numbers, that is wrong.

1. dinamix

x=1 and x= 1/3

2. anonymous

I would try using the definition of the absolute value function to rewrite the LHS into something that you can easily match up with the RHS. $|x|=\begin{cases}x&\text{for }x>0\\0&\text{for }x=0\\-x&\text{for }x<0\end{cases}$ This means \begin{align*}|x-|x-1||&=\begin{cases}x-|x-1|&\text{for }x-|x-1|>0\\0&\text{for }x-|x-1|=0\\-x+|x-1|&\text{for }x-|x-1|<0\end{cases}\\[2ex] &=\begin{cases}x-|x-1|&\text{for }x>\dfrac{1}{2}\\[1ex]0&\text{for }x=\dfrac{1}{2}\\[1ex]-x+|x-1|&\text{for }x<\dfrac{1}{2}\end{cases} \end{align*} You also have \begin{align*} |x-1|&=\begin{cases}x-1&\text{for }x>1\\0&\text{for }x=1\\-x+1&\text{for }x<1\end{cases} \end{align*}

3. anonymous

Putting all this together, you get \begin{align*} |x-|x-1||&= \begin{cases} 1&\text{for }x>1\\x&\text{for }x=1\\[1ex]2x-1&\text{for }\dfrac{1}{2}<x<1\\[1ex]0&\text{for }x=\dfrac{1}{2}\\[1ex]-2x+1&\text{for }x<\dfrac{1}{2} \end{cases} \end{align*}

4. anonymous

Now, given that $\lfloor x\rfloor=\begin{cases}&\vdots\\ 0&\text{for }0\le x<1\\ 1&\text{for }1\le x<2 \\&\vdots\end{cases}$ you have the isolated solution $$x=\dfrac{1}{2}$$ (since both LHS and RHS are zero) and the range $$[1,2)$$.