All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Algorithms
Golden Ratio Gradation (Posted on 2022-01-27) Difficulty: 3 of 5
Devise an algorithm for writing any positive base ten integer in base φ number system.
**** φ, called the Golden Ratio is a positive real number equal to (1+√5)/2

See The Solution Submitted by K Sengupta    
Rating: 5.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Some Thoughts re: my take on it - precision questions Comment 4 of 4 |
(In reply to my take on it by Charlie)

I had hoped to gain precision by exploiting the Fibonacci relationship (see my post) such that each calculation of a power of Phi involves one call to 5^(.5) and one division by 2.  I hoped this would be more precise than raising Phi to various powers.
But what I'm not sure about is how much this may or may not have helped.  For one thing, I'm not sure how precise Python represents the square root of 5.

I did just now find online a discussion of reducing or expanding the number of 1's in a Base Phi Representation, but it was not at all intuitively obvious to me why there is an equivalence between occurrences of 011 and 100 -- that is it wasn't intuitive until I looked once more at the table of powers of Phi in [a,b] notation.  
Aha!  The n-th power of Phi is the sum of the 2 next smaller powers.  

  Posted by Larry on 2022-01-27 15:11:09
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (3)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information