20021220, 00:42  #1 
Dec 2002
2 Posts 
Converting big numbers to and from binary and decimal
Hi,
I hope you guys can answer this, here seems to be the place for discussing math dealing with huge numbers... Does anybody know of any fast algorithms that can be used to convert big integers (several million digits) from binary to decimal? Any recommendations on how to program this? Any suggestions will be helpful  languages, data structures, etc. I'm basically looking to not do a brute force conversion that I did in high school. Thank you, Quantum Skyline 
20021220, 03:56  #2 
Oct 2002
53_{8} Posts 
The standard algorithm is binary splitting; it takes O(n (log n)^2) time. You'll find it in Knuth's volume 2.

20021221, 01:10  #3 
Nov 2002
43 Posts 
I was wondering if you'd work with "big numbers" via unicode or strings as opposed to int, or long...

20021221, 03:10  #4 
Nov 2002
43 Posts 
http://home.earthlink.net/~usondermann/progtip.html#Top

20021221, 22:38  #5  
Dec 2002
2 Posts 
Quote:
Now let's see if my library has a copy of Knuth's books (and if I still have my library card). Quantum Skyline 

20021227, 19:23  #6 
Nov 2002
43_{10} Posts 
I have the three volumes, I think they are original editions. So if you need something from one of them, let me know.

Thread Tools  
Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Is every product of distinct Fermat numbers symmetrical in binary?  only_human  Puzzles  9  20150626 10:30 
very long binary representation to decimal  davar55  Programming  24  20141207 00:19 
How to convert 5495bit binary number to decimal?  Stargate38  Software  12  20120207 21:19 
Square numbers and binary representation  ET_  Miscellaneous Math  40  20100606 12:55 
decimalbinary prime pairs  ixfd64  Math  2  20031016 13:40 