PDA

View Full Version : Converting base?


none12345
Oct 15, 2009, 06:57 PM
Hello guys I was just wondering, how do you convert a base 8 to base 12?

For example converting (13.57)base 8 into a number in base 12?

Stratmando
Oct 15, 2009, 07:08 PM
Let me know if this helps:
Base-N Calculator (http://www.efunda.com/units/base_n.cfm)

none12345
Oct 15, 2009, 08:27 PM
Let me know if this helps:
Base-N Calculator (http://www.efunda.com/units/base_n.cfm)

Thanks Strat. It helps but I kind of need to know how to do the process for my test lol.

ebaines
Oct 16, 2009, 10:11 AM
The process is easiest if you first convert from base 8 to base 10, then convert that number from base 10 to base 12.

So first convert the original number from base 8 to base 10.

Since this is a homework problem, I won't solve this exact problem for you, but I will show how to do a similar type of problem. Suppose you want to convert 26.52 (base 8) to base 12. Now 26.52 (base 8) means you have: 2 in the 8's column, plus 6 in the units column plus 5 in the 1/8 column, plus 2 in the (1/8)^2 column, for a total of 2*8 + 6 + 5/8 + 2/64 = 22 + 42/64. I trust that you know why we use these particular values of 8, 1, 1/8, 164, etc when talking about base 8, right?

Now we need to convert 22+42/64 to base 12. Note that 22 is greater than 12 and less than 12^2, so that means we know that the greatest significant digit will be in the 12's column. Sart by determining the largest possible number of 12's that divides into 22 + 42/64; this will be the digit for the 12's column. Clearly this is '1',' since you can divide 12 into 22 + 42/64 only once. So the most significant digit of our answer is '1.' Then we subtract 12 times this number and continue with the 1's column. Subtracting 1*12 from 22 + 42/64 yields 10+42/64. Now we know that the digit for the 1's column is 10 - but hold on, how do you express '10' as a single digit? By convention when working in bases > 10 we use the letters A, B, C, etc as a single-digit representation of base 10 equivalents for 10, 11, 12, etc. Thus 10 (base 10) expressed in base 12 is 'A'. So the digit for the 1's column is 'A.' Thus so far we have "'1A" in base 12. Next step is to subtract 10 from the number we were just working with: 10 + 42/64 - 10*1 = 42/64. This is less than one, so we know we need a decimal point here. Next step is to determine the digit for the 1/12 column - determine how many times 1/12 divides into 42/64, and the answer to that is 7 with a remainder of 14/192. Hence so far we have 1A.7 +14/192. And keep going - for the next digit how many times does (1/12)^2 go into 14/192? The answer is 10 - recall that we represent this as A - with a remainder of 2/576. So now we are up to 1A.7A in base 12. We're getting close to the end now - how many times does (1/12)^3 divide into 2/576? The answer is 6, with no remainder (hooray!). So, the final answer is 1A.7A6.

I trust this process was reasonably clear. There are some short cuts you can use if the base you're converting to is a nice multiple of the base you started from - for example, it's really quite easy to convert base 2 directly to base 8 without doing the base 10 conversion. But in general I find it easiest to go to base 10 first.

Post back and let us know what you get for an answer to your homework problem.