24

V 1

  • Upload
    nuri

  • View
    34

  • Download
    0

Embed Size (px)

DESCRIPTION

V 1. V 2. No edges between vertices in V 1 or V 2 This is a bipartite graph but not a complete bipartite graph ( so it is NOT K 6, 4 ). b. a. c. g. f. e. d. {a, b, d }, {c, e, f, g} K 3, 4. How many vertices and edges in K m, n ?. If a is in V1, then, b, d, e must be in V2 (why?) - PowerPoint PPT Presentation

Citation preview

Page 1: V 1
Page 2: V 1

V1 V2

No edges between vertices in V1 or V2

This is a bipartite graph but not a complete bipartite graph ( so it is NOT K6, 4 ).

Page 3: V 1

e

f

g

a bc

d{a, b, d }, {c, e, f, g}

K3, 4

How many vertices and edges in Km, n?

Page 4: V 1
Page 5: V 1

If a is in V1, then, b, d, e must be in V2 (why?)

Then, c is in V1 and there is no inconsistency.

So we can rearrange the graph as follows:

Page 6: V 1
Page 7: V 1

Theorem: A simple graph is bipartite if and only if it is possible to assign one of two different colors to each vertex of the graph so that no two adjacent vertices are assigned the same color.

Page 8: V 1

a

f

e

b

c

d

Is a bipartite graph?

Page 9: V 1

aa

f

e

b

c

d

Page 10: V 1

a

f

e

d

c

b

Is a bipartite graph?

Page 11: V 1

a

f

e

d

c

b

Page 12: V 1

a

f

e

d

c

b

Not a bipartite graph

Page 13: V 1

Application: Job AssignmentsSuppose that there are m employees in a group and j different jobs that need to be done, where m ≤ j.

Each employee is trained to do one or more these jobs.

Use a bipartite graph to model employee capabilities.

Testing Implementation Architecture Requirements

John Mary Helen Brad

Page 14: V 1

Matching

A subset of edges such that no two edges are incident with the same vertex.

A matching

Not a matching

Page 15: V 1

Maximal matching is a matching with the largest number of edges.

Maximal matchingNot a maximal matching

Page 16: V 1

Testing Implementation Architecture Requirements

John Mary Helen Brad

Job assignment:

To assign jobs to employees so that the largest number of employees are assigned jobs, we seek a maximum matching in the graph that model employee capabilities.

Page 17: V 1
Page 18: V 1
Page 19: V 1

9.3 Representing Graphs

Vertex Adjacent Vertices------------------------------------------------u1 u2, u5u2 u1, u3, u4u3 u2, u4u4 u2, u3, u5u5 u1, u2, u4

Adjacency list

Page 20: V 1

Adjacency Matrix

Order the vertices in some way

V1, V2, …., Vn , the adjacency matrix is an n-by-n matrix

Page 21: V 1
Page 22: V 1
Page 23: V 1
Page 24: V 1

Vertices

Edges