Question: For this problem set we define A = {a 1 , a 2 , , a n } to be a set of n elements.

For this problem set we define A = {a1, a2, , an} to be a set of n elements. A relation R over A is a subset ofA A.

Relations can be represented in a variety of ways. One method that is conceptually convenient is to represent a relation as a boolean matrix. As an example, when n= 4 we have the following:

R= {(a1,a2 ), (a1,a3 ), (a2,a1 ), (a2,a2 ), (a3,a4 ), (a4,a1)}

M= 0 1 1 0

1 1 0 0

0 0 0 1

1 0 0 0

Here, the entry in the ith row and jth column of the matrix, Mij, is 1 iff the ordered pair (ai,aj ) R , and is 0 otherwise. Note that this defines a bijection between the set of relations on A and the set of nn matrices with 0/1 entries.

Problem 6. A relation R over A is transitive if, for every i,j,k: (ai, aj) R and (aj, ak) R implies that (ai, ak) R. Is the relation in the example above transitive?

Problem 8a. Compute the product matrix M2 = M M, where M is the example matrix shown above (again, treating 1 as true and 0 as false). Verify that the following statement is true: M2ij = 1 if and only if there is a directed path of length exactly 2 from ai to aj. Problem 8b. Prove that if R is a relation on a set of size n and M is its corresponding boolean matrix representation, then Mkij = 1 if and only if there is a path of length exactly k from ai to aj in the directed graph corresponding to R. (Hint: use induction on the length of the path.)

Problem 11. Define the n n identity matrix I : Ijj = 1, 1 j n, Ijk = 0, j k. Show that R* = (I M)n.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!