Machine-translated by Google. Questions are authored in English.
Top

Discussion

The following digital circuit acts as a :

Inputs A and B each also pass through an inverter; one AND gate takes A and the inverse of B, a second AND gate takes the inverse of A and B, and an OR gate combines these two to give Xout; a third AND gate takes the inverse of A and B to give Yout

  • A.Half-Subtractor
  • B.Half-Adder
  • C.Half-Adder/Subtractor
  • D.2's complement Adder/ Subtractor

Answer: A

The circuit is a half-subtractor.

Reading the gates:

\[ \begin{aligned} X_{out} &= A\bar{B} + \bar{A}B = A \oplus B \\ Y_{out} &= \bar{A}B \end{aligned} \]

For the subtraction A - B of two bits, the difference is \(A \oplus B\) and a borrow is needed only when A = 0 and B = 1, which is \(\bar{A}B\). So \(X_{out}\) is the difference and \(Y_{out}\) the borrow.

A half-adder has the same XOR output but its second output, the carry, is AB, not \(\bar{A}B\). Nothing in the circuit switches between adding and subtracting, so it is neither a half-adder/subtractor nor a 2's complement adder/subtractor.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.