Binary to Octal Conversion Examples
Binary to octal conversion is an important concept in number systems used in computer science and digital electronics. It helps in simplifying long binary numbers by converting them into a shorter base-8 representation. This is especially useful in low-level programming, memory addressing, and digital system design.
The examples of binary to octal conversion given below will help learners understand the step-by-step process with clear explanations and practical understanding.
Understanding Binary to Octal Conversion
Binary to octal conversion is a quick and efficient method because each group of 3 binary bits corresponds directly to one octal digit.
1. What is Binary Number System?
The binary number system is a base-2 number system used internally by computers.
- Base: 2
- Digits: 0 and 1
- Each position represents powers of 2
2. What is Octal Number System?
The octal number system is a base-8 number system.
- Base: 8
- Digits: 0, 1, 2, 3, 4, 5, 6, 7
- Each position represents powers of 8
3. Relationship Between Binary and Octal
Binary and octal are closely related because:
- 1 octal digit = 3 binary bits
So, binary numbers are grouped into sets of 3 bits for conversion.
Binary to Octal Conversion Methods
There are two main methods for converting binary to octal:
1. Binary to Octal Conversion using Grouping Method
In this method, binary digits are grouped into sets of 3 bits (from right to left), and each group is converted into its octal equivalent.
2. Binary to Octal Conversion using Decimal Method
In this method, the binary number is first converted into decimal, and then the decimal number is converted into octal.
Let’s explain both methods with examples
1. Binary to Octal Conversion using Standard Table
The binary to octal conversion table helps students quickly convert binary numbers into their octal equivalents by grouping bits. This method is widely used in digital systems and programming because it simplifies long binary numbers.
The list of binary groups and their octal equivalents is given below:
| Binary | Octal |
|---|---|
| 000 | 0 |
| 001 | 1 |
| 010 | 2 |
| 011 | 3 |
| 100 | 4 |
| 101 | 5 |
| 110 | 6 |
| 111 | 7 |
Steps for Binary to Octal Conversion using a Standard Table
Binary to octal conversion is a simple method based on grouping binary digits into sets of 3 bits. Each group is then converted into its octal equivalent using the standard table.
Step 1: Write the Given Binary Number
Start by writing the binary number clearly.
- Example: (101011)₂
Step 2: Group Binary Digits into Sets of 3 (from Right to Left)
Divide the binary number into groups of three digits starting from the right side.
- 101011 → 101 011
|
If necessary, add leading zeros to complete the leftmost group of three digits
|
Step 3: Convert Each Group into Octal
Use the standard table to convert each 3-bit group into its octal equivalent.
- 101₂ = 5₈
- 011₂ = 3₈
Step 4: Combine All Octal Digits
Write all octal digits together to get the final answer.
- (101011)₂ = (53)₈
Examples are the best way to understand binary to octal conversion in a practical and exam-oriented manner. Below are solved examples with step-by-step explanations. The list of solved examples is given below:
Example 1: Convert (101101)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (101101)₂ into its equivalent octal.
Description:
By grouping the binary digits into sets of three from right to left and replacing each group with its corresponding octal equivalent using the standard table, we get the octal of (101101)₂
The octal of 101₂ is 5₈
The octal of 101₂ is 5₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(101101)₂ = 55₈
Example 2: Convert (1100110)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1100110)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 100 110
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 100₂ is 4₈
- The octal of 110₂ is 6₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1100110)₂ = 146₈
Example 3: Convert (1110101)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1110101)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 110 101
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 110₂ is 6₈
- The octal of 101₂ is 5₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1110101)₂ = 165₈
Example 4: Convert (10011101)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (10011101)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 010 011 101
By replacing each group with its corresponding octal equivalent:
- The octal of 010₂ is 2₈
- The octal of 011₂ is 3₈
- The octal of 101₂ is 5₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(10011101)₂ = 235₈
Example 5: Convert (101011110)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (101011110)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 101 011 110
By replacing each group with its corresponding octal equivalent:
- The octal of 101₂ is 5₈
- The octal of 011₂ is 3₈
- The octal of 110₂ is 6₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(101011110)₂ = 536₈
Example 6: Convert (1101010111)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1101010111)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 101 010 111
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 101₂ is 5₈
- The octal of 010₂ is 2₈
- The octal of 111₂ is 7₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1101010111)₂ = 1527₈
Example 7: Convert (101110011010)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (101110011010)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 101 110 011 010
By replacing each group with its corresponding octal equivalent:
- The octal of 101₂ is 5₈
- The octal of 110₂ is 6₈
- The octal of 011₂ is 3₈
- The octal of 010₂ is 2₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(101110011010)₂ = 5632₈
Example 8: Convert (110101110011)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (110101110011)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 110 101 110 011
By replacing each group with its corresponding octal equivalent:
- The octal of 110₂ is 6₈
- The octal of 101₂ is 5₈
- The octal of 110₂ is 6₈
- The octal of 011₂ is 3₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(110101110011)₂ = 6563₈
Example 9: Convert (111001010111)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (111001010111)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 111 001 010 111
By replacing each group with its corresponding octal equivalent:
- The octal of 111₂ is 7₈
- The octal of 001₂ is 1₈
- The octal of 010₂ is 2₈
- The octal of 111₂ is 7₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(111001010111)₂ = 7127₈
Example 10: Convert (1001101110010)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1001101110010)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 001 101 110 010
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 001₂ is 1₈
- The octal of 101₂ is 5₈
- The octal of 110₂ is 6₈
- The octal of 010₂ is 2₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1001101110010)₂ = 11562₈
Example 11: Convert (1110101101011)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1110101101011)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 110 101 101 011
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 110₂ is 6₈
- The octal of 101₂ is 5₈
- The octal of 101₂ is 5₈
- The octal of 011₂ is 3₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1110101101011)₂ = 16553₈
Example 12: Convert (10101100111010)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (10101100111010)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 010 101 100 111 010
By replacing each group with its corresponding octal equivalent:
- The octal of 010₂ is 2₈
- The octal of 101₂ is 5₈
- The octal of 100₂ is 4₈
- The octal of 111₂ is 7₈
- The octal of 010₂ is 2₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(10101100111010)₂ = 25472₈
Example 13: Convert (11011010101101)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (11011010101101)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 011 011 010 101 101
By replacing each group with its corresponding octal equivalent:
- The octal of 011₂ is 3₈
- The octal of 011₂ is 3₈
- The octal of 010₂ is 2₈
- The octal of 101₂ is 5₈
- The octal of 101₂ is 5₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(11011010101101)₂ = 33255₈
Example 14: Convert (111001011010111)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (111001011010111)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 111 001 011 010 111
By replacing each group with its corresponding octal equivalent:
- The octal of 111₂ is 7₈
- The octal of 001₂ is 1₈
- The octal of 011₂ is 3₈
- The octal of 010₂ is 2₈
- The octal of 111₂ is 7₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(111001011010111)₂ = 71327₈
Example 15: Convert (1001011101010111)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1001011101010111)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 001 011 101 010 111
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 001₂ is 1₈
- The octal of 011₂ is 3₈
- The octal of 101₂ is 5₈
- The octal of 010₂ is 2₈
- The octal of 111₂ is 7₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1001011101010111)₂ = 113527₈
Example 16: Convert (1110101011100110)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1110101011100110)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 110 101 011 100 110
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 110₂ is 6₈
- The octal of 101₂ is 5₈
- The octal of 011₂ is 3₈
- The octal of 100₂ is 4₈
- The octal of 110₂ is 6₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1110101011100110)₂ = 165346₈
Example 17: Convert (101110010111001011)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (101110010111001011)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 101 110 010 111 001 011
By replacing each group with its corresponding octal equivalent:
- The octal of 101₂ is 5₈
- The octal of 110₂ is 6₈
- The octal of 010₂ is 2₈
- The octal of 111₂ is 7₈
- The octal of 001₂ is 1₈
- The octal of 011₂ is 3₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(101110010111001011)₂ = 562713₈
Example 18: Convert (110101011100101110)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (110101011100101110)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 110 101 011 100 101 110
By replacing each group with its corresponding octal equivalent:
- The octal of 110₂ is 6₈
- The octal of 101₂ is 5₈
- The octal of 011₂ is 3₈
- The octal of 100₂ is 4₈
- The octal of 101₂ is 5₈
- The octal of 110₂ is 6₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(110101011100101110)₂ = 653456₈
Example 19: Convert (1110011010101110011)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (1110011010101110011)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 001 110 011 010 101 110 011
By replacing each group with its corresponding octal equivalent:
- The octal of 001₂ is 1₈
- The octal of 110₂ is 6₈
- The octal of 011₂ is 3₈
- The octal of 010₂ is 2₈
- The octal of 101₂ is 5₈
- The octal of 110₂ is 6₈
- The octal of 011₂ is 3₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(1110011010101110011)₂ = 1632563₈
Example 20: Convert (101011110010111010010)₂ to Octal
Solution:
The following diagram shows the conversion of the binary number (101011110010111010010)₂ into its equivalent octal.
Description:
Group the binary digits into sets of three from right to left:
→ 101 011 110 010 111 010 010
By replacing each group with its corresponding octal equivalent:
- The octal of 101₂ is 5₈
- The octal of 011₂ is 3₈
- The octal of 110₂ is 6₈
- The octal of 010₂ is 2₈
- The octal of 111₂ is 7₈
- The octal of 010₂ is 2₈
- The octal of 010₂ is 2₈
By joining all the octal digits together to form the final octal number. So, the final result is:
(101011110010111010010)₂ = 5362722₈
2. Binary to Octal Conversion (Using Decimal Number System)
This method has two main Steps:
Step 1: Convert Binary to Decimal
- Write the given binary number
- Start from the rightmost digit
- Multiply each digit by powers of 2:
- Rightmost digit → × 2⁰
- Next digit → × 2¹
- Next → × 2² and so on
- Add all the results
- The sum is your decimal number
For Fractional Part (if present)
Digits after the decimal use negative powers of 2:
- First digit → × 2⁻¹
- Next digit → × 2⁻²
- Next → × 2⁻³
Step 2: Convert Decimal to Octal
- Take the decimal number
- Divide it by 8
- Write down the remainder
- Repeat division until the quotient becomes 0
- Write remainders in reverse order
This gives the octal result
Fractional Part (if present)
For decimal fractions, use the multiplication by 8 method to convert it into octal
- Take the fractional part
- Multiply it by 8
- Write down the integer part (0–7)
- Keep the fractional part only
- Repeat until Fraction becomes 0 or Required accuracy is reached
Write the collected digits in the same order
Example 01: Convert (101010.0011)₂ to Octal
Step 1: Convert Binary to Decimal
Integer Part (101010)₂ Conversion
(101010)₂ = 1 × 2⁵ + 0 × 2⁴ + 1 × 2³ + 0 × 2² + 1 × 2¹ + 0 × 2⁰
(101010)₂ = 32 + 0 + 8 + 0 + 2 + 0
(101010)₂ = (42)₁₀
Fractional Part (.0011)₂ Conversion
(0.0011)₂ = 0 × 2⁻¹ + 0 × 2⁻² + 1 × 2⁻³ + 1 × 2⁻⁴
(0.0011)₂ = 0 + 0 + 1/8 + 1/16
(0.0011)₂ = (0.1875)₁₀
Combine the integer and the fractional Part
(101010)₂ + (0.0011)₂ = (42)₁₀ + (0.1875)₁₀
(101010.0011)₂ = (42.1875)₁₀
Step 2: Convert Decimal to Octal
Integer Part (42)₁₀ Conversion
42 ÷ 8 = 5 remainder 2
5 ÷ 8 = 0 remainder 5
(42)₁₀ = (52)₈
Fractional Part (0.1875)₁₀ Conversion
0.1875 × 8 = 1.5 → 1
0.5 × 8 = 4.0 → 4
(0.1875)₁₀ = (.14)₈
Combine the integer and the fractional Part
(42.1875)₁₀ = (52.14)₈
Final Answer
Hence, the given binary (101010.0011)₂ is converted to octal (52.14)₈. So we can write
(101010.0011)₂ = (42.1875)₁₀ = (52.14)₈