0% found this document useful (0 votes)
2 views17 pages

Unit 2 Computer Organization

Boolean algebra, proposed by George Boole in 1854, is a branch of algebra that deals with binary variables and logical operations, essential for digital electronics, set theory, and statistics. It includes operations such as negation (NOT), conjunction (AND), and disjunction (OR), which are foundational for constructing logical expressions and truth tables. Key laws and theorems, including De Morgan's laws, govern the manipulation of these expressions, allowing for simplification and analysis in various mathematical contexts.

Uploaded by

sw59rldvtn
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views17 pages

Unit 2 Computer Organization

Boolean algebra, proposed by George Boole in 1854, is a branch of algebra that deals with binary variables and logical operations, essential for digital electronics, set theory, and statistics. It includes operations such as negation (NOT), conjunction (AND), and disjunction (OR), which are foundational for constructing logical expressions and truth tables. Key laws and theorems, including De Morgan's laws, govern the manipulation of these expressions, allowing for simplification and analysis in various mathematical contexts.

Uploaded by

sw59rldvtn
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Boolean Algebra

Boolean algebra is a type of algebra that is created by operating the binary system.
In the year 1854, George Boole, an English mathematician, proposed this algebra.
This is a variant of Aristotle’s propositional logic that uses the symbols 0 and 1, or
True and False. Boolean algebra is concerned with binary variables and logic
operations.
Boolean Algebra is fundamental in the development of digital electronics systems as
they all use the concept of Boolean Algebra to execute commands. Apart from
digital electronics this algebra also finds its application in Set Theory, Statistics, and
other branches of mathematics.
What is Boolean Algebra?
Boolean Algebra is a branch of algebra that deals with boolean values—true and
false. It is fundamental to digital logic design and computer science, providing a
mathematical framework for describing logical operations and expressions
Boolean Algebra Operations
Various operations are used in Boolean algebra but the basic operations that form
the base of Boolean Algebra are.
 Negation or NOT Operation
 Conjunction or AND Operation
 Disjunction or OR Operation
These operations have their own symbols and precedence and the table added
below shows the symbol and the precedence of these operators.

Operator Symbol Precedence

NOT ‘ (or) ⇁ First

AND . (or) ∧ Second

OR + (or) ∨ Third

We can easily define these operations using two boolean variables.


Let’s take two boolean variables A and B that can have any of the two values 0 or 1,
i.e. they can be either OFF or ON. Then these operations are explained as,
Negation or NOT Operation
Using the NOT operation reverse the value of the Boolean variable from 0 to 1 or
vice-versa. This can be understood as:
 If A = 1, then using NOT operation we have (A)’ = 0
 If A = 0, then using the NOT operation we have (A)’ = 1
 We also represent the negation operation as ~A, i.e if A = 1, ~A = 0
Check: Properties of Boolean Algebra
Conjunction or AND Operation
Using the AND operation satisfies the condition if both the value of the individual
variables are true and if any of the value is false then this operation gives the
negative result. This can be understood as,
 If A = True, B = True, then A . B = True
 If A = True, B = False, Or A = false, B = True, then A . B = False
 If A = False, B = False, then A . B = False

Disjunction (OR) Operation


Using the OR operation satisfies the condition if any value of the individual variables
is true, it only gives a negative result if both the values are false. This can be
understood as,
 If A = True, B = True, then A + B = True
 If A = True, B = False, Or A = false, B = True, then A + B = True
 If A = False, B = False, then A + B = Falses
Boolean Algebra Table

Boolean Algebra Table


Given Below is the Expression for the Boolean Algebra

Operation Symbol Definition

AND Operation ⋅ or ∧ Returns true only if both inputs are true.

OR Operation + or ∨ Returns true if at least one input is true.


Operation Symbol Definition

NOT Operation ¬ or ∼ Reverses the input.

XOR Operation ⊕ Returns true if exactly one input is true.

NAND Operation ↓ Returns false only if both inputs are true.

NOR Operation ↑ Returns false if at least one input is true.

XNOR Operation ↔ Returns true if both inputs are equal.

Boolean Expression and Variables


