Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-25 Thread Michael Jones
The nat->string code allows any base -- or at least it did -- but it was not exposed in the Int APIs. Maybe you'll want to access the sources. On Sun, Jul 23, 2017 at 8:34 PM, me wrote: > > > On Saturday, July 22, 2017 at 9:37:16 AM UTC-6, Rémy Oudompheng wrote: >> >> >> The

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-24 Thread me
On Saturday, July 22, 2017 at 9:37:16 AM UTC-6, Rémy Oudompheng wrote: > > > The most annoying issue you might encounter is that if your 2GB > strings are numbers printed in base 10, the math/big will not be able > to parse them in a reasonable time using the standard method > (SetString). >

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-24 Thread me
On Saturday, July 22, 2017 at 9:19:44 AM UTC-6, Rémy Oudompheng wrote: > > > I wrote a little module (github/remyoudompheng/bigfft) to play with > FFT-based multiplication of huge integers, while maintaining > interoperability with the math/big package. > > I think I saw that on Github and

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-24 Thread me
On Saturday, July 22, 2017 at 9:06:03 AM UTC-6, hsmyers wrote: > > Like everything else, '*it depends…*' > > Do you want speed? > At some point, speed will become important, but if it's under 1 minute or around 2 minutes it's "good enough"... > Do you want the bulk of the coding already

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-23 Thread Bakul Shah
I get about 26 seconds to multiple billion bit (2^10^9-1) numbers with Gambit-Scheme (which has a built-in FFT multiplier written in Scheme by Brad Lucier). On the same hardware your bigfft packet takes about 24s for multiplying two billion digit numbers. GMP is of

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-22 Thread Michael Jones
Oh no! I wrote some of that code. Maybe I should revisit. On Sat, Jul 22, 2017 at 10:54 AM Hugh S. Myers wrote: > Ah! Excellent solution. I wrote one of the early multiple precision > packages for the C users group in the 80's and I typically wrote in C > first, then

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-22 Thread Hugh S. Myers
Ah! Excellent solution. I wrote one of the early multiple precision packages for the C users group in the 80's and I typically wrote in C first, then disassembled and reduced the code and re-assembled again. Not the best approach, but it allowed some exciting prime number research for the time…

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-22 Thread Rémy Oudompheng
The math/big library has basic routines implemented in assembly for most common architectures, with all the math written in Go atop those. Rémy. 2017-07-22 17:39 GMT+02:00 Hugh S. Myers : > Is math/big pari based? > > On Sat, Jul 22, 2017 at 8:36 AM, Rémy Oudompheng

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-22 Thread Hugh S. Myers
Is math/big pari based? On Sat, Jul 22, 2017 at 8:36 AM, Rémy Oudompheng wrote: > 2017-07-22 17:19 GMT+02:00 Rémy Oudompheng : > > 2017-07-22 16:48 GMT+02:00 me : > >> How does GoLang compare to other languages for

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-22 Thread Rémy Oudompheng
2017-07-22 17:19 GMT+02:00 Rémy Oudompheng : > 2017-07-22 16:48 GMT+02:00 me : >> How does GoLang compare to other languages for mathematics dealing with >> really large numbers? >> >> Prefer the ability to work with 2GB sized strings as numbers (need

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-22 Thread Rémy Oudompheng
2017-07-22 16:48 GMT+02:00 me : > How does GoLang compare to other languages for mathematics dealing with > really large numbers? > > Prefer the ability to work with 2GB sized strings as numbers (need much > bigger than int64) > > I see there is this: >

Re: [go-nuts] Math on Huge (2GB) numbers in GoLang

2017-07-22 Thread Hugh S. Myers
Like everything else, '*it depends…*' Do you want speed? Do you want the bulk of the coding already available as a library/module? With or without a user interface? Answer those first and then ask again. Oh! Replace Javascript with Perl… On Sat, Jul 22, 2017 at 7:48 AM, me