📘 Lecture 08 — BOOLEAN ALGEBRA AND LOGIC SIMPLIFICATION
📖 Overview: This lecture introduces Boolean algebra as the mathematical foundation of digital systems. It covers essential definitions, laws, rules, and theorems used to represent and simplify logic circuits. Understanding these concepts is crucial for analyzing and minimizing complex digital circuits to reduce gate count and cost.
🗂️ Topics Covered
The lecture begins with fundamental Boolean algebra definitions (variable, complement, literal) and operations (Boolean addition and multiplication). It then explains the three basic laws (commutative, associative, distributive) followed by twelve rules of Boolean algebra. DeMorgan’s theorems are introduced along with their application. The lecture concludes with Boolean analysis of logic circuits, simplification using Boolean algebra, and the standard forms of Boolean expressions (SOP and POS) with their implementations.
📝 Lecture Summary
Boolean Algebra Definitions
A variable is a symbol (usually an uppercase letter) used to represent a logical quantity and can have a value of 0 or 1. A complement is the inverse of a variable, indicated by a bar over the variable (e.g., complement of X is X̅); if X=0 then X̅=1, and if X=1 then X̅=0. A literal is a variable or the complement of a variable.
Boolean Addition is performed by an OR gate and results in a sum term. A sum term is 1 when any one literal is 1, and 0 when all literals are 0. Examples of sum terms: A+B, A̅+B, A+B+C̅.
Boolean Multiplication is performed by an AND gate and results in a product term. A product term is 1 when all literal terms are 1, and 0 when any one literal is 0. Examples of product terms: A·B, A̅·B, A·B·C.
Laws of Boolean Algebra
1. Commutative Law for Addition and Multiplication
- Commutative Law for Addition: A + B = B + A
- Commutative Law for Multiplication: A·B = B·A
The ordering of literals at the input of OR and AND gates does not affect the result. This law holds true for any number of literals.
2. Associative Law for Addition and Multiplication
- Associative Law for Addition: A + (B + C) = (A + B) + C
- Associative Law for Multiplication: A·(B·C) = (A·B)·C
The grouping of literals for Boolean Addition and Multiplication does not change the result. Adding B and C first, then adding A to the result, is the same as adding A and B first, then adding C. Similarly for multiplication.
3. Distributive Law
- A·(B + C) = A·B + A·C
Adding literals B and C and then multiplying the result with A is the same as multiplying A with B and adding that to the product of A and C. This law holds true for any number of literals.
Rules of Boolean Algebra
These rules can be proved by substituting literals with Boolean values 0 and 1.
- A + 0 = A
- A + 1 = 1
- A·0 = 0
- A·1 = A
- A + A = A
- A + A̅ = 1
- A·A = A
- A·A̅ = 0
- A̿ = A (Double complement)
- A + A·B = A — (Proof: A·(1+B) = A·1 = A)
- A + A̅·B = A + B — (Proof: A(B+1) + A̅·B = AB + A + A̅·B = B(A+A̅) + A = B + A)
- (A+B)·(A+C) = A + B·C — (Proof: AA+AC+AB+BC = A(1+C+B) + BC = A + BC)
💡 Why this matters: These rules are the essential tools for simplifying Boolean expressions, leading to simpler and more cost-effective digital circuits.
DeMorgan’s Theorems
DeMorgan’s First Theorem states: The complement of a product of variables is equal to the sum of the complements of the variables. 🔑 Definition — DeMorgan’s First Theorem: A̅·B̅ = A̅ + B̅ 📐 Formula: A·B = A̅ + B̅ → The complement of the AND of two variables equals the OR of their complements.
DeMorgan’s Second Theorem states: The complement of a sum of variables is equal to the product of the complements of the variables. 🔑 Definition — DeMorgan’s Second Theorem: A̅+B̅ = A̅·B̅ 📐 Formula: A + B = A̅·B̅ → The complement of the OR of two variables equals the AND of their complements.
DeMorgan’s theorems prove the equivalency of NAND and negative-OR gates, and NOR and negative-AND gates respectively. These theorems can be applied to expressions with any number of variables:
- X·Y·Z = X̅ + Y̅ + Z̅
- X + Y + Z = X̅·Y̅·Z̅
Example: Applying DeMorgan’s Theorem to (A + B·C)·(A·C + B): = (A + B·C)̅ + (A·C + B)̅ = A̅·(B·C)̅ + (A·C)̅·B̅ = A̅·(B̅ + C̅) + (A̅ + C̅)·B̅ = A̅·B̅ + A̅·C̅ + A̅·B̅ + B̅·C̅ = A̅·B̅ + A̅·C̅ + B̅·C̅
Boolean Analysis of Logic Circuits
Boolean algebra provides a concise way to represent the operation of a logic circuit. The function of a logic circuit can be determined by evaluating the Boolean expression using different input combinations.
For the circuit represented by the expression (AB + C̅)D:
- Starting from the left input side, the AND gate provides AB.
- The OR gate adds AB and complement C to get (AB + C̅).
- The AND gate on the right multiplies (AB + C̅) with D.
The expression output is 1 if both D = 1 and (AB + C̅) = 1. The term (AB + C̅) = 1 only if AB = 1 or C = 0. Therefore, the expression equals 1 when: D=1 AND (C=0 OR AB=1).
Analysis of the function table (16 possible input combinations) shows output F=1 for input combinations: 0001, 0101, 1001, 1101, and 1111.
Simplification using Boolean Algebra
Boolean expressions can be simplified using laws, rules, and theorems to result in fewer variables and a simpler circuit.
Example: Simplify AB + A(B+C) + B(B+C) = AB + AB + AC + BB + BC (Distributive Law) = AB + AC + B + BC (BB = B using rule 7) = AB + AC + B (B+BC = B using rule 10) = B + AC (B+AB = B using rule 10)
The simplified expression B+AC results in a simpler circuit with fewer gates compared to the original.
Standard Form of Boolean Expressions
All Boolean expressions can be converted into one of two standard forms: Sum-of-Products (SOP) or Product-of-Sums (POS).
1. Sum-of-Products (SOP) Form When two or more product terms are summed by Boolean addition, the result is a SOP expression. The domain of an SOP expression is the set of all variables (complemented and un-complemented) contained in the expression. Examples: AB + ABC, ABC + CDE + BCD, AB̅ + ABC̅ + AC̅
- A SOP expression cannot have a term with an overbar extending over the entire term.
2. Product-of-Sums (POS) Form When two or more sum terms are multiplied by Boolean multiplication, the result is a POS expression. Examples: (A+B)(A+B+C), (A+B+C)(C+D+E)(B+C+D), (A+B̅)(A+B+C̅)(A̅+C)
Implementation of SOP and POS Expressions
An SOP expression can be implemented by an AND-OR combination of gates. Product terms are implemented by AND gates, and the OR gate combines the outputs of the AND gates.
A POS expression can be implemented by an OR-AND combination of gates. Sum terms are implemented by OR gates, and the AND gate combines the outputs of the OR gates.
Conversion of a General Expression to SOP Form
Any logical expression can be converted into SOP form by applying Boolean algebra techniques:
- AB + B(CD + EF) = AB + BCD + BEF
- (A+B)(B+C+D) = AB + AC + AD + B + BC + BD = AC + AD + B
- (A+B)̅ + C = (A̅·B̅) + C = (A̅·B̅) + C (using DeMorgan's Theorem, this is already in SOP form)
⭐ Key Takeaways
Boolean algebra is the essential mathematical foundation for analyzing and simplifying digital logic circuits. The student must master the three basic laws (commutative, associative, distributive) and the twelve rules of Boolean algebra, as these are the primary tools for simplification. DeMorgan’s theorems are critical for understanding the equivalency between NAND/NOR gates and their negative-gate counterparts, and for manipulating complemented expressions. All Boolean expressions can be expressed in either Sum-of-Products (SOP) or Product-of-Sums (POS) standard forms, with SOP implemented using AND-OR gate networks and POS using OR-AND networks. The ultimate goal is to use Boolean algebra to minimize expressions, thereby reducing the number of gates required to implement a logic circuit, saving cost and complexity.
🧠 Quick Revision Questions
- State DeMorgan’s First Theorem and apply it to simplify the expression (X·Y·Z)̅.
- Using Boolean algebra rules, simplify the expression A + A̅·B and show the steps.
- Convert the expression (A+B)·(B+C) into its Sum-of-Products (SOP) form.
- For the Boolean expression (AB + C̅)D, determine all input combinations (A, B, C, D) that produce an output of 1.
- Explain the difference between Sum-of-Products (SOP) and Product-of-Sums (POS) forms, and describe how each is implemented with logic gates.
📘 Lecture 9 — Boolean Algebra and Logic Simplification
📖 Overview: This lecture focuses on the practical application of Boolean algebra to analyze, simplify, and represent logic circuits. It demonstrates how a complex logic circuit's Boolean expression is evaluated, simplified using Boolean theorems, and verified through truth tables. The lecture also introduces standard Sum-of-Products (SOP) and Product-of-Sums (POS) forms, their conversion, and the concepts of Minterms and Maxterms for canonical representation.
🗂️ Topics Covered
This lecture covers Boolean analysis of logic circuits through two detailed examples, including finding the Boolean expression, evaluating it, creating truth tables, and simplifying the expression using DeMorgan's theorems and Boolean rules. It further explains the conversion of non-standard SOP and POS expressions into their standard forms, defines Minterms and Maxterms, and demonstrates how to convert between standard SOP and POS forms, as well as how to map SOP and POS expressions to truth tables.
📝 Lecture Summary
Boolean Analysis of Logic Circuits, evaluating of Boolean expressions, representing the operation of Logic circuits and Boolean expressions in terms of Function tables and representing Boolean expressions in SOP and POS forms
The lecture begins by establishing the interrelationship between Boolean Analysis of Logic Circuits, evaluating Boolean expressions, representing them in function tables (truth tables), and representing them in SOP (Sum-of-Products) and POS (Product-of-Sums) forms. Boolean laws, rules, and theorems are the tools used to change between these forms.
Example 1
1. Finding the Boolean Expression The first example analyzes a logic circuit (Figure 9.1) composed of NOT, AND, NAND, and NOR gates. The Boolean expression is derived by working from the left side of the circuit. The output of the first NOT gate is B, and the second NOT gate is A. The output of a two-input AND gate for A and B is A.B. Another AND gate for C and D gives C.D. A three-input NAND gate combines the outputs of the first AND gate and the C.D product, resulting in A.B.C.D. Finally, a two-input NOR gate produces the final expression: A.B + A.B.C.D. 🔑 Definition — Logic Circuit Analysis: The process of deriving a Boolean expression from a logic circuit diagram.
2. Evaluating the Expression The expression is evaluated by letting X = A.B and Y = A.B.C.D, so the output is X + Y (X NOR Y). The output of a NOR gate is 1 only when both inputs are 0 (X=0 and Y=0). X=0 when either A=0 or B=1. Y=0 when A.B.C.D = 1, which requires A=0, B=0, C=1, D=1. Therefore, the overall expression is 1 only when A=0, B=0, C=1, and D=1.
3. Putting the Results in Truth Table Format A truth table (Table 9.1) with 16 input combinations for variables A, B, C, and D is created. The output F is 1 for only the input combination (A=0, B=0, C=1, D=1) and 0 for all other 15 combinations.
4. Simplification of Boolean Expression The expression is simplified using DeMorgan's theorem. Applying DeMorgan's second theorem (A + B = A.B) to the NOR expression gives (A.B).(A.B.C.D). Then, applying DeMorgan's first theorem to (A.B) and Rule 9 (A = A) to the second term yields (A + B).(A.B.C.D). Using the distributive law and Rule 8 (A.A = 0), the expression simplifies to A.B.C.D. The simplified expression is 1 when A=0, B=0, C=1, and D=1. 📐 Formula: A + B = A.B (DeMorgan's Second Theorem) 📌 Example: Given AB + ABCD, applying DeMorgan's theorem yields (A+B).(ABCD).
5. Putting the result in Truth Table format The truth table (Table 9.2) for the simplified expression A.B.C.D is identical to the truth table for the original expression (Table 9.1), verifying that the simplification is correct.
6. Implementing Logic Circuit from Simplified Boolean expression The simplified expression F = A.B.C.D is a product term with four literals. It is implemented using NOT gates for A and B and a single 4-input AND gate (Figure 9.2). This is a much simpler circuit than the original.
Example 2
1. Finding the Boolean Expression The second example circuit (Figure 9.3) has three NOT gates, a three-input AND gate, a two-input OR gate, and a NAND gate. The outputs are A, C, A.B.C, and C + D. The NAND gate output is the final expression: (A.B.C).(C + D).
2. Evaluating the Expression Let X = A.B.C and Y = C + D, so the output is X.Y (X NAND Y). The output of a NAND gate is 1 when either input is 0 (X=0 or Y=0). X=0 when A=1, B=0, or C=1. Y=0 when C=1 and D=0. The expression output is 1 when (A=1 OR B=0 OR C=1) OR (C=1 AND D=0).
3. Putting the Results in Truth Table Format The truth table (Table 9.2) shows that variable D has no effect on the output. The table can be reduced to a three-variable truth table (Table 9.3) for A, B, and C.
4. Simplification of Boolean Expression Applying DeMorgan's first theorem (A.B = A + B) to the expression gives (A.B.C) + (C + D). Applying DeMorgan's theorems again yields (A + B + C) + (C.D). Applying Rule 9 results in (A + B + C) + (C.D). Finally, factoring C gives A + B + C(1 + D), which simplifies to A + B + C. The simplified expression is 1 when A=1, B=1, or C=1. 📐 Formula: A.B = A + B (DeMorgan's First Theorem) 📌 Example: Given (ABC)(C+D), applying DeMorgan's theorem yields (A+B+C)(CD).
5. Putting the result in Truth Table format The truth table for the simplified expression A + B + C (Table 9.4) is identical to the reduced truth table (Table 9.3), verifying the simplification. 💡 Why this matters: When D has no effect on the output, it is a "don't care" condition, and the circuit can be simplified by removing the logic associated with D.
6. Implementing Logic Circuit from Simplified Boolean expression The simplified expression F = A + B + C is a sum term with three literals. It is implemented using a single NOT gate for B and a 3-input OR gate (Figure 9.4).
Standard SOP form
A standard SOP form contains product terms that include all the variables in the domain of the expression. For example, the SOP expression AC + BC is not standard for a domain of A, B, C. A non-standard SOP is converted into standard SOP by using the rule A + A = 1 to multiply each term by the missing variable(s). 📐 Formula: A + A = 1 📌 Example: AC + BC becomes ABC + ABC + ABC + ABC, which simplifies to ABC + ABC + ABC.
Standard POS form
A standard POS form contains sum terms that include all the variables in the domain of the expression. A non-standard POS is converted into a standard POS by using the rule AA = 0 to add the missing variable(s) to each sum term. 📐 Formula: AA = 0 📌 Example: (A+B+C)(A+B+D) becomes (A+B+C+D)(A+B+C+D)(A+B+C+D)(A+B+C+D).
Converting to Standard SOP and POS forms
Converting to standard forms is crucial because any logic circuit can be implemented using either SOP (AND-OR) or POS (OR-AND) gate combinations. Converting between standard SOP and standard POS is straightforward and helps in choosing the implementation with the minimum number of gates. Furthermore, standard forms are essential for simplifying expressions using Karnaugh maps and for programming PLDs (Programmable Logic Devices).
Minterms and Maxterms
In standard SOP, the product terms are called Minterms. In standard POS, the sum terms are called Maxterms. A Minterm is equal to 1 for only one specific combination of input variables, and a Maxterm is equal to 0 for only one specific combination. Table 9.5 shows the relationship between variable values, Minterms, and Maxterms.
Binary representation of a standard Product term or Minterm
A standard product term (Minterm) is equal to 1 for only one combination. For instance, ABC = 1 only when A=1, B=1, C=0. An SOP expression is 1 when one or more of its product terms are 1.
Binary representation of a standard Sum term or Maxterm
A standard sum term (Maxterm) is equal to 0 for only one combination. For instance, (A+B+C+D) = 0 only when A=0, B=1, C=0, D=1. A POS expression is 0 when one or more of its sum terms are 0.
Converting Standard SOP into Standard POS
To convert from standard SOP to standard POS, list all the binary values of the product terms in the SOP (these are the "1" outputs). The missing binary values are the "0" outputs, which correspond to the sum terms in the standard POS. The expression is often written using Canonical Sum (Σ) and Canonical Product (Π) notation. 📐 Formula: Canonical Sum = Σ(minterm numbers); Canonical Product = Π(maxterm numbers) 📌 Example: Σ(0,2,3,5,7) = ABC + ABC + ABC + ABC + ABC. The missing values are 1, 4, and 6, so the equivalent POS is Π(1,4,6) = (A+B+C)(A+B+C)(A+B+C).
Verifying POS expression is equivalent to SOP expression
The equivalence of the SOP and POS expressions is verified by algebraically expanding the POS expression and simplifying it back into the original SOP form.
Boolean Expressions and Truth Tables
All standard Boolean expressions can be easily converted into truth table format, and standard SOP or POS expressions can be determined from a truth table.
Converting SOP expression to Truth Table format
To map an SOP expression to a truth table, first write the expression in standard SOP form. Then, for each Minterm present in the standard SOP, set the output to 1. 📌 Example: For domain A, B, C, the SOP expression AB + BC is converted to standard SOP: ABC + ABC + ABC + ABC. This corresponds to Minterms 3, 4, 5, and 7 (binary 011, 100, 101, 111). In the truth table, F=1 for these combinations.
Converting POS expression to Truth Table format
To map a POS expression to a truth table, first write the expression in standard POS form. Then, for each Maxterm present in the standard POS, set the output to 0. 📌 Example: For domain A, B, C, the POS expression (A+B)(B+C) is converted to standard POS: (A+B+C)(A+B+C)(A+B+C)(A+B+C). This corresponds to Maxterms 1, 2, 3, and 5 (binary 001, 010, 011, 101). In the truth table, F=0 for these combinations.
⭐ Key Takeaways
For the exam, you must be able to systematically analyze a logic circuit to derive its Boolean expression, then evaluate it by understanding the behavior of basic gates (AND, OR, NAND, NOR, NOT). You must be skilled at applying DeMorgan's theorems and Boolean rules (like Rule 8 A·A=0, Rule 9 A=A, and the OR form of Rule 9 A+A=1) to simplify complex expressions. The most critical skill is verifying simplification by showing that the original and simplified expressions have identical truth tables. You must also be comfortable converting between non-standard and standard SOP/POS forms, using the A+A=1 and AA=0 rules, and understanding how to convert a standard SOP into a standard POS (and vice-versa) using Minterm and Maxterm numbers with Σ and Π notation.
🧠 Quick Revision Questions
- For the logic circuit expression F = (A.B) + (C.D), what is the equivalent simplified form after applying Boolean theorems if it were derived from a NAND-NOR combination?
- Convert the non-standard POS expression (A+B)(B+C) into its standard POS form for a domain of three variables.
- If a standard SOP expression has the Canonical Sum Σ(0, 2, 4, 6), what is the equivalent Canonical Product (Π) for the same function?
- Explain the key difference in how Minterms and Maxterms are used when mapping an SOP expression versus a POS expression to a truth table.
- Simplify the Boolean expression (X+Y) · (X+Z) and explain which Boolean rule or theorem you used.
📘 Lecture 10 — Karnaugh Map & Boolean Expression Simplification
📖 Overview: This lecture introduces the Karnaugh Map (K-Map) as a systematic graphical method for simplifying Boolean expressions, overcoming the limitations of algebraic simplification using laws and theorems. It covers the structure and organization of 2, 3, and 4-variable K-Maps, the process of mapping Standard and non-Standard SOP expressions, grouping adjacent cells, and simplification techniques. The lecture also explains how to handle "Don't Care" conditions and map directly from function tables for practical digital circuit design.
🗂️ Topics Covered
The lecture covers the organization of the 3-variable Karnaugh Map in column and row forms, and the 4-variable Karnaugh Map. It explains the concept of grouping adjacent cells for simplification, including corner cells and powers-of-two groups. The process of mapping Standard and non-Standard SOP expressions to K-Maps is detailed through multiple examples. Simplification of SOP expressions using the K-Map is demonstrated with several 3 and 4-variable examples. Finally, the lecture covers mapping directly from a function table and the use of "Don’t Care" conditions to achieve further simplification.
📝 Lecture Summary
Karnaugh Map & Boolean Expression Simplification
Simplifying Boolean expressions using laws, rules and theorems does not guarantee the simplest form because some simplifications are not obvious. The Karnaugh Map (K-Map) provides a systematic array-based method for simplification. Adjacent cells in the array can be grouped to simplify expressions for 2, 3, 4, and 5 variables.
The 3-variable Karnaugh Map
A 3-variable K-Map contains 8 cells. These can be arranged in two forms: a column form (2 columns, 4 rows) where the left column represents AB values (00, 01, 11, 10) and the top row represents C values (0, 1); and a row form (2 rows, 4 columns) where the left column represents A (0, 1) and the top row represents BC values (00, 01, 11, 10). The numbers in the cells represent the Minterms or Maxterms. For example, cell 0 represents minterm 0 with binary value 000 for variables A, B, and C.
🔑 Definition — Minterm: A product term that includes all variables in the domain of the expression, either in complemented or un-complemented form, representing a single '1' output condition.
The 4-variable Karnaugh Map
A 4-variable K-Map has an array of 16 cells in a square format with 4 rows and 4 columns. The left column represents the binary values of variables A and B, while the top row represents the binary values of variables C and D. Cell 6 represents minterm 6 with binary value 0110 for A, B, C, and D. 💡 Why this matters: The K-Map's structure allows visual identification of adjacent terms that can be combined to eliminate variables.
Grouping and Adjacent Cells
The K-Map array is considered to be wrapped around, so all sides are adjacent. Groups of 2, 4, 8, 16, 32 etc. adjacent cells are formed. Adjacent cells can be row-wise, column-wise, the four corner cells, or row-column groups. Groups are formed based on 1s (Minterms) or 0s (Maxterms). A group should have the maximum number of cells possible, with the size being a power of 2. The goal is to form the minimal number of largest groups that uniquely cover all cells.
Mapping a standard SOP Expression
For a Standard SOP expression, a 1 is placed in the cell corresponding to each product term (Minterm) present. Cells without 1s contain 0s. For example, the expression ( \overline{A}BC + A\overline{B}C + AB\overline{C} ) (minterms 2, 4, 6) is mapped by placing a 1 in cells 2, 4, and 6 of a 3-variable K-Map. Similarly, a 4-variable expression with 7 minterms (1, 4, 5, 6, 8, 13, 14) is mapped by placing 1s in those corresponding cells.
Mapping a non-standard SOP Expression
Non-standard SOP expressions can be mapped directly without first converting to standard form. For example, the expression ( A + \overline{B}C ) is mapped by first marking all cells where A is present (minterms 4, 5, 6, 7), then marking cells where ( \overline{B}C ) is present (minterms 1, 5). The resulting K-Map shows the expression has five product terms. Similarly, expression ( \overline{A} + \overline{C} ) is mapped by marking cells for ( \overline{A} ) (minterms 0, 1, 2, 3) and then ( \overline{C} ) (minterms 0, 1, 4, 5). For 4 variables, expression ( \overline{D} + A\overline{C} + \overline{B}C ) is mapped term by term by marking cells where each term is present.
Simplification of SOP expressions using the Karnaugh Map
The first step is mapping the SOP expression on the K-Map. Next, groups of 1s are formed, starting with the largest group of size 2, 4, 8, 16, etc. Multiple unique groups are formed, each having at least one 1 not common to any other group. A single isolated 1 forms a group of one cell. Each group represents a product term with variables that occur in only one form.
For a 3-variable K-Map: a group of 1 cell yields a 3-variable term, 2 cells yields a 2-variable term, 4 cells yields a 1-variable term, and 8 cells yields a value of 1. For a 4-variable K-Map: 1 cell yields a 4-variable term, 2 cells yields a 3-variable term, 4 cells yields a 2-variable term, 8 cells yields a 1-variable term, and 16 cells yields a value of 1.
Example 1 & 2: A 3-variable expression with 5 minterms groups into three groups of 2: cells 2,6 → ( \overline{B}C ); cells 5,7 → ( AC ); cells 1,5 → ( B\overline{C} ). The simplified expression is ( \overline{B}C + AC + B\overline{C} ). Another expression with 4 minterms groups into one single cell (4 → ( A\overline{B}\overline{C} )) and two groups of 2 (cells 1,3 → ( \overline{A}C ); cells 2,3 → ( \overline{A}B )), simplifying to ( A\overline{B}\overline{C} + \overline{A}C + \overline{A}B ).
Example 3 & 4: A 3-variable expression with 5 minterms forms one group of 4 (cells 2,3,6,7 → ( B )) and one group of 2 (cells 5,7 → ( AC )), simplifying to ( B + AC ). Another expression with 5 minterms forms three groups of 2: cells 4,5 → ( A\overline{B} ); cells 3,7 → ( BC ); cells 2,3 → ( \overline{A}B ), simplifying to ( A\overline{B} + BC + \overline{A}B ).
Example 5: A 4-variable expression with 11 minterms forms three groups of 4: cells 8,9,12,13 → ( A\overline{C} ); cells 1,3,9,11 → ( \overline{B}D ); cells 6,7,14,15 → ( BC ). Simplified expression: ( A\overline{C} + \overline{B}D + BC ).
Example 6: An 8-minterm 4-variable expression forms one group of 2 (cells 8,12 → ( A\overline{C}\overline{D} )) and two groups of 4 (cells 3,7,11,15 → ( CD ); cells 6,7,14,15 → ( BC )), simplifying to ( A\overline{C}\overline{D} + CD + BC ).
Example 7: A 9-minterm 4-variable expression forms two groups of 4 (corner cells 0,2,8,10 → ( \overline{B}D ); cells 2,3,10,11 → ( \overline{B}C )) and two groups of 2 (cells 13,15 → ( ABD ); cells 2,6 → ( \overline{A}C\overline{D} )), simplifying to ( \overline{B}D + \overline{B}C + ABD + \overline{A}C\overline{D} ).
📐 Formula: Grouping Rule: Group adjacent 1s in powers of 2 (1, 2, 4, 8, 16...) to form circles, ensuring each cell is covered and at least one cell per group is unique.
📌 Example: For the 4-variable K-Map in Figure 10.12, cells 8,9,12,13 form a group of 4. A and B vary (0,1) and (0,1) while C is 0 and D varies. The variable that changes (D) is eliminated, leaving ( A\overline{C} ).
Mapping Directly from Function Table
In practice, a digital circuit's function is defined using a Function Table. The information is directly mapped to a K-Map, simplified, and the resulting expression is implemented with logic gates. For example, an Odd-Prime Number Checker circuit accepts 4-bit numbers (0-15). The function table shows output 1 for odd prime numbers (1, 3, 5, 7, 11, 13). Mapping this to a 4-variable K-Map and simplifying yields the expression ( AD + \overline{B}C\overline{D} + BC\overline{D} ).
Don’t Care Conditions
Don't Care conditions occur when certain input combinations never happen. Their corresponding outputs are marked as x (don't care) in the function table and K-Map. During grouping, x outputs can be considered as 0 or 1 to achieve maximal simplification. For the Odd-Prime Checker, if only inputs 0-9 occur (states 10-15 never occur), all don't care states can be considered 0s, simplifying the expression to ( AD ). If only inputs 0-8 occur, states 9-15 can be considered 1s to form a group of 8 cells, simplifying the expression to the single literal ( D ).
🔑 Definition — Don't Care Condition: An input combination that never occurs in a circuit, allowing its output to be assigned arbitrarily (0 or 1) during K-Map simplification to achieve a simpler expression.
📌 Example: In a 4-variable K-Map where cells 3, 10, and 15 are don't cares (assuming they never occur), they can be treated as 1s to form a larger group. As in Figure 10.17, the simplified expression becomes ( C + \overline{A}D ) instead of the original ( A\overline{B}C + CD + BC ).
⭐ Key Takeaways
The Karnaugh Map is a systematic graphical tool for simplifying Boolean expressions that overcomes the limitations of algebraic methods. You must be able to construct and interpret 3-variable (8 cells) and 4-variable (16 cells) K-Maps in both column and row forms. The core simplification process involves mapping SOP expressions, forming the largest possible groups of adjacent 1s (in powers of 2), and deriving the minimal product term for each group by eliminating variables that change within the group. The ability to directly map from a function table and strategically use Don't Care conditions (marked as 'x') by treating them as either 0 or 1 is critical for achieving maximum simplification. Remember that the K-Map wraps around on all sides, making corner cells and edge cells adjacent.
🧠 Quick Revision Questions
- How many cells does a 4-variable Karnaugh Map have, and what is the binary representation of the cell marked '13'?
- In the Odd-Prime Number Checker example, what was the simplified Boolean expression when only inputs 0 to 9 were considered (states 10-15 were don't cares)?
- What is the relationship between the size of a group in a 4-variable K-Map (1, 2, 4, 8, or 16 cells) and the number of variables in its resulting product term?
- What are the four types of adjacent cells that can be grouped in a K-Map?
- In a 3-variable K-Map using row form, what do the binary values 0 and 1 in the left column represent, and what do the binary values 00, 01, 11, and 10 in the top row represent?
📘 Lecture 11 — Karnaugh Map & Boolean Expression Simplification
📖 Overview: This lecture extends Karnaugh Map techniques to simplify standard Product-of-Sums (POS) expressions, demonstrating how groups of 0s are used instead of 1s. It also covers converting between POS and SOP forms using the K-map, introduces 5-variable Karnaugh maps, and explains how to design multiple-output logic circuits using the example of a BCD to 7-Segment Decoder, including the use of don't care conditions for simplification.
🗂️ Topics Covered
Mapping a Standard POS Expression, Karnaugh Map simplification of POS expressions (with rules for sum-term reduction in 3-variable and 4-variable K-maps), worked examples (1–7) of POS simplification, converting between POS and SOP using the K-map, introduction to Five-Variable Karnaugh Maps (construction, mapping, grouping, and simplification), and Functions having multiple outputs exemplified by a BCD to 7-Segment Decoder (function tables, Karnaugh maps, and simplified expressions for each segment a–g).
📝 Lecture Summary
Mapping a Standard POS Expression
To map a standard POS expression on a K-map, place a 0 in the cell corresponding to each maxterm (sum term) present in the expression. All other cells receive a 1. For example, the standard POS expression (A + B + C)・(A + B + C)・(A + B + C)・(A + B + C) over a domain of three variables has maxterms 1, 2, 5, and 7, so 0s are placed at those locations and 1s elsewhere.
🔑 Definition — Maxterm: a sum term in a POS expression where each variable appears once, either complemented or un-complemented.
Karnaugh Map simplification of POS expressions
POS expressions are simplified on a K-map by grouping cells containing 0s (instead of 1s). The same rules for forming groups apply as for SOP simplification. After grouping, each group represents a simplified sum term where variables that appear in both complemented and un-complemented forms within the group are eliminated.
🔑 Definition — Sum Term (from a POS group): a term formed by variables that appear in only one form (complemented or un-complemented) within the group.
For a 3-variable K-map:
- A group of 1 cell yields a 3-variable sum term.
- A group of 2 cells yields a 2-variable sum term.
- A group of 4 cells yields a 1-variable sum term.
- A group of 8 cells yields a value of 0 for the expression.
For a 4-variable K-map:
- A group of 1 cell yields a 4-variable sum term.
- A group of 2 cells yields a 3-variable sum term.
- A group of 4 cells yields a 2-variable sum term.
- A group of 8 cells yields a 1-variable sum term.
- A group of 16 cells yields a value of 0 for the expression.
Example 1 & 2 (Figure 11.2)
A POS expression with 3 maxterms is mapped to a 3-variable column-based K-map. Two groups are formed:
- Group of cells 0 and 4 forms the sum term (B + C).
- Single cell 3 forms the sum term (A + B + C). The simplified expression is (B + C)・(A + B + C).
A POS expression with 4 maxterms forms three groups:
- Single cell 0: (A + B + C)
- Group of cells 5 and 7: (A + C)
- Group of cells 6 and 7: (A + B) The expression simplifies to (A + B + C)・(A + C)・(A + B).
Example 3 & 4 (Figure 11.3)
A POS expression with 3 maxterms forms two groups of two cells:
- Group of cells 0 and 1: (A + B)
- Group of cells 0 and 4: (B + C) Simplifies to (A + B)・(B + C).
Another 3-maxterm POS expression forms a group of 2 cells and a single cell:
- Group of cells 0 and 1: (A + B)
- Single cell 6: (A + B + C) Simplifies to (A + B)・(A + B + C).
Example 5 (Figure 11.4)
A POS expression with 5 maxterms is mapped to a 4-variable K-map. Three groups of two cells are formed:
- Group of cells 4 and 5: (A + B + C)
- Group of cells 0 and 4: (A + C + D)
- Group of cells 2 and 10: (B + C + D) Simplifies to (A + B + C)・(A + C + D)・(B + C + D).
Example 6 (Figure 11.5)
A POS expression with 8 maxterms is mapped to a 4-variable K-map. Groups formed:
- Group of cells 0, 1, 4, 5: (A + C)
- Group of cells 1, 5, 9, 13: (C + D)
- Group of cells 2 and 10: (B + C + D) Simplifies to (A + C)・(C + D)・(B + C + D).
Example 7 (Figure 11.6)
A POS expression with 6 maxterms forms:
- Group of cells 4 and 5: (A + B + C)
- Group of cells 5 and 7: (A + B + D)
- Group of cells 1 and 9: (B + C + D)
- Single cell 14: (A + B + C + D) Simplifies to (A + B + C)・(A + B + D)・(B + C + D)・(A + B + C + D).
Converting between POS and SOP using the K-map
On a K-map that already has 0s and 1s plotted, grouping the 1s produces the SOP expression. Grouping the 0s produces the POS expression. For example, from the K-map in Figure 11.7, grouping 1s yields the SOP expression BD + BC + ABC + ABD + ACD.
Five-Variable Karnaugh Map
A 5-variable K-map is constructed by stacking two 4-variable K-maps. Cells 0–15 lie in the map for variable A=0, and cells 16–31 lie in the map for A=1. Groups can span across both maps, forming groups of 2, 4, 8, 16, or 32 cells.
Simplification of 5-Variable Karnaugh Map (Figure 11.9)
Two 4-variable K-maps (A=0 and A=1) are used. Groups are formed:
- Cells 1, 5, 17, 21: group of 4 → BDE
- Cell 2 (A=0): single cell → ABCDE
- Cells 10, 11, 26, 27: group of 4 → BCD
- Cells 11, 14, 26, 30: group of 4 → BDE
- Cells 16, 17, 20, 21 (A=1): group of 4 → ABD
- Cells 25, 27 (A=1): group of 2 → ABCDE
Functions having multiple outputs
Practical logic circuits often have multiple inputs and multiple outputs. Each output is represented by its own function table (or a combined table). The BCD to 7-Segment Decoder is an example: it has 4 inputs (A, B, C, D) and 7 outputs (segments a, b, c, d, e, f, g). For each BCD digit (0–9), specific segments light up. Since only 10 of 16 input combinations are valid, the remaining 6 are don't care conditions (x), which help simplify the Boolean expressions for each segment.
Seven function tables (Figure 11.12a–g) define output 1 or 0 for each input combination. Using seven 4-variable K-maps (Figure 11.13a–g), the simplified expressions are:
🔑 Definition — Don't Care Condition: input combinations that never occur and can be treated as either 0 or 1 to achieve the simplest possible logic expression.
- a = A + C + BD + BD
- b = B + CD + CD
- c = C + D + B
- d = A + BD + BC + CD + BCD
- e = BD + CD
- f = B + CD + BC + BD
- g = A + BC + CD + BC
📐 Formula (simplified segment a): a = A + C + BD + BD → A OR C OR (B AND NOT D) OR (NOT B AND D) 📐 Formula (simplified segment b): b = B + CD + CD → B OR (C AND D) OR (C AND NOT D) 📐 Formula (simplified segment c): c = C + D + B → C OR NOT D OR NOT B
💡 Why this matters: Using don't care conditions dramatically reduces circuit complexity. Without them, expressions for segments like 'a' would require many more gates, increasing cost, power, and propagation delay.
⭐ Key Takeaways
For exam success, remember that POS simplification on a K-map uses groups of 0s (not 1s), and the size of the group determines how many variables are eliminated from the sum term. Converting between POS and SOP is simply a matter of grouping 0s or 1s on the same map. Five-variable K-maps are built from two stacked 4-variable maps where groups can cross between them. Finally, when dealing with multiple-output circuits like a BCD-to-7-segment decoder, don't care states (from unused input combinations) are critical tools for obtaining the simplest possible Boolean expressions for each output.
🧠 Quick Revision Questions
- In a 3-variable K-map, what is the size of the sum term produced by a group of 2 cells containing 0s?
- A POS expression mapped on a 4-variable K-map has groups of 0s covering cells 0, 1, 4, 5 and cells 2, 10. What are the two simplified sum terms?
- How do you convert a mapped POS expression into its equivalent SOP form?
- For a 5-variable K-map, how many cells are in the map for A=0, and how do you form a group that spans both sub-maps?
- In the BCD to 7-Segment decoder, why are don't care conditions (x) used, and how do they affect the simplified expression for segment 'a'?