Boolean expression is an expression that produces a Boolean value when
evaluated, i.e. it produces either a true value or a false value. Whereas boolean
variables are variables that store Boolean numbers.
P + Q = R is a Boolean phrase in which P, Q, and R are Boolean variables that
can only store two values: 0 and 1. The 0 and 1 are the synonyms for false and
True and are used in Boolean Algebra, sometimes we also use “Yes” in place
of True and “No” in place of False.
Thus, we can say that statements using Boolean variables and operating on
Boolean operations are Boolean Expressions. Some examples of Boolean
expressions are,
 A + B = True
 A.B = True
 (A)’ = False
Check: Axioms of Boolean Algebra
Boolean Algebra Terminologies
There are various terminologies related to Boolean Algebra, which are used to
explain various parameters of Boolean Algebra. That includes,
 Boolean Variables
 Boolean Function
 Literal
 Complement
 Truth Table
Now, we will discuss the important terminologies of Boolean algebra in the
article below,
Boolean Variables
Variables used in Boolean algebra that store the logical value of 0 and 1 are
called the boolean variables. They are used to store either true or false values.
Boolean variables are fundamental in representing logical states or
propositions in Boolean expressions and functions.
Boolean Function
A function of the Boolean Algebra that is formed by the use of Boolean
variables and Boolean operators is called the Boolean function. It is formed by
combining Boolean variables and logical expressions such as AND, OR, and
NOT. It is used to model logical relationships, conditions, or operations.
Literal
A variable or the complement of the variable in Boolean Algebra is called the
Literal. Literals are the basic building blocks of the boolean expressions and
functions. They represent the operands in logical operations.
Complement
The inverse of the Boolean variable is called the complement of the variable.
The complement of 0 is 1 and the complement of 1 is 0. It is represented by ‘ or
(¬) over the variable. Complements are used to represent logical negations in
Boolean expressions and functions.
Truth Table
Table containing all the possible values of the logical variables and the
combination of the variable along with the given operation is called the truth
table. The number of rows in the truth table depends on the total Boolean
variables used in that function. It is given by using the formula,
Number of Rows in Truth Table = 2 n
where “n” is the number of Boolean variables used.
Truth Tables in Boolean Algebra
A truth table represents all the combinations of input values and outputs in a
tabular manner. All the possibilities of the input and output are shown in it and
hence the name truth table. In logic problems, truth tables are commonly used
to represent various cases. T or 1 denotes ‘True’ & F or 0 denotes ‘False’ in the
truth table.
Example: Draw the truth table of the conditions A + B and A.B where A and b
are boolean variables.
Solution:
The required Truth Table is,

A B X=A+B Y = A.B

T T T T

T F T F

F T T F

F F F F

Boolean Algebra Rules


In Boolean Algebra there are different fundamental rules for logical
expression.
 Binary Representation: In Boolean Algebra the variables can have only
two values either 0 or 1 where 0 represents Low and 1 represents high.
These variables represents logical states of the system.
 Complement Representation: The complement of the variables is
represented by (¬) or (‘) over the variable. This indicates logical negation
or inversion of the variable’s value. So Complement of variable A can be
represented by A‾A,if the value of A=0 then its complement is 1.
 OR Operation: The OR operation is represented by (+) between the
Variables. OR operation returns true if at least one of the operands is
true. For Examples let us take three variables A,B,C the OR operation
can be represented as A + B + C.
 AND Operation: The AND Operation is denoted by (.) between the
Variables. AND operation returns true only if all the operands are true.
For Examples let us take three variables A,B,C the AND operation can be
represented A.B.C or ABC.
Laws for Boolean Algebra
The basic laws of the Boolean Algebra are added in the table added below,
Law OR form AND form

Identity Law P+0=P P.1 = P

Idempotent Law P+ P=P P.P = P

Commutative Law P+ Q=Q+P P.Q = Q.P

Associative Law P + (Q + R) = (P + Q) + R P.(Q.R) = (P.Q).R

Distributive Law P + QR = (P + Q).(P + R) P.(Q + R) = P.Q + P.R

Inversion Law (A’)’ = A (A’)’ = A

De Morgan’s Law (P + Q)’ = (P)’.(Q)’ (P.Q)’ = (P)’ + (Q)’

Let’s learn about these laws in detail.


Identity Law
In the Boolean Algebra, we have identity elements for both AND(.) and OR(+)
operations. The identity law state that in boolean algebra we have such
variables that on operating with AND and OR operation we get the same result,
i.e.
 A+0=A
 A.1 = A
