SlideShare a Scribd company logo
EULER PATHS AND
CIRCUITS
BY M PIR SYED AYAZ FARID SHAH
CLASS MCS 4TH
HOW TO FIND DEGREES OF VERTICES?
• the degree of a vertex is the number of edges connecting it.
EULER PATHS AND CIRCUITS
• An Euler path is a path that uses every edge of a graph exactly once. An Euler
path starts and ends at deferent vertices.
• An Euler circuit is a circuit that uses every edge of a graph exactly once. An Euler
circuit starts and ends at the same vertex.
• Our goal is to find a quick way to check whether a graph (or multigraph) has an Euler path or
circuit.
EULER PATHS AND CIRCUITS
• If a graph G has an Euler path,
then it must have
• exactly two odd vertices.
• If a graph G has an Euler circuit,
then all of its vertices
• must be even vertices.
FLEURY'S ALGORITHM
• To find an Euler path or an Euler circuit:
• 1. Make sure the graph has either 0 or 2 odd vertices.
• 2. If there are 0 odd vertices, start anywhere. If there are 2
• odd vertices, start at one of them.
• 3. Follow edges one at a time. If you have a choice between
• a bridge and a non-bridge, always choose the non-bridge.
• 4. Stop when you run out of edges.
• This is called Fleury's algorithm, and it always works!

More Related Content

What's hot

Topological Sorting
Topological SortingTopological Sorting
Topological Sorting
ShahDhruv21
 
Graph theory in network system
Graph theory in network systemGraph theory in network system
Graph theory in network system
Manikanta satyala
 
Koningsberg bridge problem
Koningsberg  bridge  problemKoningsberg  bridge  problem
Koningsberg bridge problem
Sudiksha Joshi
 
introduction to graph theory
introduction to graph theoryintroduction to graph theory
introduction to graph theoryChuckie Balbuena
 
Graph Theory
Graph TheoryGraph Theory
Graph Theory
Ehsan Hamzei
 
Hamiltonian path
Hamiltonian pathHamiltonian path
Hamiltonian path
Arindam Ghosh
 
Applications of graph theory
                      Applications of graph theory                      Applications of graph theory
Applications of graph theory
NilaNila16
 
Graph
GraphGraph
Graph
ssnetvnr
 
Graphs: Hamiltonian Path and Circuit
 Graphs: Hamiltonian Path and Circuit Graphs: Hamiltonian Path and Circuit
Graphs: Hamiltonian Path and Circuit
Liwayway Memije-Cruz
 
Knowledge representation and Predicate logic
Knowledge representation and Predicate logicKnowledge representation and Predicate logic
Knowledge representation and Predicate logic
Amey Kerkar
 
Graph isomorphism
Graph isomorphismGraph isomorphism
Graph isomorphismCore Condor
 
Application of Linear Algebra in Electrical Circuit
Application of Linear Algebra in Electrical CircuitApplication of Linear Algebra in Electrical Circuit
Application of Linear Algebra in Electrical Circuit
Badruzzman Jhon
 
Floyd Warshall Algorithm
Floyd Warshall Algorithm Floyd Warshall Algorithm
Floyd Warshall Algorithm
Imamul Kadir
 
Linear Algebra presentation.pptx
Linear Algebra presentation.pptxLinear Algebra presentation.pptx
Linear Algebra presentation.pptx
ProveedorIptvEspaa
 
Hamilton paths and circuit
Hamilton paths and circuitHamilton paths and circuit
Hamilton paths and circuit
Sohag Babu
 
Graph Theory
Graph TheoryGraph Theory
Graph Theory
Rashmi Bhat
 
POST’s CORRESPONDENCE PROBLEM
POST’s CORRESPONDENCE PROBLEMPOST’s CORRESPONDENCE PROBLEM
POST’s CORRESPONDENCE PROBLEM
Rajendran
 
Find Transitive Closure Using Floyd-Warshall Algorithm
Find Transitive Closure Using Floyd-Warshall AlgorithmFind Transitive Closure Using Floyd-Warshall Algorithm
Find Transitive Closure Using Floyd-Warshall Algorithm
Rajib Roy
 

What's hot (20)

