0% found this document useful (0 votes)
800 views57 pages

Lesson Plan: Boolean Algebra and Logic Gates

This lesson plan introduces students to Boolean algebra and logic gates over 120 minutes. It aims to give students knowledge of Boolean operators, fundamental logic gates, truth tables, and circuit design. The lesson begins with an introduction and pre-assessment, followed by a development section covering Boolean operators, logic gates like AND, OR, NAND and NOR gates, and truth tables. It concludes with recapping the main points, assessing student learning outcomes, and planning for the next lecture.

Uploaded by

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

Lesson Plan: Boolean Algebra and Logic Gates

This lesson plan introduces students to Boolean algebra and logic gates over 120 minutes. It aims to give students knowledge of Boolean operators, fundamental logic gates, truth tables, and circuit design. The lesson begins with an introduction and pre-assessment, followed by a development section covering Boolean operators, logic gates like AND, OR, NAND and NOR gates, and truth tables. It concludes with recapping the main points, assessing student learning outcomes, and planning for the next lecture.

Uploaded by

Roman Mia
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 57

Lesson Plan

Title: Boolean Algebra and Logic Gates Ref. No: Lecture


18, 19
Target Population: CSC 103 Duration: 120 min
Aims: To introduce students to Boolean Algebra and Logic Gates

Learning outcomes: At the end of the lecture, the students will have a
knowledge of different types of Boolean operators and fundamental gates,
truth table and logic circuit design.

Content Method/ Resource or Time


Technique Aid
Introduction: Attendance, Lecture; Q/A White board, 20 min
Rapport building, Summary Multimedia
of the previous lecture by a projector
student, Questions from the
previous class, Pre-
assessment, Lecture outline
Development: Lecture, Q/A, White board, 80 min
1. Importance of Boolean algebra Discussion Multimedia
2. Boolean operators projector
3. Definition of logic gate
4. Different types of logic gates
5. Truth Table
6. Circuit drawing

Conclusion: Lecture, Q/A White board, 20 min


1. Recap of main points Multimedia
2. Students’ Feedback & Answer projector
3. Assessment of students’
Learning Outcomes
4. References/Suggested Reading
(Lecture notes and pages 50-72
of CSE book) and Forward
planning for next lecture

2
Importance of Boolean Algebra
Boolean logic is a form of algebra in which all
values are reduced to either TRUE or FALSE.
Boolean algebra is extremely important in
computer sciences, such as programming,
database querying and computer engineering,
as electrical signals at the most basic level are
translated to and from binary (true/false, 1/0,
on/off, closed/open, etc).
Boolean Algebra is used to analyze and
simplify the digital (logic) circuits. It uses
only the binary numbers i.e. 0 and 1. It is
also called as Binary Algebra or logical
Algebra. 

Boolean algebra was invented by George


Boole in 1854.
Boolean Operators and
Fundamental Gates
Arithmetic operators: + (add), - (subtract), x
(multiply) and / (divide).
a+b
a and b are called operands; + is the operator.
Apart from arithmetic operators, we can define
logical operators which operate on truth values; a
truth value can be TRUE or FALSE.
Basic Operations of Boolean Algebra

• Like other algebras, Boolean Algebra uses


variables (called statements) and operators.

• Variables in Boolean algebra is called logic variable


that only has 2 possible values, either true (1) or
false (0) whereas its operator is called logical
operator or Boolean operator.
The common logical operators (which are also
called Boolean operators) are:
AND
OR
NOT
Logic symbols
Symbol Symbol Name Meaning / definition Example
· and and x · y
^ caret / circumflex and x ^ y
& ampersand and x & y
+ plus or x + y
∨ reversed caret or x ∨ y
| vertical line or x | y
x' single quote Not x'
¯ bar Not x
! exclamation mark Not ! x
not Not ¬ x
¬
~ tilde Not ~ x
⊕ circled plus / oplus exclusive or - xor x ⊕ y
Logic Gate

A logic gate is an elementary building block


