Subtractor (Digital Electronics)

#Technical studies – Study 21

Introduction

In digital system subtractor is a combinational logic circuit that perform an arithmetic operation called subtraction. This operation is same as the 1’s complement method in binary number system. The rules of binary subtraction are:

 0 – 0 = 0, 0 – 1 = 1, 1 – 0 = 1, 1 – 1 = 0

 In subtraction the result is called difference. When the minuend is smaller than the subtrahend it borrows 1 from its left bit to subtract the subtrahend. That bit is called borrow bit.

A combinational logic circuit that subtracts one bit from another bit is called half subtractor.  

Similarly, a combinational logic circuit that performs the subtraction by considering the borrow bit from the higher column is called full subtractor.  

Half Subtractor:

Half subtractor is a digital logic circuit that takes 2 inputs performs the subtraction operation and provides two outputs called difference and borrow. Half subtractor is also called LSB subtractor, because it can perform the subtraction for LSB only.

Half subtractor block diagram
Truth table of half subtractor

According to the truth table

The difference d = A¯B+AB¯ = AB

And the borrow =A¯B

So the logic circuit is same as half adder with the complemented minuend.

Logic diagram of half subtractor

Half subtractor logic diagram using AOI (AND OR INVERTER) logic:

The logic circuit of half adder can be designed using AOI logic as below.

Half subtractor using AOI logic

Half subtractor using NAND logic:

The logic circuit of half subtractor can be designed using NAND logic as below.

The Boolean expression for half subtractor using NAND logic is –

d = AB 

   = A¯B+AB¯

   = A¯B+AA¯+AB¯+BB¯

   = A(A¯+B¯)+B(A¯+B¯)

   = A.AB¯+B.AB¯

   =A.AB¯¯¯+B.AB¯¯¯

   = A.AB¯¯.B.AB¯¯¯

And b = AB¯

            = B(A¯+B¯) = B.AB¯ = B.AB¯¯¯

So the logic circuit for half subtractor using NAND logic can be designed as below –

Half subtractor using NAND logic

Half subtractor using NOR logic:

The logic circuit of subtractor can be designed using NOR logic.

The Boolean expression for half subtractor using NOR logic is –

d = AB

    = A¯B+AB¯

    = A¯B+AA¯+AB¯+BB¯

    = A¯(A+B)+B¯(A+B)

    =A¯(A+B)¯¯ + B¯(A+B)¯¯

    = A¯¯+A+B¯¯ + B¯¯+A+B¯¯

    = A+A+B¯+B+A+B¯¯

And b = A¯B

            = A¯(A+B) = A¯(A+B)¯¯

            = A+(A+B)¯¯

So the logic circuit for half subtractor using NOR logic can be designed as below –

Half subtractor using NOR logic

Full subtractor:

Full subtractor is a digital logic circuit that takes three inputs performs the subtraction and provides two outputs called difference and borrow. Out of three bits two bits are the variables and third one is previous borrow.

Block diagram of full subtractor
Truth table of full subtractor

According to the truth table: –

d= A¯ B¯bi+A¯Bb¯i+AB¯ b¯i+ABbi

    = bi(AB+A¯ B¯) + b¯i(AB¯+A¯B)

    = bi(AB¯)+b¯i(AB)

    = ABbi

And

bout = A¯ B¯ bi+ A¯Bb¯i+ A¯Bbi + ABbi

        = bi(AB+A¯ B¯) + A¯B(bi+b¯i)

        = bi(AB¯)+A¯B

So the logic circuit can be designed as below:

Logic circuit of full subtractor

Full subtractor using AOI (AND OR INVERTER) logic:

 Using AOI logic the logic circuit for the full subtractor can be designed.

Logic diagram of full subtractor using AOI logic

Full subtractor using NAND logic:

Full subtractor logic circuit can be designed using NAND logic.

The Boolean expression for full subtractor using NAND logic is –

d = ABbi = (AB) bi

    = (AB)¯ bi+(AB) b¯i

    = (AB)¯ bi+(AB)(AB¯)+(AB)b¯i+bi b¯i

    = (AB)((AB¯)+bi¯)+bi((AB¯)+bi¯)  

    = (AB).(AB) bi¯ + bi(AB) bi¯

    = (AB).(AB) bi¯¯¯+bi.(AB) bi¯ ¯¯

    = (AB)(AB) bi¯¯.bi(AB) bi¯¯¯

And

  bout = A¯B+bi(AB)¯ 

          = A¯B+bi(AB)¯¯¯

          = A¯B¯.bi(AB)¯¯¯

          = B(A¯+B¯)¯.bi(bi¯+(AB)¯)¯¯

          = B.AB¯¯.bi(bi.(AB))¯¯¯

 

Therefore the logic circuit for full subtractor using NAND logic can be designed as below – 

 

Logic circuit for full subtractor using NAND logic

Full subtractor using NOR logic:

Full subtractor logic circuit can be designed using NOR logic.

The Boolean expression for full subtractor using NOR logic is –

d= ABbi

   = (AB)bi=(AB)bi¯¯

   = (AB) bi+(AB)¯ b¯i¯

   = (AB)+(AB¯) bi¯ . bi+(AB¯) bi¯¯

    = (AB)+(AB)+bi¯¯+bi+(AB)+bi¯¯

    = (AB)+(AB)+bi¯¯+bi+(AB)+bi¯¯¯¯

And 

bout = A¯B+bi(AB¯)

       = A¯(A+B) + (AB¯)((AB)+bi)

       = A¯(A+B)¯¯ + (AB)¯(AB)+bi¯¯

       = A+(A+B¯)¯ + (AB)+(AB)+bi¯¯

       =  A+(A+B¯)¯ + (AB)+(AB)+bi¯¯¯¯

Therefore the logic circuit for full subtractor using NOR logic can be designed as below –

Logic circuit of full subtractor using NOR logic

Please write in the comment box below if you have any questions.

Leave a Reply

Your email address will not be published. Required fields are marked *