# Doesn't polynomial long division violate the general rules of division?

Doesn't polynomial long division violate the general rules of division? As we don't divide each term in the numerator by the whole denominator (like with the division of the real numbers), what we do is dividing each term in the numerator (starting from the highest power term till the lowest power term) by the highest power term only in the denominator ignoring the other terms. How does this style of division succeed?

I searched many websites like Quora and even this site but no one has discussed this point which I consider it as a violation of division rules. Could anyone clarify this point to me? Thanks in advance.

• Your error seems to be in the phrase "ignoring the other terms". Those other terms are retained and determine much of what you do at the next step and later in the computation. – Andreas Blass Apr 25 '20 at 13:40
• But how can I multiply by terms which I did not use in the division step ? I know that in long division of real numbers we multiply the quotient by the divisor which we divide by in the division step, but in polynomials we don't do that, in division step we divide by one term (the highest power term) but in multiplication step we multiple the quotient by all terms in the divisor, isn't that different from the long division of real numbers? – kareem mohamed Apr 26 '20 at 11:31
• Your question now has several good, detailed answers. They seem to be enough to explain your error completely. – Andreas Blass Apr 26 '20 at 12:51
• OK, thank you so much sir, i really appreciate your help – kareem mohamed Apr 26 '20 at 15:15

Dividing $$3x^4 + 2x^3 + 6x^2 + 8x + 4$$ by $$x^3+2x+1$$ to obtain $$3x+2$$ remainder $$x+2$$ works exactly the same way you do long division with numbers to find that $$32684$$ divided by $$1021$$ is $$32$$ remainder $$12$$. Just compare the steps in detail and there is no real difference.

You can view it this way: We have polynomials $$f(x)$$ and $$g(x)$$. We want to find polynomials $$q(x)$$ and $$r(x)$$ such that $$\tag1 f(x)=q(x)g(x)+r(x).$$ Well, that's trivial: Just take $$q(x)=0$$ and $$r(x)=f(x)$$. Okay, so we want something better: We want $$\deg r$$ to be as small as possible. Can we improve upon the trivial solution $$q=0, r=f$$? We can replace $$q(x)$$ with $$q(x)+cx^d$$ and $$r(x)$$ with $$r(x)-cx^dg(x)$$ without destroying the equality $$(1)$$. And as long as $$\deg r\ge deg g$$, we can let $$d=\deg r-\deg g$$ and $$c$$ the quotient of their leading coefficients and - voila! - we have another solution to $$(1)$$ but the new $$r$$ has lower degree. If we continue this, we will ultimately obtain a solution where $$\deg r<\deg g$$ and $$(1)$$ still holds.

• I don't know how can I thank you, thank you so much sir, i really appreciate your help – kareem mohamed Apr 26 '20 at 15:13

The only general rule of division is that it must be precisely reversible by multiplication. So $$2020 \div 50$$ is $$40.4$$ because $$40.4 \times 5 = 2020.$$ Doing division with integer remainder, $$2020 \div 11$$ is $$183$$ with remainder $$7$$ because $$11 \times 183 + 7 = 2020.$$

Now, recalling what the meaning of a decimal number is, we have \begin{align} 2020 &= 2 (10^3) + 0(10^2) + 2(10) + 0,\\ 11 &= 1(10) + 1, \end{align}

where the right-hand sides of these equations look a lot like $$2x^3 + 0x^2 + 2x + 0$$ and $$x + 1$$ where $$x = 10.$$

Let's see what happens if we try dividing $$2x^3 + 0x^2 + 2x + 0$$ by $$x + 1$$.

$$\require{enclose} \begin{array}{r} 2x^2 - 2x + 4 \\[-3pt] x + 1 \enclose{longdiv}{2x^3 + 0x^2 + 2x + 0} \\[-3pt] \underline{2x^3 + 2x^2}\phantom{{} + 2x + 0} \\[-3pt] -2x^2 + 2x \phantom{{} + 0} \\[-3pt] \underline{-2x^2 - 2x}\phantom{{} + 0} \\[-3pt] 4x + 0 \\[-3pt] \underline{4x + 4} \\[-3pt] -4 \end{array}$$