Topological Sorting
Topological SortingTopological Sorting
Topological Sorting
 
Graph theory in network system
Graph theory in network systemGraph theory in network system
Graph theory in network system
 
Koningsberg bridge problem
Koningsberg  bridge  problemKoningsberg  bridge  problem
Koningsberg bridge problem
 
LR PARSE.pptx
LR PARSE.pptxLR PARSE.pptx
LR PARSE.pptx
 
introduction to graph theory
introduction to graph theoryintroduction to graph theory
introduction to graph theory
 
Graph Theory
Graph TheoryGraph Theory
Graph Theory
 
Hamiltonian path
Hamiltonian pathHamiltonian path
Hamiltonian path
 
Applications of graph theory
                      Applications of graph theory                      Applications of graph theory
Applications of graph theory
 
Graph
GraphGraph
Graph
 
AI Lesson 03
AI Lesson 03AI Lesson 03
AI Lesson 03
 
Graphs: Hamiltonian Path and Circuit
 Graphs: Hamiltonian Path and Circuit Graphs: Hamiltonian Path and Circuit
Graphs: Hamiltonian Path and Circuit
 
Knowledge representation and Predicate logic
Knowledge representation and Predicate logicKnowledge representation and Predicate logic
Knowledge representation and Predicate logic
 
Graph isomorphism
Graph isomorphismGraph isomorphism
Graph isomorphism
 
Application of Linear Algebra in Electrical Circuit
Application of Linear Algebra in Electrical CircuitApplication of Linear Algebra in Electrical Circuit
Application of Linear Algebra in Electrical Circuit
 
Floyd Warshall Algorithm
Floyd Warshall Algorithm Floyd Warshall Algorithm
Floyd Warshall Algorithm
 
Linear Algebra presentation.pptx
Linear Algebra presentation.pptxLinear Algebra presentation.pptx
Linear Algebra presentation.pptx
 
Hamilton paths and circuit
Hamilton paths and circuitHamilton paths and circuit
Hamilton paths and circuit
 
Graph Theory
Graph TheoryGraph Theory
Graph Theory
 
POST’s CORRESPONDENCE PROBLEM
POST’s CORRESPONDENCE PROBLEMPOST’s CORRESPONDENCE PROBLEM
POST’s CORRESPONDENCE PROBLEM
 
Find Transitive Closure Using Floyd-Warshall Algorithm
Find Transitive Closure Using Floyd-Warshall AlgorithmFind Transitive Closure Using Floyd-Warshall Algorithm
Find Transitive Closure Using Floyd-Warshall Algorithm
 

Similar to Euler paths and circuits

Fleurys abas abbasli_
Fleurys abas  abbasli_Fleurys abas  abbasli_
Fleurys abas abbasli_
abas1333
 
Presentation on Graph
Presentation on GraphPresentation on Graph
Presentation on Graph
Salim Hosen
 
Slide task 6
Slide task 6Slide task 6
Slide task 6
Hafiz Safwan
 
Depth first traversal(data structure algorithms)
Depth first traversal(data structure algorithms)Depth first traversal(data structure algorithms)
Depth first traversal(data structure algorithms)
bhuvaneshwariA5
 
3rd Test - Slope and parallel lines
3rd Test - Slope and parallel lines3rd Test - Slope and parallel lines
3rd Test - Slope and parallel linesBrandeis High School
 
distructweek15graphstheoryupdated-160227143444.pdf
distructweek15graphstheoryupdated-160227143444.pdfdistructweek15graphstheoryupdated-160227143444.pdf
distructweek15graphstheoryupdated-160227143444.pdf
ansariparveen06
 
Graph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptx
Graph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptxGraph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptx
Graph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptx
MuhammadMuqrrab1
 
Distruct week 15 graphs theory (updated)
Distruct week 15 graphs theory (updated)Distruct week 15 graphs theory (updated)
Distruct week 15 graphs theory (updated)
Robert Almazan
 
Topics.pdf
Topics.pdfTopics.pdf
Topics.pdf
ssuser4030a8
 
