It results that, for large integers, the computer time needed for a division is the same, up to a constant factor, as the time needed for a multiplication, whichever multiplication algorithm is used. Variants of these algorithms allow using fast multiplication algorithms. A recipe for making food is an algorithm, the method you use to solve addition or long division problems is an algorithm, and the process of folding a shirt or a pair of pants is an algorithm. Some are applied by hand, while others are employed by digital circuit designs and software. When you think of an algorithm in the most general way (not just in regards to computing), algorithms are everywhere. Newton–Raphson and Goldschmidt algorithms fall into this category. A division algorithm is an algorithm which, given two integers N and D, computes their quotient and/or remainder, the result of Euclidean division.
Fast division methods start with a close approximation to the final quotient and produce twice as many digits of the final quotient on each iteration.
Examples of slow division include restoring, non-performing restoring, non-restoring, and SRT division. Slow division algorithms produce one digit of the final quotient per iteration. Some are applied by hand, while others are employed by digital circuit designs and software.ĭivision algorithms fall into two main categories: slow division and fast division. For the division algorithm for polynomials, see Polynomial long division.Ī division algorithm is an algorithm which, given two integers N and D, computes their quotient and/or remainder, the result of Euclidean division.
For the theorem proving the existence of a unique quotient and remainder, see Euclidean division. For the pencil-and-paper algorithm, see Long division. This article is about algorithms for division of integers.