Discrete mathematics (Show your work)

4. Convert the following, show all work required for the conversions as done by hand. a) Write the base-10 number 51 in binar

Respuesta :

Answer:

  110011

Step-by-step explanation:

The tedious way to do this is to divide by 2 until the quotient is 0, noting remainders at each step:

  • 51/2 = 25 r 1
  • 25/2 = 12 r 1
  • 12/2 = 6 r 0
  • 6/2 = 3 r 0
  • 3/2 = 1 r 1
  • 1/2 = 0 r 1

Taken from bottom to top, the list of remainders comprises the binary number: 110011.

___

Alternatively, you can convert the number to hexadecimal (base-16) or octal (base-8), then make the simple conversions from those digits to binary. In octal, we have ...

  • 51/8 = 6 r 3
  • 6/8 = 0 r 6

Then the number in octal is 51 = 63₈. Your familiarity with binary lets you write the binary number from memory, since you recall 6 = 110₂ and 3 = 011₂. Each octal digit must be expressed as three binary digits (or bits) in order to maintain appropriate place values.

That is, ...

  63₈ = 110011₂

_____

Comment on octal-binary conversion

The binary values of the digits 0-7 are ...

  • 0 = 000₂
  • 1 = 001₂
  • 2 = 010₂
  • 3 = 011₂
  • 4 = 110₂
  • 5 = 101₂
  • 6 = 110₂
  • 7 = 111₂

Three binary bits can express numbers 0-7 as shown. So, using octal as an intermediate base in doing the conversion to binary lets you do the conversion 3 bits at a time, instead of one bit at a time.

Likewise, four binary bits can express numbers 0-15, so hexadecimal as an intermediate base lets you do the conversion 4 bits at a time: 51/16 = 3 r 3 ⇒ 0011 0011₂.