Boolean algebra and minimization: algebraic technique, Karnaugh map and tabular method
Boolean algebra laws and theorems, canonical SOP and POS forms, and minimising functions by algebra, by Karnaugh maps (with don't cares) and by the Quine–McCluskey tabular method, including prime and essential prime implicants.
Variables take values and . Write (or ) for NOT, for AND, for OR.
Law
OR form
AND form
Identity
Null
Idempotent
Complement
Absorption
De Morgan
Distributive
Two more that simplify fast:
and .
Consensus: . The term is redundant. Dual: .
Duality: swap with and with (leave variables and complements alone). Every identity stays true under duality. The dual of is . A function equal to its own dual is self-dual.
XOR: ; , , and XOR is associative. XNOR is its complement.
Counting: with variables there are rows in the truth table and distinct Boolean functions; of them are self-dual.
Universal gates: NAND alone and NOR alone can build NOT, AND and OR, so each is functionally complete. So are and , but not (it cannot make NOT).
2. Canonical forms: minterms and maxterms
A minterm is an AND of all variables, each plain or complemented; it is for exactly one input row. Minterm is numbered by the row's binary value: for , (row ).
A maxterm is an OR of all variables; it is for exactly one row. (complement the variables that are in the row).
Note .
Canonical SOP (sum of minterms) lists the rows where : .
Canonical POS (product of maxterms) lists the rows where : the same .
The two lists are complementary: together they contain every index from to exactly once. And .
Expanding a term to minterms: a product term with missing variables covers minterms. With , the term covers .
Minimal forms. A minimal SOP has the fewest product terms, and among those the fewest literals. A minimal POS is found the same way by grouping the s (giving in SOP form) and applying De Morgan.
Form
Built from
Lists rows where
minterms
maxterms
Two-level AND–OR (SOP) maps directly to NAND–NAND, and OR–AND (POS) to NOR–NOR.
3. Karnaugh maps
A Karnaugh map (K-map) arranges the truth table so that neighbouring cells differ in exactly one variable. Rows and columns follow Gray code order , and the map wraps around: the left edge touches the right edge, the top touches the bottom, and the four corners are adjacent.
Grouping rules (for SOP, group the s):
Groups are rectangles of cells (powers of 2).
Make each group as large as possible; a group of cells removes variables.
Use as few groups as possible to cover every . Overlaps are allowed.
Read a group's term from the variables that stay constant across it.
Implicants:
An implicant is any valid group of s.
A prime implicant (PI) is a group that cannot be enlarged.
An essential prime implicant (EPI) is a PI that covers some no other PI covers. Every minimal SOP contains all EPIs.
Method: circle all PIs, take the EPIs, then cover any remaining s with as few extra PIs as possible.
Don't cares ( or ): input rows that never occur, or whose output does not matter. Treat each as if it helps make a bigger group, otherwise as . Never make a group of only don't cares.
For POS, group the s to get as an SOP, then complement with De Morgan.
4-variable K-map for $F = \sum m(0, 2, 5, 7, 8, 10, 13, 15)$. The four corners are adjacent, so they form one group $B'D'$; the centre square is $BD$.
4. The tabular (Quine–McCluskey) method
The Quine–McCluskey method does the K-map's job systematically, and works for any number of variables.
Step 1: find all prime implicants.
Write each minterm (and each don't care) in binary and group them by the number of 1s.
Compare each term with every term in the next group. If two differ in exactly one bit, combine them, writing in that position (for example and give ). Tick both.
Repeat on the new list: combine terms whose positions match and that differ in one other bit.
Terms never ticked are the prime implicants.
Step 2: the prime implicant chart.
Rows are PIs; columns are the minterms (not the don't cares).
A column with a single mark identifies an essential PI. Take it and delete the columns it covers.
Remove dominated rows and columns, and repeat.
If no essential PI remains and columns are still uncovered, the chart is cyclic; choose by trial or by Petrick's method (write the covering condition as a product of sums and multiply out).
Method
Best for
Weakness
Algebra
small expressions, spotting identities
no proof of minimality
K-map
up to 4 (at most 5) variables
hard to see groups beyond that
Quine–McCluskey
any number of variables, programs
long by hand
A function can have more than one minimal SOP, but the number of literals in a minimal SOP is fixed.
Formulas to remember
De Morgan's laws
Absorption and redundancy
Consensus theorem
Distributive (OR over AND)
XOR
Number of Boolean functions input variables
Number of self-dual functions
Group size and literalsIn an -variable K-map
Common mistakes
Ordering K-map rows and columns as 00, 01, 10, 11 instead of the Gray code 00, 01, 11, 10.
Missing wrap-around groups, especially the four corners of a 4-variable map.
Making a group of only don't cares, or forcing every don't care to 1.
Writing the dual by complementing variables; duality swaps only + with · and 0 with 1.
Listing maxterm indices for the rows where F = 1; Π M lists the rows where F = 0.
Assuming the minimal SOP is unique; when the PI chart is cyclic there can be several, with the same literal count.
Worked examples
Try each step yourself, then reveal the working.
Example 1: Algebraic simplification with consensus
numerical
Simplify .
Step 1: Look for a consensus term.
Try it on paper first.
Example 2: A K-map with wrap-around groups
numerical
Minimise .
Step 1: Place the 1s on the map.
Try it on paper first.
Example 3: Using don't cares
numerical
Minimise .
Step 1: Find the group for column CD = 11.
Try it on paper first.
Example 4: A cyclic prime implicant chart
conceptual
For , list the prime implicants, find the essential ones, and give a minimal SOP.
10 questions: up to 4 official PYQs and original practice questions, with GATE marking (MCQ wrong answers lose marks). Score 60% or more to pass. A new set is drawn each time.
Mark as mastered
Loading your progress…
My revision notes
Notes written by the GATEiit team against the official GATE CSE syllabus; being checked by a reviewer. Updated 2026-11-21. Spotted a mistake? Use Report an issue on any question, or contact us.