Commutative Law
Binary variables in Boolean Algebra follow the commutative law. This law
states that operating boolean variables A and B is similar to operating boolean
variables B and A. That is,
 A. B = B. A
 A+B =B +A
Associative Law
Associative law state that the order of performing Boolean operator is illogical
as their result is always the same. This can be understood as,
 (A.B).C =A.(B.C)
 ( A + B ) + C = A + ( B + C)
Distributive Law
Boolean Variables also follow the distributive law and the expression for
Distributive law is given as:
 A . ( B + C) = (A . B) + (A . C)
Inversion Law
Inversion law is the unique law of Boolean algebra this law states that, the
complement of the complement of any number is the number itself.
 (A’)’ = A
Apart from these other laws are mentioned below:
AND Law
AND law of the Boolean algebra uses AND operator and the AND law is,
 A.0=0
 A.1=A
 A.A=A
OR Law
OR law of the Boolean algebra uses OR operator and the OR law is,
 A+0=A
 A+1=1
 A+A=A
De Morgan’s Laws are also called De morgan’s Theorem. They are the most
important laws in Boolean Algebra and these are added below under the
heading Boolean Algebra Theorem
Boolean Algebra Theorems
There are two basic theorems of great importance in Boolean Algebra, which
are De Morgan’s First Laws, and De Morgan’s Second Laws. These are also
called De Morgan’s Theorems. Now let’s learn about both in detail.
De Morgan’s First laws
De Morgan’s Law states that the complement of the product (AND) of two
Boolean variables (or expressions) is equal to the sum (OR) of the complement
of each Boolean variable (or expression).
(P.Q)’ = (P)’ + (Q)’
The truth table for the same is given below:

P Q (P)’ (Q)’ (P.Q)’ (P)’ + (Q)’

T T F F F F

T F F T T T

F T T F T T

F F T T T T

We can clearly see that truth values for (P.Q)’ are equal to truth values for (P)’ +
(Q)’, corresponding to the same input. Thus, De Morgan’s First Law is true.
De Morgan’s Second laws
Statement: The Complement of the sum (OR) of two Boolean variables (or
expressions) is equal to the product(AND) of the complement of each Boolean
variable (or expression).
(P + Q)’ = (P)’.(Q)’
Proof:
The truth table for the same is given below:

P Q (P)’ (Q)’ (P + Q)’ (P)’.(Q)’

T T F F F F

T F F T F F

F T T F F F

F F T T T T

We can clearly see that truth values for (P + Q)’ are equal to truth values for
(P)’.(Q)’, corresponding to the same input. Thus, De Morgan’s Second Law is
true.
Examples on Boolean Algebra
Draw Truth Table for P + P.Q = P
Solution:
The truth table for P + P.Q = P

P Q P.Q P + P.Q

T T T T

T F F T

F T F F

F F F F

In the truth table, we can see that the truth values for P + P.Q is exactly the
same as P.
Draw Truth Table for P.Q + P + Q
Solution:
The truth table for P.Q + P + Q

P Q P.Q P.Q + P + Q

T T T T

T F F T

F T F T

F F F F

Solve A‾+B⋅CA+B⋅C
Solution:
Using De Morgan’s Law
A‾+B.C=A‾.(B+C)A+B.C=A.(B+C)
Using Distributive Law
A‾.(B+C)=A‾.B+A‾.CA.(B+C)=A.B+A.C
So, the simplified expression for the given equation
A‾.(B+C)=A‾.B+A‾.CA.(B+C)=A.B+A.C

Laws of Boolean algebra


There are the following laws of Boolean algebra:
Commutative Law
This law states that no matter in which order we use the variables. It means
that the order of variables doesn't matter. In Boolean algebra, the OR and the
addition operations are similar. In the below diagram, the OR gate display that
the order of the input variables does not matter at all.
For two variables, the commutative law of addition is written as:
A+B = B+A

For two variables, the commutative law of multiplication is written as:


A.B = B.A
Associative Law
This law states that the operation can be performed in any order when the
variables priority is same. As '*' and '/' have same priority. In the below
diagram, the associative law is applied to the 2-input OR gate.
For three variables, the associative law of addition is written as:
A + (B + C) = (A + B) + C

For three variables, the associative law of multiplication is written as:


