Canonical cover

Last updated

A canonical cover for F (a set of functional dependencies on a relation scheme) is a set of dependencies such that F logically implies all dependencies in , and logically implies all dependencies in F.

Contents

The set has two important properties:

  1. No functional dependency in contains an extraneous attribute.
  2. Each left side of a functional dependency in is unique. That is, there are no two dependencies and in such that .

A canonical cover is not unique for a given set of functional dependencies, therefore one set F can have multiple covers .

Algorithm for computing a canonical cover

  1. Repeat:
    1. Use the union rule to replace any dependencies in of the form and with .
    2. Find a functional dependency in with an extraneous attribute and delete it from
  2. ... until does not change [1]

Canonical cover example

In the following example, Fc is the canonical cover of F.

Given the following, we can find the canonical cover: R = (A, B, C, G, H, I), F = {A→BC, B→C, A→B, AB→C}

  1. {A→BC, B→C, A→B, AB→C}
  2. {A → BC, B →C, AB → C}
  3. {A → BC, B → C}
  4. {A → B, B →C}

Fc =  {A → B, B →C}

Extraneous attributes

An attribute is extraneous in a functional dependency if its removal from that functional dependency does not alter the closure of any attributes. [2]

Extraneous determinant attributes

Given a set of functional dependencies and a functional dependency in , the attribute is extraneous in if and any of the functional dependencies in can be implied by using Armstrong's Axioms. [2]

Using an alternate method, given the set of functional dependencies , and a functional dependency X → A in , attribute Y is extraneous in X if , and . [3]

For example:

Extraneous dependent attributes

Given a set of functional dependencies and a functional dependency in , the attribute is extraneous in if and any of the functional dependencies in can be implied by using Armstrong's axioms. [3]

A dependent attribute of a functional dependency is extraneous if we can remove it without changing the closure of the set of determinant attributes in that functional dependency. [2]

For example:

References

  1. Silberschatz, Abraham (2011). Database system concepts (PDF) (Sixth ed.). New York: McGraw-Hill. ISBN   978-0073523323. Archived from the original (PDF) on 2020-11-08.
  2. 1 2 3 Elmasri, Ramez (2016). Fundamentals of database systems. Sham Navathe (Seventh ed.). Hoboken, NJ: Pearson. ISBN   978-0-13-397077-7. OCLC   913842106.
  3. 1 2 K, Saravanakumar; asamy. "How to find extraneous attribute? An example" . Retrieved 2023-03-14.