Make Math Work
DecimalToFraction

Usage: DecimalToFraction Number_1 [,Number_2]
DecToFrac Number_1 [,Number_2]
Dec2Frac Number_1 [,Number_2]

The DecToFrac command will convert a decimal number into its fractional representation in lowest terms. To convert any non-repeating decimal to a fraction, enter the decimal you wish to convert in place of Number_1, for example, DecToFrac 0.125.

DecToFrac can handle repeating decimals. To convert a repeating decimal, enter the non-repeating portion in place of Number_1, and the repeating portion in place of Number_2. For example, 1/6 in its decimal form is 0.16666, with the 6 repeating, theoretically, forever. Entering this decimal into MakeMathWork as DecToFrac 0.1, 6 will return a result of 1/6. If your decimal number does not have a non-repeating portion, that is, the whole entry repeats, for example, .33333…, enter zero for the non-repeating portion, and 3 as the repeating portion. Your entry will look like DecToFrac 0, 3, which will return a result of 1/3.



To convert fractions to decimals use FracToDec.

Examples:
DecToFrac 0.25 returns 1/4.
DecToFrac 0, 142857 returns 1/7.
DecToFrac 0.25, 12 returns 829/3300.