Unit2 - Subjective Questions
ECE213 • Practice Questions with Detailed Answers
State and prove De Morgan's Theorems for two variables using Truth Tables.
De Morgan's Theorems are two fundamental rules in Boolean algebra used to simplify logical expressions and change logic gate implementation types.
Theorem 1: The complement of a product of variables is equal to the sum of their individual complements.
Theorem 2: The complement of a sum of variables is equal to the product of their individual complements.
Proof using Truth Table:
| A | B | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| 0 | 0 | 1 | 1 | 0 | 1 | 1 | 0 | 1 | 1 |
| 0 | 1 | 1 | 0 | 0 | 1 | 1 | 1 | 0 | 0 |
| 1 | 0 | 0 | 1 | 0 | 1 | 1 | 1 | 0 | 0 |
| 1 | 1 | 0 | 0 | 1 | 0 | 0 | 1 | 0 | 0 |
Columns 6 and 7 prove Theorem 1. Columns 9 and 10 prove Theorem 2.
Why are NAND and NOR gates referred to as Universal Gates? Demonstrate how to implement basic gates (AND, OR, NOT) using only NAND gates.
Universal Gates: NAND and NOR gates are called universal gates because any Boolean function or logical circuit can be implemented using only NAND gates or only NOR gates. It is not necessary to use other basic gates like AND, OR, or NOT.
Implementation using NAND Logic:
- NOT Gate: Connect both inputs of a NAND gate together.
- AND Gate: Follow a NAND gate with a NOT gate (made from NAND).
- OR Gate: Invert inputs A and B individually using NAND gates, then feed them into a NAND gate (De Morgan's Law application).
Simplify the following Boolean function using a K-Map and implement the simplified circuit using logic gates:\n
Step 1: Plotting the K-Map (4 variables)
We place 1s in cells: 0, 1, 2, 4, 5, 6, 8, 9, 12, 13, 14.
Step 2: Grouping
- Quad 1: Cells (0, 1, 4, 5, 8, 9, 12, 13). This is actually an Octet. All these cells have in common.
- Term:
- Quad 2: Cells (0, 2, 4, 6, 8, 10 is missing, 12, 14). Let's look closer.
- Group (0, 2, 4, 6): Row 0 and 1, Columns 00 and 10. Common: .
- Group (4, 6, 12, 14): Row 1 and 3, Columns 00 and 10. Common: .
- Group (8, 9, 12, 13) is covered by the octet.
- Group (0, 4, 8, 12) is covered by the octet.
Correction on Groups for Optimization:
- Octet (0, 1, 4, 5, 8, 9, 12, 13): Corresponds to variable .
- Quad (0, 2, 4, 6): Corresponds to .
- Quad (4, 6, 12, 14): Corresponds to .
Note: (0, 2, 4, 6) covers the remaining 1s at 2 and 6. The term covers 14.
Simplified Expression:
Step 3: Implementation
- Inputs: A, B, C, D.
- NOT gates for C, A, D.
- AND gates for and .
- One 3-input OR gate to sum , , and .
Differentiate between Canonical forms and Standard forms in Boolean algebra with examples.
Canonical Form:
- Also known as Expanded form.
- Each term in the expression must contain all the variables of the function, either in complemented or uncomplemented form.
- Types: Sum of Minterms (Canonical SOP) and Product of Maxterms (Canonical POS).
- Example: For function , is a canonical SOP.
Standard Form:
- Also known as Simplified or Minimal form.
- The terms do not necessarily contain all variables.
- Obtained after simplification (using Algebra or K-Maps).
- Types: Sum of Products (SOP) and Product of Sums (POS).
- Example: For function , is a standard form (derived from ).
Define Minterms and Maxterms. Explain the relationship between a minterm and a maxterm for the same combination of variables.
Minterm ():
A minterm is a standard product term in a Boolean function containing all variables exactly once, either complemented or uncomplemented. For a function of variables, there are minterms. It evaluates to 1 for a specific combination of inputs.
- Example (3 variables): For input 101, minterm is .
Maxterm ():
A maxterm is a standard sum term containing all variables exactly once. It evaluates to 0 for a specific combination of inputs.
- Example (3 variables): For input 101, maxterm is .
Relationship:
A minterm and a maxterm for the same index/combination are complements of each other.
Simplify the following Boolean expression using Boolean Algebra rules: \n
Step-by-step Simplification:
- Expression:
- Factor out from the last two terms:
- Apply Inverse Law ():
- Rearrange:
- Apply Absorption/Redundancy Law ():
Final Answer:
Explain the concept of Don't Care conditions in K-Maps. How do they aid in simplification?
Definition:
In digital systems, certain input combinations may never occur, or the output for certain input combinations may not matter (it can be either 0 or 1 without affecting system operation). These conditions are called Don't Care conditions, denoted by 'X', 'd', or ''.
Role in Simplification:
- When grouping 1s in a K-Map (for SOP), Don't Cares can be treated as 1s if they help form a larger group (pair, quad, or octet).
- If a Don't Care cell does not help in forming a larger group, it is treated as a 0 and ignored.
- This flexibility allows for larger groupings, which reduces the number of literals in the final expression, resulting in a simpler and cheaper circuit implementation.
State and prove the Consensus Theorem in Boolean Algebra.
Statement:
The Consensus Theorem states that if a term is the product of two variables (e.g., A and B), and another term is the product of the complement of one of these variables and a third variable (e.g., and C), then the product of the remaining two variables (B and C) is redundant if added to the expression.
Equation:
Proof:
- Take the LHS:
- Multiply the consensus term () by since :
- Expand:
- Rearrange:
- Factorize:
- Since :
= RHS (Proved)
Explain the XOR (Exclusive-OR) and XNOR (Exclusive-NOR) gates. Provide their symbols, truth tables, and Boolean expressions.
1. XOR Gate (Exclusive-OR):
- Function: Output is High (1) only when the inputs are different.
- Expression:
- Truth Table:
- 0, 0 0
- 0, 1 1
- 1, 0 1
- 1, 1 0
2. XNOR Gate (Exclusive-NOR):
- Function: Output is High (1) only when the inputs are same (Equivalence gate).
- Expression:
- Truth Table:
- 0, 0 1
- 0, 1 0
- 1, 0 0
- 1, 1 1
Convert the following expression into Canonical SOP (Sum of Products) form:\n
To convert to Canonical SOP, every term must contain all variables (A, B, C).
Expression:
Step 1: Expand the first term 'A'
- Missing variables: B and C.
- Multiply by and .
Step 2: Expand the second term 'BC'
- Missing variable: A.
- Multiply by .
Step 3: Combine and remove duplicates
- Remove duplicate .
Final Canonical SOP:
In sigma notation:
Distinguish between Prime Implicants (PI) and Essential Prime Implicants (EPI) in the context of K-Map simplification.
Prime Implicant (PI):
- A Prime Implicant is a product term obtained by combining the maximum possible number of adjacent 1s (squares) in the K-map.
- It represents a group that is not completely contained within any other larger group.
- Identification: Any valid group (pair, quad, octet) that cannot be expanded further.
Essential Prime Implicant (EPI):
- An Essential Prime Implicant is a Prime Implicant that covers at least one '1' (minterm) that is not covered by any other Prime Implicant.
- Importance: EPIs must be included in the final minimal expression to ensure all minterms are covered.
- Identification: Look for a '1' that is circled only once. The group belonging to that '1' is an EPI.
Obtain the simplified expression in POS (Product of Sums) form using a K-map for the function:\n
To find the simplified POS, we group the 0s in the K-map.
Since the input is given in Maxterms (), these indices represent the 0s in the map.
Plotting 0s:
- 0s at indices: 0, 1, 2, 3, 4, 10, 11.
Grouping:
- Quad 1: Cells (0, 1, 2, 3). This is the entire first row (Variables ).
- Term:
- Quad 2: Cells (0, 4) ... wait, let's look for better groups.
- Cells (2, 3, 10, 11) form a Quad. Row 0 and 2 ( changes, changes? No). Let's trace:
- Rows 00 (0,1,2,3) and 10 (8,9,10,11). Columns 11 and 10.
- This group is indices 2,3 (0011, 0010) and 10,11 (1010, 1011).
- Variable , Variable is constant? No.
- Let's check standard K-Map structure: Row 0 (), Row 2 ( - No, Row 3 is 10). Indices 2,3 are in Row 0. Indices 10,11 are in Row 2 ().
- Common in Row 0 and Row 2 is . Common in Col 3 and Col 2 is .
- Wait, Logic correction: Row 0 is . Row 2 is . Common is . Columns are $11$ and $10$. Common is . So term is .
- Cells (2, 3, 10, 11) form a Quad. Row 0 and 2 ( changes, changes? No). Let's trace:
- Remaining 0: Cell 4 (0100). Can combine with Cell 0 (0000) as a pair. Or (0,4) is .
- Is there a larger group for 4? No adjacent 0s at 5, 6, 12, 14, 20...
- Wait, map wrapping. (0, 4) is a pair. Term: ? No.
- Let's re-evaluate Quad 1 covers 0. So 4 needs to be covered. Group (0, 4). Term: .
Correct Groups:
- Quad (0, 1, 2, 3):
- Quad (2, 3, 10, 11): Common is (from rows) and (from cols - wait, maxterms invert literals).
- Row 0 ($00$) and Row 2 ($10$) -> is 0. So literal is .
- Col 3 ($11$) and Col 2 ($10$) -> is 1. So literal is .
- Term: .
- Pair (0, 4): This is redundant if 0 is covered? No, 4 must be covered.
- Group (0,4): Row 00 and 01. . Col 00. .
- Term: .
Final Expression:
Explain the Principle of Duality in Boolean Algebra. Find the dual of .
Principle of Duality:
The principle states that every algebraic identity deducible from the postulates of Boolean algebra remains valid if:
- The operators AND () and OR () are interchanged.
- The identity elements 0 and 1 are interchanged.
- Variables are kept distinct (NOT kept same, but literals remain as they are, i.e., stays , stays ).
Finding the Dual:
Expression:
- Change to
- Change to
Dual Expression:
Implement the following Boolean function using only NOR gates: \n
To implement using NOR logic, the function fits the POS form naturally, but NOR logic typically realizes a specific structure.
Logic Transformation:
We want to use NOR gates ().
- The expression is in POS form.
- Let's treat and as inputs to an AND operation.
- Using De Morgan's Law on the final output to convert AND to NOR structure requires inversion.
Implementation Steps:
- Gate 1: Inputs A, B. Output (NOR).
- Gate 2: Inputs C, D. Output (NOR).
- We need . Note that and .
- Feed X and Z into a third NOR gate.
- Apply De Morgan's Law:
Circuit: Three NOR gates are required. Two at the first level taking (A,B) and (C,D), and one at the second level taking the outputs of the first two.
Minimize the following function using a K-Map assuming that the condition for input combinations 0, 2, and 5 are Don't Cares.\n
Plotting the K-Map (3 Variables):
- 1s: Cells 1, 3, 4, 6.
- Don't Cares (X): Cells 0, 2, 5.
Grouping:
- We want to cover all 1s. Don't cares are used only if they enlarge a group.
- Group 1 (Octet?): Cells 0, 1, 2, 3, 4, 5, 6, 7? No, 7 is 0.
- Quad 1: Cells (0, 1, 2, 3). Contains 1s (1, 3) and Xs (0, 2). Valid Quad.
- Rows: . Cols: All. Term: .
- Quad 2: Cells (0, 2, 4, 6). Contains 1s (4, 6) and Xs (0, 2). Valid Quad.
- Rows: All. Cols: 00 and 10 (). Term: .
- Check coverage: All 1s (1, 3, 4, 6) are covered.
Simplified Expression:
Describe the positive and negative logic systems.
In digital electronics, binary variables (0 and 1) are represented by voltage levels. The mapping determines the logic system.
1. Positive Logic System:
- The higher voltage level is assigned the logic value 1 (High).
- The lower voltage level is assigned the logic value 0 (Low).
- Example: +5V = Logic 1, 0V = Logic 0.
2. Negative Logic System:
- The lower voltage level is assigned the logic value 1 (High).
- The higher voltage level is assigned the logic value 0 (Low).
- Example: 0V = Logic 1, +5V = Logic 0.
Relationship: A physical gate acting as a NAND gate in positive logic will act as a NOR gate in negative logic (Duality).
Derive the boolean expression for the output of a circuit that has three inputs (A, B, C) and produces a High output only when the majority of inputs are High.
Truth Table Analysis:
We need High output when 2 or 3 inputs are 1.
- 000 (0), 001 (0), 010 (0), 100 (0)
- 011 (1) - Majority
- 101 (1) - Majority
- 110 (1) - Majority
- 111 (1) - Majority
Minterms:
K-Map Simplification:
- Group 1 (3, 7):
- Group 2 (5, 7):
- Group 3 (6, 7):
Final Expression:
This is known as the Majority Function (Carry output of a Full Adder).
Prove algebraically that: \n
Proof:
- Expand the LHS:
- Apply :
- Apply the Consensus Theorem ().
- Here we have (where control is ), (where control is ), and (the redundant consensus term).
- Therefore, can be eliminated.
- LHS = RHS (Proved).
Implement the function using AND-OR-INVERT (AOI) logic.
AND-OR-INVERT logic usually results in a complement form, but specific AOI gates exist. Standard AOI implementation typically implies implementing the complement or using the specific gate structure.
However, interpreting the request as implementing the logic using basic Multi-level structure:
- Level 1 (AND):
- Gate 1: Inputs A, B. Output .
- Gate 2: Inputs C, D. Output .
- Level 2 (OR):
- Gate 3: Inputs are Output of Gate 1 (), Output of Gate 2 (), and Input E.
- Output: .
If the question specifically refers to a standard AOI gate (like CMOS AOI), the output is inverted: . To get F, one would follow the AOI gate with an Inverter.
What is the Absorption Law? Prove it.
Absorption Law:
It allows for the reduction of complicated terms to simpler ones by absorbing a term into another.
Forms:
Proof of (1) :
- Factor out A:
- Since :
- Result:
Proof of (2) :
- Expand:
- Since :
- Factor out A: