The most popular number system is Decimal or base 10. It consists of 10 digits, which are 0,1,2,3,4,5,6,7,8,9.
Base 8, also called the octal number system, has eight digits, namely 0,1,2,3,4,5,6,7.
Conversion From Base 10 to Base 8
To convert a number from Base 10 to base 8, you must follow these steps:
- Divide the number by 8 and take note of the remainder.
- Divide the resulting quotient by 8 and also take note of the remainder.
- Repeat steps 1 and 2 until the quotient becomes zero.
- The number in base 8 will be the remainder from down to up.
Example 1
Convert \(150_{10}\) to base 8.
Solution:
To convert 150 to base 8, we will have to divide it until the quotient becomes 0. We also need to take note of its remainder.
150/8 = 18 R 6
18/8 = 2 R 2
2/2 = 0 R 2
Reading the remainder upwards, 226 is the octal equivalent of 150 in decimal.
Example 2
Convert 500 from decimal to an octal number.
Solution:
The procedure is the same as the previous example.
500/8 = 62 R 4
62/ 8 = 7 R 6
7/ 8 = 0 R 7
\(500_{10}=764_8\)
Conversion From Base 8 to Base 10
You can convert an octal number to a decimal number using these steps:
- Write down the base 8 number.
- Multiply each digit by 8 raise to power 0,1,2, and so on depending on the length of the digits.
- The result of adding the product together is the base 10 equivalent of the base 8 number.
Example 3
Convert \(56_8\) to a number in base 10.
Solution:
The rightmost digit(6) of the equation will be multiplied by 8 raised to power 0, and the second rightmost digit(5) of the equation will be multiplied by 8 raised to power 1.
\(56_8=5 \times 8^1+ 6 \times 8^0\)
\(56_8=46_{10}\)
Hence, 46 is the decimal equivalent of the octal number 56.
Example 4
Convert 4364 from base 8 to base 10.
Solution:
The rightmost digit of the equation will be multiplied by 8 and raised to power 0, the second rightmost digit will be multiplied by 1, and so on.
\(4364_8 = 4 \times 8^3 + 3 \times 8^2 + 6 \times 8^1 + 4 \times 8^0\)
\(4364_8 = 4 \times 512 + 3 \times 64 + 6 \times 8 + 4 \times 1\)
\(4364_8 = 2048 + 192 + 48 + 4\)
\(4364_8 = 2292_{10}\)
Conversion of floating-point numbers From Base 8 to Base 10
To convert a floating-point number from base 8 to base 10, you should follow these steps:
- Divide the digit into an integer part and a fractional part.
- Convert the integer part as you would normally convert base 8 to base 10.
- To convert the fractional part to base 10, use the following steps:
- Multiply 8 raised to the power of -1 to the leftmost digit, multiply 8 raise to the power of -2 to the second leftmost digit, and so on.
- Add the product together.
- Add the result of steps 3 and 4 together. The resulting answer is the number in base 10.
Example 5
Convert 125.12 from Base 8 to base 10.
Solution:
125 is the integer part while 0.1 is the decimal part. First, we convert 125 to base 10.
\(125_{8}=1×8^2+2×8^1+5×8^0\)
\(125_8=64+16+5=85_{10}\)
Now, we convert the fractional part to base 10.
\(0.1_8=1×8^{-1}=0.125_{10}\)
Therefore,
\(125.1_8=85+0.125=85.125_{10}\)
Conversion of Floating-point Number From Base 10 to Base 8
A floating point number can be converted to a decimal using the following steps:
- Divide the digit into two parts: the integer part and the decimal part.
- Convert the integer part as usual.
- For the fractional part, we just have to keep multiplying the fractional part by 8 until the fractional part is zero or until a specific precision. Please take note of the integer as you multiply.
- Add the result of steps 2 and step 3.
Example 6
Convert \(250.125_{10}\) to an octal number.
Solution:
250 is the integer part while 0.125 is the fractional part.
250/8=81 R 2
31/8 = 3 R 7
3 / 8 = 0 R 3
Reading the remainders upwards, \(250_{10}=372_8\)
Now, let’s solve the fractional part
0.125 × 8 =0+1
The fractional part is 0, Hence, we stop there. \(0.125_{10}= 0.1\)
Adding the fractional and integer part together.
\(250.125_{10}=372.1_8\)