Posts

Showing posts with the label miller rabin test

Number-Theoretic Algorithms for Cryptography & Modular Arithmetic | Chapter 31 in Introduction to Algorithms

Image
Number-Theoretic Algorithms for Cryptography & Modular Arithmetic | Chapter 31 in Introduction to Algorithms Chapter 31 of Introduction to Algorithms explores foundational number-theoretic algorithms that power modern cryptography, modular arithmetic, and primality testing. From computing greatest common divisors to understanding public-key encryption like RSA, this chapter equips readers with the mathematical tools that underpin secure communication and cryptographic protocols. Watch the video above for a guided podcast-style summary of the chapter, and subscribe to Last Minute Lecture for more algorithm-focused textbook breakdowns every week. Core Number-Theoretic Concepts The chapter begins by reviewing the basics of number theory: Divisibility: d divides a if a = kd for some integer k Primes: Only divisible by 1 and themselves Greatest Common Divisor (gcd): The largest integer dividing two numbers Modular Equivalence: a ≡ b (mod n) if a and b hav...