i’m looking for an alternative to the BigInteger package of C# which has been introduced with NET 4.x.
The mathematical operations with this object are terribly slow, I guess this is caused by the fact that the arithmetics are done on a higher level than the primitive types – or badly optimized, whatever.
Int64/long/ulong or other 64bit-numbers are way to small and won’t calculate correctly – I’m talking about 64bit-integer to the power of 64-bit integers.
Hopefully someone can suggest my something. Thanks in advance.
Honestly, if you have extremely large numbers and need to do heavy computations with them and the
BigIntegerlibrary still isn’t cutting it for you, why not offload it onto an external process using whatever language or toolkit you know of that does it best? Are you truly constrained to write whatever it is you’re trying to accomplish entirely in C#?For example, you can offload to MATLAB in C#.