image
Physics Forums Logo
image
image
* Register * Upgrade Blogs Library Staff Rules Mark Forums Read
image
image   image
image

image congruence Share It Thread Tools Search this Thread image
Old Apr3-09, 12:37 AM                  #1
quasar987
 
quasar987's Avatar

quasar987 is Offline:
Posts: 3,950
Recognitions:
PF Contributor PF Contributor
Homework Helper Homework Helper
congruence

Given n and m positive integers, how can I find all the solutions to na=0 (mod m)??
  Reply With Quote
Old Apr3-09, 07:45 AM                  #2
ThirstyDog

ThirstyDog is Offline:
Posts: 33
Re: congruence

If na = 0 (mod m) then na = km for some k. To find all a consider d = gcd(n,m), if we let a = m/d * l for l any positive integer then a is guaranteed to be an integer as d divides m and as d divides n we must have na = m * (n*l/d) which implies na is a integer multiple of m.

I assume that a = m/d is the smallest a allowed as d is the greatest common divisor and I don't want to think of a proof.
  Reply With Quote
Old Apr3-09, 07:51 AM       Last edited by ramsey2879; Apr3-09 at 08:16 AM.. Reason: correction            #3
ramsey2879

ramsey2879 is Offline:
Posts: 546
Blog Entries: 2
Re: congruence

solve an = mt

PS the congruence relation m/n does not work since n does not have to be a divisor of m, eg 11/5 = 9 mod n since 9*5 = 1 mod n, but the congruence relation m/gcd(m,n)*t mod m works. as m/1 is the solution for a in that case. (Re the t If a = 2 is a solution to m = 14, n = 7 so are 4,6,8,10.12 and 14)

Sorry but Thirsty Dog gave the correct solution before me.
  Reply With Quote
Old Apr3-09, 11:18 AM                  #4
quasar987
 
quasar987's Avatar

quasar987 is Offline:
Posts: 3,950
Recognitions:
PF Contributor PF Contributor
Homework Helper Homework Helper
Re: congruence

Thanks for the reply guys.

However, I had already figured out that all elements of the form a = m/d * l (ThirstyDog's notation) are solutions. What remains for me to do is prove that these are the only solutions.

Also, I actually only interested in solutions mod m... that is, solutions such that LaTeX Code: 1\\leq a \\leq m .
  Reply With Quote
Old Apr3-09, 01:11 PM                  #5
quasar987
 
quasar987's Avatar

quasar987 is Offline:
Posts: 3,950
Recognitions:
PF Contributor PF Contributor
Homework Helper Homework Helper
Re: congruence

Ok, I found the solution in a book.

Write m=pd and n=qd (where d=gcd(m,n)) and notice that p and q are relatively prime, otherwise, d would not be the greatest common divisor of m and n.

And then it's easy: we have that m|an <==>pd|aqd <==>p|aq <==> p|a.

So the solutions are all the multiples of p.
  Reply With Quote
image image
Reply
Thread Tools


Similar Threads for: congruence
Thread Thread Starter Forum Replies Last Post
Congruence [Aqua] Linear & Abstract Algebra 1 Mar25-08 01:38 PM
Congruence [Aqua] General Math 0 Mar18-08 01:51 PM
Congruence Firepanda Precalculus Mathematics 3 Nov12-07 10:01 AM
Congruence... eljose Number Theory 2 Aug6-06 09:28 PM
congruence help katatonia Number Theory 5 Apr8-05 09:08 PM

Powered by vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd. © 2009 Physics Forums
Sciam | physorgPhysorg.com Science News Partner
image
image   image