当前位置:文档之家› 4.3 大学离散数学课件(英文版)

4.3 大学离散数学课件(英文版)


Example:
Consider the digraph of Figure 4.4. Vertex 1 has in-degree 3 and out-degree 2. Also consider the digraph shown in Figure 4.5.Vertex 3 has indegree 4 and out-degree 2, while vertex 4 has indegree 0 and out-degree 1.
abcd
SIon-lduegtrieoe n 2 3 1 1
The digraph of R is Out-degree 1 1 3 2
shown in Figure 4.6. The
following table gives the
b
in-degrees and out-
degrees of all vertices. Note that the sum of all
a
c
in-degrees must equal the
sum of all out-degrees.
d
Figure 4.6
Example:
Let A={1,4,5}, and let R be given by the digraph Shown in Figure 4.7. Find MR and R.
The Digraph of a Relation
关系的有向图 If A is a finite set and R is a relation on A, we can also represent R pictorially as follows. Draw a small circle for each element of A and label the circle with the corresponding element of A. These circles are called vertices. Draw an arrow, called an edge, from vertex ai to vertex aj if and only if ai R aj .The resulting pictorial representation of R is called a directed graph or digraph of R.
Sometimes, when we want to emphasize the geometric nature of some property of R, we may refer to the pairs of R themselves as edges and the elements of A as vertices.
2
1
3
4
Figure 4.5
An important concept for relations is inspired by the visual form of digraphs. If R is a relation on a set A and a∈A, then the in-degree of a (relative to the relation R) is the number of b∈A such that (b, a)∈R. The outdegree of a is the number of b∈A such that (a, b)∈R.
If R is a relation on A, the edges in the digraph of R correspond exactly to the pairs in R, and the vertices correspond exactly to the elements of the set A.
Example: Find the relation determined by Figure 4.5.
Solution
Since ai R aj if there is an edge from ai to aj ,we have
R={(1,1),(1,3),(2,3),(3,2), (3,3),4,3)}.
Example: Let A={1, 2, 3, 4} R={(1,1),(1,2),(2,1),(2,2),(2,3),(2,4), (3,4),(4,1)}.
Then the digraph of R is as shown in Figure 4.4.
2
13ຫໍສະໝຸດ 4Figure 4.4
A collection of vertices with edges between some of the vertices determines a relation in natural manner.
Example: Let A={a, b, c, d }, and let R be the relation
on A that has the matrix
1 0 0 0
MR
0 1 1 1
0 1
0 0
0
1
0
1
Construct the digraph of R, and list in-degrees And out-degrees of all vertices.
What this means, in terms of the digraph of R, is that the in-degree of a vertex of the number of edges terminating at the vertex. The out –degree of a vertex is the number of edges leaving the vertex. Note that the out-degree of a is |R(a)|.
Solution
1
4
5
Figure 4.7
0 1 1
MR 1 1 0 ,
0 1 1
R={(1,4),(1,5),(4,1),(4,4),(5,4), (5,5)}
相关主题