answersLogoWhite

0


Best Answer

I can't say for certain what your specific difficulty is with the process, so I will guess unfamiliarity. There are many fine websites that will perform those calculations automatically.

------------------------------

There is a general method to convert from base 10 to any other base:

  1. divide the number by the base to get a whole number quotient and remainder
  2. note the remainder
  3. replace the number by the quotient
  4. if the number is not zero repeat from step 1
  5. write the remainders in reverse order to get the decimal number in the new base.

With this converting a decimal number to binary is quite straight forward; for example 205 in binary:

205 ÷ 2 = 102 r 1

102 ÷ 2 = 51 r 0

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

→ 205 in decimal is 1100 1101 in binary.

What you may be complaining about is that converting octal and hexadecimal numbers to binary is extremely straight forward and direct; examples:

0315 (octal) = 11 001 101 = 1100 1101 in binary

0xcd (hexadecimal) = 1100 1101 binary

These conversions are extremely easy as each digit of an octal or hexadecimal number uses an exact number of binary digits:

octal numbers 0-7 are the fill range of the binary numbers 000-111 - 3 binary digits

hexadecimal numbers 0-f are the full range of the binary numbers 0000-1111 - 4 binary digits.

There is no waste so each digit of an octal or hexadecimal number can be converted into binary directly. Each new octal or hexadecimal place value column is represented by an exact 3 or 4 block of binary digits, so when a place value is added, another block of binary digits is added, so 07 + 01 = 010 which in binary is 111 + 001 = 001 000; similarly 0xf + 0x1 = 0x10 which in binary is 1111 + 0001 = 0001 0000

With decimal numbers, however, the digits 0-9 are represented by the binary 0000-1001; if each digit of a decimal number was converted to binary (an encoding known as Binary Coded Decimal, or BCD) then the binary numbers 1010-1111 (6 of them) are not being used and wasted. Alternatively, when a new place value is needed in decimal the binary will still likely use the binary digits already being used without the need for an extra block, eg 9 + 1 = 10 which in binary is 1001 + 0001 = 1010; there is no 1:1 correspondence between blocks of binary digits and decimal digits that occurs with octal and hexadecimal numbers.

User Avatar

Wiki User

8y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

8y ago

It may seem difficult if you do not properly understand what you are doing.

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Why is it so difficult to convert a number from decimal to binary?
Write your answer...
Submit
Still have questions?
magnify glass
imp