CS 4341 — Digital Logic and Computer Design, Homework 1

Download PDF

1.12 What is the smallest (most negative) 32-bit binary number that can be represented with

Unsigned numbers?

Two’s complement numbers?

Sign/Magnitude Numbers?

1.16 (c,d) Convert the following unsigned binary numbers to hexadecimal. Show your work.

1.18c Convert the following hexadecimal numbers to decimal. Show your work.

1.20d Convert the following hexadecimal numbers to unsigned binary. Show your work.

Because hexadecimal is , we can simply convert each hexadecimal digit into a 4-bit binary number

1.22 (c,d) Convert the following two’s complement binary numbers to decimal.

1.24 d Repeat Exercise 1.22, assuming the binary numbers are in sign/magnitude form rather than two’s complement representation.

1.30 (b,c,e) Convert the following decimal numbers to 8-bit two’s complement numbers or indicate that the decimal number would overflow the range.

After flipping all bits starting at the first one,

This is simple, since is a power of

After flipping all bits starting at the first one,

1.40 c Convert each of the following octal numbers to binary, hexadecimal, and decimal.

Because octal is , we can simply convert each octal digit into a 3-bit binary number

From here, because hexadecimal is , we can simply convert every 4 binary digits into a decimal number.

1.42 How many 7-bit two’s complement numbers are greater than 0? How many are less than 0? How would your answers differ for sign/magnitude numbers?

2′s complement

Sign/magnitude

1.56 (a,c,e) Convert the following decimal numbers to 6-bit two’s complement binary numbers and add them. Indicate whether or not the sum overflows a 6-bit result.

1.73 A majority gate produces a TRUE output if and only if more than half of its inputs are TRUE. Complete a truth table for the three-input majority gate shown in Figure 1.41.

ABCD
FFFF
FFTF
FTFF
FTTT
TFFF
TFTT
TTFT
TTTT

1.82 While walking down a dark alley, Ben Bitdiddle encounters a two-input gate with the transfer function shown in Figure 1.48. The inputs are A and B and the output is Y.

What kind of logic gate did he find?

He found an AND gate

What are the approximate high and low logic levels?

The approximate high and low logic levels are 2 and 1.8 respectively.

2.2 (c,d) Write a Boolean equation in sum-of-products canonical form for each of the truth tables

ABCY
0000
0011
0100
0110
1000
1010
1101
1111

ABCDY
00001
00010
00101
00111
01000
01010
01101
01111
10001
10010
10101
10110
11000
11010
11100
11110

2.6 (c,d) Minimize each of the Boolean equations from Exercise 2.2.

2.8 (c,d) Sketch a reasonably simple combinational circuit implementing each of the functions from Exercise 2.6. (The problem references the functions from 2.2)

c

d

2.12 (c,d) Repeat Exercise 2.8 using only NOT gates and NAND and NOR gates.

c

d

2.14 (a, b) Simplify the following Boolean equations using Boolean theorems. Check for correctness using a truth table or K-map.

Y = ABC + ABC

, since remains constant for both, and it doesn’t matter if C is true or not.

ABCYNot A AND B
00000
00100
01011
01111
10000
10100
11000
11100

Y = ABC + AB

. This is easy to see directly from the truth table, since only when all values are 1 is Y = 0. This can be written in product of maxterms form, which is clearly simplified.

ABCYNOT A OR NOT B OR NOT C
00011
00111
01011
01111
10011
10111
11011
11100

2.24 Write Boolean equations for the circuit in Figure 2.82. You need not minimize the equations.

2.26 Using De Morgan equivalent gates and bubble pushing methods, redraw the circuit in Figure 2.83 so that you can find the Boolean equation by inspection. Write the Boolean equation.

2.28 Find a minimal Boolean equation for the function in Figure 2.85. Remember to take advantage of the don’t care entries.

ABCDY
0000X
0001X
0010X
00110
01000
0101X
01100
0111X
10001
10010
1010X
10111
11001
11011
1110X
11111

Let’s make a k-map

This means that we get:

2.36 A priority encoder has 2N inputs. It produces an N-bit binary output indicating the most significant bit of the input that is TRUE, or 0 if none of the inputs are TRUE. It also produces an output NONE that is TRUE if none of the inputs are TRUE. Design an eight-input priority encoder with inputs A7:0 and outputs Y2.0 and NONE. For example, if the input is 00100000, the output Y should be 101 and NONE should be 0. Give a simplified Boolean equation for each output, and sketch a schematic.

A7A6A5A4A3A2A1A0Y2Y1Y0NONE
000000000001
000000010000
0000001X0010
000001XX0100
00001XXX0110
0001XXXX1000
001XXXXX1010
01XXXXXX1100
1XXXXXXX1110

2.40 Write a minimized Boolean equation for the function performed by the circuit in Figure 2.88.

(NOT A AND NOT B) OR (NOT A AND B AND NOT C AND NOT D) OR (A AND NOT B AND NOT C AND NOT D)

ABCDF
00001
00011
00101
00111
01001
01010
01100
01110
10001
10010
10100
10110
11000
11010
11100
11110

2.42 (a, b) Implement the function from Exercise 2.17(a) using

An 8:1 multiplexer

A 4:1 multiplexer and no other gates

Simplify the equation so

2.44 Determine the propagation delay and contamination delay of the circuit in Figure 2.84. Use the gate delays given in Table 2.8.

The Propagation delay is 110 because of the longest path along the bottom is . The contamination delay is along the upper path, since it is the shortest weight path to Y.

Used https://www.circuit-diagram.org/editor/ and https://logic.ly/demo/ for diagrams and typst for typsetting