What Is "Computer": A Machine That Performs Computational Tasks Using Stored Instructions
What Is "Computer": A Machine That Performs Computational Tasks Using Stored Instructions
These units communicate to each other through a set of electric wires called bus.
Processor/CPU consists of
Arithmetic logic unit (ALU): Executes arithmetic (addition, multiplication,...) and logical (AND, OR,...) operations.
Control unit: Generates a sequence of control signals telling the ALU how to operate. Registers: Fast, small memory for temporary storage during mathematical operations.
RAM stores
Data
Digital Computers
The computer deals with digital information, i.e., it deals with the information that is represented by variables that take limited number of discrete values. Use binary number system. Based on two digits, 0 and 1 called bits. Information is represented in group of bits. COMPUTER ARCHITECTURE :Structure and behaviour of the computer as seen by the user. Instruction format Instruction set Memory addresssing techniques
Boolean variable: Takes only two values either true (1) or false (0). They are used as basic units of formal logic.
Formal logic: In formal logic, a statement (proposition) is a declarative sentence that is either true(1) or false (0).
Truth table:
Represents relationship between a Boolean function and its binary variables. It enumerates all possible combinations of arguments and the corresponding function values.
symbols for logic gates. A simple circuit sketch that represents inputs and outputs of Boolean functions.
Gates
Refer to the hardware to implement Boolean operators. Used to perform manipulation of binary information. Binary information is represented by signals. The most basic gates are : AND , OR , NOT Universal Gate :
gate which can implement any Boolean function without need to use any other gate type ; inexpensive to manufacture
NAND, NOR
Logic Gates
Name
A
Symbol
X B A X B
X=A+B
A A A
X X
X = A X=A
X B A X B A X B A X B
X = (AB)
X = (A + B) X=AB or X = AB + AB X = (A B) or X = AB+ AB
Exclusive NOR
XNOR
Implementing an Inverter Using only NOR Gate The figure shows two ways in which a NOR gate can be used as an inverter (NOT gate).
Generalized DeMorgan's Theorem (a) (a + b + z)' = a'b' z' (b) (a.b z)' = a' + b' + z
Show that; 1- ab + ab' = a 2- (a + b)(a + b') = a 1- ab + ab' = a(b+b') = a.1=a 2- (a + b)(a + b') = a.a +a.b' +a.b+b.b' = a + a.b' +a.b + 0 = a + a.(b' +b) + 0
= a + a.1 + 0 = a +a=a
Another way : Take dual of the function followed by complimenting each literal.
Example
Operator precedence
The Operator precedence for evaluating boolean expressions is: Parenthesis NOT AND OR
Literal: a primed or unprimed variable Product term Product (i.e. AND) of literals Minterm(standard product): product term with every function literal appearing exactly once, in true or complemented form(but not both) Example: F(x,y,z) has 8 minterms xyz, xyz, xyz, ... n variables can be combined to form 2n minterms. A minterm equals 1 at exactly one input combination and is equal to 0 otherwise Example: xyz = 1 only when x=0, y=0,z=0 A minterm is denoted as mi where i corresponds the input combination at which this minterm is equal to 1
Maxterms(standard sums) are OR terms with every variable in true or complemented form. Example: F(x,y,z) has 8 maxterms (x+y+z),(x+y+z),(x+y+z), ... n variables can be combined to form 2n maxterms. A maxterm equals 0 at exactly one input combination and is equal to 1 otherwise Example:(x+y+z) = 0 only when x=0,y=0,z=0 A maxterm is denoted as Mi where i corresponds the input combination at which this maxterm is equal to 0 Each maxterm is the complement of its corresponding minterm and vice versa.
An Boolean function F can be expressed by A truth table Sum(ORing) of ALL the minterms that produce 1 in the function mi Writing F as A product(ANDing) of ALL the maxterms that produce 0 in the function Writing F as Mi
Canonical forms of a function: Sum of minterms (SOM) Product of maxterms (POM) Standard forms (may use less gates) Sum of products (SOP) Product of sums (POS) The sum of minterms is a special case of the SOP form, where all product terms are minterms The product of maxterms is a special case of the POS form, where all sum terms are maxterms
F = ab+a (already sum of products:SOP) F = ab + a (b+b) (expanding term) F = ab + ab + ab (it is canonical form:SOM)
Interchange the symbols S and and list those numbers missing from the original form
S of 1's of 0's
A tool for representing Boolean functions of up to six variables. K-maps are tables of rows and columns with entries represent 1`s or 0`s of SOP and POS representations. An n-variable K-map has 2n cells with each cell corresponding to an n-variable truth table value. K-map cells are labeled with the corresponding truthtable row. K-map cells are arranged such that adjacent cells correspond to truth rows that differ in only one bit position (logical adjacency).
If mi is a minterm of f, then place a 1 in cell i of the K-map. If Mi is a maxterm of f, then place a 0 in cell i. If di is a dont care of f, then place a d or x in cell i.
K-map cells that are physically adjacent are also logically adjacent. Also, cells on an edge of a K-map are logically adjacent to cells on the opposite edge of the map. If two logically adjacent cells both contain logical 1s, the two cells can be combined to eliminate the variable that has value 1 in one cells label and value 0 in the other.
Always combine as many cells in a group as possible. This will result in the fewest number of literals in the term that represents the group. Make as few groupings as possible to cover all minterms. This will result in the fewest product terms. Always begin with the largest group, which means if you can find eight members group is better than two four groups and one four group is better than pair of twogroup.
Dont-care condition
Minterms that may produce either 0 or 1 for the function. They are marked with an x in the K-map. This happens, for example, when we dont input certain minterms to the Boolean function. These dont-care conditions can be used to provide further simplification of the algebraic expression. (Example) F = A`B`C`+A`BC` + ABC` d=A`B`C +A`BC + AB`C F = A` + BC`