Let's solve the equation:
\[ |1 - x| + |x + 2| = 3 \]
Step 1: Find critical points
The absolute value expressions change behavior at points where their arguments are zero:
- \(1 - x = 0 \Rightarrow x = 1\)
- \(x + 2 = 0 \Rightarrow x = -2\)
We will consider three intervals based on these points:
- \(x < -2\)
- \(-2 \leq x \leq 1\)
- \(x > 1\)
Step 2: Solve on each interval
Interval 1: \(x < -2\)
- \(1 - x > 0 \Rightarrow |1 - x| = 1 - x\)
- \(x + 2 < 0 \Rightarrow |x + 2| = -(x + 2) = -x - 2\)
Equation:
\[ (1 - x) + (-x - 2) = 3 \]
Simplify:
\[ 1 - x - x - 2 = 3 \]
\[ -2x - 1 = 3 \]
\[ -2x = 4 \]
\[ x = -2 \]
Check if \(x = -2\) is in the interval \(x < -2\); no, it is at the boundary.
Interval 2: \(-2 \leq x \leq 1\)
- \(1 - x \geq 0 \Rightarrow |1 - x| = 1 - x\)
- \(x + 2 \geq 0 \Rightarrow |x + 2| = x + 2\)
Equation:
\[ (1 - x) + (x + 2) = 3 \]
Simplify:
\[ 1 - x + x + 2 = 3 \]
\[ 3 = 3 \]
This simplifies to an identity, which means every \(x\) in this interval satisfies the equation.
- So all \(x\) with \(-2 \leq x \leq 1\) are solutions.
Interval 3: \(x > 1\)
- \(1 - x < 0 \Rightarrow |1 - x| = x - 1\)
- \(x + 2 > 0 \Rightarrow |x + 2| = x + 2\)
Equation:
\[ (x - 1) + (x + 2) = 3 \]
Simplify:
\[ x - 1 + x + 2 = 3 \]
\[ 2x + 1 = 3 \]
\[ 2x = 2 \]
\[ x = 1 \]
Check if \(x = 1\) belongs to this interval \(x > 1\); no, it is at the boundary.
Final answer:
The solution set includes all \(x\) in the interval \(-2 \leq x \leq 1\), plus the boundary points considered.
Answer:
\[ \boxed{ x \in [-2, 1] } \]
This is the interval of solutions for the original equation.