Looking for a C++ Large Number Class

B

Bruce

I have a nice public domain large number class that uses STL vectors and
seems to be relatively bug free but is not the fastest thing on the planet
and I have a need for speed. Anyone know of any available that are really
optimized for speed. All I need for functionality is multiply, divide and
modulous operations.
 
V

Victor Bazarov

Bruce said:
I have a nice public domain large number class that uses STL vectors and
seems to be relatively bug free but is not the fastest thing on the planet
and I have a need for speed. Anyone know of any available that are really
optimized for speed. All I need for functionality is multiply, divide and
modulous operations.

Joining in the search for the biggest prime? Heheh... Have you tried
Google? Do try it, it's fun and it's full of good information...
 
G

Gianni Mariani

Bruce said:
I have a nice public domain large number class that uses STL vectors and
seems to be relatively bug free but is not the fastest thing on the planet
and I have a need for speed. Anyone know of any available that are really
optimized for speed. All I need for functionality is multiply, divide and
modulous operations.

Try GMP.

BTW - this is off topic here. You'd be better off trying a NG that
suits your question better. Nothing comes to mind but one of the crypto
groups might be a good place to start.
 
J

Jeff Schwab

Gianni said:
Try GMP.

BTW - this is off topic here. You'd be better off trying a NG that
suits your question better. Nothing comes to mind but one of the crypto
groups might be a good place to start.

I've used GMP with great success in a ~20,000 line C++ program. It
comes with C++ class wrappers around C functions. I wrapped the GMP C
functions myself, because I needed to provide some low-level operators:
reduction operators, bitwise operators, etc.
 
B

Bruce

In comp.lang.c++
Victor Bazarov said:
Joining in the search for the biggest prime? Heheh... Have you tried
Google? Do try it, it's fun and it's full of good information...

Actually, google is good for large volumes of data. I was looking for a
FAST library that some real programmers could attest to. I found MIRACL
and have begun integrating that one.

No, I'm not looking for the biggest prime, only two particular ones.
 
D

Derek

Bruce said:
I have a nice public domain large number class that uses STL
vectors and seems to be relatively bug free but is not the
fastest thing on the planet and I have a need for speed.
Anyone know of any available that are really optimized for
speed. All I need for functionality is multiply, divide and
modulous operations.

Check out http://www.oonumerics.org/oon/

Go down to the "Multiprecision, arbitrary precision data types"
section. There are a few libraries to choose from. One of them might
be what you are looking for.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,156
Messages
2,570,878
Members
47,408
Latest member
AlenaRay88

Latest Threads

Top