The number system is a special way of writing numbers using a specific set of numbers - special characters. This set of numbers is a kind of alphabet, thanks to which a person can read the recorded number.
In the process of the development of civilization, many number writing systems arose. At first it was primitive circles, sticks or hooks, the number of which was equal to the number of counted objects. The numbers could be letters of the alphabet, and even syllables of speech. Ultimately, all past and current number systems can be divided into three groups: positional systems, non-positional and mixed.
In non-positional systems, the weight and significance of a figure does not depend directly on its position in the number. In this case, certain restrictions are imposed on the order of numbers, their arrangement in ascending and descending order. For example, the well-known Roman numerals are a non-positional number system.
If in the system the weight of a digit directly changes depending on the place in the sequence by which this number is recorded, then the system is considered positional. For example, the number 888 is written in the same numbers, but they have different quantitative values ββdepending on the space occupied: 8 hundred, 8 tens, 8 units.
Any positional system is characterized by its base. In a positional system, a base is the number of different characters or signs that are used to record numbers in a given system. As the basis can be any natural numbers. Thus, you can build an infinite number of different positional systems. Decimal , binary, octal and hexadecimal are now widely used. Let's discuss them in more detail.
Decimal system
She came to Europe from India, where she arose no later than the 6th century A.D. The system uses 10 digits - from zero to nine. At the same time, the information is carried not only by the figure itself, but also by the place on which it stands.
For the decimal system, the number 10 and its degrees are especially important. The last digit on the right side of the number represents the number of units, followed by the number of tens, hundreds, thousands, etc.
The reason for the popularity and prevalence of the decimal number system in the world is that his hands were the first calculating apparatus of a person. The number of fingers became the starting point for the account system.
Binary system
This system uses two digits - one and zero. The system is built around the number two and its degrees. The rightmost digit indicates the number of units, followed by two, then four, eights, etc.
Using a convenient binary system, any natural number can be written as a sequence of zeros and ones. However, not only numbers can be encoded with a binary recording, but also pictures, films, texts, audio recordings. Technically, binary coding is implemented quite easily, so it has found wide application in the field of technology.
Octal system
In this number system, eight digits - from zero to seven. In the low order, the number 1 simply means one - the same as in the decimal system. But in the next digit, the unit means 8, then - 64 so on. The number 100 written in octal code is read as decimal 64.
To translate the octal number 611 into the binary system, it is necessary to replace each digit of this number with the corresponding binary triad. And for the reverse translation of a number from the binary to the octal number system, it is necessary to select triads from right to left in it, then replace each triple of digits with the corresponding digit from the octal system.
Hexadecimal system
The number written in the octal system already looks quite compact. But the hexadecimal system allows you to make recording even more compact. From the 1st to the 10th digits in this system, the usual sequence is used - from zero to nine, but the first six letters of the Latin alphabet are used as the next six digits (11 to 16) .
As in previous systems, the number one in the lower order indicates one. In the next category, it turns into 16 (from the decimal system), and in the next one, to 256 (from the decimal system). If the digit F is in the lower order, then it denotes the decimal number 1.
Direct and reverse translation from this number system to binary is carried out similarly to the translation for the octal system considered above.