Question:medium

Consider a relation \(R(A, B, C, D, E)\) with the following three functional dependencies: \[ AB \rightarrow C, BC \rightarrow D, C \rightarrow E \] The number of superkeys in the relation is

Show Hint

A superkey can be formed by adding any combination of attributes to a candidate key. The number of superkeys is determined by the number of attributes that can be added to the candidate key.
Updated On: Jan 30, 2026
Show Solution

Correct Answer: 8

Solution and Explanation

In the given relation, we are asked to determine the number of superkeys. A superkey is any set of attributes that can uniquely identify a tuple in the relation.

Step 1: Identify the candidate key
Given the functional dependencies:
- \( C \rightarrow E \) implies that attribute \( C \) determines \( E \).
- \( AB \rightarrow C \) implies that attributes \( A \) and \( B \) together determine \( C \), and hence also determine \( E \).
- \( BC \rightarrow D \) implies that attributes \( B \) and \( C \) together determine \( D \).

Using these dependencies: - From \( AB \rightarrow C \) and \( C \rightarrow E \), we get \( AB \rightarrow E \).
- Since \( AB \rightarrow C \) and \( BC \rightarrow D \), we can derive \( AB \rightarrow D \).

Thus, \( AB \) determines all attributes \( A, B, C, D, E \), and hence \( AB \) is a candidate key.

Step 2: Count the superkeys
Any superset of a candidate key is a superkey. The relation has 5 attributes: \( \{A, B, C, D, E\} \). The candidate key \( AB \) already contains 2 attributes.

The remaining attributes that may or may not be added are: \[ \{C, D, E\} \] Each of these attributes can either be included or excluded, giving: \[ 2^{3} = 8 \] possible superkeys.

Final Answer:
The total number of superkeys in the relation is: \[ \boxed{8} \]
Was this answer helpful?
0