Modullar arithmetics (mods)


1.0 The very basics

counting in mod 5 would look like this 0,1,2,3,4,0,1,2,3,4,0,1,2,3...
suppose you are asked to find what is equal to 18 mod 6 . we could count

mod 6 0 1 2 3 4 5 0 1 2 3 4 5 0 1 2 3 4 5 0
counting 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18


but that would take us too long.
here is a way of doing it without counting:
we find the largest number that when multiplyed by 6 will give us a result of 18 or less. Then we substract what we got from 18, and thats the answer.
in this case; 6*3 = 18 and 18-18 = 0

so 18 mod 6 is equals 0

notice that in the question what is equal to y mod x, if y is a multiple of x the answer is always 0.

expample:what is equal to 47 mod 7?
solution: since 47 is a multiple of 7 (7*7=49), the answer is 0.
Answer: 47 mod 7 equals to 0

example:what is 16 mod 3?
solution: 3*5=15, 16-15 = 1
answer: 16 mod 3 is equal to 1

exs:find the smallest number that is equal to 132 mod 9
exs: write down some numbers which are equal to 4 mod 7
exs:How many integers are there between 50 and 250 exclusive which are equal to 1 mod 8?
exs:which numbers are equal to 0 mod 4?

More will be added soon!!