Module 2 - SC
Module 2 - SC
SECURE COMMUNICATION
EN
4. Finite Fields of the Eform
A GF(p)
5.Polynomial arithmetic
, KM
E
C
,P E
.,A
R
A.
ara
ush
B
Bushara A R
AP, ECE
KMEA ENGG.COLLEGE
E
EG
LL
O
1. Groups,Rings and Fields C
G
G
EN
A
➢ Groups, rings, and fields are M
E the fundamental elements
K
of a branch of mathematics E, known as abstract
EC
algebra, or modern algebra.
P,
.,A
R
A.
Groups ra
a
sh
A group G, sometimes
Bu ·
denoted by {G, } is a set of elements
Examples of Field:
● Rational Numbers
● Real Numbers
● Complex Numbers
–
–The remainder, r, is often referred to as a
residue of modulo n, and is the smallest
non-negative integer that differs from m by a
multiple of n.
For example,
0,1…..6
5 mod 3
-5 mod 3
5 mod -3
E
G
-5 mod -3 E
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
•Two integers, a and b are said to be
congruent (denoted by ) if:
amod m=b
that is, "a is congruent to b modulo m"
•Alternatively, in arithmetic modulo m, a
and b are equivalent if their difference, (a -
b), is a multiple of m; that is, m | (EaGE - b)
LL
O
C
G
G
EN
EA
•The set of integers Z , KM= {0,1, ... m - 1} form
m E
C
the complete set of P, residues modulo m --
E
, A
R.
there are only m different
A. integers, mod m
ra
a
•The operation ush a mod m denotes the residue
B
of a, such that the residue is some integer
from 0 to m - 1. This operation is known as a
modular reduction.
Example:
10 mod 4 = 2
•Properties of modular arithmetic is:
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
5 mod 6 = 5
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
•Recall that exponentiation is defined:
sha
Bu
EUCLID(a, b)
1. A ← a; B ← b
2. if B = 0 return A = gcd(a, b)
3. R = A mod B
4. A ← B
5. B ← R
6. goto 2 E
EG
LL
O
C
To find gcd(1970, 1066) G
G
EN
A B EA R
KM
1970 1066
E, 904
C
1066 AP, 904
E
162
.,
904 A . R 162 94
a
162shar 94 68
u
94B 68 26
68 26 16
26 16 10
16 10 6
10 6 4
6 4 2
4 2 0
HOME WORK
a. Determine gcd(24140, 16762).
b. Determine gcd(4655, 12075).
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
4. Finite Fields of the form GF(p)
EXTENDED EUCLID(m, b)
1. (A1, A2, A3) ← (1, 0, m);
(B1, B2, B3) ← (0, 1, b)
2. if B3 = 0 return A3 = gcd(m, b); no inverse
3. if B3 = 1 return B3 = gcd(m, b);
E
G
B2 ← M.I of b mod m LL
E
O
4. Q = A3 / B3 G
C
G
5. (T1, T2, T3) = (A1 - QB1, AA2
EN - QB2, A3 - QB3)
E
6. (A1, A2, A3) ← (B1, B2, K B3)
M
E,
C
7. (B1, B2, B3) ← (T1, ,P ET2, T3)
.,A
8. goto 2 A.
R
ara
ush
B
1. Find the Multiplicative Inverse of 550 mod
1759
E
EG
LL
O
C
G
G
EN
EA
Step 1: , KM
E
T1 = 1-3*0 = 1 EC
AP,
.,
T2 = 0-3*1 = -3 A. R
ra
T3 = 1759 - 3*550
sha = 109
Step 2: Bu
T1 = 0-5*1 = -5
T2 = 1-5*-3 = 16
T3 = 550 - 5*109 = 5
Step 3:
T1 = 1-21*-5 = 106
T2 = -3-21*16 = -339
T3 = 109 - 21*5 = 4
Step 4:
T1 = -5-1*106 = -111
T2 = 16-1*-339 = 355
T3 = 5- 1*4 = 1
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
Addition and subtraction are performed by adding or subtracting
corresponding coefficients.
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
Multiplicative Inverse of a Polynomial Arithmetic
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B
E
EG
LL
O
C
G
G
EN
EA
, KM
E
EC
AP,
,
. R.
A
ara
ush
B