SCEN103 Hexadecimal Numbers

Hex for short

Binary numbers can be unwieldy in length

Place holders are powers of 16
Power of 16: 3 2 1 0
Weight: 4096  256   16    1

Sixteen symbols or characters needed:
The usual 10 of 0, 1, 2, ... 9 plus A, B, C, D, E, and F

Correspondence between new hexadecimal digits and decimal/binary
DecimalHexBinary
10A1010
11B1011
12C1100
13D1101
14E1110
15F1111

4 bits used to represent a single hex digit

Example: conversion of 7CE to decimal.
7CE =  (7 x 162) + (C x 16) + E
(7 x 256) + (12 x 16) + 14
1792 + 192 + 14
1998

If there is any likelihood of confusion, the base of the number system should be indicated by explicitly writing the radix. For example, the answer above, decimal 1998, would be more precisely written as 199810. Hexadecimal numbers are typically indicated by using the subscript H behind the number; in the example above 7CEH was converted to a decimal number. Note that 1998 would be ambiguous if written in a context where the counting base is not clear; is 1998H or 199810 intended?

Example: conversion of 7CE to binary.
7CE =  0111 1100 1110


Back to SCEN103 Home Page.
Comments, suggestions, or requests to ghw@udel.edu.

"http://www.physics.udel.edu/~watson/scen103/hex.html"
Last updated March 18, 1999.
Copyright George Watson, Univ. of Delaware, 1999.