Using each of the digits 1 to 9 exactly once, and the standard arithmetic operators, +,-, *, /, and, () as many times as required; come up with a value that is closest to φ.
This means, minimizing abs(V - φ), where V is the obtained value and, abs is the
absolute function.
(I) Use only the individual digits. Concatenations like (98-34)/(1*2) - (56/7) are NOT allowed.
(II) Concatenations are allowed.
Note: φ is the golden ratio or the golden mean.
One strategy for Part II:
Find the largest two adjacent Fibonacci numbers, with only digits 1 to 9 and only once each; φ(9) divided by φ(8):
34/21 = 1.619047619047619 err=0.0010136302977241662
This is too large by about 1/1000, so let's make a fraction out of the remaining digits as close to that as possible.
After a few attempts:
34/21 - 8/7965 = 1.61804322482289 err=9.23607299085916E-06
34/21 - 8/7956 = 1.61804208863032 err=8.09988042904664E-06
34/21 - 7/6958 = 1.61804158283032 err=7.5940804202812E-06
|
Posted by Larry
on 2023-02-07 12:08:15 |