How do you solve linear congruences?

Hi all,

So we just covered solving congruence's in my discrete 1 class. Our professor gave us 1 example in the notes, and to be honest it sucked and I don't understand it at all. Can someone explain to me how you solve this linear congruence(the one example she did in class)

Re: How do you solve linear congruences?

Can we assume that you know what "congruent modulo 27" means? Two numbers, x and y, are "congruent modulo 27" if and only if there difference, x- y, is a multiple of 27. Equivalently, if they have the same remainder when divided by 27.

Here, the problem is to find x such that 10x= 2 (mod 27). That is the same as saying that 10x= 27k+ 2 and that is the same as the "Linear Diophantine" equation 10x- 27k= 2.

So one solution is x= -16, k= -6. But adding any multiple of 27 to x and any multiple of 10 to k is also a solution:
10(-16+ 27n)- 27(-6+ 10n)= -160+ 270n-(-162+ 270n)= 2 for any integer n:
x= -16+ 27n, k= -6+ 10n. In particular, taking n= 1 gives x= -16+ 27= 11, the only solution lying between 0 and 27.