裴蜀定理

形式

\(a,b\in\mathbb{Z}\),那么对于 \(\forall x,y\in\mathbb{Z}\)\(\gcd(a,b)\mid a\times x+b\times y\)

此外,一定 \(\exists\,x,y \in \mathbb{Z}\),使得 \(a\times x+b\times y=\gcd(a,b)\) 成立。

证明

证明第一点:

\[\begin{array}{l} \because \gcd(a,b)\mid a,\gcd(a,b)\mid b\\ \therefore \gcd(a,b)\mid ax,\gcd(a,b)\mid by\,\,(x,y\in\mathbb{Z})\\ \therefore \gcd(a,b)=a\times x+b\times y \end{array} \]

证明第二点:

\(a\times x+b\times y\) 的最小正整数值为 \(r\),考虑证明 \(a\bmod r=0\)

\(p=\Big\lfloor\dfrac{a}{r}\Big\rfloor\),则可得 \(a\bmod r=a-p\times r\)​。

代入 \(r\),得到 \(a\bmod r=a-p\times(a\times x+b\times y)\)

进一步可得 \(a\times(1-p\times x)+b\times (-p\times y)\),这就是 \(ax'+by'\)​ 的形式。

因为 \(0\le a\bmod r<r\),且 \(r\)\(a\times x+b\times y\) 的最小正整数值,

所以 \(a\bmod r = 0\),即 \(r\)\(a\) 的因数。

同理可得 \(r\) 也是 \(b\) 的因数。

所以 \(r\)\(a,b\) 的公因数,即 \(r\mid\gcd(a,b)\)

又因为 \(a\times x+b\times y\) 都是 \(\gcd(a,b)\) 的倍数,所以 \(\gcd(a,b)\mid r\)

\(r=\gcd(a,b)\)

posted @ 2025-01-31 16:04  OIer_wst  阅读(28)  评论(0)    收藏  举报