You asked how to do it so I am explaining the process:
You divide the sequential xx parts in the numerator into sequential xx parts of the denominator. Each stage leaves a remainder for which the process is repeated.
Demonstration within the context of this question.
color(green)("==============================")==============================
Step 1: 4x^3 divide x = 4x^24x3÷x=4x2
Used the 4x^34x3 from 4x^3+2x-64x3+2x−6 and the xx from x-1x−1
So the color(red)("first")first part of your answer is color(blue)(4x^2)4x2
color(green)("============================")============================
Step 2: Find the remainder
4x^2 times (x-1) = 4x^3 - 4x4x2×(x−1)=4x3−4x
This is then subtracted so we have:
4x^3 + 2x -64x3+2x−6 .......Original equation
(4x^3 -4x) -(4x3−4x)− ...... Subtract
~~~~~~~~~~~~~
color(white)("xxxxxx") 6x - 6xxxxxx6x−6. This is the first remainder
color(green)("=================================")=================================
Step 3.
Again divide the 6x6x in the previous remainder by the xx in x-1x−1 giving 66.
So the color(red)("second")" "second part of the answer is color(blue)(+6)+6
6(x-1) =6x-66(x−1)=6x−6 which is subtracted from the most recent remainder giving:
4x^3 + 2x -64x3+2x−6 .......Original equation
(4x^3 -4x) -(4x3−4x)− ...... Subtract
~~~~~~~~~~~~~
color(white)("xxxxxx") 6x - 6xxxxxx6x−6. This is the remainder
color(white)("xxxxxx") ( 6x - 6) -xxxxxx(6x−6)−. Subtract
~~~~~~~~~~~~~~~~~~~~~~~~~~
color(white)("xxxxxxx") 0 + 0" "xxxxxxx0+0 which is the second remainder.
The zeros mean that we have an exact division
In this case
(4x^3 +2x-6)/(x-1) =4x^2+64x3+2x−6x−1=4x2+6
Suppose we had ended up with a remainder that the x " in " (x-1)x in (x−1) could not be divided into. In that case we would express the whole of that remainder as a fraction with (x-1)(x−1) as the denominator.
Suppose that had ended up with a remainder of just 2. Then in that case the answer would be:
4x^2 + 2/(x-1) + 64x2+2x−1+6
Hope this helps. It takes a lot of practice.