Base 12 FractionsDate: 11/05/2001 at 06:59:05 From: Karla Killian Subject: Decimal conversion of Base 12 I have read through the FAQ's and I do not understand the method for doing decimals in base 12. The formulas were too complicated for me to understand. I need a simple way to understand how to do and interpret decimals in base 12. Example: 14.51 base 10 to base 12 would be 12.?? Date: 11/05/2001 at 12:58:00 From: Doctor Peterson Subject: Re: Decimal conversion of Base 12 Hi, Karla. I don't know which page you looked at; there are many answers related to various bases, so you may have missed one that would communicate better to you. Let's not call these "decimals," since that implies base ten. I'll just call it a "base-12 fraction." First, you have to convert the whole part 14 to base 12, and you have correctly done that, giving 12 (base 12). Now you have to convert 0.51 to base 12. To do that, just repeatedly multiply by the base, 12, and use the whole part of the product as the next digit in the answer, then repeat with the fractional part: . +---------------> 6 | 0.51 * 12 = 6.12 | +-----------+ | +---------------> 1 | | 0.12 * 12 = 1.44 | +-----------+ | +---------------> 5 | | 0.44 * 12 = 5.28 and so on. The answer is 0.615.... To check this, this number means 6 * 12^-1 + 1 * 12^-2 + 5 * 12^-3 + ... = 6*0.08333... + = 0.50000... + 1*0.00694... + 0.00694... + 5*0.00057... + 0.00289... + ... ... = 0.50983 + something small so it looks right so far. The final answer, of course, is 12.615... (base 12). - Doctor Peterson, The Math Forum http://mathforum.org/dr.math/ Date: 11/05/2001 at 16:42:09 From: Doctor Greenie Subject: Re: Decimal conversion of Base 12 Hi, Karla -- My rather lengthy response which follows consists of the following: I. a link to a page in the Dr. Math archives where I found a (rather formal and technical) discussion of a method for converting the fraction part of a base-10 number to another base; II. a description of an algorithm that can be used to convert a base-10 decimal fraction to its representation in another base; III. numerous examples of the use of the algorithm; and IV. an explanation of what you are really doing when you use the algorithm (i.e., an explanation of why the algorithm works). I strongly suspect that parts II and III - the description of the algorithm and the examples of its use - will be of most interest to you. The discussion on the page in the archives referenced in part I of my response is probably more formal and more technical than what you are after. I think the explanation of the algorithm that I have provided in part IV is more accessible to the non-mathematician than the one in the archives; however, it too may be beyond what you are interested in. Note that whenever we convert a decimal fraction to another base n, we can check our work by using the place values for base n to the right of the radix point. (A "decimal point" divides the whole number and fraction parts in the base-10 (decimal) representation of a number; the generic term for that point in any base n is the "radix point.") For example, in our familiar base 10, the number .1234 (base 10) means 1 2 3 4 -- + --- + ---- + ----- 10 100 1000 10000 In base 6, the fraction .1234 (base 10) has the base-10 equivalent 1 2 3 4 - + -- + --- + ---- 6 36 216 1296 I show the work of checking my results in a few of the examples below; in general, the amount of arithmetic required to do the checking is too complicated to bother with.... I. A link to a reference in the Dr. Math archives on this subject... Fraction/Decimal Conversion to Other Bases http://mathforum.com/dr.math/problems/trinidad8.12.98.html II. The Algorithm Here is the algorithm to be used: (NOTE: Thankfully, all of the arithmetic used in the algorithm is your familiar base-10 arithmetic!) ********************************************************************** Algorithm for converting fraction part of a base-10 number to base n: Step 1: multiply the fraction part by the base, n Step 2: keep the whole number part of the result as the next digit in the base-n representation of the number Step 3: (a) if there is no fraction part remaining, the representation of the number in base n terminates; you are done (b) if the fraction part remaining is the same as a fraction part you have seen before, the digits in the representation of the number in base n repeat from this point on Example: the converted digits up to this point are ".1423" and now the remaining fraction part is the same as it was when the next digit turned out to be the "4" -- the complete conversion is then ".1423423423423..." with the sequence of digits "423" repeating forever (c) if the fraction part remaining is different from all fraction parts obtained previously, continue by returning to step 1 ********************************************************************** III. Examples Here are several examples of the method, used to convert the decimal .125 (equivalent to the common fraction 1/8) to different bases. Note that, in the first example, no "conversion" is performed. I include this example as what is (I hope) a clearly understandable example of the algorithm. Example 1: "Convert" .125 (base 10) to base 10 step 1: 10(.125) = 1.25 step 2: next digit in base-10 representation is "1" step 3c: continue at step (1) using new fraction part .25 step 1: 10(.25) = 2.5 step 2: next digit in base-10 representation is "2" step 3c: continue at step (1) using new fraction part .5 step 1: 10(.5) = 5.0 step 2: next digit in base-10 representation is "5" step 3a: (base-10 representation terminates) result: .125 (base 10) = .125 (base 10) Example 2: Convert .125 (base 10) to base 4 step 1: 4(.125) = 0.5 step 2: next digit in base-4 representation is "0" step 3c: continue at step (1) using new fraction part .5 step 1: 4(.5) = 2.0 step 2: next digit in base-4 representation is "2" step 3a: (base-4 representation terminates) result: .125 (base 10) = .02 (base 4) check: 0 2 1 .02 (base 4) = - + -- = - 4 16 8 Example 3: Convert .125 (base 10) to base 5 step 1: 5(.125) = 0.625 step 2: next digit in base-5 representation is "0" step 3c: continue at step (1) using new fraction part .625 step 1: 5(.625) = 3.125 step 2: next digit in base-5 representation is "3" step 3b: the fraction part is the same as one obtained earlier (in this case, it is the same as we started with); therefore, the digits "03" repeat infinitely result: .125 (base 10) = .03030303... (base 5) check: 0 3 0 3 .03030303... (base 5) =( - + -- ) + ( --- + --- ) + ... 5 25 125 625 = (3/25) + (3/25)(1/25) + (3/25)(1/25)^2 + ... = (3/25)/[1-(1/25)] = (3/25)/(24/25) = 3/24 = 1/8 Example 4: Convert .125 (base 10) to base 6 step 1: 6(.125) = 0.75 step 2: next digit in base-6 representation is "0" step 3c: continue at step (1) using new fraction part .75 step 1: 6(.75) = 4.5 step 2: next digit in base-6 representation is "4" step 3c: continue at step (1) using new fraction part .5 step 3c: 6(.5) = 3.0 step 2: next digit in base-6 representation is "3" step 3a: (base-6 representation terminates) result: .125 (base 10) = .043 (base 6) check: 0 4 3 1 1 8+1 9 1 .043 (base 6) = - + -- + --- = 0 + - + -- = --- = -- = - 6 36 216 9 72 72 72 8 Example 5: Convert .125 (base 10) to base 12 step 1: 12(.125) = 1.5 step 2: next digit in base-12 representation is "1" step 3c: continue at step (1) using new fraction part .5 step 1: 12(.5) = 6.0 step 2: next digit in base-12 representation is "6" step 3a: (base-6 representation terminates) result: .125 (base 10) = .16 (base 12) check: 1 6 12+6 18 1 .16 (base 12) = -- + --- = ---- = --- = - 12 144 144 144 8 Now, to see how the algorithm is actually used (without spending a lot of effort thinking about what we are doing at each step), let's repeat some of the preceding examples and do a couple of more examples, just showing the arithmetic, without all the words, and without taking the time to check our results. Example 2 (again): Convert .125 (base 10) to base 4 4(.125) = 0.5 4(.5) = 2.0 (no fraction part remaining -- base-4 representation terminates) result: .125 (base 10) = .02 (base 4) Example 3 (again): Convert .125 (base 10) to base 5 5(.125) = 0.625 5(.625) = 3.125 (remaining fraction part is one we have already seen -- base-5 representation repeats) result: .125 (base 10) = .03030303... (base 5) Example 6: Convert .125 (base 10) to base 9 9(.125) = 1.125 9(.125) = 1.125 (remaining fraction part is one we have already seen -- base-9 representation repeats) result: .125 (base 10) = .1111... (base 9) Example 7: Convert .125 (base 10) to base 7 7(.125) = 0.875 7(.875) = 6.125 (remaining fraction part is the one we started with -- base-7 representation repeats) result: .125 (base 10) = .06060606... (base 7) Now let's take your decimal fraction .51 and convert it to a couple of different bases using the same algorithm. Example 8: Convert .51 (base 10) to base 5 5(.51) = 2.55 5(.55) = 2.75 5(.75) = 3.75 (remaining fraction part is one we have already seen -- base-5 representation repeats) result: .51 (base 10) = .2233333... (base 5) Example 9: Convert .51 (base 10) to base 6 6(.51) = 3.06 6(.06) = 0.36 6(.36) = 2.16 6(.16) = 0.96 6(.96) = 5.76 6(.76) = 4.56 6(.56) = 3.36 (remaining fraction part is one we have already seen -- base-6 representation repeats) result: .51 (base 10) = .30 20543 20543 20543... (base 6) (I displayed the base-6 representation so that it is easy to see the sequence of repeating digits) Example 10: Convert .51 (base 10) to base 12 (your example...) 12(.51) = 6.12 12(.12) = 1.44 12(.44) = 5.28 12(.28) = 3.36 12(.36) = 4.32 12(.32) = 3.84 12(.84) = 10.08 12(.08) = 0.96 ... (You can carry this one out further on a calculator if you want; it goes about 20 digits before the digits start repeating...) result (incomplete): .51 (base 10) = .615343A0???? (base 12) IV. Explanation Here is an explanation of the method, using some of the examples we have worked out. Let's look first at how the algorithm is used in the "conversion" of .125 (base 10) to base 10 and think about what we are really doing. Here is the "conversion" of .125 to base 10 using the algorithm: 10(.125) = 1.25 (1) 10(.25) = 2.5 (2) 10(.5) = 5.0 (3) In step (1) above, we aren't REALLY multiplying our base-10 number by 10. What we are actually doing is taking the base-10 fraction ".125" and multiplying it AND DIVIDING IT by 10 to re-write it as 10(.125) 1.25 1 .25 .125 = -------- = ---- = -- + --- 10 10 10 10 By multiplying and dividing our base-10 number by 10, we have succeeded in rewriting the number as (1/10) + (x/10) where x is less than 1; this tells us that the first digit to the right of the decimal (radix) point is 1. So at this point we know the base-10 representation is .1?????? In step (2) above, again we aren't really multiplying .25 by 10; we are taking (.25/10) and multiplying it and dividing it by 10; in so doing, we have now expressed our original base-10 fraction as 1 .25 1 10(.25) 1 2.5 1 2 .5 .125 = -- + --- = -- + ------- = -- + --- = -- + --- + --- 10 10 10 10(10) 10 100 10 100 100 At this point, we have succeeded in rewriting the number as (1/10) + (2/100) + (x/100) where x is less than 1; this tells us that the second digit to the right of the decimal (radix) point is 2. So at this point we know the base-10 representation is .12????? Finally, in step (3) above, again we aren't really multiplying .5 by 10; we are taking (.5/100) and multiplying it and dividing it by 10; in so doing, we have now expressed our original base-10 fraction as 1 2 .5 1 2 10(.5) .125 = -- + --- + --- = -- + --- + ------- 10 100 100 10 100 10(100) 1 2 5 = -- + --- + ---- = (base 10) .125 10 100 1000 To demonstrate what we are really doing with a couple of more examples, let's again perform the conversion of .125 to base 12 and to base 6 -- in each case, first using the algorithm and then showing what it is that we are really doing. Example 5 (once more): Convert .125 to base 12 By the algorithm: 12(.125) = 1.5 12(.5) = 6.0 result: .125 (base 10) = .16 (base 12) What we are really doing when we use the algorithm (in converting to base 12, we multiply by 12 AND divide by 12 at each step): 12(.125) 1.5 1 .5 1 12(.5) 1 6 .125 = -------- = --- = -- + -- = -- + ------ = -- + --- 12 12 12 12 12 12(12) 12 144 = (base 12) .16 Example 4 (again): Convert .125 to base 6 By the algorithm: 6(.125) = 0.75 6(.75) = 4.5 6(.5) = 3 result: .125 (base 10) = .043 (base 6) What we are really doing when we use the algorithm (in converting to base 6, we multiply by 6 AND divide by 6 at each step): 6(.125) .75 0 .75 0 6(.75) 0 4.5 .125 = ------- = --- = - + --- = - + ------ = - + --- 6 6 6 6 6 6(6) 6 36 0 4 .5 0 4 6(.5) 0 4 3 = - + -- + -- = - + -- + ----- = - + -- + --- = (base 6) .043 6 36 36 6 36 6(36) 6 36 216 I hope all of this helps. Write back if you have any further questions about this. - Doctor Greenie, The Math Forum http://mathforum.org/dr.math/ |
Search the Dr. Math Library: |
[Privacy Policy] [Terms of Use]
Ask Dr. Math^{TM}
© 1994- The Math Forum at NCTM. All rights reserved.
http://mathforum.org/dr.math/