English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

Hello people?

I'm having an XHTML course at college and the instructor had given us a lesson about the numbering systems (The Binary, Decimal, Octal, and Hexadecimal numbering systems).

And I have a small problem with converting from the Decimal system to the Octal or Hexadecimal systems..

Requesting assistance.. Please??

2007-07-06 06:47:19 · 9 answers · asked by omar h 1 in Science & Mathematics Mathematics

9 answers

These systems are all just used to show numbers in different bases.

For example, in the decimal system (base 10), each digit, between 0 and 9 (that's 10 different digits), is multiplied by 10 to the power of the digit's placeholder (steps from the right-most digit). For instance, in the decimal number 329,
9 x 10^0 + 2 x 10^1 + 3 x 10^2 = 329.

This works the same way with hexadecimal (base 16), where:
...
A=10
B=11
C=12
D=13
E=14
F=15

For example the hex value F3 can be calculated like so:
3 x 16^0 + F x 16^1
this simplifies to:
3 x 1 + 15 x 16
3 + 240
243 in base 10

2007-07-06 07:01:43 · answer #1 · answered by Z W 2 · 0 0

OK, let's show this by way of example.
Let's pick some random base 10 number... say, 4538.
To convert that to hexadecimal, I'd first look at the powers of 16.
16^1 = 16
16^2 = 256
16^3 = 4096

Start with the biggest power, 16^3 = 4096.
4096 fits into 4538 once, so the "thousands" hex digit is a 1.
4538-4096 = 442
Look at the next lower power, 16^2 = 256.
256 fits into 442 once, so the "hundreds" hex digit is a 1.
442 - 256 = 186
Look at the next lower power, 16^1 = 16.
16 fits into 186 11 times, so the "tens" hex digit is an 11, or B.
186 - (11*16) = 10
The "ones" hex digit is a 10, or A.

The decimal number 4538 = the hex number 11BA.

Hope that makes the method clear!

2007-07-06 07:02:37 · answer #2 · answered by Bramblyspam 7 · 0 0

Remember that each number place corresponds to the base to a different power. In base 10, the first place is the ones place (10^0), then the tens place (10^1), then the hundreds place (10^2), etc. In base 8, it's just the same: ones (8^0), eights (8^1), sixty-fours, (8^2), etc.

To convert from base 10 to base 8, look for the largest power of 8 that "fits" in the number. For example, if we want to convert 777, base 10, into base 8, we go about it as follows:

8^3 = 512, which is the largest power that fits. It fits one time into 777. So, we mark our first base 8 digit as a 1. Then we subtract 512 from 777, leaving 265.

Now we go to the next place (the next lower power of 8). 8^2 = 64, which fits 4 times into 265. So, our second base 8 digit is a 4. Then we subtract 4*64 from 265, leaving 9.

Now we go to the next place. 8^1 = 8. This fits one time into 9, so our third base 8 digit is a 1. This leaves 1 left over.

Now we go to the next place. 8^0 = 1. This fits one time into 1, so our fourth (and final) base 8 digit is a 1.

Hence, 777 in base 10 becomes 1411 in base 8.


To convert 5555 to base 16, here's the process, in brief:
16^3 = 4096, which fits 1 time.
5555 - 4096 = 1459
16^2 = 256, which fits 5 times.
1459 - 256*5 = 179
16^1 = 16, which fits 11 times (but 11 is just "B" in hexadecimal)
179 - 16*11 = 3
16^0 = 1, which fits 3 times.

So, 5555 (base 10) = 15B3 (base 16).

2007-07-06 07:07:33 · answer #3 · answered by lithiumdeuteride 7 · 0 0

To understand the process you need to think in terms of powers of the base of the system. Instead of grouping in units, 10's, 100's, 1000's, 10000's, etc., for octal e.g., you group the decimal-equivalent number into units, 8's, 64's, 512's, 4096's, etc., using as many of these in order to convert the original number. You want to understand the theory before using the available system-based conversions.

2007-07-06 07:04:57 · answer #4 · answered by John V 6 · 0 0

If you are using Windows, you can use the Windows calculator (Start...Programs...Accessories...Calculator), click on View and use Scientific. You can then convert a number from decimal to octal to hex.

2007-07-06 06:56:54 · answer #5 · answered by N E 7 · 0 0

You can use TI scientific calculator to help with conversion.
I have an old one (TI-36 Solar)

1. to convert from decimal to HEX, for example
ENTER a decimal number, say, 45
PRESS MODE HEX
it displays 2D

2007-07-06 07:35:23 · answer #6 · answered by buoisang 4 · 0 0

to convert 100 to octal
100/8 =12 and reminder is 4
12/8=1 and reminder is 4
1
The answer is 144

100 in hex
100/16=6 and rem = 4
6
the answer is 64

2007-07-06 07:02:05 · answer #7 · answered by zohair 2 · 0 0

because of the fact Arabic numbering equipment is effective. do you recognize numbering equipment in kanji? 13 hundreds and a pair of thousands and fifteen would desire to be write as ???????? in kanji. It does not extra healthful for calculation. We write it as 13215 in Arabic equipment now. What an hassle-free equipment.

2016-12-10 03:58:03 · answer #8 · answered by Anonymous · 0 0

Use a base converter. There's a free one online here:

http://www.cut-the-knot.org/binary.shtml

2007-07-06 06:52:50 · answer #9 · answered by rand7263 2 · 0 0

fedest.com, questions and answers