https://github.com/kynan/codedojo30
Representing integers in the Fibonacci basis
https://github.com/kynan/codedojo30
Last synced: about 2 months ago
JSON representation
Representing integers in the Fibonacci basis
- Host: GitHub
- URL: https://github.com/kynan/codedojo30
- Owner: kynan
- License: mit
- Created: 2014-01-28T01:10:31.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2014-01-28T01:10:44.000Z (almost 12 years ago)
- Last Synced: 2025-03-08T23:52:39.371Z (10 months ago)
- Language: Python
- Size: 102 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Representing integers in the Fibonacci basis
============================================
We can use the Fibonacci sequence as a [basis for a numbering system][1]:
10 = 10010Fib = 0 * 1 + 1 * 2 + 0 * 3 + 0 * 5 + 1 * 8
This representation is not necessarily unique (unlike the decimal number
system), e.g. 4 = 11Fib or 100Fib.
Built by [Florian Rathgeber][2] for the [London Code Dojo 30][2].
Usage
-----
python fib.py N
Shows the Fibonacci base representations of the integers up to `N`.
License
-------
MIT
[1]: http://www.maths.surrey.ac.uk/hosted-sites/R.Knott/Fibonacci/fibrep.html#fibbase
[2]: https://twitter.com/frathgeber
[3]: http://www.meetup.com/London-Code-Dojo/events/151874652/