ANALYTIC-GEOMETRY(4).pptx
ANALYTIC-GEOMETRY(4).pptxANALYTIC-GEOMETRY(4).pptx
ANALYTIC-GEOMETRY(4).pptx
BercasioKelvin
 

Similar to Euler paths and circuits (11)

Math
MathMath
Math
 
Fleurys abas abbasli_
Fleurys abas  abbasli_Fleurys abas  abbasli_
Fleurys abas abbasli_
 
Presentation on Graph
Presentation on GraphPresentation on Graph
Presentation on Graph
 
Slide task 6
Slide task 6Slide task 6
Slide task 6
 
Depth first traversal(data structure algorithms)
Depth first traversal(data structure algorithms)Depth first traversal(data structure algorithms)
Depth first traversal(data structure algorithms)
 
3rd Test - Slope and parallel lines
3rd Test - Slope and parallel lines3rd Test - Slope and parallel lines
3rd Test - Slope and parallel lines
 
distructweek15graphstheoryupdated-160227143444.pdf
distructweek15graphstheoryupdated-160227143444.pdfdistructweek15graphstheoryupdated-160227143444.pdf
distructweek15graphstheoryupdated-160227143444.pdf
 
Graph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptx
Graph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptxGraph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptx
Graph-Theory-and-Management-Science-2-Fleurys-Algorithm-and-Eulerizing.pptx
 
Distruct week 15 graphs theory (updated)
Distruct week 15 graphs theory (updated)Distruct week 15 graphs theory (updated)
Distruct week 15 graphs theory (updated)
 
Topics.pdf
Topics.pdfTopics.pdf
Topics.pdf
 
ANALYTIC-GEOMETRY(4).pptx
ANALYTIC-GEOMETRY(4).pptxANALYTIC-GEOMETRY(4).pptx
ANALYTIC-GEOMETRY(4).pptx
 

Recently uploaded

Lapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdfLapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdf
Jean Carlos Nunes Paixão
 
Language Across the Curriculm LAC B.Ed.
Language Across the  Curriculm LAC B.Ed.Language Across the  Curriculm LAC B.Ed.
Language Across the Curriculm LAC B.Ed.
Atul Kumar Singh
 
The approach at University of Liverpool.pptx
The approach at University of Liverpool.pptxThe approach at University of Liverpool.pptx
The approach at University of Liverpool.pptx
Jisc
 
Group Presentation 2 Economics.Ariana Buscigliopptx
Group Presentation 2 Economics.Ariana BuscigliopptxGroup Presentation 2 Economics.Ariana Buscigliopptx
Group Presentation 2 Economics.Ariana Buscigliopptx
ArianaBusciglio
 
Marketing internship report file for MBA
Marketing internship report file for MBAMarketing internship report file for MBA
Marketing internship report file for MBA
gb193092
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
camakaiclarkmusic
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
Peter Windle
 
Chapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptxChapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptx
Mohd Adib Abd Muin, Senior Lecturer at Universiti Utara Malaysia
 
Synthetic Fiber Construction in lab .pptx
Synthetic Fiber Construction in lab .pptxSynthetic Fiber Construction in lab .pptx
Synthetic Fiber Construction in lab .pptx
Pavel ( NSTU)
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Thiyagu K
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
Scholarhat
 
Model Attribute Check Company Auto Property
Model Attribute  Check Company Auto PropertyModel Attribute  Check Company Auto Property
Model Attribute Check Company Auto Property
Celine George
 
STRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBC
STRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBCSTRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBC
STRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBC
kimdan468
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
JosvitaDsouza2
 
The French Revolution Class 9 Study Material pdf free download
The French Revolution Class 9 Study Material pdf free downloadThe French Revolution Class 9 Study Material pdf free download
The French Revolution Class 9 Study Material pdf free download
Vivekanand Anglo Vedic Academy
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
siemaillard
 
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th SemesterGuidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Atul Kumar Singh
 
Acetabularia Information For Class 9 .docx
Acetabularia Information For Class 9  .docxAcetabularia Information For Class 9  .docx
Acetabularia Information For Class 9 .docx
vaibhavrinwa19
 
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup   New Member Orientation and Q&A (May 2024).pdfWelcome to TechSoup   New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
TechSoup
 
Multithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race conditionMultithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race condition
Mohammed Sikander
 

Recently uploaded (20)

Lapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdfLapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdf
 
Language Across the Curriculm LAC B.Ed.
Language Across the  Curriculm LAC B.Ed.Language Across the  Curriculm LAC B.Ed.
Language Across the Curriculm LAC B.Ed.
 
The approach at University of Liverpool.pptx
The approach at University of Liverpool.pptxThe approach at University of Liverpool.pptx
The approach at University of Liverpool.pptx
 
Group Presentation 2 Economics.Ariana Buscigliopptx
Group Presentation 2 Economics.Ariana BuscigliopptxGroup Presentation 2 Economics.Ariana Buscigliopptx
Group Presentation 2 Economics.Ariana Buscigliopptx
 
Marketing internship report file for MBA
Marketing internship report file for MBAMarketing internship report file for MBA
Marketing internship report file for MBA
 
CACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdfCACJapan - GROUP Presentation 1- Wk 4.pdf
CACJapan - GROUP Presentation 1- Wk 4.pdf
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
 
Chapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptxChapter 3 - Islamic Banking Products and Services.pptx
Chapter 3 - Islamic Banking Products and Services.pptx
 
Synthetic Fiber Construction in lab .pptx
Synthetic Fiber Construction in lab .pptxSynthetic Fiber Construction in lab .pptx
Synthetic Fiber Construction in lab .pptx
 
Unit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdfUnit 2- Research Aptitude (UGC NET Paper I).pdf
Unit 2- Research Aptitude (UGC NET Paper I).pdf
 
Azure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHatAzure Interview Questions and Answers PDF By ScholarHat
Azure Interview Questions and Answers PDF By ScholarHat
 
Model Attribute Check Company Auto Property
Model Attribute  Check Company Auto PropertyModel Attribute  Check Company Auto Property
Model Attribute Check Company Auto Property
 
STRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBC
STRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBCSTRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBC
STRAND 3 HYGIENIC PRACTICES.pptx GRADE 7 CBC
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
 
The French Revolution Class 9 Study Material pdf free download
The French Revolution Class 9 Study Material pdf free downloadThe French Revolution Class 9 Study Material pdf free download
The French Revolution Class 9 Study Material pdf free download
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 
Guidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th SemesterGuidance_and_Counselling.pdf B.Ed. 4th Semester
Guidance_and_Counselling.pdf B.Ed. 4th Semester
 
Acetabularia Information For Class 9 .docx
Acetabularia Information For Class 9  .docxAcetabularia Information For Class 9  .docx
Acetabularia Information For Class 9 .docx
 
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup   New Member Orientation and Q&A (May 2024).pdfWelcome to TechSoup   New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
 
Multithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race conditionMultithreading_in_C++ - std::thread, race condition
Multithreading_in_C++ - std::thread, race condition
 

Euler paths and circuits

  • 1. EULER PATHS AND CIRCUITS BY M PIR SYED AYAZ FARID SHAH CLASS MCS 4TH
  • 2. HOW TO FIND DEGREES OF VERTICES? • the degree of a vertex is the number of edges connecting it.
  • 3. EULER PATHS AND CIRCUITS • An Euler path is a path that uses every edge of a graph exactly once. An Euler path starts and ends at deferent vertices. • An Euler circuit is a circuit that uses every edge of a graph exactly once. An Euler circuit starts and ends at the same vertex. • Our goal is to find a quick way to check whether a graph (or multigraph) has an Euler path or circuit.
  • 4. EULER PATHS AND CIRCUITS • If a graph G has an Euler path, then it must have • exactly two odd vertices. • If a graph G has an Euler circuit, then all of its vertices • must be even vertices.
  • 5. FLEURY'S ALGORITHM • To find an Euler path or an Euler circuit: • 1. Make sure the graph has either 0 or 2 odd vertices. • 2. If there are 0 odd vertices, start anywhere. If there are 2 • odd vertices, start at one of them. • 3. Follow edges one at a time. If you have a choice between • a bridge and a non-bridge, always choose the non-bridge. • 4. Stop when you run out of edges. • This is called Fleury's algorithm, and it always works!