Among other things: you cannot really make a satisfactory model of a real number using two integers. The best known model is the floating-point model which is based on
significand,
coefficient,
mantissa, and
exponent and already exists and standardized as IEEE 754:
http://en.wikipedia.org/wiki/Floating_point[
^],
http://en.wikipedia.org/wiki/IEEE_754[
^].
This is a binary representation; and you are trying to work with strings instead of binary objects, which is itself is a pointless activity — working with string representation of data instead of data itself.
By the way, do you understand that a mathematical real number, its single instance, in general case, carries infinite amount of information?
I would advice you to stop doing what you are doing and learn some mathematics and elementary computer science around these problems.
—SA