Week 4 - BOOLEAN ALGEBRA AND LOGIC GATES 1

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 36

Honesty Game

If you think it’s TRUE raise your


right hand and put it on your
chest.
If you think it’s FALSE raise your
left hand and put it on your
head.
Observe your other classmate
too, so that you get to know
them well.
1. Your life is a phase full of energy, hope, life, joy and beauty.
2. You do not have responsibility on your shoulders and enjoying a carefree life.
3. You are great explorer of new things without fear and easily molded.
4. You are experiencing a challenging journey to make your decisions right, choosing right
environment and people, and expressing emotions.
5. You are oversensitive, have feelings of entitlement, and you are also babied.
6. You’re living your lives in the internet world, to where a constant stream of knowledge
and information can be seen and displayed.
7. You are in state of great pressures and mood swings.
8. When you are advised to be matured enough, yet you tend to be treated like kids.

9. You are a K-pop fan.


10. You are behaving like a responsible person and doing something great, doing
extraordinary things for your success.
Short Pre-test
Direction: Analyze the following and choose the letter of the Best answer.
1. Which of the following Boolean expressions returns a false result?
a. True AND False b. True OR False c. NOT False d. True and True
2. When you use the advanced settings in an online search engine and use the
option to search for 'all these words', which type of Boolean logic are you using?
a. AND b. OR c. NOT d. No Boolean Logic
3. Consider the following inputs: c = 5; b = 8; d = 3. If (c < b) OR (b < d)
What does it mean?
a. Invalid b. False c. True d. 3
4. Why are NAND and NOR gates considered to be functionally complete?
a. Each could be made of AND, OR and NOT gates.
b. They are equivalent to each other.
c. They require fewer transistors.
d. Each could be used exclusively to form any other gate operation.
5. Which of the following combinations of gates would produce the following
truth table?

a. c.

b. d.
Key to correction:

1. b. True OR False
2. a. AND
3. c. True
4. a. Each could be made of AND, OR and NOT gates.

5. a.
At the end of the lesson you are expected to:
➢Explain the basis of logic;
➢Understand and perform various binary operations
such as addition (OR), multiplication (AND), and
negation (NOT) ;
➢Apply Boolean properties;
➢Develop logical truth table based on Boolean
equations.
What is a logic?
✓ It came from the Greek word logos, which can
be translated as "opinion", "expectation",
"reason", or "argument".
✓ Logic in science
--- is concerned with the evaluation of arguments,
namely with deciding whether they are correct or
not, as well as being consistent, complete and
sound.
✓ Logic in research-
-- implies that the research is guided by the rules
of logical reasoning and the logical process of
induction and deduction.
✓ Logic in math-
-- the logic statements can involve words, and
symbols together or just symbols.
What is a Boolean Algebra?
❑Boolean algebra is a mathematical system for the
manipulation of variables that can have one of two
values.
• In formal logic, these values are “true” and “false.”
• In digital systems, these values are “on” and “off,” 1 and 0, or
“high” and “low.”
❑Boolean expressions are created by performing
operations on Boolean variables.
• Common Boolean operators include AND, OR, and NOT and etc.
What is Logic Gates?
❑Are the basic building blocks of any digital
system.
❑The relationship between the input and
the output is based on a certain logic.
❑Logic gates are named as AND gate, OR
gate, NOT gate.
(NAND, XOR, NOR Gates)
Not Gate is a horizontal bar X or X’
above the number/variable
0=1
1=0
Or Gate is a plus/addition X+Y
0+0 = 0
0+1 = 1
1+0 = 1
1+1 = 1
And is multiplication
0*0 = 0 X•Y XY
0*1 = 0
1*0 = 0
1*1 = 1
Boolean Algebra, Logic Gates (AND, OR, Not) & Truth Table

❑ AND X•Y XY
▪ When both the inputs are high,
then the output is high,
otherwise the output is low.
❑ OR X+Y
▪ If any of the input is high , then
the output is high.

❑ NOT X X’
▪ The output is inversely
proportional to the input.
Universal Gates (the
NAND and NOR gates)

Because all the other


gates like AND, OR, NOT,
XOR, and XNOR gates can
be from it.
The exclusive
OR (XOR) gate.
The output of the
XOR operation is
true only when
the values of the
inputs differ.
Complement’s of NAND, NOR and XOR
Neg-OR

Neg-AND
1. 2. 3. 4.

Identify each of these logic gates by name, and complete


their respective truth tables:
5. 6.

