MCS-212 · Block 1 Unit 3

Boolean Algebra and Circuits

Section 1 of 6

Block 1 · Unit 3Boolean Algebra and Circuits11 min · Section 1 of 6

3.1Boolean algebra: definition and examples

Covers IGNOU MCS-212 §3.2 (definition, Examples 1–3)

In Unit 1 you saw that propositions with ∨\lor, ∧\land and ¬\neg obey laws such as De Morgan’s and the distributive laws. Sets with ∪\cup, ∩\cap and complement obey exactly the same laws, and so do electrical switches. Instead of proving the same laws three times, mathematicians collect them into one structure: a Boolean algebra.

The definition

The order inside (X,∨,∧,′,O,I)(X, \lor, \land, ', O, I) matters: the first operation is the join, whose identity is OO; the second is the meet, whose identity is II.

Three examples

Boolean algebraSet XXjoin ∨\lormeet ∧\landcomplementOOII
Propositionsall propositions SS∨\lor (or)∧\land (and)¬\negcontradiction Ftautology T
Power setP(A)P(A), all subsets of a set AA∪\cup∩\capcomplement A∖YA \setminus Y∅\emptysetAA
Switches / bits{0,1}\{0, 1\}parallel (OR)series (AND)invert (NOT)01

For example, in the power-set algebra the identity law Y∪∅=YY \cup \emptyset = Y and the complement law Y∩(A∖Y)=∅Y \cap (A \setminus Y) = \emptyset are familiar facts about sets.

Switches and the two-element Boolean algebra

A switch has two states: closed (current flows), written 1, and open, written 0. A variable that can take only the values 0 and 1 is a Boolean variable. The invert x′x' of a switch xx is always in the opposite state.

Two switches can be connected in two ways:

Parallel and series connections
Parallel (a par b):          Series (a ser b):
   ┌──[ a ]──┐
───┤         ├───            ───[ a ]───[ b ]───
   └──[ b ]──┘
current flows if a OR b      current flows if a AND b
is closed                    are closed
aabbaa par bbaa ser bb
0000
0110
1010
1111

So {0,1}\{0, 1\} with par (∨\lor), ser (∧\land) and invert (′'), O=0O = 0, I=1I = 1, is a Boolean algebra. It is called the two-element Boolean algebra and is written B={0,1}B = \{0, 1\}.

The switching algebra BnB^n

BnB^n is the set of all nn-tuples of bits, e.g. B3={(0,0,0),(0,0,1),…,(1,1,1)}B^3 = \{(0,0,0), (0,0,1), \dots, (1,1,1)\} with 8 elements. The operations work component by component:

(1,0,1)∨(0,0,1)=(1,0,1),(1,0,1)∧(0,1,1)=(0,0,1),(1,0,1)′=(0,1,0).(1,0,1) \lor (0,0,1) = (1,0,1), \quad (1,0,1) \land (0,1,1) = (0,0,1), \quad (1,0,1)' = (0,1,0).

O=(0,…,0)O = (0, \dots, 0) and I=(1,…,1)I = (1, \dots, 1). This is exactly what a CPU does with bitwise operators: in C or Python, 5 | 1 is 5, 5 & 3 is 1, because 101∨001=101101 \lor 001 = 101 and 101∧011=001101 \land 011 = 001.

Key takeaways

  • A Boolean algebra: (X,∨,∧,′,O,I)(X, \lor, \land, ', O, I) satisfying associative, commutative, distributive, identity and complement laws.
  • Examples: propositions (S,∨,∧,¬,F,T)(S, \lor, \land, \neg, F, T), sets (P(A),∪,∩,c,∅,A)(P(A), \cup, \cap, {}^c, \emptyset, A), bits ({0,1},OR,AND,NOT,0,1)(\{0,1\}, \text{OR}, \text{AND}, \text{NOT}, 0, 1).
  • Parallel connection = OR, series connection = AND, invert = NOT.
  • BnB^n (switching algebra) works component by component, like bitwise operators.

Practice questions

Answer on paper first, then check. The explanation matters more than the letter you chose.

Question 1 · multiple choice

In a Boolean algebra (X,∨,∧,′,O,I)(X, \lor, \land, ', O, I), which statement is an identity law?

Show answer

Answer: C. x∨O=xx \lor O = x

B4 says x∨O=xx \lor O = x and x∧I=xx \land I = x. Option 2 is tempting, but x∧O=Ox \land O = O, not xx.

Question 2 · multiple choice

In the Boolean algebra (P(A),∪,∩,c,∅,A)(P(A), \cup, \cap, {}^c, \emptyset, A), which element plays the role of II?

Show answer

Answer: A. AA

II is the identity for meet (∩\cap): Y∩A=YY \cap A = Y for every subset YY. ∅\emptyset is OO, the identity for ∪\cup.

Question 3 · multiple choice

Two switches a=1a = 1 (closed) and b=0b = 0 (open) are connected in series. What is the state value of aa ser bb?

Show answer

Answer: B. 0

In series, current must pass through both switches, so both must be closed: 1∧0=01 \land 0 = 0. Option 3 describes a parallel connection.

Question 4 · multiple choice

In B3B^3, what is (1,0,1)′(1, 0, 1)'?

Show answer

Answer: D. (0,1,0)(0, 1, 0)

The complement flips every component. Option 3 is tempting because (1,1,1)(1,1,1) is II, but II is x∨x′x \lor x', not x′x'.

Question 5 · multiple choice

In B3B^3, what is (1,0,1)∧(0,1,1)(1, 0, 1) \land (0, 1, 1)?

Show answer

Answer: C. (0,0,1)(0, 0, 1)

Componentwise AND: 1∧0=01 \land 0 = 0, 0∧1=00 \land 1 = 0, 1∧1=11 \land 1 = 1. Option 1 is the componentwise OR.

Question 6 · short answer

Show that the complement laws hold in the two-element Boolean algebra B={0,1}B = \{0, 1\}.

Show worked answer

In BB, O=0O = 0, I=1I = 1, 0′=10' = 1 and 1′=01' = 0. Law x∧x′=Ox \land x' = O: for x=0x = 0, 0∧1=00 \land 1 = 0; for x=1x = 1, 1∧0=01 \land 0 = 0. Law x∨x′=Ix \lor x' = I: for x=0x = 0, 0∨1=10 \lor 1 = 1; for x=1x = 1, 1∨0=11 \lor 0 = 1. Both laws hold for every element of BB, so the complement laws (B5) hold.

↑ ↓ move↵ openTab switch type