Assignment unit 3 – Smart Home Security System using Boolean Algebra and Logic Gates
Assignment unit 3 – Smart Home Security System using Boolean Algebra and Logic Gates
Question 1:
a. Define Boolean expressions:
I am using the following short names:
b. Simplify:
● Since both X and Y are just single variables, they are already in their simplest form, and
no need to simplify further.
Question 2:
Let’s say:
Now, we want to write what happens when these things are not true:
Example:
● De Morgan's theorems are just special rules in Boolean algebra that help us flip AND to
OR and OR to AND, when we are using NOT.
● These are helpful when designing circuits, because sometimes it’s easier to use one
type of gate (like using only AND or NOR gates).
Question 3:
a. Truth table for AND gate: “Motion sensor AND front Door is opened:
b. Truth table for NOR gate: “Alarm is armed NOR windows are closed”.
Let:
● A = Alarm is armed
● B = Windows are closed
● Expression: X AND Y
● Truth table matches exactly – the result is 1 only when both X and Y are 1.
● Expression: NOT (A OR B)
● Again, this matches the NOR truth table. Only gives 1 when both A and B are 0.
● The expressions work exactly like the gates in the truth tables.
● AND only gives true when both inputs are true.
● NOR is like OR but with a NOT added, it gives true only when both inputs are
false.
● So the expressions and truth tables are equivalent. Everything checks out.
Question 5:
OR