Docsity

The Greatest Common Divisor and Groups Modulo N, Study notes of Introduction to Sociology

Partial preview of the text

Download The Greatest Common Divisor and Groups Modulo N and more Study notes Introduction to Sociology in PDF only on Docsity!

COMPUTATIONAL NUMBER THEORY

Notation

Z = {... , − 2 , − 1 , 0 , 1 , 2 ,.. .}

N = { 0 , 1 , 2 ,.. .}

Z+ = { 1 , 2 , 3 ,.. .}

d|a means d divides a

Example: 2 |4.

For a, N ∈ Z let gcd(a, N) be the largest d ∈ Z+ such that d|a and d|N.

Example: gcd(30, 70) =

Integers mod N

For N ∈ Z+, let

  • ZN = { 0 , 1 ,... , N − 1 }
  • (^) Z∗ N = {a ∈ ZN : gcd(a, N) = 1}
  • ϕ(N) = |Z∗ N |

Example: N = 12

  • (^) Z 12 = { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 }
  • Z∗ 12 =

Integers mod N

For N ∈ Z+, let

  • ZN = { 0 , 1 ,... , N − 1 }
  • (^) Z∗ N = {a ∈ ZN : gcd(a, N) = 1}
  • ϕ(N) = |Z∗ N |

Example: N = 12

  • (^) Z 12 = { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 }
  • Z∗ 12 = { 1 , 5 , 7 , 11 }
  • (^) ϕ(12) =

Division and mod

Fact: For any a, N ∈ Z with N > 0 there exist unique q, r ∈ N such that

  • a = Nq + r
  • (^0) ≤ r < N

Refer to q as the quotient and r as the remainder. Then

a mod N = r ∈ ZN

is the remainder when a is divided by N.

Def: a ≡ b (mod N) iff (a mod N) = (b mod N).

Examples:

  • If a = 17 and N = 3 then the quotient and remainder are q =? and r =?

Division and mod

Fact: For any a, N ∈ Z with N > 0 there exist unique q, r ∈ N such that

  • a = Nq + r
  • (^0) ≤ r < N

Refer to q as the quotient and r as the remainder. Then

a mod N = r ∈ ZN

is the remainder when a is divided by N.

Def: a ≡ b (mod N) iff (a mod N) = (b mod N).

Examples:

  • If a = 17 and N = 3 then the quotient and remainder are q = 5 and r = 2

Division and mod

Fact: For any a, N ∈ Z with N > 0 there exist unique q, r ∈ N such that

  • a = Nq + r
  • 0 ≤ r < N

Refer to q as the quotient and r as the remainder. Then a mod N = r ∈ ZN is the remainder when a is divided by N.

Def: a ≡ b (mod N) iff (a mod N) = (b mod N).

Examples:

  • (^) If a = 17 and N = 3 then the quotient and remainder are q = 5 and r = 2
  • 17 mod 3 = 2
  • (^17) ≡ 14 (mod 3)

Division and mod

Fact: For any a, N ∈ Z with N > 0 there exist unique q, r ∈ N such that

  • a = Nq + r
  • 0 ≤ r < N

Refer to q as the quotient and r as the remainder. Then a mod N = r ∈ ZN is the remainder when a is divided by N.

Def: a ≡ b (mod N) iff (a mod N) = (b mod N).

Examples:

  • (^) If a = 17 and N = 3 then the quotient and remainder are q = 5 and r = 2
  • 17 mod 3 = 2
  • (^17) ≡ 14 (mod 3) because 17 mod 3 = 14 mod 3 = 2

Groups

Let G be a non-empty set, and let · be a binary operation on G. This means that for every two points a, b ∈ G , a value a · b is defined.

We say that G is a group if it has the following properties: 1 Closure: For every a, b ∈ G it is the case that a · b is also in G. 2 Associativity: For every a, b, c ∈ G it is the case that (a · b) · c = a · (b · c). 3 Identity: There exists an element 1 ∈ G such that a · 1 = 1 · a = a for all a ∈ G. 4 Invertibility: For every a ∈ G there exists a unique b ∈ G such that a · b = b · a = 1. The element b in the invertibility condition is referred to as the inverse of the element a, and is denoted a−^1.

ZN under MOD-ADD

Fact: Let N ∈ Z+. Then ZN is a group under addition modulo N. Addition modulo N: a, b 7 → a + b mod N

ZN under MOD-ADD

Fact: Let N ∈ Z+. Then ZN is a group under addition modulo N.

Example: Let N = 12, so ZN = Z 12 = { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 }

Closure: a, b ∈ ZN ⇒ a + b mod N ∈ ZN. Check: 9 + 7 mod 12 = 16 mod 12 = 4 ∈ Z 12

ZN under MOD-ADD

Fact: Let N ∈ Z+. Then ZN is a group under addition modulo N.

Example: Let N = 12, so ZN = Z 12 = { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 }

Associative: ((a + b mod N) + c) mod N = (a + (b + c mod N)) mod N

Check:

(9 + 7 mod 12) + 10 mod 12 = (16 mod 12) + 10 mod 12 = 4 + 10 mod 12 = 2

9 + (7 + 10 mod 12) mod 12 = 9 + (17 mod 12) mod 12

= 9 + 5 mod 12 = 2

ZN under MOD-ADD

Fact: Let N ∈ Z+. Then ZN is a group under addition modulo N.

Example: Let N = 12, so ZN = Z 12 = { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 }

Inverse: ∀a ∈ ZN ∃a−^1 ∈ Z∗ N such that a + a−^1 mod N = 0.

Check: 9 −^1 is the x ∈ Z 12 satisfying

9 + x ≡ 0 (mod 12)

so x =

ZN under MOD-ADD

Fact: Let N ∈ Z+. Then ZN is a group under addition modulo N.

Example: Let N = 12, so ZN = Z 12 = { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 }

Inverse: ∀a ∈ ZN ∃a−^1 ∈ Z∗ N such that a + a−^1 mod N = 0.

Check: 9 −^1 is the x ∈ Z 12 satisfying

9 + x ≡ 0 (mod 12)

so x = 3