- Digital Electronics Tutorial
- Digital Electronics - Home
- Digital Electronics Basics
- Types of Digital Systems
- Types of Signals
- Logic Levels And Pulse Waveforms
- Digital System Components
- Digital Logic Operations
- Digital Systems Advantages
- Number Systems
- Number Systems
- Base Conversions
- Binary Numbers Representation
- Binary Arithmetic
- Signed Binary Arithmetic
- Octal Arithmetic
- Hexadecimal Arithmetic
- Complement Arithmetic
- Binary Codes
- Binary Codes
- 8421 BCD Code
- Excess-3 Code
- Gray Code
- ASCII Codes
- EBCDIC Code
- Code Conversion
- Error Detection & Correction Codes
- Logic Gates
- Logic Gates
- AND Gate
- OR Gate
- NOT Gate
- Universal Gates
- XOR Gate
- XNOR Gate
- CMOS Logic Gate
- Two Level Logic Realization
- Threshold Logic
- Boolean Algebra
- Boolean Algebra
- Laws of Boolean Algebra
- Boolean Functions
- DeMorgan's Theorem
- SOP and POS Form
- Minimization Techniques
- K-Map Minimization
- Three Variable K-Map
- Four Variable K-Map
- Five Variable K-Map
- Six Variable K-Map
- Don't Care Condition
- Quine-McCluskey Method
- Min Terms and Max Terms
- Canonical and Standard Form
- Max Term Representation
- Simplification using Boolean Algebra
- Combinational Logic Circuits
- Digital Combinational Circuits
- Digital Arithmetic Circuits
- Multiplexers
- Parity Bit Generator and Checker
- Comparators
- Encoders
- Keyboard Encoders
- Priority Encoders
- Decoders
- Demultiplexers
- Arithmetic Logic Unit
- 7-Segment LED Display
- Code Converters
- Code Converters
- Binary to Decimal Converter
- Decimal to BCD Converter
- BCD to Decimal Converter
- Binary to Gray Code Converter
- Gray Code to Binary Converter
- BCD to Excess-3 Converter
- Excess-3 to BCD Converter
- Adders
- Half Adders
- Full Adders
- Serial Adders
- Parallel Adders
- Full Adder using Half Adder
- Half Adder vs Full Adder
- Binary Adder-Subtractor
- Subtractors
- Half Subtractors
- Full Subtractors
- Parallel Subtractors
- Full Subtractor using 2 Half Subtractors
- Half Subtractor using NAND Gates
- Sequential Logic Circuits
- Digital Sequential Circuits
- Clock Signal and Triggering
- Latches
- Flip-Flops
- Conversion of Flip-Flops
- Shift Registers
- Shift Register Applications
- Counters
- Finite State Machines
- Algorithmic State Machines
- A/D and D/A Converters
- Analog-to-Digital Converter
- Digital-to-Analog Converter
- DAC and ADC ICs
- Realization of Logic Gates
- NOT Gate from NAND Gate
- OR Gate from NAND Gate
- AND Gate from NAND Gate
- NOR Gate from NAND Gate
- XOR Gate from NAND Gate
- XNOR Gate from NAND Gate
- NOT Gate from NOR Gate
- OR Gate from NOR Gate
- AND Gate from NOR Gate
- NAND Gate from NOR Gate
- XOR Gate from NOR Gate
- XNOR Gate from NOR Gate
- NAND/NOR Gate using CMOS
- Memory Devices
- Memory Devices
- RAM and ROM
- Cache Memory Design
- Programmable Logic Devices
- Programmable Logic Devices
- Programmable Logic Array
- Programmable Array Logic
- Field Programmable Gate Arrays
- Digital Electronics Families
- Digital Electronics Families
- CPU Architecture
- CPU Architecture
Digital Electronics - Octal Arithmetic
What is Octal Arithmetic?
In digital electronics, octal numbers are widely used in system designing, encoding, decoding, etc. Octal arithmetic can be defined as the mathematics that provides a set of rules and operators to manipulate octal numbers. In other words, a mathematical system of numerical calculations that utilizes octal numbers is referred to as octal arithmetic.
In octal arithmetic, we can perform the following four basic arithmetic operations −
- Octal Addition
- Octal Subtraction
- Octal Multiplication
- Octal Division
In digital electronic systems, octal numbers are used to represent binary information and data in a more compact form, as an octal digit can represent a group three binary digits or bits. Therefore, the understanding of octal arithmetic is important in the study of digital electronics.
Let us discuss each of the four octal arithmetic operations one-by-one in detail with the help of examples.
Octal Addition
In octal arithmetic, octal addition is one of the basic arithmetic operations used to add two or more octal numbers to produce their sum. Octal addition is similar to decimal addition. But, in the case of octal addition, a carry is generated to pass over to the next column when the sum is equal to or greater than 8.
Let us see some solved examples to understand the process of octal addition.
Example 1
Add (315)8 and (222)8.
Solution
The addition of octal numbers 315 and 222 is given below −
Explanation
Add the octal digits in the rightmost column: 5 + 2 = 7. Write down the digit 7 as result.
Move to the second column and add the octal digits 1 and 2: 1 + 2 = 3. Write down the digit 3 as result.
Move to the next column and add the octal digits in the third column: 3 + 2 = 5. Write down the digit 5 as result.
Hence, the final result of octal addition of 315 and 222 is 537.
Example 2
Perform the octal addition (372)8 + (716)8.
Solution
The addition of given octal numbers is explained below −
Explanation
Add the octal digits in rightmost column: 2 + 6 = (10)8. Thus, write down the last digit (0) as the result and carry over the 1 to the next column.
Move to the second column and add the octal digits including the carry-over from the previous step: 7 + 1 + 1 = (11)8. Write the last digit (1) as the result and carry over left 1 to the next column.
Move to the third column and add the octal digits along with the carry from the previous step: 3 + 7 + 1 = 13. No digits left to add. Thus, write down the result.
Hence, the final result of the octal addition is 1310.
Octal Subtraction
Octal subtraction is another basic arithmetic operation performed on octal numbers. It is used to find the difference between two octal numbers.
Let an octal subtraction as (x)8 - (y)8, if the digit x is smaller than the digit y, a borrow 1 from the next higher order position is taken to perform the octal subtraction.
Let us see some solved examples to understand the octal subtraction.
Example 1
Subtract (213)8 from (325)8.
Solution
The given octal subtraction is performed below −
Explanation
Start subtracting from the digits in the rightmost column: 5 – 3 = 2. Write down the digit 2 as result.
Move to the next column and subtract the digits: 2 – 1 = 1. Write down the digit as result.
Move to the next column and subtract the octal digits: 3 – 2 = 1. Write down the digit 1 as result.
Thus, the final result of the given octal subtraction is (112)8.
Example 2
Subtract (125)8 from (317)8.
Solution
The octal subtraction of numbers 3178 and 1258 is explained below −
Explanation
Subtract rightmost digits: 7 – 5 = 2. Write down the digit 2 as result.
Move to the second column and subtract digits: 1 – 2. Since 1 is less than 2, a borrow 1 from the next higher digit is taken that makes it 11. Thus, the octal subtraction is 11 – 2 = 7. Write down the octal digit 7 as result.
Move to the leftmost column and subtract the digits: 2 – 1 = 1. Write down the digit 1 as result.
Thus, the final result of the subtraction is (172)8.
Octal Multiplication
Octal multiplication is the third basic arithmetic operation performed on octal numbers. It is used find the product of two octal numbers.
The octal multiplication is performed by multiplying each digit of one octal number by each digit of another octal number. The final result is obtained by summing up all the partial products of the multiplication.
The following numerical examples demonstrate the method of performing octal multiplication.
Example 1
Multiply (375)8 by (5)8.
Solution
The multiplication of given octal numbers is explained below −
Explanation
Multiply the octal digit 5 by each digit of the octal number 375. Write down the results of multiplication to get the final product that is (2361)8.
Example 2
Perform the octal multiplication of (624)8 and (25)8.
Solution
The multiplication of given octal numbers is explained below −
Explanation
Multiply the rightmost digit (5)8 of the second octal number 25 by each digit of the first octal number 624 and write down the partial products.
Move to the next digit (2)8 of the octal number 25 and multiply it by each digit of the octal number 624. Shift one position to the left and write down the partial product.
Add all the partial products to obtain the final result, that is (20444)8.
Octal Division
Octal division is one of the basic arithmetic operations that can be performed on octal numbers to find their quotient and remainder.
The step-by-step procedure of octal division is described below −
Step 1 − Start by dividing the leftmost digits of the dividend by the divisor.
Step 2 − Multiply the quotient obtained by the divisor and subtract the product from the dividend.
Step 3 − Bring down the next octal digits of the dividend and repeat the above two steps until all the digits in the dividend are used.
Let us understand the division of octal numbers through some solved examples.
Example 1
Divide (1275)8 by (3)8.
Solution
The octal division of given numbers is shown below −
In this example, the division of octal number (1275)8 by (3)8 gives (351)8 as quotient and (2)8 as remainder.
Let us take another example for a better understanding of octal division.
Example 2
Perform octal division of (1365)8 by (5)8.
Solution
The octal division of given numbers is described below −
In this example of octal division, the quotient is (227)8 and the remainder is (2)8.
We can also perform octal arithmetic operations by converting them to binary form. As we know, an octal digit can be represented by a group of 3 binary digits or bits.
The binary representation of each octal digit is given in the following table −
Octal Digit | 3-Bit Binary |
---|---|
0 | 000 |
1 | 001 |
2 | 010 |
3 | 011 |
4 | 100 |
5 | 101 |
6 | 110 |
7 | 111 |
Let us see some examples to learn the octal arithmetic operations through binary conversion.
Octal Addition through Binary Conversion
The addition of two octal numbers through binary conversion can be performed as per the following steps −
Step 1 − Convert the given octal number to their binary equivalent.
Step 2 − Add the obtained binary numbers.
Step 3 − Convert final result back to the octal format.
Example
Add (75)8 and (14)8 through binary conversion.
Solution
Converting the given octal numbers to their binary equivalents.
(75)8 = (111 101)2
(14)8 = (001 100)2
Adding the octal numbers in their binary format,
Converting the sum from binary to octal to obtain the final result,
(001 001 001)2 = (111)8
Octal Subtraction through Binary Conversion
To perform octal subtraction of two numbers through binary conversion, we first convert them to their binary equivalent, then perform subtraction according to the rules of binary subtraction, and finally convert the final result back to the octal number system.
Here is an example that demonstrates how you can perform octal subtraction through binary conversion.
Example
Subtract (16))8 from (47)8 by converting in the binary equivalent.
Solution
Converting the given octal numbers to their equivalent binary,
(47)8 = (100 111)2
(16)8 = (001 110)2
Subtracting the numbers using the rules of binary subtraction,
Converting the result back to the octal number system,
(011 001)2 = (31)8
Octal Multiplication Through Binary Conversion
Just like addition and subtraction, we can also perform the multiplication of octal numbers by converting them into their equivalent binary. The following example demonstrates how you can perform octal multiplication through binary conversion.
Example
Multiply (417)8 by (3)8 in binary form.
Solution
Converting the given octal numbers to binary,
(417)8 = (100 001 111)2
(3)8 = (011)2
Multiplying the obtained binary numbers,
Converting the result back to the octal format,
(1 100 101 101)2 = (1455)8
Octal Division through Binary Conversion
To perform octal division through binary conversion, we first convert the given octal number to their equivalent binary, then perform their division as per the rules of binary division, and finally convert the result back to the octal form.
The following example explains how you can perform octal division through binary conversion.
Example
Divide (547)8 by (5)8 using binary conversion method.
Solution
Converting the given octal numbers to their binary equivalents,
(547)8 = (101 100 111)2
(5)8 = (101)2
Performing binary division as per the rules of binary division arithmetic,
Converting the binary result back to the octal format,
Quotient = (1 000 111)2 = (107)8
Remainder = (100)2 = (4)8
Conclusion
In this chapter, we explained various arithmetic operations such as addition, subtraction, multiplication and division of octal numbers.
We also covered the binary method of octal arithmetic operations in which we first convert the given octal numbers to their binary equivalent, and then perform the arithmetic operations, and finally convert the binary result back to the octal format.