To find the number of real roots of the equation
\[ 5 + |2^x - 1| = 2^x (2^x - 2), \]
we will analyze the equation by considering two cases based on the modulus function.
### Step 1: Consider Case 1: \( 2^x - 1 \geq 0 \)
In this case, we have:
\[ |2^x - 1| = 2^x - 1. \]
Thus, the equation becomes:
\[ 5 + (2^x - 1) = 2^x (2^x - 2). \]
Simplifying this gives:
\[ 5 + 2^x - 1 = 2^x (2^x - 2) \]
\[ 4 + 2^x = 2^{2x} - 2^{x + 1}. \]
Rearranging this, we get:
\[ 2^{2x} - 2^{x + 1} - 2^x - 4 = 0. \]
Let \( t = 2^x \). Then, substituting \( t \) into the equation gives:
\[ t^2 - 3t - 4 = 0. \]
### Step 2: Solve the Quadratic Equation
Now we will solve the quadratic equation:
\[ t^2 - 3t - 4 = 0. \]
Using the quadratic formula \( t = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a} \):
Here, \( a = 1, b = -3, c = -4 \):
\[ t = \frac{3 \pm \sqrt{(-3)^2 - 4 \cdot 1 \cdot (-4)}}{2 \cdot 1} \]
\[ t = \frac{3 \pm \sqrt{9 + 16}}{2} \]
\[ t = \frac{3 \pm 5}{2}. \]
This gives us two solutions:
1. \( t = \frac{8}{2} = 4 \)
2. \( t = \frac{-2}{2} = -1 \) (not possible since \( t = 2^x \) must be positive)
Thus, we have:
\[ t = 4 \Rightarrow 2^x = 4 \Rightarrow x = 2. \]
### Step 3: Consider Case 2: \( 2^x - 1 < 0 \)
In this case, we have:
\[ |2^x - 1| = -(2^x - 1) = 1 - 2^x. \]
Thus, the equation becomes:
\[ 5 + (1 - 2^x) = 2^x (2^x - 2). \]
Simplifying this gives:
\[ 6 - 2^x = 2^{2x} - 2^{x + 1}. \]
Rearranging this, we have:
\[ 2^{2x} - 2^{x + 1} + 2^x - 6 = 0. \]
Again, let \( y = 2^x \):
\[ y^2 - y - 6 = 0. \]
### Step 4: Solve the Quadratic Equation
Now we will solve the quadratic equation:
\[ y^2 - y - 6 = 0. \]
Using the quadratic formula:
Here, \( a = 1, b = -1, c = -6 \):
\[ y = \frac{-(-1) \pm \sqrt{(-1)^2 - 4 \cdot 1 \cdot (-6)}}{2 \cdot 1} \]
\[ y = \frac{1 \pm \sqrt{1 + 24}}{2} \]
\[ y = \frac{1 \pm 5}{2}. \]
This gives us two solutions:
1. \( y = \frac{6}{2} = 3 \)
2. \( y = \frac{-4}{2} = -2 \) (not possible since \( y = 2^x \) must be positive)
Thus, we have:
\[ y = 3 \Rightarrow 2^x = 3 \Rightarrow x = \log_2(3). \]
### Step 5: Check Validity of Solutions
- For Case 1, \( x = 2 \) is valid since \( x \geq 0 \).
- For Case 2, \( x = \log_2(3) \) is valid, but since \( \log_2(3) \) is approximately 1.585, it does not satisfy \( x \leq 0 \).
### Conclusion
The only valid solution is \( x = 2 \). Therefore, the number of real roots of the equation is:
**1 real root.**
---