Anda di halaman 1dari 23

TR1313: INTRODUCTION TO DISCRETE MATHEMATICS

LECTURE 20: MATHEMATICAL STRUCTURE AND GRAPH THEORY

Discrete Mathematical Structure


Some problems in IT requires the ability to model structured objects. Example: Data structure Program structure System structure Since we are dealing with discrete objects, we are interested in discrete structure.

Unstructured And Structured Discrete Object

Unstructured object Structured object

Discrete Mathematical Structure


Discrete mathematical structure is the use of mathematical concepts in modeling discrete structure. Discrete mathematical structure consists of at least one set and one relation on the set. So if a simple structure H consists of a set A and a relation R, then H is written as H = (A,R)

Example 1 Example of structures: Sequence Bag Partially Ordered Set (poset) Lattice Group Language

Representation
There are two ways of representing a mathematical structure:
By using pictorial representation By using matrix representation

Graphs
A type of pictorial representation that can be used to represent structures is called a graph.

Important Names
1736: Leonhard Euler Basel, 1707-St. Petersburg, 1786 He wrote A solution to a problem concerning the geometry of a place. First paper in graph theory. Problem of the Knigsberg bridges: Starting and ending at the same point, is it possible to cross all seven bridges just once and return to the starting point?

Important Names
William Rowan Hamilton (Dublin, Ireland 1805-1865) applied "quaternions" worked on optics, dynamics and analysis created the "icosian game" in 1857, a precursor of Hamiltonian cycles. Denes Konig (Budapest, Hungary 1844-1944) Interested in four-color problem and graph theory 1936: publishes Theory of finite and infinite graphs, the first textbook on graph theory

What Is A Graph G?
A graph G is a pair G = (V, E), where V = V(G) = set of vertices E = E(G) = set of edges Example 2: V = {s, u, v, w, x, y, z} E = {(x,s), (x,v)1, (x,v)2, (x,u), (v,w), (s,v), (s,u), (s,w), (s,y), (w,y), (u,y), (u,z),(y,z)}

Edges
An edge may be labeled by a pair of vertices, for instance e = (v,w). e is said to be incident on v and w. Isolated vertex = a vertex without incident edges.

Special Edges
Parallel edges Two or more edges joining a pair of vertices in the example, a and b are joined by two parallel edges

Special Edges
Loops An edge that starts and ends at the same vertex In the example, vertex d has a loop

Simple Graph
A graph without loops or parallel edges.

Exercise 1
Is this graph a simple graph?

Weighted Graphs
A graph where each edge is assigned a numerical label or weight. Length of path = the sum of the weights of the edges Example 3 length of path v1,v2,v3 is _______

Directed Graphs (Digraphs)


G is a directed graph or digraph if each edge has been associated with an ordered pair of vertices, i.e. each edge has a direction

Complete Graph Kn
Let n > 3 The complete graph Kn is the graph with n vertices and every pair of vertices is joined by an edge. The figure represents K5

Exercise 2
Draw (i) K3

(ii) K5

Bipartite Graphs
A bipartite graph G is a graph such that o V(G) = V(G1) V(G2) o |V(G1)| = m, |V(G2)| = n o V(G1) V(G2) = o No edges exist between any two vertices in the same subset
v1

v2
v3

v4 v5

V(G1) = {v1,v2,v3} V(G2) = {v4,v5}

Exercise 3
Is the following graph bipartite?
(i) (ii) b d e

c
a

Complete Bipartite Graph Km,n


A bipartite graph is the complete bipartite graph Km,n if every vertex in V(G1) is joined to a vertex in V(G2) and conversely, - |V(G1)| = m - |V(G2)| = n

Exercise 4
Draw (i) K2,3 (ii) K3,3

Anda mungkin juga menyukai