原书出处
Introduction to Algorithms, Fourth Edition
31 第31章 数论算法
s are each relatively prime to an integer p, then their product is relatively prime to p.
Theorem 31.6 For any integers a, b, and p, we have gcd(ab, p) = 1 if and only if gcd(a, p) = 1 and gcd(b, p) = 1 both hold. Proof If gcd(a, p) = 1 and gcd(b, p) = 1, then it follows from Theorem 31.2 that there exist integers x, y, x′, and y′ such that ax + py = 1, bx′ + py′ = 1. Multiplying these equations and rearranging
gives ab(xx′) + p(ybx′ + y′ax + pyy′) = 1. Since 1 is thus a positive linear combination
原书定位详情
来源:a19c7933-4eda-4176-aebd-30fe7e1ad292
正文位置:extracted/Introduction to Algorithms, Fourth Edition/_epub-src/OEBPS/chapter031.xhtml
EPUB SHA-256:ec7ced04bb875b93983816aef7a667855a4b71c5cf53b63406b9439c74e27aea