Number Systems & Logic Gates Day 2
Octal Number System Base (Radix)8 Digits0, 1, 2, 3, 4, 5, 6, 7 e.g = =648 1 =88 0 =1 The digit 2 in the second position from the right represents the value 16 and the digit 1 in the fourth position from the right represents the value 512.
Hexadecimal Number System Base (Radix)16 Digits0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F e.g.2F4D 16 2 F 4 D 16 3 = = = =1 The digit F in the third position from the right represents the value 3840 and the digit D in the first position from the right represents the value 13.
Eg to Binary Conversions: Decimal to Binary (Integer) Remainder Divide integer until the integer quotient becomes
Eg to Decimal 2 0 x 02 1 x 12 2 x 12 3 x 02 4 x Conversions: Binary to Decimal (Integer)
Eg to Octal Conversions: Decimal to Octal (Integer)
Eg to Decimal x 78 1 x 08 2 x x Conversions: Octal to Decimal (Integer)
D Eg to Hexadecimal F E D C 14-B 13-A D39 16 Conversions: Decimal to Hexadecimal (Integer)
Eg. D39 16 to Decimal D x x x x F E D C 14-B 13-A Conversions: Hexadecimal to Decimal (Integer)
Eg to Octal Conversions: Binary to Octal Therefore, =
Eg to Binary Conversions: Octal to Binary Therefore, =
Eg to Hexadecimal D Conversions: Binary to Hexadecimal Therefore, = 65D 16
Eg. 65D 16 to Binary D Conversions: Hexadecimal to Binary Therefore, 65D 16 =
Logic Gates Binary information is represented in digital computers by physical quantities called signals. Two different electrical voltage levels such as 3 volts and 0.5 volts may be used to represent binary 1 and 0. Binary logic deals with binary variables and with operations that assume a logical meaning.
Logic Gates Contd.. A particular logic operation can be described in an algebraic or tabular form. The manipulation of binary information is done by the circuits called logic gates, which are blocks of hardware that produce signals of binary 1 or 0 when input logic requirements are satisfied.
Logic Gates Contd.. Each gate has a distinct graphics symbol and it’s operation can be described by means of an algebraic expression or in a form of a truth table. Each gate has one or more binary inputs and one binary output.
Logic Gates AND OR (Inclusive OR) NOT (inverter) NAND (Not AND) NOR (Not OR) XOR (Exclusive OR) XNOR (Exclusive NOR)
Logic Operations ANDLogic GateTruth Table A B x A B x A, B Binary Input Variables x Binary Output Variable X=A.B
Logic Operations ORLogic GateTruth Table A B x A B x X=A+B This is read as x equals A or B
Logic Operations NOT Logic GateTruth Table A x x A X=A` X=A
Logic Operations NANDLogic GateTruth Table A B x A B x X=A.B
Logic Operations NOR Logic GateTruth Table A B x A B x X=A+B
Logic Operations XOR Logic GateTruth Table A B x A B x
Logic Operations Exclusive-NOR Logic GateTruth Table A B x A B x X= A + B