So the result of $$(2x^3 + 0x^2 + 2x + 0) \div (x + 1)$$ is $$2x^2 - 2x + 4$$ with remainder $$-4.$$ This obeys the general requirements of division with remainder, because $$(x + 1) \times (2x^2 - 2x + 4) + (-4) = 2x^3 + 0x^2 + 2x + 0.$$

Now let's compare this to the usual evaluation of $$2020\div 11$$ by long division.

Keep in mind first of all that just because two algorithms arrange their parts in somewhat similar ways on the paper does not mean that they must be the same algorithm. There is a "long division" algorithm for taking square roots, for example, that works like long division in some ways (writing one digit of the result at a time, using that one digit to form a product, and subtracting that product from the leftmost several digits of something else).

With that in mind, let's see how the usual long division of $$2020\div 11$$ differs from long division of $$2x^3 + 0x^2 + 2x + 0$$ by $$x + 1.$$

For one thing, we assume that $$x = 10.$$ This is a somewhat arbitrary decision, and in fact we could choose differently. For example, we could be doing division problems in base $$5,$$ in which case the string of digits $$2020$$ actually means $$2(5^3) + 2(5),$$ that is, we would assume that $$x = 5.$$

For another thing, we forbid the coefficient of any term of any polynomial to be negative. For example, we don't allow a number to be written $$2(10^2) - 2(10) + 4,$$ even though that is a perfectly good polynomial over the number $$10.$$ Again this is a somewhat arbitrary restriction, since there are "balanced" bases in which digits can have negative values.

A consequence of these restriction is that the remainder cannot be negative.

For another thing, we forbid the coefficient of any term to be greater than $$9.$$ For example, $$1(10^2) + 11$$ is ruled out even though it is a perfectly good polynomial over $$10.$$

We also forbid any coefficient to be anything except an integer. Try dividing $$3x^2 + 5x + 1$$ by $$2x + 3$$ without using non-integers such as $$\frac32$$ in the result.

Furthermore, we apply all these restrictions not just to the input and output expressions, but to all expressions at all steps within the computation. In the division of $$2x^3 + 0x^2 + 2x + 0$$ by $$x + 1,$$ for example, the step where we subtract $$2x^3 + 2x^2$$ from $$2x^3 + 0x^2$$ is not allowed, because $$-2x^2$$ has a negative coefficient.

In order to make all of this possible, we apply a trick that is not available to us in polynomial long division: we take advantage of the assumption that $$x = 10$$ in order to change the coefficients. For example, instead of writing $$2(10^3) - 2(10^2)$$ we would write $$1(10^3) + 8(10^2).$$ The reason we cannot apply this "trick" in polynomial long division is that $$2x^3 - 2x^2 \neq x^3 + 8x^2$$ in general. The use of this trick means that the results of the division are often valid only in the same numeric base in which they were performed; if you want to know the result of $$2020\div 11$$ in base $$5$$ or base $$16,$$ the base-$$10$$ result is not very useful.

We also find that certain techniques that we can use in polynomial long division have to be modified in order to stay within all these extra restrictions. Sometimes this means you practically have to do a step by trial and error--for example, what is the correct one-digit quotient when dividing $$691$$ by $$173$$? It is not $$6$$ (from $$6\div 1$$). And we might guess that $$5$$ is too large, but what about $$4$$? If the numbers are large enough you may find it useful to work out the possible multiples of the divisor in a separate area on the page in order to figure out which digits you can write in each step.

So you may say that polynomial long division breaks the "rules" because it does not obey the arbitrary additional restrictions that we enforce when we do long division of decimal-system numerals in the usual way. But I could equally well say that the usual long division algorithm breaks the "rules" of polynomial long division in order to get an artificially constrained result that is not even correct as a general polynomial, only when everything is evaluated at $$x = 10.$$

