Вы находитесь на странице: 1из 2

NANYANG TECHNOLOGICAL UNIVERSITY

SCHOOL OF ELECTRICAL & ELECTRONIC ENGINEERING

EE2004 DIGITAL ELECTRONICS

TUTORIAL 1

1. Convert the following numbers with the indicated bases to decimal: (4310)5 and
(198)12.
Ans: 58010 & 26010

2. Determine the base of the numbers in each case for the following operations to be
correct: (a) 14/2 = 5, (b) 54/4 = 13, (c) 24+17 = 40.
Ans: 6, 8, & 11

3. Convert each of the following decimal numbers to binary, octal and hexadecimal
numbers: (a) 27, (b) 915.
Ans: (a) 110112, 338, & 1B16
(b) 0011 1001 00112, 16238, & 39316

4. Obtain the 1’s and 2’s complements of the following binary numbers:
(a) 00101010 (b) 01101011 (c) 00000000 (d) 11111111 (e) 10000000

Ans: Binary numbers 1’s Complement 2’s Complement


(a) 00101010 11010101 11010110
(b) 01101011 10010100 10010101
(c) 00000000 11111111 00000000
(d) 11111111 00000000 00000001
(e) 10000000 01111111 10000000

5. For each of the following pairs (A, B) of numbers, calculate A + B, A - B, -A + B, and


-A - B, assuming an 8-bit two’s complement number system. Check the results by
decimal arithmetic. Explain any unusual results.

(a) 01010101, 00001010 (+9510, +7510, -7510, -9510)


(b) 01101011, 00101010 (Invalid result, +6510, -6510, Invalid result)
(c) 11101010, 00101111 (+2510, -6910, +6910, -2510)
(d) 10000000, 01111111 (-110, Invalid result, can’t be obtained, can’t be obtained)

6. Convert decimal +61 and +27 to binary using the 2’s complement representation. Then
perform the binary equivalent of (+27) + (-61), (-27) + (+61) and (-27) + (-61). Convert
the answers back to decimal and verify that they are correct.
Ans: -3410, +3410, -8810

1
7. Encode each of the following decimal numbers in BCD.
(a) 39 (b) 1950 (c) 94704 (d) 625

Ans: Denary Number BCD


(a) 39 0011 1001
(b) 1950 0001 1001 0101 0000
(c) 94704 1001 0100 0111 0000 0100
(d) 625 0110 0010 0101

8. A register (to be studied in later part of the course) of n bits in size is a memory for
storing an n-bit data. When a 12-bit register stores 100010010111, what is its content if
it represents:

(a) three decimal digits in BCD; Ans: 897


(b) an unsigned binary number; Ans: 2,199
(c) a 2’s complement number. Ans: -1897

Вам также может понравиться