Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Experiment # 2 To Understand Laws of Boolean Algebra: Objective

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 14

Name SYED WAHEED AHAMED

Reg. # 2020-EE-411
Marks
Experiment # 2

To Understand Laws of Boolean Algebra


Objective:

 Two understand binary arithmetic and binary logic


 Boolean algebra laws

Theory:

Boolean algebra is the basic mathematics needed for the study and design of digital systems.
Main ingredients of Algebra are
1. Set of elements
2. Set of operators
3. Number of postulates

In 1904, E. V. Huntington formulated a number of postulates that give us formal definition of


Boolean algebra. Boolean algebra is an algebraic structure defined by a set of elements, B,
together with two binary operators “+” and “.” provided that the following postulates are
satisfied.

1. Closure
 with respect to the binary operation OR (+); c=x+y
 with respect to the binary operation AND (·); c=x.y
2. Identity
 with respect to OR (+) is 0:
x + 0 = 0 + x = x, for x = 1 or x = 0
 with respect to AND (·) is 1:
x · 1 = 1 · x = x, for x = 1 or x =0
3. Commutative Law
 With respect to OR (+):
x+y=y+x
 With respect to AND (·):
x·y=y·x

4. Distributive Law
 with respect to the binary operation OR (+):
x + (y · z) = (x + y) · (x + z) + is distributive over .
 with respect to the binary operation AND (·):
x · (y + z) = (x · y) + (x · z) . is distributive over +

5. Complement
For every element x, that belongs to B, there also exists an element x’ (complement of x) such
that:
 x + x´ = 1, for x = 1 or x = 0
 x · x´ = 0, for x = 1 or x = 0
6. Membership
There exists at least two elements, x and y, of the set such that
x ≠ y e.g. 0 ≠ 1

LAWS OF BOOLEAN ALGEBRA

Commutative laws Associative laws


A·B=B·A A · B · C = A · (B · C) = (A · B) · C

A∨ B = B ∨ A A ∨ B ∨ C  =  A ∨ (B ∨ C)  =  (A ∨ B) ∨ C

Distributive laws
A · (B ∨ C) = (A · B) ∨ (A · C)

 A ∨ (B · C) = (A ∨ B) · (A ∨ C)

 