7.
8.
9.
Write the Boolean expression for each of these logic
gates, showing how the output (Q) algebraically relates
to the inputs (A and B):
1. 2. 3.

4. 5. 6.
8.
7.

9.
Remember
❖Gates can have multiple inputs and more than one output.
✓A second output can be provided for the complement of the
operation.
Number of possible input =
What is the significance or
importance of “LOGIC” in
our lives?
1. Which gate only has an output of 1 if both inputs are 1?
A. OR B. NAND C. NOR D. AND
2. Which gate has an output of 1 if one but not both inputs is
1?
A. OR B. XOR C. NOT D. AND
3. Which gate has an output of 1 unless both inputs are 1?
A. NAND B. AND C. XOR D. NOR
4. Logic gates must have two inputs and one output?
A. True B. False
5. XOR gate can be made from?
A. All NAND gates B. All NOR gates C. Both A and D D. AND, OR and NOT gates
6. If both inputs are 1 in an OR gate the output will be 0?
A. True B. False
7. XOR gates can be made from?
A. All NAND Gates C. AND, OR, and NOT Gates
B. All NOT gates D. Both A and C
8. Which gate gives outputs which are opposite to the outputs given by a NAND
gate?
A. AND Gate B. NOR Gate C. OR Gate D. XOR Gate
9. In boolean algebra, which operation does putting a bar above a letter
represent?
A. AND Gate B. NOT Gate C. OR Gate D. None of the above
10. Which gate will have the output 1 if both inputs are 0?
A. NOR Gate B. OR Gate C. XOR Gate D. NAND Gate
“We can accomplish self-discovery,
expansion of consciousness, and self
renewal. Therefore, when we faced our
daily routine, difficult problem or situation
and issues to resolve, logic and reasoning
are important to remember and be applied
for the best or most desired results.”
1. Which gate only has an output of 1 if both inputs are 1?
A. OR B. NAND C. NOR D. AND
2. Which gate has an output of 1 if one but not both inputs is
1?
A. OR B. XOR C. NOT D. AND
3. Which gate has an output of 1 unless both inputs are 1?
A. NAND B. AND C. XOR D. NOR
4. Logic gates must have two inputs and one output?
A. True B. False
5. XOR gates can be made from?
A. All NAND gates B. All NOR gates C. BOTH A and D D. AND, OR and NOT gates
6. If both inputs are 1 in an OR gate the output will be 0?
A. True B. False
7. XOR gate can be made from?
A. All NAND Gates C. AND, OR, and NOT Gates
B. All NOT gates D. Both A and C
8. Which gate gives outputs which are opposite to the outputs given by a NAND
gate?
A. AND Gate B. NOR Gate C. OR Gate D. XOR Gate
9. In boolean algebra, which operation does putting a bar above a letter
represent?
A. AND Gate B. NOT Gate C. OR Gate D. None of the above
10. Which gate will have the output 1 if both inputs are 0?
A. NOR Gate B. OR Gate C. XOR Gate D. NAND Gate
SUMMARY 4.

2.

1.
3.
6.
5.

7.

8. 9.
Needs Improvement Fair Good Excellent Total Points
(4 pts.) (6 pts.) (8 pts.) (10 pts.)
Innovative Design (10 Too simple with Quite unique and Structure is standard with Structure and programming were
pts.) unnecessary creative with fewer necessary manipulators and unexpected.
manipulators that makes manipulators. sensors.
the bot unstable.
Locomotion and Difficulty to do task, Goes with a defined Do its task very well which Robot has a desired and well-
Navigation (10 points) inaccurate or direction according to its allows sensors to work well. defined task with consistency.
inconsistent. task.
Programming (20 points) Programming is Programming is Programming is organized Programming is logically organized
inefficient and somewhat organized and and the robot do what is and very efficient.
disorganized. do some of the task expected.
which is/are expected
about the Bot.

Structural The robot’s structural Robot structure is Robot’s base is stable. Robot’s assembly is reliable and
(25 points) foundation is weak. Easily somewhat stable and Showed planned ideas from durable. The Bot was designed
falls apart. show’s team’s design the team. very well with uniqueness and
ideas. creativity.

Teamwork Little knowledge of There was evidence of The knowledge of structure, The team completely understand
(35 points) teamwork. teamwork in the design, assembly, design and what’s going on about the robot’s
Programming, structure programming and programming was directed by task, programming, design and its
and design of the Bot structure. the team members. structure.
was done only by few The team also showed the
members. (2 or 3) underlying science and technology
of their robot.

You might also like