In: Computer Science
Prove that every real number with a terminating binary representation (finite number of digits to the right of the binary point) also has a terminating decimal representation (finite number of digits to the right of the decimal point).
Real number with terminating binary representation also has terminating decimal representation:
Consider a fraction p/q has value all 0’s after some places in binary representation.
Represent p/q with numerical value as follows.
Here, k has some finite value.
Consider the value of p and q.
To prove the condition, consider any integer with power of k.
Consider an integer 5k. Multiply and divide the term p/q with 5k.
Substitute 2k for q.
To get the fraction value of p/q, the value of (5k)p is always less than (10k).
Therefore, in general for any proper fraction with finite decimal expansion can be represented as q/10k, with consideration of q is divisible by 5k.
For example if q is taken as value 5k, then
Therefore, real number with terminating binary representation also has terminating decimal representation.
Therefore, real number with terminating binary representation also has terminating decimal representation.