0
$\begingroup$

I'm trying to come up with a formula to reliably reduce a number like NNN.NNNN to a simple integer – NNNN such that NNNN can be converted back to NNN.NNNN as it were before using the inverse of the same formula.

Would be grateful if you could provide some formula or pointers in that direction.

  • 1
    If you know how many Ns there are after the decimal point, you can just multiply with an appropriate power of $10$.2012-11-23
  • 0
    @peter: Can you provide more specifics? Also, what is the application? I can imagine some things you might be trying to do for which there is a much simpler way than trying to solve the mathematical problem you are trying to describe.2012-11-23
  • 0
    Do you mean you want to convert a "terminating" decimal number to a fraction?2012-11-23

1 Answers 1