A(BC) = (AB)C
According to this law, no matter in what order the variables are grouped when
ANDing more than two variables. In the below diagram, the associative law is
applied to 2-input AND gate.

Distributive Law:
According to this law, if we perform the OR operation of two or more variables
and then perform the AND operation of the result with a single variable, then
the result will be similar to performing the AND operation of that single
variable with each two or more variable and then perform the OR operation of
that product. This law explains the process of factoring.
For three variables, the distributive law is written as:
A(B + C) = AB + AC
Rules of Boolean algebra
There are the following rules of Boolean algebra, which are mostly used in
manipulating and simplifying Boolean expressions. These rules plays an
important role in simplifying boolean expressions.

1. A+0=A 7. A.A=A

2. A+1=1 8. A.A'=0

3. A.0=0 9. A''=A

4. A.1=A 10. A+AB=A

5. A+A=A 11. A+A'B=A+B

6. A+A'=1 12. (A+B)(A+C)=A+BC

Rule 1: A + 0 = A
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform OR operation with 0, the result will be the same as the input
variable. So, if the variable value is 1, then the result will be 1, and if the
variable value is 0, then the result will be 0. Diagrammatically, this rule can be
defined as:
Rule 2: (A + 1) = 1
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform OR operation with 1, the result will always be 1. So, if the variable
value is either 1 or 0, then the result will always be 1. Diagrammatically, this
rule can be defined as:

Rule 3: (A.0) = 0
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform the AND operation with 0, the result will always be 0. This rule
states that an input variable ANDed with 0 is equal to 0 always.
Diagrammatically, this rule can be defined as:

Rule 4: (A.1) = A
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform the AND operation with 1, the result will always be equal to the
input variable. This rule states that an input variable ANDed with 1 is equal to
the input variable always. Diagrammatically, this rule can be defined as:
Rule 5: (A + A) = A
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform the OR operation with the same variable, the result will always be
equal to the input variable. This rule states an input variable ORed with itself is
equal to the input variable always. Diagrammatically, this rule can be defined
as:

Rule 6: (A + A') = 1
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform the OR operation with the complement of that variable, the result
will always be equal to 1. This rule states that a variable ORed with its
complement is equal to 1 always. Diagrammatically, this rule can be defined
as:

Rule 7: (A.A) = A
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform the AND operation with the same variable, the result will always be
equal to that variable only. This rule states that a variable ANDed with itself is
equal to the input variable always. Diagrammatically, this rule can be defined
as:
Rule 8: (A.A') = 0
Let's suppose; we have an input variable A whose value is either 0 or 1. When
we perform the AND operation with the complement of that variable, the result
will always be equal to 0. This rule states that a variable ANDed with its
complement is equal to 0 always. Diagrammatically, this rule can be defined
as:

Rule 9: A = (A')'
This rule states that if we perform the double complement of the variable, the
result will be the same as the original variable. So, when we perform the
complement of variable A, then the result will be A'. Further if we again
perform the complement of A', we will get A, that is the original variable.

Rule 10: (A + AB) = A


We can prove this rule by using the rule 2, rule 4, and the distributive law as:
A + AB = A(1 + B) Factoring (distributive law)
A + AB = A.1 Rule 2: (1 + B)= 1
A + AB = A Rule 4: A .1 = A
Rule 11: A + AB = A + B
We can prove this rule by using the above rules as:
A + AB = (A + AB)+ AB Rule 10: A = A + AB
A+AB= (AA + AB)+ AB Rule 7: A = AA
A+AB=AA +AB +AA +AB Rule 8: adding AA = 0
A+AB= (A + A)(A + B) Factoring
A+AB= 1.(A + B) Rule 6: A + A = 1
A+AB=A + B Rule 4: drop the 1

Rule 12: (A + B)(A + C) = A + BC


We can prove this rule by using the above rules as:
(A + B)(A + C)= AA + AC + AB + BC Distributive law
(A + B)(A + C)= A + AC + AB + BC Rule 7: AA = A
(A + B)(A + C)= A( 1 + C)+ AB + BC Rule 2: 1 + C = 1
(A + B)(A + C)= A.1 + AB + BC Factoring (distributive law)
(A + B)(A + C)= A(1 + B)+ BC Rule 2: 1 + B = 1
(A + B)(A + C)= A.1 + BC Rule 4: A .1 = A
(A + B)(A + C)= A + BC

You might also like