Binary Addition using 2'S Complement

Binary Addition using 2’S Complement – Definition, Examples | How to do 2’S Complement Binary Addition?

A binary number is a number expressed in the base 2 numeral system which uses only two symbols 0 and 1. Each digit in the binary is called a bit or binary digit. The addition is one of the basic arithmetic operations. Binary addition is one of the binary operations. The binary addition works similarly to the base 10 decimal system. Check out more about the binary addition using 2s complement with solved example questions in the following sections of this page.

Also, Read

Binary Addition

The binary addition is similar to the decimal system, but it is a base 2 system. The binary system has two digits 0 and 1. Almost all functionalities of the computer system use the binary number system. The process of the addition operation is very familiar to the decimal system by just adjusting the base 2 of the numbers.

Before attempting the binary addition process, we should have complete knowledge of how the place works in the binary number system. Most modern digital computers and electric circuits perform binary operations by representing each bit as a voltage signal. the bit 0 in the binary system denotes the “OFF” state, bit 1 in the binary system denotes the “ON” state.

2’s Complement of a Binary Number

To get the 2’s complement of a given binary number, invert the given number and add 1 to the least significant bit (LSB) of the given result. The various uses of 2’s complement of binary numbers are signed binary number representation, to perform arithmetic operations on binary numbers.

Example:

2’s complement of 101

Invert 101 = 010

Add 1 to LSB of 010 = 010 + 1

= 011

So, 2’s complement of 101 is 011.

Binary Addition using 2’s Complement

Binary Addition using 2’s Complement is similar to the normal addition of two binary numbers. When you add two positive numbers, then the result is a positive number. When you add two negative numbers, then the addition will be a negative number. The basic rules of binary addition is 1 + 1 = 10 (1 is carry), 0 + 0 = 0, 0 + 1 = 1, 1 + 0 = 1. If two numbers have different signs then follow these cases.

Case I: When the positive number has a greater magnitude.

In this case, the carry obtained is discarded and the final result is the addition of two numbers

Let us take the 5-bit numbers 1011 and -0101

2’s complement of 0101 = 1011

1 0 1 1 ⇒ 0 1 0 1 1

– 0 1 0 1 ⇒ 1 1 0 1 1 (2’s Complement)

⇒ 0 0 1 1 0 (Carry 1 is discarded)

So, 1011 – 0101 = 00110

Case II: When the negative number has a greater magnitude.

If the negative number has a greater magnitude then no carry will be generated in the sign bit. The result of an addition will be negative and the final result obtained by taking 2’s complement of the magnitude bits of the result.

Let us take two numbers as + 0100 and -0111

+ 0 1 0 0 ⇒ 0 0 1 0 0

– 0 1 1 1 ⇒ 1 1 0 0 1 (2’s complement)

⇒ 1 1 1 0 1

2’s complement of 1101 is 0011.

Hence the required sum is – 0011.

Case III: When the numbers are negative.

When two negative numbers are added a carry will be generated from the sign bit which will be discarded. 2’s complement of the magnitude bits of the operation will be the final sum.

Let us take two numbers as -0111 and -0010

– 0 1 1 1 ⇒ 1 1 0 0 1 (2’s complement)

– 0 0 1 0 ⇒ 1 1 1 1 0 (2’s complement)

⇒ 1 0 1 1 1 (Carry 1 discarded)

2’s complement of 0111 is 1001

Hence the required sum is -1001.

Solved Examples on Binary Addition using 2’s Complement

Example 1:

Find the sum of -1101 and -1110 using the 2’s complement.

Solution:

Given numbers are -1101, -1110

Find the 2’s complement of the negative numbers

So, 2’s complement of 01110 is 10010 and 01101 is 10011

Add the complemet numbers

1 0 0 1 0 + 1 0 0 1 = 1 0 0 1 0 1

End carry 1 of the sum is dicarded

2’s complement of the result 00101 is 11011

So, sum of -1101, -1110 is -11011.

Example 2:

Find 10101 – 10111 using the 2’s complement concept.

Solution:

The given numbers are 10101, -10111

2’s complement of the negative number 10111 is 01001

Add first number and 2’s complement of negative number

1 0 1 0 1 + 0 1 0 0 1 = 1 1 1 1 0

2’s complement of the result 11110 is 00010.

So, 10101 – 10111 = -00010

Example 3:

Find the addition of 00110 and 01001 using the 2’s complement.

Solution:

Given numbers are 00110, 01001

0 0 1 1 0 + 0 1 0 0 1 = 0 1 1 1 1

Hence, the sum is 0 1 1 1 1.

FAQs on Binary Addition using 2’s Complement

1. What are the Rules of Binary Addition?

The four basic rules of the binary addition are 0 + 0 = 0, 0 + 1 = 1, 1 + 0 = 1, 1 + 1 = 10.

2. How to add two binary numbers?

Add the first column if two numbers are 1 then the result is 10. Here, 1 is the carry. Continue adding till no digit is left on the left side. The result is the sum of two binary numbers.

3. How to find 2’s complement of a binary number?

Invert the given numbers and add one to the least significant bit to get the 2’s complement of the binary number.

Leave a Comment

Scroll to Top
Scroll to Top