You are on page 1of 3

Câu 8(C3)

Cho các quan hệ sau:


r(A B C) s(D E F) t(A B D)
a1 b1 c1 d1 e1 f1 a1 b1 d1
a2 b2 c2 d2 e2 f2 a2 b2 d2
a3 b3 c3 d3 e3 f3 a1 b3 d3
a2 b1 d2
a2 b2 d1
a3 b3 d3
a2 b3 d3

Hãy tính giá trị của các biểu thức đại số quan hệ:
a. r x s *t
b. CF((C= c2)  (F= f2)(r x s))
Bài làm
a. r x s *t
s * t = (D E F A B)
d1 e1 f1 a1 b1
d1 e1 f1 a2 b2
d2 e2 f2 a2 b2

d2 e2 f2 a2 b1

d3 e3 f3 a1 b3

d3 e3 f3 a3 b3

d3 e3 f3 a2 b3
r x s * t = (A B C D E F A B)

a1 b1 c1 d1 e1 f1 a1 b1
a1 b1 c1 d1 e1 f1 a2 b2
a1 b1 c1 d2 e2 f2 a2 b2
a1 b1 c1 d2 e2 f2 a2 b1
a1 b1 c1 d3 e3 f3 a1 b3
a1 b1 c1 d3 e3 f3 a3 b3
a1 b1 c1 d3 e3 f3 a2 b3
a2 b2 c2 d1 e1 f1 a1 b1
a2 b2 c2 d1 e1 f1 a2 b2
a2 b2 c2 d2 e2 f2 a2 b2
a2 b2 c2 d2 e2 f2 a2 b1
a2 b2 c2 d3 e3 f3 a1 b3
a2 b2 c2 d3 e3 f3 a2 b3
a3 b3 c3 d1 e1 f1 a1 b1
a3 b3 c3 d1 e1 f1 a2 b2
a3 b3 c3 d2 e2 f2 a2 b2
a3 b3 c3 d3 e3 f3 a1 b3
a3 b3 c3 d3 e3 f3 a3 b3

b. CF((C=c2) (F=f2)(r x s))

rxs=( A B C D E F)
a1 b1 c1 d1 e1 f1

a1 b1 c1 d2 e2 f2

a1 b1 c1 d3 e3 f3

a2 b2 c2 d1 e1 f1

a2 b2 c2 d2 e2 f2

a2 b2 c2 d3 e3 f3

a3 b3 c3 d1 e1 f1

a3 b3 c3 d2 e2 f2
a3 b3 c3 d3 e3 f3

(C=c2)  (F=f2)(r x s) = (A B C D E F)

a2 b2 c2 d2 e2 f2

CF((C=c2)  (F=f2) (r x s) = (C F)

c2 f2

You might also like