## RNS APAL™

RNS-APAL™ is the world’s first arbitrary precision RNS library!  What makes RNS-APAL™ different is that digital computation is performed using the residue number system.

Get hands on experience in general purpose computation using the residue number system (RNS).  MaiTRIX has released this basic yet impressive code base to the public!

What is an arbitrary precision arithmetic library?

Mechanical Model of Modular RNS Counter

Arbitrary precision numbers can be as large or as precise as one wishes, while an arithmetic library provides the routines that perform arithmetic operations on these large numbers.  One example of an arbitrary precision library is the GNU Multiple Precision Arithmetic Library called GMP.

But GMP is a library taking advantage of a fixed-radix number system, such as binary or decimal.  In practice, these libraries will typically use a radix that is a power of two, such as 65,536 (i.e., 216); this means the “digits” are 16-bits wide.  This allows the library to make the best use of the host computer word size.  But regardless of the radix chosen, these libraries suffer from needing to perform carry from digit to digit for most all arithmetic operations.

RNS-APAL™ is different.  It performs arbitrary precision arithmetic and computation without carry from digit to digit.  While it still represents “digital arithmetic”, it’s entirely different than what we’ve been taught since grade school!  Furthermore, RNS-APAL™ is significantly advanced over prior art RNS research.  MaiTRIX has pioneered many techniques that allows general purpose computation to be performed and exploited using residue arithmetic.  These advances are so new and ground-breaking that a new field of arithmetic has been born, and it’s called modular computation!

Why an arbitrary precision RNS library?

The RNS APAL source code models many of the techniques disclosed in our various patents and papers. The code helps disclose basic math operations such as fractional multiplication and integer division by providing actual source code and working examples. RNS ALU operation and general-purpose computation using the residue number system is therefore explained without reading patents and complex professional papers.

RNS-APAL now on GitHub!