1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Sonja [21]
3 years ago
14

Assume each student is assigned an advisor from a department. Each classroom is assigned a classroom (class# determines Classroo

m). (Student#, Class#) is the primary key to this relation. Is this relation in 2NF? Justify your answer and decompose if necessary. Assuming each advisor is assigned an office and each advisor belongs to a particular department. Then argue whether further normalization to 3NF is necessary, and if so, perform it.
Computers and Technology
1 answer:
Luden [163]3 years ago
3 0

Answer:

Check the explanation

Explanation:

As we know that any relation will be in 2NF if it satisfies following two conditions

1> It should be in 1NF.

2> It should not contain any partial dependency i.e. all the non-prime attributes should fully functionally dependent on the relation key(s).

In the given table,

The primary key is (Student#,class#).

And one of functional dependency is

Class# determines Classroom (Class# ------> Classroom)

This functional dependency is a partial functional dependency because in this dependency a proper subset(Class#) of a relation key(Student#,Class#)  functionally determines a non-prime attribute(Classroom).

Since this table contains a partial dependency therefore as per the definition of 2NF this table is not in 2NF.

Now we can decompose it into 2NF by splitting the table into the following two tables(R1 and R2).

R1(Student#, Class#, Advisor, Advisor-office, Department) and R2(Class#, Classroom)

R1 table is shown below.

Student# Class# Advisor Advisor-office Department

1011                    101-07 Jones           212    CSCI

1011                    201-02 Jones           212    CSCI

1011                    310-11 Jones           212     CSCI

2010           101-07 Anderson   308    MATH

2010          201-02 Anderson   308    MATH

2010          120-12 Anderson   308    MATH

R2 table is shown below

Class# Classroom

101-07 WIL230

201-02 OVR212

310-11 WIL224

120-12 WIL306

Now these tables(R1 and R2) are in 2NF.

Argument For 3NF

As we know that any relation will be in 3NF if it satisfies following two conditions

1> It should be in 2NF.

Student# Class# Advisor

1011                 101-07 Jones

1011                 201-02 Jones

1011                  310-11 Jones

2010         101-07 Anderson

2010         201-02 Anderson

2010         120-12 Anderson

R12 is shown below

Advisor Advisor-office

Jones          212

Anderson  308

R13 is shown below

Advisor Advisor-office

Jones         CSCI

Anderson MATH

So these four tables (R11, R12, R13, R2) correctly represent the third normal form of the given table.

2> It should not contain any transitive dependency i.e. all the non-prime attributes should be non-transitively dependent on the relation key(s).

Now from the question, we come to know that

1> Each advisor is assigned an office, which means that following functional dependency exists in table R1

Advisor determines Advisor-office (Advisor------> Advisor-office).

2>Each advisor belongs to a particular department, which means that following functional dependency also exists in table R1

Advisor determines Department (Advisor------> Department).

So we have following two dependencies in table R1

1>  Advisor determines Advisor-office (Advisor------> Advisor-office).

2> Advisor determines Department (Advisor------> Department).

Since we know that (Student#,Class#) is a primary key, so it should determine Advisor functionally i.e.

(Student#,Class#)----> Advisor

and from above two conditions we have

Advisor--->Advisor-office and Advisor----->Department

We can clearly see that Advisor---->Advisor-office and  Advisor----->Department are two transitive dependency because Advisor itself is functionally dependent on (Student#, Class#) .

So here we can see that two non prime attributes (Advisor-office and Department) are transitively dependent on the Primary key(Student#,Class#).

Therefore as per definition R1 is not in 3NF. But R2 is in 3NF as per definition.

So we can decompose R1 into 3NF by splitting the table into the following three tables(R11, R12, and R13).

R11(Student#, Class#, Advisor), R12 (Advisor, Advisor-office), and R13(Advisor, Department)  

R11 is shown below

Student# Class# Advisor

1011                101-07 Jones

1011                201-02 Jones

1011                310-11 Jones

2010       101-07 Anderson

2010       201-02 Anderson

2010       120-12 Anderson

R12 is shown below

Advisor Advisor-office

Jones      212

Anderson 308

R13 is shown below

Advisor Advisor-office

Jones          CSCI

Anderson MATH

So these four tables (R11, R12, R13, R2) correctly represent the third normal form of the given table.

You might be interested in
Plzz help.... <br><br>i will mark u as brainliest if u answer correct
shtirl [24]

Answer:

import java.util.Scanner;

class Main {

 public static void main(String[] args) {

   Scanner scan = new Scanner(System.in);

   while(true) {

     System.out.print("Enter an integer (0 to exit): ");

     int num = scan.nextInt();

     if (num == 0) break;

     if (num%3 == 0 && num%5 == 0) {

       System.out.printf("%d is divisable by both 3 and 5.\n", num);

     }

     else if (num%3 == 0 && num%5 != 0) {

       System.out.printf("%d is divisable by 3 but not by 5.\n", num);

     }

     else if (num%3 != 0 && num%5 == 0) {

       System.out.printf("%d is divisable by 5 but not by 3.\n", num);

     } else {

       System.out.printf("%d is not divisable by 3 or 5.\n", num);

     }

   }

   scan.close();

 }

}

3 0
3 years ago
Choose the person responsible for each innovation.
shepuryov [24]

Answer:

John Blankenbaker

Explanation:

5 0
3 years ago
0010 0000<br> What is the binary decimal
Degger [83]

Answer:

The decimal number is 32 and the Hexidecimal  is 20

5 0
3 years ago
Read 2 more answers
In the Unified Process (UP), related activities are grouped into UP ____. a. Services b. Disciplines c. Cycles d. Practices
Paha777 [63]

Answer:

b. Disciplines

Explanation:

The Unified Process (UP) is a type of development framework that repeats itself and can be customized and used for several different variations of the same underlying process. In the Unified Process (UP), related activities are grouped into UP Disciplines, as one of the many components that make up the Unified Process.

6 0
3 years ago
Ashton assigned a string value to a variable. Which program statement should he use?
ryzh [129]
The second one
bc it looks correct

6 0
3 years ago
Other questions:
  • Alicia is a dietitian. She gives other people suggestions for nutrition. She wants to organize a large amount of data concerning
    8·2 answers
  • Who can effectively use website authoring software?
    6·1 answer
  • The Task Manager cannot be used to turn Services on and off.<br> True or False?
    8·2 answers
  • A machine that is used to print newspaper is a
    12·2 answers
  • An administrator has several cables plugged into a patch panel and needs to determine which one comes from a specific port. Whic
    15·1 answer
  • How do you check how much space is left in current drive?
    9·1 answer
  • 3.
    5·1 answer
  • Differences of a desktop computer and a laptop
    13·1 answer
  • Someone, please answer this.
    15·1 answer
  • When a module is processed:
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!