Converting Binary to Octal start 100011001010012 STEP ONE: Take the binary number and from right to left, group all placeholders in triplets. Add leading zeros, if necessary: 010 001 100 101 001
010 001 100 101 0012 214518 = STEP TWO: Convert each triplet to its single-digit octal equivalent. (HINT: For each triplet, the octal conversion is the same as converting to a decimal number): 010 001 100 101 001 2 1 4 5 1
Converting Octal to Binary 435208 = 1000111010100002 STEP ONE: Take each octal digit and convert each digit to a binary triplet. Keep leading zeros: 4 3 5 2 100 011 101 010 000
Hexadecimal System Sometimes, it is necessary to use a numbering system that has more than ten base digits One such numbering system, hexadecimal, is useful on the Web Hexadecimal number, a Base-16 numbering system, is used in specifying web colors
Hexadecimal Numbering There are new symbols for the Base-16 equivalents of the Base-10 numbers 10, 11, 12, 14 and 15. Examine: DEC 1 2 3 4 5 6 7 HEX 8 9 10 11 12 13 14 15 A B C D E F
Decimal Hexadecimal Octal Binary 0000 1 0001 2 0010 3 0011 4 0100 5 0101 6 0110 7 0111 8 10 1000 9 11 1001
Decimal Octal Binary 10 A 12 1010 11 B 13 1011 C 14 1100 D 15 1101 E Hexadecimal Octal Binary 10 A 12 1010 11 B 13 1011 C 14 1100 D 15 1101 E 16 1110 F 17 1111
Convert a hexadecimal number to a binary number, simply divided the binary number into 4-bit groups substitute the corresponding four bits in binary for each hexadecimal digit in the number. For example, convert ABCD to a binary value, The binary equivalent is: ABCD= 1010 1011 1100 1101
Binary to Hex Conversion Break the binary number into 4-bit groups from the Left to the right. Convert the 4-bit binary number to its Hex equivalent. For example, the binary value 101011111011 0010 will be written: 1010 1111 1011 0010=AFB2
Hex to Binary Conversion Convert the Hex number to its 4-bit binary equivalent. Combine the 4-bit groups by removing the spaces. For example, the hex value AFC7 will be written: AFC7=1010 1111 1110 0111
Hex to Decimal Conversion To convert from Hex to Decimal, multiply the value in each position by its hex weight and add each value. use the expansion form AFB.2=10*163 +15*162 +11*16+2*16-1
Decimal to Hex Conversion Repeated Division By 16 Divide the decimal number by 16, and write the remainder on the side as the least significant digit. This process is continued by dividing the quotient by 16 and writing the remainder until the quotient is 0. the remainders represent the hex equivalent of the decimal number are written beginning at the least significant digit (right) and each new digit is written to the next more significant digit (the left) of the previous digit.
Example convert 196710 to Hex 1967/16 122 15 F 122/16 7 10 AF 7/16 7AF Division Quotient Remainder Hex Number 1967/16 122 15 F 122/16 7 10 AF 7/16 7AF Then (1967)10 =(7AF)16
Decimal fraction to B, O and H Product with Base New farction integer 0.0625 2X0.0625 0.1250 .0 2X0.125 0.250 .00 2X0.25 0.5 .000 1.0 .0001 0.062510 = .00012
Fraction Product with Base New fraction integer 0.0625 8X0.0625 0.5000 .0 0.5 8X0.5 4. 0 .04 0.062510 = .048 16X0.0625 1.0000 .1 0.062510 = .116
Convert (1967.0626)10 to B,O,H Division Quotient Remainder Hex Number 1967/8 245 7 245/8 30 3 37 30/8 6 376 3/8 3637 (1967)10= (3537)8 0.062510 = .048 (1967.0626)10= (3637.04)8
Binary Addition + 1 10 0 + 0 = 0 0 + 1 = 1 1 + 0 = 1 1 + 1 = 10
Multiply Binary numbers * 1 0 * 0 = 0 0 * 1 = 0 1 * 0 = 0 1 * 1 = 1
1111 carry 111101 100111+ 1100100 1 1 1 (carry) 0 1 1 0 1 1 0 1 1 1+ ------------- 1 0 0 1 0 0
Multiply 1011 and 1010 1 0 1 1 × 1 0 1 0 --------------- 0 0 0 0 1 0 1 1 × 1 0 1 0 --------------- 0 0 0 0 + 1 0 1 1 ------------------ 1 1 0 1 1 1 0
------------------------------------ Multiply Example 1 1 0 1 1 1 1 1 1 ------------------------------------ 1 0 1 1 1 1 0 1 1