CSE410 HOMEWORK #2 Spring 2003 DUE: Thursday, April 17 1. (a) Give the representation of the decimal number -5 as a 7 bit value in each of sign-magnitude, one's complement, two's complement, and excess 2^(n-1) notation. (b) Consider the two's complement representation of signed integers using 4 bits. For each of the 16 possible bit configurations, give in decimal notation, the corresponding number represented. 2. Assume that numbers are represented in two's complement with 5 bits. (a) What are the largest and smallest numbers (in decimal) that can be represented? (b) Perform the indicated computations: i) 01010 + 00011 ii) 01010 + 10010 iii) 00000 - 11110 iv) 10010 + 11110 3. Derive the representations of the numbers 5/32 and -8.5 in IEEE floating-point standard 754 format. Show your work. Express your answers in hexadecimal. 4. A 32 bit word contains the following bit string S (in hexadecimal): B F 4 0 0 0 0 0 For each of the questions below, show your work in deriving the answer. (a) If S denotes an integer in sign-magnitude representation, what is the value of the represented integer in standard decimal notation? (b) Assume that S represents an integer in two's complement representation. What is the value of S in base 10 (decimal)? (c) Suppose that S denotes a floating point number in IEEE 754 floating point format. Expressed in standard scientific notation, base 10, what is the represented number?