2
$\begingroup$

Calculate the modulo operations given below (without the usage of a calculator):

$101 \times 98 \mod 17 =$

$7^5 \mod 15 =$

$12^8 \mod 7 =$

$3524 \mod 63 =$

$−3524 \mod 63 =$

Ok with calculator I have no problem with it. However, I need to learn how can I compute them without calculator.

$\endgroup$
2
  • 1
    $\begingroup$ Are you familiar with the theorem that if $a \equiv b \pmod{n}$ and $c \equiv d \pmod{n}$, then $ac \equiv bd \pmod{n}$? $\endgroup$ Commented Nov 26, 2014 at 17:00
  • $\begingroup$ There are a lot of tricks, basically you want to multiply things out, taking multiple away as you go, eg. 7^5=(49^2)*7=(4^2)*7=16*7=7 (mod 15). In the last case, -3524 is minus the previous answer, so you almost get that one for free $\endgroup$ Commented Nov 26, 2014 at 17:01

3 Answers 3

1
$\begingroup$

By definition of modular arithmetic, $3524 \pmod{63}$ is the remainder when $3524$ is divided by $63$.

To find $-3524 \pmod{63}$, multiply your answer for $3524 \pmod{63}$ by $-1$. If you want a positive residue, add $63$ to this result.

For the product $101 \cdot 98 \mod{17}$, use the theorem that if $a \equiv b \pmod{n}$ and $c \equiv d \pmod{n}$, then $ac \equiv bd \pmod{n}$.

Since $101 = 5 \cdot 17 + 1$, $101 \equiv 16 \pmod{17}$. Since $98 = 5 \cdot 17 + 13$, $98 \equiv 13 \pmod{17}$. Thus,

$$101 \cdot 98 \equiv 16 \cdot 13 \equiv 208 \equiv 4 \pmod{17}$$

since $208 = 12 \cdot 17 + 4$.

However, you can simplify the calculations further if you use residues with absolute value at most $n/2$.

Since $101 = 6 \cdot 17 - 1$, $101 \equiv -1 \pmod{17}$. Since $98 = 6 \cdot 17 - 4$, $98 \equiv -4 \pmod{17}$. Thus,

$$101 \cdot 98 \equiv -1 \cdot -4 \equiv 4 \pmod{17}$$

which agrees with our previous result.

For $12^8 \pmod{7}$, observe that $12 \equiv 5 \pmod{7}$, so $12^8 \equiv 5^8 \pmod{7}$.

If $p$ is a prime modulus and $k \neq 0$, then $k^{p - 1} \equiv 1 \pmod{p}$. Hence, $5^6 \equiv 1 \pmod{7}$, so

$$12^8 \equiv 5^8 \equiv 5^65^2 \equiv 5^2 \equiv 4 \pmod{7}$$

For $7^5 \pmod{15}$, reduce modulo $15$ after you calculate each power. For instance,

$$7^2 \equiv 49 \equiv 4 \pmod{15}$$

so

$$7^3 \equiv 7 \cdot 7^2 \equiv 7 \cdot 4 \equiv 28 \equiv -2 \pmod{15}$$

Since you know the residues of $7^2 \pmod{15}$ and $7^3 \pmod{15}$, you can multiply their residues to find the residue of $7^5 = 7^2 \cdot 7^3$ modulo $15$. If you want a positive residue, add a suitable multiple of $15$.

$\endgroup$
1
$\begingroup$

Hint for the first one: $$101 \times 98 \mod 17 = (101 \mod 17) \times (98 \mod 17)$$ $$ = (16 \times 13) \mod 17$$

Similarly, for the third one, it can be simplified by turning $$12^8 \mod 7 =$$

The base has a residue of 5, and only multiplies with itself, so we only need the residue. As for the power, because its mod 7, we know that the answer has 6 possibilities (because its prime, it can be 0). It will cycle through these, in at most 6 steps, so we can remove the seven to simplify it. So, we subtract 6 from 8, and get $$=5^2 \mod 7$$ $$=25 \mod 7$$

$\endgroup$
5
  • $\begingroup$ These methods can always be used when multiplication, addition, or powers are larger than the modulo. $\endgroup$ Commented Nov 26, 2014 at 17:13
  • $\begingroup$ Just want to remind you, as you seem to be a new user, if you like an answer, give it a vote. $\endgroup$ Commented Nov 26, 2014 at 17:14
  • $\begingroup$ Thanks a lot you're right I am new. Here goes your acceptance. $\endgroup$ Commented Nov 26, 2014 at 17:16
  • $\begingroup$ Be careful. Since $7$ is prime, it does not have zero divisors. Therefore, there are only six possible residues for powers of $5$. As you can check, $5^6 \equiv 1 \pmod{7}$. Thus, $12^8 \equiv 5^8 \equiv 5^2 \equiv 4 \pmod{7}$. $\endgroup$ Commented Nov 26, 2014 at 17:17
  • $\begingroup$ @N.F.Taussig You are right, I appear to have erred. $\endgroup$ Commented Nov 26, 2014 at 17:18
0
$\begingroup$

Start by learning Fermat's little theorem, then move to the generalized version with Euler's totient function. After that, learn the Chinese remainder theorem.

$\endgroup$

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.