Solve Ax ≡ B mod C w/ Bezout's Identity

  • Context: High School 
  • Thread starter Thread starter TMO
  • Start date Start date
  • Tags Tags
    Turning
Join the discussion
Registration is free. Ask a follow-up in this thread, or start your own.
1 reply · 2K views
TMO
Messages
45
Reaction score
1
This is a very obvious question, but I am having trouble concentrating. Let ax ≡ b mod c and let gcd(a, c) | b. How do I convert this equation into Bezout's identity so that I can use the extended Euclidean algorithm?
 
Physics news on Phys.org
TMO said:
This is a very obvious question, but I am having trouble concentrating. Let ax ≡ b mod c and let gcd(a, c) | b. How do I convert this equation into Bezout's identity so that I can use the extended Euclidean algorithm?
You can divide by ##\operatorname{gcd}(a,b)## all three numbers to get ##a'x \equiv b' \operatorname{mod} c'## with now ##\operatorname{gcd}(a',b')=1## and use the Euclidean division to find ##1=na'+mb'##.

But somehow I'm not sure whether you meant this or something else.