返回题库

不定方程 3x+7y=10000 的通解

Full Solutions

专题
General / 综合
难度
L2

题目详情

求所有整数解 (x,y)(x,y) 使得 3x+7y=100003x+7y=10000

所有解可写为 x=a+7nx=a+7ny=b3ny=b-3nnn 为任意整数),其中 bb 为最小正整数。求 abab

Find all pairs of integers (x,y)(x,y) such that 3x+7y=100003x + 7y = 10000. All of the solutions can be written in the form x=a+7nx = a + 7n and y=b3ny = b - 3n, where nn is any arbitrary integer and a,ba,b are integers such that bb is a minimal positive integer. Find abab.

解析

利用 3(2)+7(1)=13(-2)+7(1)=1,乘以 10000 得一个解 (20000,10000)(-20000,10000)

通解为

(x,y)=(20000+7n, 100003n).(x,y)=(-20000+7n,\ 10000-3n).

m=n3333m=n-3333,可改写为

(x,y)=(3331+7m, 13m),(x,y)=(3331+7m,\ 1-3m),

此时 b=1b=1 最小正,故 ab=3331ab=3331


Original Explanation

Since 33 and 77 are clearly relatively prime, there must exist a solution to this equation. We note that 3(2)+7(1)=13(-2) + 7(1) = 1, so if we multiply by 1000010000 on both sides, 3(20000)+7(10000)=100003(-20000) + 7(10000) = 10000, which means (x,y)=(20000,10000)(x,y) = (-20000,10000) is a solution to this equation. By the latter hint, we can write all solutions to this equation in the form (20000+7n,100003n)(-20000 + 7n, 10000 - 3n).

We now need to reduce this equation so that the integer in front of 3n-3n is as small as possible. We note that 9999=333339999 = 3 \cdot 3333, so we note that if m=n3333m = n - 3333, we can rewrite the form of solutions as (20000+7(m+3333),100003(m+3333))=(3331+7m,13m)(-20000 + 7(m + 3333), 10000 - 3(m + 3333)) = (3331 + 7m, 1 - 3m).

This is the general form where bb is as small as possible but possible. In particular ab=3331ab = 3331.