SlideShare a Scribd company logo
2
Most read
3
Most read
6
Most read
Euler Phi
Lets talk about the problem first,
we want to know how many number is relatively prime / co-primes to N.
What's relatively prime / Co-prime ?
if gcd(x,y) == 1 , then they are x and y are co-primes.
Simply,
if 1 is the only number that can evenly divide x and y then they are
co-primes.
As example,
So, 12 and 13 are co-primes.
Our problem was,
how many numbers are there which are co-primes to N.
Means,
Lets Assume , N = 8
We can see there are 4 number co-primes with N=8.
So we are looking for a general formula to find for any N.
Euler phi function do that for us.
Suppose we are going to find the value of phi(N)
where,
Here p1 , p2 .. pk are primes
and this is actually the prime factorization of N
So for N = 24
Lets talk about the formula to find out the phi() value for any N.
formula is,
Lets try the proof of it,
Lets talk about some case,
Case 1 : N is Prime
When N is primes we can make it sure that there is no number
except 1 and itself that can divide it otherwise it cant be a prime.
So , it maintained such relation with every number less than it.
the relation is,
gcd(x,n) = 1;
So we can surely say that phi of such n is phi(n) = n-1.
When n is a prime of course.
Case 2 : When N is power of Prime
Means if we can express N as power of 1 single prime.
Like N = 8
we can write is as N = 2 x 2 x 2.
or N = 2 ^ 3
In this scenario,
phi(n) = n - (n / p);
where n = p ^ x; =======================> x is any integer,p is prime <===
HOW !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Lets take an example,
where N = 8.
So , every number which are divisble by 2 before 8 are not maintain
the realtion.
which is,
gcd(n,x) 1;
bc their gcd will be 2 or greater than 2.
Here we can see , 4 numbers are not coprimes to n.
which is exactly
n / p = 8 / 2 = 4.
so if we subtract all those numbers whose are not co-prime to N
then we could be able to find the exact value of phi(n).
in this case that is,
phi(8) = 8 - (8 / 2) = 4
so phi(8) = 4;
if we can write N like this ,
Then the number of numbers not coprime to N is ,
Which are actually divisible by P.So they cant be coprime to N.
so the final foumula for such N that can be written as a single
prime is,
Now its looks like the equation above.The general formula,
We know Phi function is multiplicative,
means,
phi(m * n) = phi(m) * phi(n).
Lets not talk about the proof of multiplicity of phi now.
Assume that is multiplicative and complete the proof.
So as we know any number can express multiplication of primes.What we
call primes factorization.
lets say,factorization of N is,
We already found out that phi of such numbers that can be expressed
as power of single prime is,
Now its look like exactly the same we written before.
You can follow the reference list below to know further.
Thank you.

More Related Content

PPTX
Eulers totient
PPTX
number theory.ppt
PPT
Linear Equation Word Problem Complete.ppt
PPTX
Combinatorics
PPTX
Number theory
PPTX
Find Transitive closure of a Graph Using Warshall's Algorithm
PPT
Set theory
PPT
Proof
 
Eulers totient
number theory.ppt
Linear Equation Word Problem Complete.ppt
Combinatorics
Number theory
Find Transitive closure of a Graph Using Warshall's Algorithm
Set theory
Proof
 

What's hot (20)

PPTX
Introduction to Modular Arithmetic
PPT
Conditional Probability
PPT
Lec 02 logical eq (Discrete Mathematics)
PPT
Discrete Math Lecture 03: Methods of Proof
PPT
Number theory
PPTX
Mathematical induction and divisibility rules
PPT
Introduction to Optimization.ppt
PDF
Recurrence relations
PPTX
Naive string matching
PDF
Mathematical Logic
PPT
Number theory
PPTX
Probability
PPT
Linear differential equation with constant coefficient
PPTX
LECTURE 2: PROPOSITIONAL EQUIVALENCES
PPT
systems of linear equations & matrices
PPTX
Ode powerpoint presentation1
PPTX
N-queens.pptx
PPTX
5.4 mathematical induction
PPTX
introduction to division algorithm
Introduction to Modular Arithmetic
Conditional Probability
Lec 02 logical eq (Discrete Mathematics)
Discrete Math Lecture 03: Methods of Proof
Number theory
Mathematical induction and divisibility rules
Introduction to Optimization.ppt
Recurrence relations
Naive string matching
Mathematical Logic
Number theory
Probability
Linear differential equation with constant coefficient
LECTURE 2: PROPOSITIONAL EQUIVALENCES
systems of linear equations & matrices
Ode powerpoint presentation1
N-queens.pptx
5.4 mathematical induction
introduction to division algorithm
Ad

Similar to Euler phi (20)

PPTX
9. Euler_s phi Algorithm. pptx
PPTX
Number Theory.pptx
PPT
PDF
Lovely Professional University UNIT 1 NUMBER SYSTEM.pdf
PPT
Number system-Final.ppthhh jbjbbjb bjjnbjkggb
PDF
Number theory
PPTX
Arithmetic sequence in elementary and HS
PDF
11 Applied_Mathemathics HANDBOOK.pdf
PPTX
Information and network security 34 primality
PPT
math 208 report fundamental theorem of arithmetic
PDF
Tenth class state syllabus-text book-em-ap-ts-mathematics
PPT
ch08_cryptography_notes_by_william_stallings
PPT
ch08 modified.pptmodified.pptmodified.ppt
PDF
Probabilistic approach to prime counting
PPT
EULER AND FERMAT THEOREM
PPT
Iss lecture 3
PPTX
Number system - factors.pptx
PDF
Number theory
9. Euler_s phi Algorithm. pptx
Number Theory.pptx
Lovely Professional University UNIT 1 NUMBER SYSTEM.pdf
Number system-Final.ppthhh jbjbbjb bjjnbjkggb
Number theory
Arithmetic sequence in elementary and HS
11 Applied_Mathemathics HANDBOOK.pdf
Information and network security 34 primality
math 208 report fundamental theorem of arithmetic
Tenth class state syllabus-text book-em-ap-ts-mathematics
ch08_cryptography_notes_by_william_stallings
ch08 modified.pptmodified.pptmodified.ppt
Probabilistic approach to prime counting
EULER AND FERMAT THEOREM
Iss lecture 3
Number system - factors.pptx
Number theory
Ad

