Skip navigation

This solution is for the book I am currently reading. All of my notes and solutions are available at Google Code.

Here is my work for problem 2.16:

Assuming w = 4, we can assign a numeric value to each possible hexadecimal
digit, assuming either an unsigned or two's-complement interpretation. Fill in
the following table according to these interpretations by writing out the nonzero
powers of two in the summations shown in Equation 2.1 and 2.2 (in the book pg 52).



  Hexadecimal  Binary     Unsigned         Signed
  -----------------------------------------------------
       A        1010   2^3 + 2^1 = 10  -2^3 + 2^1 = -6
  -----------------------------------------------------
       0
  -----------------------------------------------------
       3
  -----------------------------------------------------
       8
  -----------------------------------------------------
       C
  -----------------------------------------------------
       F
  -----------------------------------------------------


Answers:

  Hexadecimal  Binary                    Unsigned         Signed
  -------------------------------------------------------------------------------
       A        1010               2^3 + 2^1 = 10                 -2^3 + 2^1 = -6
  -------------------------------------------------------------------------------
       0        0000                       0 =  0                          0 =  0
  -------------------------------------------------------------------------------
       3        0011               2^2 + 2^0 =  3                  2^2 + 2^0 =  3
  -------------------------------------------------------------------------------
       8        1000                     2^3 =  8                       -2^3 = -8
  -------------------------------------------------------------------------------
       C        1100               2^3 + 2^2 = 12                 -2^3 + 2^2 = -4
  -------------------------------------------------------------------------------
       F        1111   2^3 + 2^2 + 2^1 + 2^0 = 15    -2^3 + 2^2 + 2^1 + 2^0 =  -1
  -------------------------------------------------------------------------------


Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: