Number Systems - Overview
Number systems and codes are used to give meaning to collections of symbols. A number system consists of an alphabet. Number systems fall into one of three primary types. These are counting, relative position, and absolute position.
Counting Number System
The least useful number system, but certainly the simplest, is the counting system. This number system has an alphabet of only one character. This character is written once for every value to be added to the total number. The position of the characters has no meaning. Arithmetic is very simple to do in this number system, but representing moderately large numbers is difficult. This system is most commonly used by people taking surveys on a clipboard.
Relative Position Number Systems
Relative position number systems allow larger numbers to be represented fairly efficiently compared to counting number systems. In this type of number system, the value of a number is the sum of all the parts unless a character precedes a larger one, in which case it is subtracted. One popular relative position number system is the Roman Numeral system still used on many clocks. This system has an alphabet that consists of
This number system has several drawbacks. Most notably, arithmetic is very difficult (what is
Absolute Position Number Systems
Absolute position number systems are the most familar systems to us. They offer the greatest utility in terms of representing large numbers as well as performing complex mathematical operations on them. These number systems consist of a base which is equal to the number of characters in the alphabet. Base10, or decimal, is familar to everyone. The value of a number is equal to the sum of the parts scaled by their position. Positions start at 0, and work left increasing by one with every additional character.
Binary (Base2) Alphabet =
The decimal point, or more generically the radix point, marks the position where the fractional portion of a number starts. The negative positions, and therefore negative powers of the base, result in fractional values to the right of the radix point.
In this course, we will be using binary and hexadecimal most of the time. Hexadecimal can be thought of as binary digits grouped together rather than as an independent number system. This should feel very similar to working with large decimal numbers where commas are used to group digits like 1,273,481,285. Working from right to left, group 4 binary digits together and replace with the single hexadecimal character. Similarly, writing out the binary value for each hexidecimal digit will convert from hex to binary.
0x123 = 0001 0010 0011
10100111010 = 0101 0011 1010 = 0x53A
When selecting a number system, always remember that wise selections can make your life easier. Spend the time looking at your design options before rushing on the first idea that looks like it will work.Last Modified: