Factor by grouping
x^3+x^2-x-1 =[x^3+x^2]+[-x-1]x3+x2−x−1=[x3+x2]+[−x−1]
The first bracket has a common factor of x^2x2 and the second bracket has a common factor of -1−1. take those out to get:
x^3+x^2-x-1 = x^2[x+1] color(red)(+) (-1)[x+1]x3+x2−x−1=x2[x+1]+(−1)[x+1]
Now we have two terms, one on each side of the red color(red)(+) +.
Each term has a factor (in brackets) of [x+1][x+1]. Tlhat is a common factor, so we can factor it out:
x^3+x^2-x-1 = x^2[x+1] color(red)(+) (-1)[x+1]x3+x2−x−1=x2[x+1]+(−1)[x+1]
color(white)"ssssssssssssssssss"ssssssssssssssssss =( x^2 color(red)(+) (-1))[x+1]=(x2+(−1))[x+1]
color(white)"ssssssssssssssssss"ssssssssssssssssss =( x^2 - 1)(x+1)=(x2−1)(x+1)
x^3+x^2-x-1 = ( x^2 - 1)(x+1)x3+x2−x−1=(x2−1)(x+1)
Are we finished or can anything be factored more?
x^2-1x2−1 is a difference of twp squares, so we can factor it.
x^3+x^2-x-1 = ( x+1)(x - 1)(x+1)x3+x2−x−1=(x+1)(x−1)(x+1)
Now we are finished.