Absorption Negation laws (De Morgan)
A ∨ (A B) = A
A´. B= A ' ∨ B'
A · (A ∨ B) = A

 A · (A' ∨ B) = A · B ∨ B = A' · B'


A
A ∨ (A' · B) = A ∨ B
 Commutative laws

Commutative law for the AND operation

The commutative law for AND operations:

A·B=B·A

Commutative law for the OR operation

The commutative law for OR operations is:

A∨B=B∨A

 Associative laws

Associative law for the AND operation

The associative law for AND operations is:

A · B · C  =  A · (B · C)  =  (A · B) · C

 
Associative law for the OR operation

The associative law for OR operations is:

A ∨ B ∨ C  =  A ∨ (B ∨ C)  =  (A ∨ B) ∨ C

 Distributive laws

First distributive law

The first distributive law is:

A · (B ∨ C)  =  (A · B) ∨  (A · C)

Note on the sequence of operations: 


Similar to ordinary algebra where multiplication and division take precedence over addition and subtraction,
here AND operations have priority over OR operations.
2nd distributive law

The 2nd distributive law is: A ∨ (B · C)  =  (A ∨ B) · (A ∨ C)

 Absorption

In the following exercises, we will specifically investigate


AND/OR/NOT sequences with two input variables that can be
simplified.

Procedure and observation:

Exercise: Experiment set-up Commutative law, AND

Fig.1 : Experiment set-up Commutative law, AND

Table 1
Q1 Q0
I1 I0

B A Q2 Q1
0 0 0 0
0 1 0 0
1 0 0 0
1 1 1 1
↑ ↑
B·A A·B
 Exercise: Experiment set-up Commutative law, OR

Fig.2 : Experiment set-up Commutative law, OR

Table 2
Q1 Q0
I1 I0

B A Q2 Q1
0 0 0 0
0 1 1 1
1 0 1 1
1 1 1 1
↑ ↑
B∨A A∨B

Exercise: Associative law AND

Fig.3a : Experiment set-up -  Fig.3b : Experiment set-up - 


Associative law A·(B·C) Associative law (A·B)·C
Table 1 re re
Fig.1.1 Fig.1.2

Q2 Q1 Q0
I0 I0

C B A Q1 Q2

0 0 0 0 0

0 0 1 0 0

0 1 0 0 0

0 1 1 0 0

1 0 0 0 0

1 0 1 0 0

1 1 0 0 0

1 1 1 1 1
↑ ↑
A·(B·C) (A·B)·C

Exercise: Associative law OR

Fig.4a : Experiment set-up -  Fig.4b : Experiment set-up - 


Associative law A∨(B∨C) Associative law (A∨B)∨C

Table 2 re re
Fig.2.1 Fig.2.2
Q2 Q1 Q0
I0 I0
C B A Q1 Q2
0 0 0 0 0

0 0 1 1 1

0 1 0 1 1

0 1 1 1 1

1 0 0 1 1

1 0 1 1 1

1 1 0 1 1

1 1 1 1 1

↑ ↑
A∨(B∨C) (A∨B)∨C

Exercise 1: 1st distributive law  

Fig.5a : Experiment set-up -   Fig.5b : Experiment set-up, 


1st distributive law   1st distributive law 
Q1 = A · (B ∨  C) Q2 = (A · B) ∨  (A · C)
Table 1
Q2 Q1 Q0
I0 I0

C B A Q1 Q2
0 0 0 0 0
0 0 1 0 0
0 1 0 0 0
0 1 1 1 1
1 0 0 0 0
1 0 1 1 1
1 1 0 0 0
1 1 1 1 1
Q1=A·(B∨C)
Q2 = (A·B) ∨(A·C)

Exercise :2nd distributive law

Fig.6a : Experiment set-up,  Fig.6b : Experiment set-up, 


2nd distributive law 2nd distributive law
Q1 = A ∨  (B · C) Q2 = (A ∨  B) · (A ∨  C)

Table 2
Q2 Q1 Q0
I0 I0
C B A Q1 Q2
0 0 0 0 0
0 0 1 1 1
0 1 0 0 0
0 1 1 1 1
1 0 0 0 0
1 0 1 1 1
1 1 0 1 1
1 1 1 1 1
Q1 = A∨(B·C)
Q2 = (A ∨ B) · (A ∨ C)

Exercise: Q = A +  (A · B)

Fig.7 : Experiment set-up - Q = A ∨  (A · B)


Table 1
Q1 Q0
I0

B A Q
0 0 0  

0 1 1
1 0 0
1 1 1

  Q = A ∨  (A · B) =  

Exercise:              A · (A + B)  

Fig.8 : Experiment set-up - Q = A · (A ∨  B)

Table 2  
Q1 Q0
I0
B A Q
0 0 0
0 1 1
1 0 0
1 1 1

  Q = A · (A ∨ B) =    

 Exercise 3              A · ( A’ + B )  

Experiment set-up

Fig.9: Experiment set-up - Q = A · (A’ +  B)


Table 3
Q1 Q0
I0

B A Q
0 0 0  

0 1 0
1 0 0
1 1 1

  Q = A · ( A’ ∨ B ) =    

 Exercise 4              A +( A’ · B )

Fig.10: Experiment set-up - Q = A ∨  (A’ · B)

Table 4  
Q1 Q0
I0

B A Q
0 0 0
0 1 1
1 0 1
1 1 1

  Q = A ∨ (A’ · B) =    

Lab Exercises:

 Q2.1 Write the commutative law in your own words. Is this law the same as the commutative law for
normal multiplication?
Commutative law used in OR & AND gate operation,
In case of OR gate A+B = B+A describe that if two inputs A & B are the same then change the ordering of the
inputs resultant output will not change in both (A+B , B+A) case.
In case of AND gate A.B = B.A describe that if two inputs A & B are the same then change the ordering of the
inputs resultant output will not change in both (A.B , B.A) case.
For normal multiplication rule this commutative law is the same as mathematics multiplication.
 Q2.2 Write the associative law in your own words. Is this law the same as the associative law for
normal multiplication & normal addition?
A+(B+C) = (A+B)+C
In case of OR gate A+(B+C) = (A+B)+C describe that if three inputs A, B & C are the same then change the
ordering of the inputs resultant output will not change in both case.
A.(B.C) = (A.B).C
In case of AND gate A.(B.C) = (A.B).C describe that if three inputs A, B & C are the same then change the
ordering of the inputs resultant output will not change in both case.
For normal multiplication rule & normal addition this Associate law is the same as mathematics operation.

 Q2.3 Write the distributive law in your own words. Is this law the same as the distributive law in
normal algebra?
 The distributive law is written for three variables as follows: A(B + C) = AB + AC This law states that
ORing two inputs and then ANDing the result with a single variable is equivalent to ANDing the single
variable with each of the two or more variables and then ORing the products.
This law is same as the normal mathematics rules.
 Q2.4 Why we simplify the logical expressions in Boolean algebra?
We do simplify the logical expression for logical circuit implementation as if we do not simplify the
logical expression the circuit may be in large size. This will take much space and cost so we have some
rules to solve the Boolean expression. As in result the output of the simplified circuit is the same.

You might also like