Forum > General

Anyone interested in testing a new Big Integer library?

(1/18) > >>

I've been working on a new Big Integer library.  Is anyone interested in testing it out?

I've tried to make it...
1  easy to use - minimal changes required to existing code
2  reasonably fast (EDIT: with latest optimisations, is now faster then the FNX library)
3  pure Pascal code, no assembly and no C, so portable and reliable
4  runs on 32 bit CPUs and 64 bit CPUs
5  small footprint, small code size
6  will actually compile straight out of the box with no messing about
7  unlicensed/public domain, I'm happy to give it away free of any restrictions

Why did I make this?  I could not find any Big Integer library that met all the above criteria. The FNX library is very good, but is 64 bit only. EDIT: I've recently been looking at the MRArith library; it's very fast, but is rather difficult to use and requires substantial changes to existing code.

1  only whole integers, no support for other number types
2  only has basic arithmetic, logical and formatting operations
3  does not have extensive maths operations
4  does not have dynamically sized variables, only fixed size, but this can be changed at compiled time with a define
5  relies on Delphi mode for implicit operator overloading

I would welcome all criticism & comments, from anyone who has an interest in programming with big integers. I would especially welcome suggestions from speed freaks on how to make the code run faster   :D


I am. Where can it be found?

Also there is a unit with flexible data length, allowing practically as long integers as much memory you have.
It has a very limited floating point support as well.
It can handle any base from 2 to 16, most of the formatting used out there.

Would be interested to compare the functionality.

Check this:


--- Quote from: ad1mt on November 08, 2023, 06:44:44 pm ---7  unlicensed/public domain, I'm happy to give it away free of any restrictions

--- End quote ---

I love the spirit of that statement but in practice, its a problem. The Linux distributions, for example, will not permit code that does not have an acceptable open license.  If they don't see a license that they recognise and has been declared suitable, they need to refer to the lawyers and we all know what that means.

I stamp my code with The-Clear-BSD-License - its pretty liberal but not completely. See

Just put a file in there called copyright and have the text -

Files: *
Copyright: 2017-2023 Your Name <>
License: The-Clear-BSD-License

EDIT: stating the bleeding obvious, you would change the names to yours ....

You probably could and should stamp that on each file but its enough.

Keep up the good work !


Or LGPL v2, so Lazarus/fpc users can use it without any problems for their programs.


I do often use the Unlicense.


[0] Message Index

[#] Next page

Go to full version