of a digital circuit. Most logic gates have two
inputs and one output. At any given moment,
every terminal is in one of the two binary
conditions low (0) or high (1), represented by
different voltage levels.
• A Logic Gate in an electronic sense makes a
‘logical’ decision based upon a set of rules, and if
the appropriate conditions are met then the gate
is opened and an output signal is produced.
 
• Logic gates are therefore the decision making
units in electronic systems and there are many
different types for different applications. We will
now look at different type of gates and the rules
each one uses to decide an appropriate output.
The Truth Table is a chart that shows all possible
combinations of inputs and the resulting
outputs.
There are 2 to the power n possible combination
of inputs.  For example with three inputs there
are 2^3=8 possible combination of inputs.
All permutations of the inputs are listed on the
left, and the output of the circuit is listed on the
right. The desired output can be achieved by a
combination of logic gates.
1. The NOT gate (or inverter)

This is the simplest form of


logic gate and has only one
input and one output. So
how can it make a decision if
it only has one input? Simply
the purpose of this gate is to
invert the input signal so if a
Logic 0 is at the input, the
output will be at Logic 1 and
vice versa. The symbol for a
NOT gate is as follows.
13

NOT Logic Symbol

Output
Input 1 0

Input 0 1 Output

13
Truth Table for NOT Gate
The truth table for a NOT gate is the simplest of
all Truth Tables and is shown below:

Input Output

0 1

1 0

14
2.The AND gate.

We will start with a two-input AND gate. The


symbol for a two-input AND gate is as follows.
The truth table for the two input AND gate is shown below:

Inputs Output
A B Q
0 0 0
0 1 0
1 0 0
1 1 1
• We can see that the output is only at a Logic 1
when Input A AND Input B are at a Logic 1.

• The Boolean expression for a two input AND


gate is Q=A.B
Now we will consider a three-input AND gate.
The symbol is:

Q
The truth table for the three-input AND gate is shown below:

Inputs Output
A B C Q
0 0 0 0
0 0 1 0
0 1 0 0
0 1 1 0
1 0 0 0
1 0 1 0
1 1 0 0
1 1 1 1
• We can see that the output is only at a Logic 1
when Input A AND Input B AND Input C are at
a Logic 1.

• The Boolean expression for a three-input AND


gate is Q=A.B.C

Prepare a Truth Table for a four-input AND gate


and give the Boolean expression for it.
3. The OR gate

The symbol for a two-input OR gate is as follows:

A
Q
B
The truth table for the two-input OR gate is shown below:

Inputs Output
A B Q
0 0 0
0 1 1
1 0 1
1 1 1

We can see that the output is at a Logic 1 when


Input A OR Input B OR both are at a Logic 1.
The Boolean expression for a 2 input OR gate is:
Q=A+B
Three-input OR gate symbol:

Q
Truth Table for three-input OR gate
Inputs Output
A B C Q
0 0 0 0
0 0 1 1
0 1 0 1
0 1 1 1
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 1
• We can see that the output is at a Logic 1
when either Input A OR Input B OR Input C OR
any combination are at a Logic 1.

• The Boolean expression for a three-input OR


gate is: Q=A+B+C

• Prepare a Truth Table for a four-input OR gate


and give the Boolean expression for it.
4.The NAND gate.

The symbol for a two-input NAND gate


The truth table for the two-input NAND gate
Inputs Output
A B Q
0 0 1
0 1 1
1 0 1
1 1 0

If you compare this truth table with that for the AND
gate, you will find that the output Q is the exact
opposite to the AND gate.
The Boolean expression for a 2 input NAND gate is:
Q=AB
Construct Truth Tables for 3-input and 4-
input NAND gates with their symbols and
Boolean expressions.
5.The NOR gate
The symbol for a two-input NOR gate
Truth Table for two-input NOR gate
Inputs Output
A B Q
0 0 1
0 1 0
1 0 0
1 1 0

If you compare this truth table with that for the OR gate, you
will find that the output Q is the exact opposite of the OR gate.