Recently uploaded (20)

PDF
102 student loan defaulters named and shamed – Is someone you know on the list?
PDF
Module 4: Burden of Disease Tutorial Slides S2 2025
PDF
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
PDF
Pre independence Education in Inndia.pdf
PPTX
Pharmacology of Heart Failure /Pharmacotherapy of CHF
PDF
Business Ethics Teaching Materials for college
PDF
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
PDF
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PDF
RMMM.pdf make it easy to upload and study
PDF
STATICS OF THE RIGID BODIES Hibbelers.pdf
PPTX
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
PDF
Microbial disease of the cardiovascular and lymphatic systems
PDF
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf
PPTX
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
PDF
O5-L3 Freight Transport Ops (International) V1.pdf
PPTX
Pharma ospi slides which help in ospi learning
PPTX
Final Presentation General Medicine 03-08-2024.pptx
PDF
Mark Klimek Lecture Notes_240423 revision books _173037.pdf
PPTX
Cell Types and Its function , kingdom of life
102 student loan defaulters named and shamed – Is someone you know on the list?
Module 4: Burden of Disease Tutorial Slides S2 2025
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
Pre independence Education in Inndia.pdf
Pharmacology of Heart Failure /Pharmacotherapy of CHF
Business Ethics Teaching Materials for college
grade 11-chemistry_fetena_net_5883.pdf teacher guide for all student
BÀI TẬP BỔ TRỢ 4 KỸ NĂNG TIẾNG ANH 9 GLOBAL SUCCESS - CẢ NĂM - BÁM SÁT FORM Đ...
Abdominal Access Techniques with Prof. Dr. R K Mishra
RMMM.pdf make it easy to upload and study
STATICS OF THE RIGID BODIES Hibbelers.pdf
Introduction to Child Health Nursing – Unit I | Child Health Nursing I | B.Sc...
Microbial disease of the cardiovascular and lymphatic systems
Saundersa Comprehensive Review for the NCLEX-RN Examination.pdf
IMMUNITY IMMUNITY refers to protection against infection, and the immune syst...
O5-L3 Freight Transport Ops (International) V1.pdf
Pharma ospi slides which help in ospi learning
Final Presentation General Medicine 03-08-2024.pptx
Mark Klimek Lecture Notes_240423 revision books _173037.pdf
Cell Types and Its function , kingdom of life

Euler phi

  • 1. Euler Phi Lets talk about the problem first, we want to know how many number is relatively prime / co-primes to N. What's relatively prime / Co-prime ? if gcd(x,y) == 1 , then they are x and y are co-primes. Simply, if 1 is the only number that can evenly divide x and y then they are co-primes. As example, So, 12 and 13 are co-primes. Our problem was, how many numbers are there which are co-primes to N. Means, Lets Assume , N = 8 We can see there are 4 number co-primes with N=8. So we are looking for a general formula to find for any N.
  • 2. Euler phi function do that for us. Suppose we are going to find the value of phi(N) where, Here p1 , p2 .. pk are primes and this is actually the prime factorization of N So for N = 24 Lets talk about the formula to find out the phi() value for any N. formula is, Lets try the proof of it, Lets talk about some case, Case 1 : N is Prime When N is primes we can make it sure that there is no number except 1 and itself that can divide it otherwise it cant be a prime. So , it maintained such relation with every number less than it. the relation is, gcd(x,n) = 1; So we can surely say that phi of such n is phi(n) = n-1. When n is a prime of course.
  • 3. Case 2 : When N is power of Prime Means if we can express N as power of 1 single prime. Like N = 8 we can write is as N = 2 x 2 x 2. or N = 2 ^ 3 In this scenario, phi(n) = n - (n / p); where n = p ^ x; =======================> x is any integer,p is prime <=== HOW !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Lets take an example, where N = 8. So , every number which are divisble by 2 before 8 are not maintain the realtion. which is, gcd(n,x) 1; bc their gcd will be 2 or greater than 2.
  • 4. Here we can see , 4 numbers are not coprimes to n. which is exactly n / p = 8 / 2 = 4. so if we subtract all those numbers whose are not co-prime to N then we could be able to find the exact value of phi(n). in this case that is, phi(8) = 8 - (8 / 2) = 4 so phi(8) = 4; if we can write N like this , Then the number of numbers not coprime to N is , Which are actually divisible by P.So they cant be coprime to N. so the final foumula for such N that can be written as a single prime is, Now its looks like the equation above.The general formula,
  • 5. We know Phi function is multiplicative, means, phi(m * n) = phi(m) * phi(n). Lets not talk about the proof of multiplicity of phi now. Assume that is multiplicative and complete the proof. So as we know any number can express multiplication of primes.What we call primes factorization. lets say,factorization of N is, We already found out that phi of such numbers that can be expressed as power of single prime is,
  • 6. Now its look like exactly the same we written before. You can follow the reference list below to know further. Thank you.