[Home]
[Edit this page]
[Recent Changes]
[Special Pages]
[Help]
hexadecimal
Obviously, after 9, we run out of standard digits to represent the quantity up to sixteen. The convention is to supply the letters A-F to represent the decimal quantities 10-15 respectively. Thus, the number A would follow 9 (representing decimal 10), B would follow A, up until F (representing decimal 15) and then, using powers of sixteen, the second digit would enter into play.
Thus, the hexadecimal number 10 represents the decimal number 16, and following the quantities, the hexadecimal number 20 represents the decimal number 32.
Each digit, starting with 160 (1) immediately to the left of the decimal and moving towards the left, represents multipliers of the following quantities:
So what? (aka WTF?)
Hexadecimal is used as a compact way to represent bitpatterns, hence it being associated with assembler, though it's actually associated with bitmanipulation and representing bitpatterns in general. In decimal each the bitpattern represented by say the tens digit in 19, overlaps with the bitpattern representing 9. So whenever you want to represent a bitpattern in decimal you have to think about how every digit can effect the pattern. With hexadecimal, each digit has a single independent of every other digit mapping to a bitpattern. Which is
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
hexadecimal
Hexadecimal
The hexadecimal numbering system, or base 16, is a numbering system based on the assumption that each digit represents a power of sixteen. These powers begin with 160 (1) immediately to the left of the decimal point, and increase as one moves to the left and decrease as one moves to the right. Thus, the second digit to the left of the decimal represents 161 (16) and the third represents 162 (256).Obviously, after 9, we run out of standard digits to represent the quantity up to sixteen. The convention is to supply the letters A-F to represent the decimal quantities 10-15 respectively. Thus, the number A would follow 9 (representing decimal 10), B would follow A, up until F (representing decimal 15) and then, using powers of sixteen, the second digit would enter into play.
Thus, the hexadecimal number 10 represents the decimal number 16, and following the quantities, the hexadecimal number 20 represents the decimal number 32.
Each digit, starting with 160 (1) immediately to the left of the decimal and moving towards the left, represents multipliers of the following quantities:
- 1
- 16
- 256
- 4096
- 65536
- 1048576
So what? (aka WTF?)
Hexadecimal is used as a compact way to represent bitpatterns, hence it being associated with assembler, though it's actually associated with bitmanipulation and representing bitpatterns in general. In decimal each the bitpattern represented by say the tens digit in 19, overlaps with the bitpattern representing 9. So whenever you want to represent a bitpattern in decimal you have to think about how every digit can effect the pattern. With hexadecimal, each digit has a single independent of every other digit mapping to a bitpattern. Which is
- 0 = 0000
- 1 = 0001
- 2 = 0010
- 3 = 0011
- 4 = 0100
- 5 = 0101
- 6 = 0110
- 7 = 0111
- 8 = 1000
- 9 = 1001
- A = 1010 = 10 (note how bits from 9 overlap 10's)
- B = 1011 = 11
- C = 1100 = 12
- D = 1101 = 13
- E = 1110 = 14
- F = 1111 = 15
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
