If I enter: 1/RandomInteger[10^200]+1/RandomInteger[10^200]
I get (instantly) an exact fraction. Is this fraction in simplified (reduced) form? In other words is the greatest common divisor of the numerator and denominator equal to 1?.
Asked
Active
Viewed 170 times
1
J. M.'s missing motivation
- 124,525
- 11
- 401
- 574
Geoffrey Critzer
- 1,661
- 1
- 11
- 14
1 Answers
3
The answer is yes, and you can also test it.
1/RandomInteger[10^200] + 1/RandomInteger[10^200] /.
Rational[a_, b_] :> GCD[a, b]
1
Ukiyo-E
- 259
- 1
- 4
RandomIntegerhave to do with the fundamental question anyway?) – David G. Stork Mar 18 '15 at 13:12RandomInteger. – David G. Stork Mar 18 '15 at 13:42Internal`RationalNoReduce(e.g.Internal`RationalNoReduce[2, 4]). The lack of reduction is persistent. – Dan Fortunato Mar 18 '15 at 15:59