Difference between revisions of "Euclidean algorithm"
From Maths
(Created page with "'''Note:''' this is an algorithm for computing the GCD of two positive integers ==Definition== The algorithm is as follows<ref>The mathematics of ciphers, Number theory a...") |
(No difference)
|
Revision as of 08:52, 21 May 2015
Note: this is an algorithm for computing the GCD of two positive integers
Contents
[hide]Definition
The algorithm is as follows[1]:
Input | a,b∈N+, such that a≥b (swap them around if a<b) |
---|---|
Output | The GCD of a and b |
Process |
|
Proofs of correctness
TODO: These proofs
The algorithm terminates
Given this algorithm loops until R=0 it is important to know for certain that eventually we will have R=0
The algorithm computes the GCD
Equally important is the proof that the algorithm always outputs the GCD of a and b
References
- Jump up ↑ The mathematics of ciphers, Number theory and RSA cryptography - S. C. Coutinho