Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Tried to solving $|x^2-5x+5|<1$ using the square method, but I don't know what I did wrong:

$$-1<x^2-5x+5<1$$ $$-6<x^2-5x<-4$$ $$-6+\frac{25}{4}<x^2-5x+\frac{25}{4}<-4+\frac{25}{4}$$ $$\frac{25-24}{4}<\left(x-\frac{5}{2}\right)^2<\frac{25-16}{4}$$ $$\frac{\pm\sqrt1}{\sqrt4}<\sqrt{\left(x-\frac{5}{2}\right)^2}<\frac{\pm\sqrt9}{\sqrt4}$$ $$\frac{\pm1}{2}<x-\frac{5}{2}<\frac{\pm3}{2}$$ $$\frac{5\pm1}{2}<x<\frac{5\pm3}{2}$$

Possible solutions:

$2<x<1$ (not valid)

$2<x<4$ (ok)

$3<x<1$ (not valid)

$3<x<4$ (ok, but is a subset of solution 2.

Therefore $S=\{2<x<4\}$

The only problem is that the correct solution is $S=\{1<x<2\text{ or }3<x<4\}$. Where am I wrong?

share|cite|improve this question
Hint: what happens when you take square roots in an inequality and consider both the positive and negative root. For example, $1<4<9$, but taking square roots, $\pm 1<2<\pm 3$ gives something fishy. Afterall, if say $-1<0$ but squaring both sides does not preserve the inequality: $1<0$. – Alex R. May 3 '12 at 20:25
The double inequality $$\frac{25-24}{4}<\left(x-\frac{5}{2}\right)^2<\frac{25-16}{4}$$ is not equivalent to $$\frac{\pm\sqrt1}{\sqrt4}<\sqrt{\left(x-\frac{5}{2}\right)^2}<\frac{\pm\sqrt9}{‌​\sqrt4}$$ – Américo Tavares May 3 '12 at 20:29
Why not? If I had them separated (like equation 1 and 2) wouldn't it be valid? I'm not questioning your math, I'm just trying to grasp it. – Luiz Borges May 3 '12 at 20:32
@Luiz Borges Well, $\sqrt{\left( x-\frac{5}{2}\right) ^{2}}\geq 0$ and $\frac{-\sqrt{9}}{\sqrt{4}}<0$; and similarly for the first inequality. – Américo Tavares May 3 '12 at 21:07
@LuizBorges The solution is $1<x<2$ or $3<x<4$. Proof. The solution of the first inequality $x^{2}-5x+4<0$ is $1<x<4$, because the roots of $x^{2}-5x+4=0$ are $x_{1}=1$ and $x_{2}=4$, and the coefficient of $x^{2}$ is positive. The solution of the second inequality $x^{2}-5x+6>0$ is $x<2$ or $x>3$, because the roots of $x^{2}-5x+6=0$ are $x_{1}=2$ and $x_{2}=3$, and the coefficient of $x^{2}$ is positive. – Américo Tavares May 3 '12 at 21:15
up vote 3 down vote accepted

You have a $\pm$ on each side of the inequality, but you need to change the direction of inequality for the "minus".

So you would have $$\dfrac{5 + 1}{2} < x < \dfrac{5+3}{2}$$ (The $+$'s go together), or $$\dfrac{5 - 1}{2} > x > \dfrac{5 - 3}{2}$$ (The $-$'s go together)

share|cite|improve this answer
I did reached that by trial analysis, but why is that? I'm trying to run away from "magic rules"... :( – Luiz Borges May 3 '12 at 20:31
See Phira's answer, which I will now comment on. – The Chaz 2.0 May 3 '12 at 20:32
I got it know. I will accept your answer, but it could be Phira as well. I got choose one. Thanks. – Luiz Borges May 3 '12 at 20:54
Anytime. Maybe I'll have a look at her other answers and find a few I haven't voted on :) – The Chaz 2.0 May 3 '12 at 21:00
@LuizBorges: It's not a "magic rule", it's the fact that $\sqrt{x^2}=|x|$, not $\pm x$. – Arturo Magidin May 3 '12 at 21:31

When you take the root of an inequality, you have to make sure that everything is positive and then take positive roots.

So after taking the roots, you get:

$\frac 12 < |x-\frac 52| < \frac 32$.

Now, you can regard the two cases $x> \frac 52$ and $x < \frac 52$ to eliminate the absolute value.

share|cite|improve this answer
(For Luiz) - When $x > \dfrac{5}{2}$, the absolute value can be dropped. This gives the first inequality in my answer. When $x < \dfrac{5}{2}$, you must multiply everything by $-1$, giving the second inequality in my answer. – The Chaz 2.0 May 3 '12 at 20:33

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.