can someone help me with the following problems :(
Problem 1
Design a digital circuit that determines the amount of 1’s and 0’s in an 8-bit binary number and check whether both quantities are odd or even.
Problem 2
Create a medium subtractor circuit, which allows subtracting the x-y bits which generate the difference in the output and the loan in the output p.
ANSWER OF 1;
Write down the truth table. The output is a 1 if the combination of inputs is odd, otherwise 0.
Now at this point you could do a formal analysis and develop a minimised logic equation, but from the examination of the truth table, you can immediately observe the following:
The XOR gate can be thought of as a controlled inverter - if one of its inputs is 0, the output follows the other input, if it’s 1, the output is the inverse of the input. So to implement this we just need two XOR gates:

ANSWER 2;
As their name implies, a Binary Subtractor is a decision making circuit that subtracts two binary numbers from each other, for example, X – Y to find the resulting difference between the two numbers.
Unlike the Binary Adder which produces a SUM and a CARRY bit when two binary numbers are added together, the binary subtractor produces a DIFFERENCE, D by using a BORROW bit, B from the previous column. Then obviously, the operation of subtraction is the opposite to that of addition.
We learnt from our maths lessons at school that the minus sign, “–” is used for a subtraction calculation, and when one number is subtracted from another, a borrow is required if the subtrahend is greater than the minuend. Consider the simple subtraction of the two denary (base 10) numbers below.
| 123 | X | (Minuend) |
| – 78 | Y | (Subtrahend) |
| 45 | DIFFERENCE |
We can not directly subtract 8 from 3 in the first column as 8 is greater than 3, so we have to borrow a 10, the base number, from the next column and add it to the minuend to produce 13 minus 8. This “borrowed” 10 is then return back to the subtrahend of the next column once the difference is found. Simple school math’s, borrow a 10 if needed, find the difference and return the borrow.
The subtraction of one binary number from another is exactly the same idea as that for subtracting two decimal numbers but as the binary number system is a Base-2 numbering system which uses “0” and “1” as its two independent digits, large binary numbers which are to be subtracted from each other are therefore represented in terms of “0’s” and “1’s”.
Binary Subtraction
Binary Subtraction can take many forms but the rules for subtraction are the same whichever process you use. As binary notation only has two digits, subtracting a “0” from a “0” or a “1” leaves the result unchanged as 0-0 = 0 and 1-0 = 1. Subtracting a “1” from a “1” results in a “0”, but subtracting a “1” from a “0” requires a borrow. In other words 0 – 1 requires a borrow.
Binary Subtraction of Two Bits
| 0 | 1 | 1 | (borrow)1→ 0 |
| – 0 | – 0 | – 1 | – 1 |
| 0 | 1 | 0 | 1 |
For the simple 1-bit subtraction problem above, if the borrow bit is ignored the result of their binary subtraction resembles that of an Exclusive-OR Gate. To prevent any confusion in this tutorial between a binary subtractor input labelled, B and the resulting borrow bit output from the binary subtractor also being labelled, B, we will label the two input bits as X for the minuend and Y for the subtrahend. Then the resulting truth table is the difference between the two input bits of a single binary subtractor is given as:
2-input Exclusive-OR Gate
| Symbol | Truth Table | ||
2-input Ex-OR Gate |
Y | X | Q |
| 0 | 0 | 0 | |
| 0 | 1 | 1 | |
| 1 | 0 | 1 | |
| 1 | 1 | 0 | |
As with the Binary Adder, the difference between the two digits is only a “1” when these two inputs are not equal as given by the Ex-OR expression. However, we need an additional output to produce the borrow bit when input X = 0 and Y = 1. Unfortunately there are no standard logic gates that will produce an output for this particular combination of X and Y inputs.
But we know that an AND Gate produces an output “1” when both of its inputs X and Y are “1” (HIGH) so if we use an inverter or NOT Gate to complement the input X before it is fed to the AND gate, we can produce the required borrow output when X = 0 and Y = 1 as shown below.

Then by combining the Exclusive-OR gate with the NOT-AND combination results in a simple digital binary subtractor circuit known commonly as the Half Subtractor as shown.
A Half Subtractor Circuit
A half subtractor is a logical circuit that performs a subtraction operation on two binary digits. The half subtractor produces a sum and a borrow bit for the next stage.
Half Subtractor with Borrow-out

| Symbol | Truth Table | |||
![]() |
Y | X | DIFFERENCE | BORROW |
| 0 | 0 | 0 | 0 | |
| 0 | 1 | 1 | 0 | |
| 1 | 0 | 1 | 1 | |
| 1 | 1 | 0 | 0 | |
From the truth table of the half subtractor we can see that the DIFFERENCE (D) output is the result of the Exclusive-OR gate and the Borrow-out (Bout) is the result of the NOT-AND combination. Then the Boolean expression for a half subtractor is as follows.
For the DIFFERENCE bit:
D = X XOR Y = X ⊕ Y
For the BORROW bit
B = not-X AND Y = X.Y
If we compare the Boolean expressions of the half subtractor with a half adder, we can see that the two expressions for the SUM (adder) and DIFFERENCE (subtractor) are exactly the same and so they should be because of the Exclusive-OR gate function. The two Boolean expressions for the binary subtractor BORROW is also very similar to that for the adders CARRY. Then all that is needed to convert a half adder to a half subtractor is the inversion of the minuend input X.
One major disadvantage of the Half Subtractor circuit when used as a binary subtractor, is that there is no provision for a “Borrow-in” from the previous circuit when subtracting multiple data bits from each other. Then we need to produce what is called a “full binary subtractor” circuit to take into account this borrow-in input from a previous circuit.
ANSWER OF 1;
Write down the truth table. The output is a 1 if the combination of inputs is odd, otherwise 0.
Now at this point you could do a formal analysis and develop a minimised logic equation, but from the examination of the truth table, you can immediately observe the following:
The XOR gate can be thought of as a controlled inverter - if one of its inputs is 0, the output follows the other input, if it’s 1, the output is the inverse of the input. So to implement this we just need two XOR gates:

ANSWER 2;
As their name implies, a Binary Subtractor is a decision making circuit that subtracts two binary numbers from each other, for example, X – Y to find the resulting difference between the two numbers.
Unlike the Binary Adder which produces a SUM and a CARRY bit when two binary numbers are added together, the binary subtractor produces a DIFFERENCE, D by using a BORROW bit, B from the previous column. Then obviously, the operation of subtraction is the opposite to that of addition.
We learnt from our maths lessons at school that the minus sign, “–” is used for a subtraction calculation, and when one number is subtracted from another, a borrow is required if the subtrahend is greater than the minuend. Consider the simple subtraction of the two denary (base 10) numbers below.
| 123 | X | (Minuend) |
| – 78 | Y | (Subtrahend) |
| 45 | DIFFERENCE |
We can not directly subtract 8 from 3 in the first column as 8 is greater than 3, so we have to borrow a 10, the base number, from the next column and add it to the minuend to produce 13 minus 8. This “borrowed” 10 is then return back to the subtrahend of the next column once the difference is found. Simple school math’s, borrow a 10 if needed, find the difference and return the borrow.
The subtraction of one binary number from another is exactly the same idea as that for subtracting two decimal numbers but as the binary number system is a Base-2 numbering system which uses “0” and “1” as its two independent digits, large binary numbers which are to be subtracted from each other are therefore represented in terms of “0’s” and “1’s”.
Binary Subtraction
Binary Subtraction can take many forms but the rules for subtraction are the same whichever process you use. As binary notation only has two digits, subtracting a “0” from a “0” or a “1” leaves the result unchanged as 0-0 = 0 and 1-0 = 1. Subtracting a “1” from a “1” results in a “0”, but subtracting a “1” from a “0” requires a borrow. In other words 0 – 1 requires a borrow.
Binary Subtraction of Two Bits
| 0 | 1 | 1 | (borrow)1→ 0 |
| – 0 | – 0 | – 1 | – 1 |
| 0 | 1 | 0 | 1 |
For the simple 1-bit subtraction problem above, if the borrow bit is ignored the result of their binary subtraction resembles that of an Exclusive-OR Gate. To prevent any confusion in this tutorial between a binary subtractor input labelled, B and the resulting borrow bit output from the binary subtractor also being labelled, B, we will label the two input bits as X for the minuend and Y for the subtrahend. Then the resulting truth table is the difference between the two input bits of a single binary subtractor is given as:
2-input Exclusive-OR Gate
| Symbol | Truth Table | ||
2-input Ex-OR Gate |
Y | X | Q |
| 0 | 0 | 0 | |
| 0 | 1 | 1 | |
| 1 | 0 | 1 | |
| 1 | 1 | 0 | |
As with the Binary Adder, the difference between the two digits is only a “1” when these two inputs are not equal as given by the Ex-OR expression. However, we need an additional output to produce the borrow bit when input X = 0 and Y = 1. Unfortunately there are no standard logic gates that will produce an output for this particular combination of X and Y inputs.
But we know that an AND Gate produces an output “1” when both of its inputs X and Y are “1” (HIGH) so if we use an inverter or NOT Gate to complement the input X before it is fed to the AND gate, we can produce the required borrow output when X = 0 and Y = 1 as shown below.

Then by combining the Exclusive-OR gate with the NOT-AND combination results in a simple digital binary subtractor circuit known commonly as the Half Subtractor as shown.
A Half Subtractor Circuit
A half subtractor is a logical circuit that performs a subtraction operation on two binary digits. The half subtractor produces a sum and a borrow bit for the next stage.
Half Subtractor with Borrow-out

| Symbol | Truth Table | |||
![]() |
Y | X | DIFFERENCE | BORROW |
| 0 | 0 | 0 | 0 | |
| 0 | 1 | 1 | 0 | |
| 1 | 0 | 1 | 1 | |
| 1 | 1 | 0 | 0 | |
From the truth table of the half subtractor we can see that the DIFFERENCE (D) output is the result of the Exclusive-OR gate and the Borrow-out (Bout) is the result of the NOT-AND combination. Then the Boolean expression for a half subtractor is as follows.
For the DIFFERENCE bit:
D = X XOR Y = X ⊕ Y
For the BORROW bit
B = not-X AND Y = X.Y
If we compare the Boolean expressions of the half subtractor with a half adder, we can see that the two expressions for the SUM (adder) and DIFFERENCE (subtractor) are exactly the same and so they should be because of the Exclusive-OR gate function. The two Boolean expressions for the binary subtractor BORROW is also very similar to that for the adders CARRY. Then all that is needed to convert a half adder to a half subtractor is the inversion of the minuend input X.
One major disadvantage of the Half Subtractor circuit when used as a binary subtractor, is that there is no provision for a “Borrow-in” from the previous circuit when subtracting multiple data bits from each other. Then we need to produce what is called a “full binary subtractor” circuit to take into account this borrow-in input from a previous circuit.
ANSWER OF 1;
Write down the truth table. The output is a 1 if the combination of inputs is odd, otherwise 0.
Now at this point you could do a formal analysis and develop a minimised logic equation, but from the examination of the truth table, you can immediately observe the following:
The XOR gate can be thought of as a controlled inverter - if one of its inputs is 0, the output follows the other input, if it’s 1, the output is the inverse of the input. So to implement this we just need two XOR gates:

ANSWER 2;
As their name implies, a Binary Subtractor is a decision making circuit that subtracts two binary numbers from each other, for example, X – Y to find the resulting difference between the two numbers.
Unlike the Binary Adder which produces a SUM and a CARRY bit when two binary numbers are added together, the binary subtractor produces a DIFFERENCE, D by using a BORROW bit, B from the previous column. Then obviously, the operation of subtraction is the opposite to that of addition.
We learnt from our maths lessons at school that the minus sign, “–” is used for a subtraction calculation, and when one number is subtracted from another, a borrow is required if the subtrahend is greater than the minuend. Consider the simple subtraction of the two denary (base 10) numbers below.
| 123 | X | (Minuend) |
| – 78 | Y | (Subtrahend) |
| 45 | DIFFERENCE |
We can not directly subtract 8 from 3 in the first column as 8 is greater than 3, so we have to borrow a 10, the base number, from the next column and add it to the minuend to produce 13 minus 8. This “borrowed” 10 is then return back to the subtrahend of the next column once the difference is found. Simple school math’s, borrow a 10 if needed, find the difference and return the borrow.
The subtraction of one binary number from another is exactly the same idea as that for subtracting two decimal numbers but as the binary number system is a Base-2 numbering system which uses “0” and “1” as its two independent digits, large binary numbers which are to be subtracted from each other are therefore represented in terms of “0’s” and “1’s”.
Binary Subtraction
Binary Subtraction can take many forms but the rules for subtraction are the same whichever process you use. As binary notation only has two digits, subtracting a “0” from a “0” or a “1” leaves the result unchanged as 0-0 = 0 and 1-0 = 1. Subtracting a “1” from a “1” results in a “0”, but subtracting a “1” from a “0” requires a borrow. In other words 0 – 1 requires a borrow.
Binary Subtraction of Two Bits
| 0 | 1 | 1 | (borrow)1→ 0 |
| – 0 | – 0 | – 1 | – 1 |
| 0 | 1 | 0 | 1 |
For the simple 1-bit subtraction problem above, if the borrow bit is ignored the result of their binary subtraction resembles that of an Exclusive-OR Gate. To prevent any confusion in this tutorial between a binary subtractor input labelled, B and the resulting borrow bit output from the binary subtractor also being labelled, B, we will label the two input bits as X for the minuend and Y for the subtrahend. Then the resulting truth table is the difference between the two input bits of a single binary subtractor is given as:
2-input Exclusive-OR Gate
| Symbol | Truth Table | ||
2-input Ex-OR Gate |
Y | X | Q |
| 0 | 0 | 0 | |
| 0 | 1 | 1 | |
| 1 | 0 | 1 | |
| 1 | 1 | 0 | |
As with the Binary Adder, the difference between the two digits is only a “1” when these two inputs are not equal as given by the Ex-OR expression. However, we need an additional output to produce the borrow bit when input X = 0 and Y = 1. Unfortunately there are no standard logic gates that will produce an output for this particular combination of X and Y inputs.
But we know that an AND Gate produces an output “1” when both of its inputs X and Y are “1” (HIGH) so if we use an inverter or NOT Gate to complement the input X before it is fed to the AND gate, we can produce the required borrow output when X = 0 and Y = 1 as shown below.

Then by combining the Exclusive-OR gate with the NOT-AND combination results in a simple digital binary subtractor circuit known commonly as the Half Subtractor as shown.
A Half Subtractor Circuit
A half subtractor is a logical circuit that performs a subtraction operation on two binary digits. The half subtractor produces a sum and a borrow bit for the next stage.
Half Subtractor with Borrow-out

| Symbol | Truth Table | |||
![]() |
Y | X | DIFFERENCE | BORROW |
| 0 | 0 | 0 | 0 | |
| 0 | 1 | 1 | 0 | |
| 1 | 0 | 1 | 1 | |
| 1 | 1 | 0 | 0 | |
From the truth table of the half subtractor we can see that the DIFFERENCE (D) output is the result of the Exclusive-OR gate and the Borrow-out (Bout) is the result of the NOT-AND combination. Then the Boolean expression for a half subtractor is as follows.
For the DIFFERENCE bit:
D = X XOR Y = X ⊕ Y
For the BORROW bit
B = not-X AND Y = X.Y
If we compare the Boolean expressions of the half subtractor with a half adder, we can see that the two expressions for the SUM (adder) and DIFFERENCE (subtractor) are exactly the same and so they should be because of the Exclusive-OR gate function. The two Boolean expressions for the binary subtractor BORROW is also very similar to that for the adders CARRY. Then all that is needed to convert a half adder to a half subtractor is the inversion of the minuend input X.
One major disadvantage of the Half Subtractor circuit when used as a binary subtractor, is that there is no provision for a “Borrow-in” from the previous circuit when subtracting multiple data bits from each other. Then we need to produce what is called a “full binary subtractor” circuit to take into account this borrow-in input from a previous circuit.
can someone help me with the following problems :( Problem 1 Design a digital circuit that...
Help with the next problem Design a digital circuit that determines the amount of 1's and 0's in an 8-bit binary number and checks whether both quantities are even or odd.
help me with this problem please :( Design a digital circuit that having an 8-bit binary number at its input, shows the quantity of 1's and 0's it contains and the difference between both quantities. The output must be represented by 3 display’s: ○ Quantity of 1’s ○ Quantity of 0’s ○ Difference 1’s - 0’s The procedure for the design of digital circuits must be carried out, including the digital diagram, using a block view.
help me with this problem please :( Design a digital circuit that having an 8-bit binary number at its input, shows the quantity of 1's and 0's it contains and the difference between both quantities. The output must be represented by 3 display’s: ○ Quantity of 1’s ○ Quantity of 0’s ○ Difference 1’s - 0’s
can someone help me with the following :( implement a digital circuit that allows you to obtain the comparison results for a pair of four-bit numbers, when they are equal, one greater than the other and vice versa
Design a digital circuit that takes two 4-bit numbers A and B as input and generates output Z as follows: (20 points) - If A and B are odd numbers then Z-A-B. - If A and B are even numbers then Z-B-A 5. If A is an even number and B is an odd number then Z-A+B If A is an odd number and B is an even number then Z-A-B-1 Assume that you have access to as many as...
Can someone help me design a gate level circuit and model using HDL? It needs to convert 3-bit gray code to a binary number representation 2) adds the gray code input to its binary representation3) includes a flag(output)to determine when an overflow occurs. For example 111 in gray code is 5 in base 10, the binary representation for 5 is 101, the sum is 1100, an overflow has occurred and the overflow bit is set to 1. You will show...
Design a circuit that will subtract 1 from a 4-bit binary number (A3A2A1A0) if the number is odd, and do no change if the number is even. Use half or full adders in your design. (Info: The number A3A2A1A0 is odd if the last binary digit A0 is 1.) (Info: subtracting 1 is the same as adding -1.)
Please solve
the problems from 2_5
Digital
system
Problem 2 Design a combinational circuit with inputs a, b, c, d and outputs w, x, y, z. Assume that the inputs a, b, c d represent a 4-bit signed number (2s complement). The output is also a signed number in 2s complement which is 5 greater than the input if the input is less than 2, and is 2 less than the input if the input is greater than or equal...
Can I get a circuit diagram of this and have the questions in it
answered/explained? Thank you.
TR. I. SINT400 quau AUC I. Parity. The parity of a string of bits is the least significant bit of their binary This sum is either 0 or 1, depending on whether the number of 1's is even or odd. This seems stupid, but adding a parity bit that makes the parity of every binary number being transmitted even allows one to determine...
help with the next problem Design a digital circuit that is a 2-bit, upstream and descending synchronous counter that with an input A, defines whether to ascend or descend. Comply with: A x 0 (ascending) A s 1 (descend), use Flip-Flop type D that is cyclic.