Decimal & Octal Numbering System
The Octal Numbering system is another number systems which is used in the digial world. In the electronics based systems the processors and the devices prefer Binary format. The decimal system is the standard numbering format which is understandable by all humans but the binary number is difficult for humans to remember or read. Hence Octal and hexadecimal systems came into existence . These are used in processors/machines. It is because, a number in digital system when represented with a higher base value could occupy less memory space. Apart from that, higher base value number systems are easy to refer address locations in processors. The normally used higher base value numbering systems are hexa decimal and octal number system.
In this octal system, the values present are from 0 to 7. As there are eight digits in this system, the radix of it is eight. This system is known as the ‘Base 8 System’. There are various direct and indirect methods available to convert decimal system to Octal . In the method called indirect, the decimal format can be converted in the form of binary using decimal to binary conversion. Once it is converted the digits are grouped into three bits and the octal values are extracted. The direct method of conversion from digital to Octal can be seen below.
Decimal to Octal Conversion
Decimal and Octal Conversion follows the method of division. By dividing the decimal with eight one can obtain the octal value. The value is divided by eight because of the radix representation of octal which is eight.
The steps followed to convert decimal into octal are
- Firstly, take the given decimal number.
- If the value of the given decimal number is lesser than ‘8’. Then the given decimal number will be in the same octal format.
- If the given value of decimal is greater than that of eight. Then in such cases start by dividing the by eight.
- Note down the remainders obtained after divisions.
- The process continues until the remainder obtained is less than eight.
- Then obtained remainders are written in the ‘reverse order’.
- The number finally extracted can be the equivalent value of the octal format.
Let us discuss the above conversion in detail followed by an example.
Convert Decimal 378 into Octal
- The given decimal value 378 can be converted by the method of division.
- 378/8 = 47(Quotient) and 2 is the Remainder.
- The quotient 47 is further divided by 8.
- 47/8 = 5 (Quotient) and 7 is the Remainder.
- As the quotient 5 is less than 8. Then in such case 5 is the octal number.
- Then these remainders are written collectively in reverse order.
- Hence 572 is the octal representation of 378 decimals.
Convert decimal 50 to octal
- The given decimal value 50 is divided by 8.
- On dividing 50/8= 6(Quotient) and the Remainder is 2.
- The quotient obtained in the previous state that is 6 is less than 8.
- Then 6 can be treated as an octal value.
- Hence collectively 82 is the octal value of 50 decimal.
Based on these steps the conversion of decimal to octal is performed. Even though online programming tools and converters are available for the conversion. Its better to have a understanding on how it ca be done manually or how these converters work.
The conversion of the Decimal values into octal is possible by the method of the division until it reaches its quotient to 0. The obtained last remainder is treated as MSD. The conversion of a mixed decimal number is simple by converting both the integer and the fraction parts separately. The fraction part of it can be converted by multiplication of the digit 8 till the product value reaches 0 or it reaches the required value of accuracy. In this case, the first integer is treated as MSD.
Octal to Decimal Conversion
As the decimal to octal conversion is discussed let us deal with the reverse process of it.
The steps involved in this conversion are as follows:
- The given octal number must be converted to a decimal by multiplication method.
- The octal value must be multiplied by 8.
- Based on the positions from the rightmost digits the power values are assigned in increment order.
- Finally obtained values are added to obtain the resultant decimal value.
If there are mixed octal numbers. In such cases, the part of integers and the part of fractions are separately converted. The integers must be multiplied with the positional weight of 8. The fraction part must be divided into 8. It is just the replicate process of decimal to octal conversion.
Convert 572 value of octal into Decimal
- Based on the positions 2 is considered to be the LSD.
- That is 5*8^2+7*8^1+2*8^0
- 5*64+7*8+2 = 320+56+2 = 378
- Hence 378 can be known as the decimal value of the given octal number 572.
Convert 57.1 value of octal into decimal
- As it is a position based system. The given number is mixed decimal. 57 is known as the integer part and 1 is the fractional part.
- The integer part must be multiplied by 8 and the fraction must be divided by 8.
- 5*8^1+7*8^0+1*8^-1 = 40+7+0.125 = 47.125.
- Hence 47.125 is the decimal representation of the value 57.1 in octal.
Decimal to Octal Conversion Table
The table of conversion for the digits to convert from decimal to octal or octal to decimal is as follows
Hence the conversion of octal number into decimal and vice versa is very simple. Even there are various programs in different languages like C, Java,python, php that convert one form of code into another format. There are also encoding and the decoding circuits which are used in circuits for hardcore conversions. The Encoders are placed at the inputs of the circuits. However, the conversion must be handled with care while the mixed decimals are provided. Can you convert the value of octal 4057.07 into a decimal?