Here's what the set up looks like...
1| 1 + 3 -1 - 31∣1+3−1−3
The 11 on the left is the "root" of the bottom, or the number that x would be to make it equal 00. Or you can just think of it is the opposite of the number after xx.
All of the numbers after are the coefficients in front of the powers of xx in decreasing order.
Now the process. Draw leave some space and draw a line underneath like so...
1| 1 + 3 -1 - 31∣1+3−1−3
-------−−−−−−−
Add down and multiply up diagonally by the number in the top left (I hope this makes sense)
1| 1 + 3 -1 - 31∣1+3−1−3
color(white)(Xll) 0color(white)(XXXXXXXXX)Xll0XXXXXXXXX<---<−−−start with a zero here
-------−−−−−−−
color(white)(Xll) 1color(white)(XXXXXXXXX)Xll1XXXXXXXXX <---<−−− add down
1| 1 + 3 -1 - 31∣1+3−1−3
color(white)(Xll) 0color(white)(llll) 1color(white)(XXXXXXX)Xll0llll1XXXXXXX<---<−−−multiply up by 1
-------−−−−−−−
color(white)(Xll) 1color(white)(Xl)4color(white)(XXXXXX)Xll1Xl4XXXXXX <---<−−− add down
Here's the rest:
1| 1 + 3 -1 - 31∣1+3−1−3
color(white)(Xll) 0color(white)(llll) 1color(white)(llla) 4color(white)(llla) 3Xll0llll1llla4llla3
-------−−−−−−−
color(white)(Xll) 1color(white)(Xl)4color(white)(iiia) 3 color(white)(iiia)0Xll1Xl4iiia3iiia0
Now use those numbers on the bottom as coefficients for a polynomial with degree one lower than the original numerator:
1x^2 + 4x + 3 + 0/(x-1)1x2+4x+3+0x−1 (this last term is the remainder, and this is how you write it)
Clean it up...
x^2 + 4x + 3x2+4x+3