Teoria conversion entre diferentes sistemas numericos

Convertir de otros sistemas al decimal (base 10)

Ej:

El sistema binario es base 2, por lo que la formula para obtener el decimal que represente el binario 101 base 2 es:

1*2

Converting from other number bases to decimal

Other number systems use different bases. The binary number system uses base 2, so the place values of the digits of a binary number correspond to powers of 2. For example, the value of the binary number 10011 is determined by computing the place value of each of the digits of the number:

1 0 0 1 1 the binary number
2^4 2^3 2^2 2^1 2^0 place values

So the binary number 10011 represents the value

(1 * 2^4) + (0 * 2^3) + (0 * 2^2) + (1 * 2^1) + (1 * 2^0)
= 16 + 0 + 0 + 2 + 1
= 19

The same principle applies to any number base. For example, the number 2132 base 5 corresponds to

2 1 3 2 number in base 5
5^3 5^2 5^1 5^0 place values

So the value of the number is

(2 * 5^3) + (1 * 5^2) + (3 * 5^1) + (2 * 5^0)
= (2 * 125) + (1 * 25) + (3 * 5) + (2 * 1)
= 250 + 25 + 15 + 2
= 292

Converting from decimal to other number bases

In order to convert a decimal number into its representation in a different number base, we have to be able to express the number in terms of powers of the other base. For example, if we wish to convert the decimal number 100 to base 4, we must figure out how to express 100 as the sum of powers of 4.

100 = (1 * 64) + (2 * 16) + (1 * 4) + (0 * 1)
= (1 * 4^3) + (2 * 4^2) + (1 * 4^1) + (0 * 4^0)
Then we use the coefficients of the powers of 4 to form the number as represented in base 4:
100 = 1 2 1 0 base   4

One way to do this is to repeatedly divide the decimal number by the base in which it is to be converted, until the quotient becomes zero. As the number is divided, the remainders – in reverse order – form the digits of the number in the other base.

Example: Convert the decimal number 82 to base 6:

82/6 = 13 remainder 4
13/6 = 2 remainder 1
2/6 = 0 remainder 2

The answer is formed by taking the remainders in reverse order:  2 1 4 base

Referencia: http://www.citidel.org/bitstream/10117/20/12/index.html



This entry was posted on Monday, December 7th, 2009 at 10:41 am and is filed under Programacion, Teoria, computacion. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

4 Responses to “Teoria conversion entre diferentes sistemas numericos”

  1. WP Themes

    Nice fill someone in on and this mail helped me alot in my college assignement. Say thank you you as your information.

  2. Daniel Gomez Rico

    Explain more, i cant undertstand you,
    Tell us how please.

  3. Emily

    Good share,you article very great, very usefull for us…thank you

  4. Julie

    The informative article encouraged me very much! Bookmarked the blog, extremely great topics just about everywhere that I read here! I appreciate the info, thanks.

Leave a Reply

Your comment