# Math Help - Modular Arithmetic

1. ## Modular Arithmetic

I'm having a hard time understanding modular numbers and aritmetic.

If I have $r=a(\mod P)$, then $r-a=bP$ where $b$ is an integer. So if I want to find 23 in $\mod 12$, I write $r=23(\mod 12)$ which should turn out to be 11 right? So 23 is equal to 11 in $\mod 12$.

So if I want to find:
$r=26(\mod 12)$

I need to find r such that:
$r-26=b12$

where b is an integer and r is the smallest possible positve number satisfying the equation. Is this correct? 26 hours would bring us to 2 o-clock since 2 is the smallest positive integer such that $2-26=b12$ where $b$is an integer. So here, $b=-2$.
-----------------------------------------------------------------
One more example with a different mod that isn't so familiar:

$r=3(\mod 7)$

$r-3=b7$

So the smallest possible number seems to be 10 with $b=1$.

$10=3(\mod 7)$

where b is an integer.
------------------------------------------------------------------

Is my reasoning correct?

2. Originally Posted by adkinsjr
I'm having a hard time understanding modular numbers and aritmetic.

If I have $r=a(\mod P)$, then $r-a=bP$ where $b$ is an integer. So if I want to find 23 in $\mod 12$, I write $r=23(\mod 12)$ which should turn out to be 11 right? So 23 is equal to 11 in $\mod 12$.

So if I want to find:
$r=26(\mod 12)$

I need to find r such that:
$r-26=b12$

where b is an integer and r is the smallest possible positve number satisfying the equation. Is this correct? 26 hours would bring us to 2 o-clock since 2 is the smallest positive integer such that $2-26=b12$ where $b$is an integer. So here, $b=-2$.
-----------------------------------------------------------------
Your reasoning here is good.

$23\equiv 11\pmod{12}$ since $23\pmod{12}\equiv11+12\pmod{12}\equiv11+0\pmod{12} \equiv11\pmod{12}$

and

$26\equiv 2\pmod{12}$ since $26\equiv 24+2\pmod{12}\equiv 2(12)+2\pmod{12}\equiv 0+2\pmod{12}\equiv 2\pmod{12}$

One more example with a different mod that isn't so familiar:

$r=3(\mod 7)$

$r-3=b7$

So the smallest possible number seems to be 10 with $b=1$.

$10=3(\mod 7)$

where b is an integer.
------------------------------------------------------------------
In this case, $r=3\equiv3\pmod{7}$ is the smallest positive value. Can you try to reason out why?

3. Originally Posted by Chris L T521
Your reasoning here is good.

$23\equiv 11\pmod{12}$ since $23\pmod{12}\equiv11+12\pmod{12}\equiv11+0\pmod{12} \equiv11\pmod{12}$

and

$26\equiv 2\pmod{12}$ since $26\equiv 24+2\pmod{12}\equiv 2(12)+2\pmod{12}\equiv 0+2\pmod{12}\equiv 2\pmod{12}$

In this case, $r=3\equiv3\pmod{7}$ is the smallest positive value. Can you try to reason out why?
I'm not understanding this at all:

$23\equiv 11\pmod{12}$ since $\underbrace{23\pmod{12}\equiv11+12\pmod{12}\equiv1 1+0\pmod{12}\equiv11\pmod{12}}$

Your going through all of those steps I underbraced, where as I'm saying that $23=11(\mod 12)$ because 23 is the smallest number such that $23-11=b12$, where $b$ is an integer. In this case, -1. Any number in $0\leq x\leq23\$ will not give an integral multiple of twelve when I subtrace 11.

In this case, is the smallest positive value. Can you try to reason out why?
No, my reasoning wouldn't work here then. For $r=a(\mod P)$, I find $r$ such that $r$ is the smallest number such that $r-a=bP$

So if $3=3(\mod 7)$, then $3-3=b7$ therefore $b=0$. So if I have $r=11 (\mod 12)$, it seems that I could just as easily claim that this is equal to 11 since $11-11=b12$ with $b=0$ again.

4. I think you've got your definition backwards. You say "23= 11 (mod 12) because 23 is the smallest number such that 23- 11= b12, where b is an integer." No, 23= 11 (mod 12) because 11 is the smallest number such that 23- 11 is a multiple of 12. And, of course, 11= 11 (mod 12) because 11 is the smallest number such that 11- 11 is a multiple of 12.