# What will be the domain of the function $f(x)=\sqrt{2\{x\}^2-3\{x\}+1}$?

I need to find the domain of the function

$$f(x)=\sqrt{2\{x\}^2-3\{x\}+1}$$

where $$x \in [-1,1]$$ and $$\{.\}$$ represents the fractional part of $$x$$

So here's what I tried:

Clearly the part inside the square root has to be greater than or equal to zero for it to exist, and by factoring the quadratic in terms of $$\{x\}$$ I get,

$$(\{x\}-1)(2\{x\}-1)\geq0$$

So, from here I got $$\{x\} \in \bigg(-\infty,\frac{1}{2}\bigg] \cup \bigg[1,\infty\bigg)$$

But we know, that the fractional part of x can only vary between 0 and 1, ie,

$$\{x\} \in[0,1)$$

So finally, I get $$\{x\} \in \bigg(-\infty,\frac{1}{2}\bigg]$$, which further reduces to the following

$$\{x\} \in \bigg[0,\frac{1}{2}\bigg]$$

And, from the question, $$x \in[-1,1]$$

But how do I finally get the domain for $$x$$ here? I'm seemingly stuck at the last step

• For which $x$ values do you get a fractional part between $0$ and $\frac{1}{2}$ ? May 9 '20 at 18:38
• @NinadMunshi I know that for $-1\le x < 0$, $\{x\} = x+1$, so here for negative values of x, how would I get the answers? In between $0$ to $1$, I only can have values between $0$ to $\frac{1}{2}$ and also include $1$ as that yields zero, but what about for negative values of $x$? Like between $-1$ and $0$? May 9 '20 at 18:41

Hint: Write $$X = \left \lfloor X \right \rfloor + \left \{ X \right \}$$ $$\\ And \left \lfloor X \right \rfloor = 0 \ or \ -1$$