The Boolean expression for a 2 input NOR gate is: Q=A+B


Construct Truth Tables for 3-input
and 4-input NOR gates with their
symbols and Boolean expressions.
6. The XOR ( eXclusive-OR ) gate
Truth Table for XOR gate
Inputs Output
A B Q
0 0 0
0 1 1
1 0 1
1 1 0

Comparison with the 2 input OR gate will reveal that Q is


a Logic 1 when either A or B is a Logic 1, but not when A
and B are Logic 1. Expression: Q = A ⊕ B
Q = A.B +A.B
7.The XNOR Gate.
The XNOR Gate
Boolean expression for XNOR gate

• Q = A ⊕ B or

• Q = A.B +A.B
8. Universal logic gates

• NOR gates alone (or alternatively NAND gates


alone) can be used to reproduce the functions
of all the other logic gates. Consequently,
these gates are sometimes called universal
logic gates.
Exercises:

Derive truth tables for the following Boolean


expressions:
1. NOT(A OR B)
2. (NOT A) OR (NOT B)
3. (NOT A) OR B
4. (NOT A) AND (NOT B)
5. (NOT A) AND (A OR (NOTB))
Exercise
Derive truth tables for the following:
1) (A AND B) OR (NOT C)
2) A AND (B AND C)
3) (A AND B) AND C
4) (NOT A) AND (B OR C)
5) NOT(A AND B) OR C
6) Construct a truth table for a Boolean
function, X = A + B . C
Circuit Drawing

1. Equation to Circuit
To convert a Boolean expression to a gate
circuit, evaluate the expression using standard
order of operations: multiplication before
addition, and operations within parentheses
before anything else.
Examples: A+C
• B (A+C)
AB+BC (B+C)
Circuit to Equation

To convert a gate circuit to a Boolean


expression, label each gate output with a
Boolean sub-expression corresponding to the
gates' input signals, until a final expression is
reached at the last gate.

Example:
Problem: Draw the circuit diagram for the equation AB + (AC)ʹ.
Write down the corresponding Boolean expression for following circuit.
Exercises:

Derive truth tables for the following Boolean


expressions:
1. NOT(A OR B) = W
2. (NOT A) OR (NOT B) = W
3. (NOT A) OR B = W
4. (NOT A) AND (NOT B) = W
5. (NOT A) AND (A OR (NOTB)) = W
Exercises:

Derive truth tables for the following Boolean


expressions:
1. NOT(A AND B) = Q
2. (NOT A) AND (NOT B) = Q
3. (NOT A) OR B = Q
4. (NOT A) OR (NOT B) = Q
5. (NOT A) AND (A OR (NOTB)) = Q
Here are some logic gate circuit problems:

• Draw a logic circuit for (A + B)C.


• Draw a logic circuit for A + BC + D.
• Draw a logic circuit for AB + AC.
• Draw a logic circuit for (A + B)(C + D)C.
The Boolean equations labelled A – I,
below are to be used to answer the
following questions.
Q  A B
Q  A.B
Q  A B Q  A.B  A.B

Q  A.B  A.B
Q  A B

QA Q  A.B

Q  A B
1. Which expression is correct for an AND gate. ……
2. Which expression is correct for a NOT gate. ……………
3. Which expression is correct for a NOR gate. ……………
4. Which two expressions are correct for an EXOR gate.
……… & ………
5. Which expression is correct for a NAND gate. ………
6. Which two expressions are correct for an XNOR gate.
……… & ………
7. Which expression is correct for an OR gate. ……………
Look at the following logic symbols
labelled A – G.
a) Which is the correct symbol for an AND gate. ……………

b) Which is the correct symbol for a NOT gate. ……………

c) Which is the correct symbol for a NOR gate. ……………

d) Which is the correct symbol for an EXOR gate. …………

e) Which is the correct symbol for a NAND gate. ……………

f) Which is the correct symbol for an XNOR gate. …………

g) Which is the correct symbol for an OR gate. ……………

You might also like