Let's perform long division to divide \(x^3 + 5x^2 + 8x + 4\) by \(x + 2\).
Step 1: Setup the division
We are dividing: \[ \begin{array}{r|l} x + 2 & x^3 + 5x^2 + 8x + 4 \ \end{array} \]
Step 2: Divide the leading terms
Divide the leading term \(x^3\) by the leading term \(x\): \[ \frac{x^3}{x} = x^2 \]
Step 3: Multiply and subtract
Now, multiply \(x^2\) by \(x + 2\) and subtract from the original polynomial: \[ x^2(x + 2) = x^3 + 2x^2 \]
Subtract: \[ (x^3 + 5x^2 + 8x + 4) - (x^3 + 2x^2) = (5x^2 - 2x^2) + 8x + 4 = 3x^2 + 8x + 4 \]
So far, we have: \[ \begin{array}{r|l} x + 2 & x^3 + 5x^2 + 8x + 4 \ & - (x^3 + 2x^2) \ \hline & 3x^2 + 8x + 4 \ \end{array} \]
Step 4: Repeat the process
Now we continue with \(3x^2 + 8x + 4\).
Divide \(3x^2\) by \(x\): \[ \frac{3x^2}{x} = 3x \]
Multiply \(3x\) by \(x + 2\) and subtract: \[ 3x(x + 2) = 3x^2 + 6x \]
Subtract: \[ (3x^2 + 8x + 4) - (3x^2 + 6x) = (8x - 6x) + 4 = 2x + 4 \]
So far, we have: \[ \begin{array}{r|l} x + 2 & x^3 + 5x^2 + 8x + 4 \ & - (x^3 + 2x^2) \ \hline & 3x^2 + 8x + 4 \ & - (3x^2 + 6x) \ \hline & 2x + 4 \ \end{array} \]
Step 5: Repeat again
Now we continue with \(2x + 4\).
Divide \(2x\) by \(x\): \[ \frac{2x}{x} = 2 \]
Multiply \(2\) by \(x + 2\) and subtract: \[ 2(x + 2) = 2x + 4 \]
Subtract: \[ (2x + 4) - (2x + 4) = 0 \]
So we have: \[ \begin{array}{r|l} x + 2 & x^3 + 5x^2 + 8x + 4 \ & - (x^3 + 2x^2) \ \hline & 3x^2 + 8x + 4 \ & - (3x^2 + 6x) \ \hline & 2x + 4 \ & - (2x + 4) \ \hline & 0 \ \end{array} \]
Final Result:
The division is complete, and the result is: \[ x^2 + 3x + 2 \]
Answer: \(x^2 + 3x + 2\)