Ruffini's Rule - Algorithm

Algorithm

The rule establishes a method for dividing the polynomial

by the binomial

to obtain the quotient polynomial

and a remainder s.

The algorithm is in fact the long division of P(x) by Q(x).

To divide P(x) by Q(x):

1. Take the coefficients of P(x) and write them down in order. Then write r at the bottom left edge, just over the line:

| an an-1 ... a1 a0 | r | ----|--------------------------------------------------------- | |

2. Pass the leftmost coefficient (an) to the bottom, just under the line:

| an an-1 ... a1 a0 | r | ----|--------------------------------------------------------- | an | | = bn-1 |

3. Multiply the rightmost number under the line by r and write it over the line and one position to the right:

| an an-1 ... a1 a0 | r | bn-1r ----|--------------------------------------------------------- | an | | = bn-1 |

4. Add the two values just placed in the same column

| an an-1 ... a1 a0 | r | bn-1r ----|--------------------------------------------------------- | an an-1+(bn-1r) | | = bn-1 = bn-2 |

5. Repeat steps 3 and 4 until no numbers remain

| an an-1 ... a1 a0 | r | bn-1r ... b1r b0r ----|--------------------------------------------------------- | an an-1+(bn-1r) ... a1+b1r a0+b0r | | = bn-1 = bn-2 ... = b0 = s |

The b values are the coefficients of the result (R(x)) polynomial, the degree of which is one less than that of P(x). The final value obtained, s, is the remainder. As shown in the polynomial remainder theorem, this remainder is equal to P(r), the value of the polynomial at r.

Read more about this topic:  Ruffini's Rule