Using a 4-bit signed input P=P3P2P1P0 and a control input Z, use a 4-bit adder and any logic gates to design a digital circuit that does the following: ● Outputs P + 3, if the input Z = 0 ● Outputs P − 3, if the input Z = 1 You can ignore cases where an overflow* might occur after performing the addition or subtraction operation, as long as the circuit performs the signed binary arithmetic correctly.
Using a 4-bit signed input P=P3P2P1P0 and a control input Z, use a 4-bit adder and any logic
gates to design a digital circuit that does the following:
● Outputs P + 3, if the input Z = 0
● Outputs P − 3, if the input Z = 1
You can ignore cases where an overflow* might occur after performing the addition or subtraction operation, as long as the circuit performs the signed binary arithmetic correctly.
*In computers, typically there is additional circuitry for an overflow flag that gets triggered when the result of an arithmetic operation “does not fit” the number of bits allocated for the output. Please ensure that your components, such as your 4-bit adder are shown clearly with the complete labels of their input and output pins and signals. The sample diagram below shows examples of these labels.
Step by step
Solved in 2 steps with 1 images