Projects
Concepts
- Complex numbersused by 3Numbers a + bi and the geometry of the complex plane.
- Euclidean algorithmused by 2Computes gcd(a, b) by repeated division; the extended version also finds Bezout coefficients.
- Modular arithmeticused by 1Arithmetic on remainders, including congruences, modular inverses and Fermat's little theorem.
- Modular exponentiationused by 2Computes a^b mod m with O(log b) multiplications by repeated squaring.
- Prime sievesused by 1The sieve of Eratosthenes and its segmented variant for listing primes.
- Primality testingused by 2Deciding whether n is prime, by trial division or probabilistic tests such as Miller-Rabin.
- Euler's totient functionused by 1phi(n) counts the integers from 1 to n that are coprime to n.
- Arithmetic functionsused by 1Functions on the positive integers, such as the divisor function and sums over divisors.
- Linear recurrencesused by 1Sequences such as Fibonacci defined by linear rules, computed quickly by matrix exponentiation.
- Finite fieldsused by 1Fields with finitely many elements, such as GF(2^8), the field used inside AES.
- Arbitrary-precision arithmeticused by 1Integer arithmetic on numbers larger than a machine word, as needed for RSA.
- Golden ratioused by 2phi = (1 + sqrt 5) / 2; its continued fraction [1; 1, 1, ...] makes it the hardest number to approximate by fractions.
