What Programming Language Can Handle 30-Digit Integers and Matrices for Free?

approx
Messages
42
Reaction score
0
I've been looking for a free download of a programming language that is easy to use and handles large numbers for a number theory problem I'm working on. I will report my results here after I use it. My TI isn't powerful enough and my other programmable calculator that I downloaded, graphcalc, doesn't do matrices. I'm guessing I need something that handles 30 digit integers, but the more the better. And of course it needs to handle matrices. Any suggestions? Thank you.
 
Physics news on Phys.org
approx said:
I've been looking for a free download of a programming language that is easy to use and handles large numbers for a number theory problem I'm working on. I will report my results here after I use it. My TI isn't powerful enough and my other programmable calculator that I downloaded, graphcalc, doesn't do matrices. I'm guessing I need something that handles 30 digit integers, but the more the better. And of course it needs to handle matrices. Any suggestions? Thank you.

Pari is excellent, and much better than Octave for number theory.
http://pari.math.u-bordeaux.fr/
 
You can handle 30 digit integers natively in 64-bit gcc. No other programming language will even come close in terms of speed.
 
Thanks for the input and the links. I'll try these out.
 
hamster143 said:
You can handle 30 digit integers natively in 64-bit gcc.

How? That would be useful. For example, that would let me compute multiplies mod a number <= 316227766016837 natively. (I'd otherwise be limited to 4294967296, which is less useful.)
 
Last edited:
CRGreathouse said:
How? That would be useful. For example, that would let me compute multiplies mod a number <= 316227766016837 natively.

You use the native type __int128_t.
 
Any language with "Big Integers" (arbitrary precision) integers should work (computational speed not being a factor). Java has a pretty basic implementation. Haskell has one as well, and is a bit faster and is often better for mathematical problems.
 
hamster143 said:
You use the native type __int128_t.

Nice, I'll have to play with that.
 
Back
Top