Or we could say that there are enough similarities between the algorithms to justify calling both of them some kind of "long division" (just as the much more different square-root algorithm also is called a "long division" algorithm), but that the algorithms also are different because they were meant to solve different problems with different constraints on the results.

• I don't how can I thank you , you gave me information that i have never known , no one before you told me that these algorithms have the same name but different techniques as they were invented to solve different problems with different constraints , thank you so much sir, I really appreciate your help. – kareem mohamed Apr 26 '20 at 14:48

You need to understand that when we do polynomial division, we mean exactly what we mean when we do integer division. Suppose you want to divide $$384$$ by $$25.$$ Then this is the same as subtracting as many copies of $$25$$ as you can from $$384.$$ Whatever is left is the remainder. You can see that this is simply a problem in multiplication and subtraction. Now, you can do this anyhow, but we usually split our integers in digital multiples of nonnegative integer powers of $$10,$$ like $$300+80+4.$$ Then you can see that $$25$$ goes $$12$$ times in the first part, and $$3$$ times in the second. The remainder is $$9.$$ This is what we do with the long division method usually taught to schoolchildren.

Now come to polynomials. Given two polynomials $$p$$ and $$d,$$ so that $$p$$ has a higher degree, we want to see how many times $$d$$ divides into $$p,$$ and then note the remainder, which will be necessarily of lower degree than $$d.$$ We're concerned with degrees here because it indicates the rough size of the polynomial when the variable is large enough. Now consider the example of trying to divide $$x^2+2x-4$$ by $$x+2.$$ Then we want to subtract as many multiples of the divisor from the dividend as we can. You can see in this case that no constant multiple will be large enough. So we take the next higher multiple of the divisor, namely $$x(x+2),$$ which works since it reduces the dividend by one degree. Then we subtract this from $$x^2+2x-4$$ to see what remains, which is $$-4$$ in this case, which is of lesser degree than the divisor, so that our work is complete. So the quotient is $$x.$$

In general we subtract as many copies of $$d$$ as needed from $$p$$ until we can no longer do so. So, if $$p$$ is of degree $$m$$ and $$d$$ of degree $$n,$$ with $$n\le m,$$ then we see that we can take as many as $$x^{m-n}$$ copies of $$d$$ from $$p,$$ provided all polynomials here are monic (otherwise use an appropriate constant coefficients). Then we now have the remainder $$p-x^{m-n}d,$$ whose degree is now less than that of $$p.$$ If its degree is greater than that of $$d,$$ we continue in this way until the degree of the remainder is less than that of $$d.$$ Let this remainder of degree $$ be denoted by $$r,$$ then we eventually have something of the form $$p-x^{m-n}d-c_1x^{m-k}d-\cdots-c_kx^{n}d=r,$$ so that factoring $$d$$ out and rearranging, we have $$p=dq+r,$$ where $$q=x^M+\sum c_kx^i,$$ with $$M=m-n.$$

Hope this helps!

• I don't know how can I thank you , thank you so much sir, i really appreciate your help, you have clarified many ambiguous points to me, but i to inquire about something, Why did you add other terms like (-dc1x^m-k) to this expression (p-dx^m-n) to equalize it to the remainder, isn't (p-dx^m-n) alone without adding any other expression equal to the remainder ? – kareem mohamed Apr 26 '20 at 15:11
• @kareemmohamed Yes, it is the remainder, but if it can still be divided by $d,$ then you continue until you can no longer divide. Consider the numerical example $300+80+4.$ If you divide the $300$ by $25,$ the remainder is now $80+4.$ But since this is bigger than $25,$ repeat the process, until you can no longer do it. – Allawonder Apr 26 '20 at 16:48
• I don't know how can I thank you, you gave me information that i had never known, no one before you clarified polynomial long division like that to me, thank you so much sir, i really appreciate your help. – kareem mohamed Apr 27 '20 at 0:01