There can only be
A | B | S | |
---|---|---|---|
0 | 0 | 0 | |
Truth Table | 0 | 1 | 1 |
1 | 0 | 1 | |
1 | 1 | 1 |
Parallel Switch
It does not matter how many or few terms we add together, either.
Consider the following sums:
But in binary addition:
In Boolean algebra, a sum term is a sum of literals.
In logic circuits, a sum term is produced by an OR operation with no AND operations involved.
Some examples of sum terms are:
A sum term is equal to
A sum term is equal to
A sum term is a sum of literals. The sum term is 1 if one or more of the literals are 1.
The sum term is zero only if each literal is 0.
Determine the values of ‘A’, ‘ B’, and ‘C’ that make the sum term of the expression:
Series Switch
In Boolean algebra, a product term or “minterm” is the product of literals.
In logic circuits, a product term is produced by an AND operation with no OR operations involved. Some examples of product terms are
A product term is equal to 1 only if each of the literals in the term is 1. A product term is equal to 0 when one or more of the literals are 0.
A product term is the product of literals.
Determine the values of ‘A’, ‘ B’, and ‘C’ that make the sum Product term of the expression:
When two or more product terms are summed by Boolean addition, the resulting expression is a sum-of-products (SOP). Some examples are:
Legal SOP Expression:
ILegal SOP Expression:
When all input variables appear in each product term, the expression is known as a standard Sum of Product (SOP) expression:
Following expression has input variables A, B, C and D , complete set of variables is not present in the first two expression
Following is a standard SOP (SSOP) expression
|
|
XOR Function |
|
Only the product terms where circuit produces 1 (values of S) are added in the equation
Combinational logic circuits can be analyzed by writing the expression for each gate and combining the expressions according to the rules for Boolean algebra.
Apply Boolean algebra to derive the expression for X.
Write the expression for each gate:
Simpler AND gates in Groups produce the same output of a big complex AND gate.
Simpler AND gates in Groups produce the same output of a big complex OR gate.
Note we see that a double inversion, cancel each other out!
Boolean Equation :
A | S | |
---|---|---|
Truth Table | 0 | 1 |
1 | 0 |
The associative laws are also applied to addition and multiplication. For addition, the associative law states
When OR’ing more than two variables, the result is the same regardless of the grouping of the variables.
For multiplication, the associative law states
When ANDing more than two variables, the result is the same regardless of the grouping of the variables.
Z= (A.B).C == A.(B.C)
Z= (A+B)+C == A+(B+C)
The commutative laws are applied to addition and multiplication. For addition, the commutative law states:
In terms of the result, the order in which variables are ORed makes no difference.
For multiplication, the commutative law states:
In terms of the result, the order in which variables are ANDed makes no difference.
The distributive law is the factoring law. A common variable can be factored from an expression just as in ordinary algebra. That is
The distributive law can be illustrated with equivalent circuits:
1- The complement of the product of two variables equals the sum of their complements.
2- The complement of the sum of two variables equals the product of their complements.
F= AB+1+CD =?
F=A.B.0.C.D =?
If we can reduce the number of gate and yet produce the
same functionality we gain the benefits of:
A literal by itself cancels out any term that contains it: (Absorption)
A literal by itself knocks out its not’ed opposite that appears in any minterm (Absorption)
Step 1: Apply Distributive Law
Step 2: Apply Complement Identity)
= 1 . (A + B)
Step 3: Apply Identity Law
Z = 1 . (A + B)
= A + B
Step 1: Apply Complement Law
Step 2: Apply Annulment Law
Step 3: Apply identity Law
Z = A + (A . B) // Brackets for clarity
Use Identity Law : A + 1 = A
Z = (A + 1) + (A . B)
Distributive law - factorise
Z = A + (1 . B)
Annulment law: A + 1 = 1
Z = A + 1
Identity law: A . 1 = A
Z = A
## NOT Gate ![bg right:43% 95%](../../figures/NOT.png) Note: NOT is represented by a Bar on top! >> Boolean Equation : $\ \ \ S = \bar{A}$ ||A|S| |--|--|--| |**Truth Table**| 0 | 1| ||1|0| >> A' or ¬A both are the same as $\bar{A}$. Code symbol is the explanation mark `!` --- ## Inversion or Complement Note we see that a double inversion, cancel each other out! Boolean Equation : $\ \ \ S = \overline{\overline{A}} == A$ ||A|S| |--|--|--| |**Truth Table**| 0 | 1| ||1|0| ![center 100%](../../figures/NOT_INV.png) ---
## Applications **Beyond computer hardware design...** - Machine learning - Neural Networks - Categorical ![bg right:50% 100%](../../figures/ML_BL.png) --- ## Applications **Programming...** The obvious reason is that you are going to write a lot of `if()` statements and you want to get them right, but also because you are going to have to fix the `if`’s of other people who’ve made logical mistakes. ![bg right:40% 90%](../../figures/boolean_Flow.png)