Информационный сервер для программистов: Исходники со всего света. Паскальные исходники со всего света
  Powered by Поисковый сервер Яndex: Найдется ВСЁ!
На Главную Исходники Форум Информер Страны мира
   Математика    >>    tinfint
   
 
 tInfInt - Unlimited Integers Arithmetic Object   Christian Sperr 23.07.1993

Модуль для работы с ОЧЕНЬ БОЛЬШИМИ целыми числами. В качестве примера приведены программы для решения уравнения Пэлла abs(x*x - n*y*y)=1 и вычисления чисел Бернулли.
Sometimes it is necessary to do arithmetic with integer numbers that are much bigger than the numbers a ordinary "integer" or "longint" variable can hold, and one has to keep even the last decimal, so using reals is not a solution. The "TInfint" object soves this problem by defining an integer with a size that is only limited by the available heap space.



14k 
 

{****************************************************************} {* INFINT.DOC } {****************************************************************} Arithmetic with integers of (almost) unlimited size. {****************************************************************} The file INFINT.ZIP contains the following files : - INFINT.DOC This File - INFINT.PAS BP 7 Source of the TInfInt Object. - PELL2.PAS Demo program, that solves Pell's equation abs(x*x - n*y*y)=1 - BERNZAHL.PAS Demo Program, that calculates Bernoulli-numbers. The Problem ----------- Sometimes it is necessary to do arithmetic with integer numbers that are much bigger than the numbers a ordinary "integer" or "longint" variable can hold, and one has to keep even the last decimal, so using reals is not a solution. The "TInfint" object soves this problem by defining an integer with a size that is only limited by the available heap space. (under DPMI this can be a lot). I wrote the first version of this "library" in 1987 in a work to get my diploma in mathematics in Turbo Pascal 3.0. Now I revised it to use the advantages of BP 7. Copyrights, disclaimer and warnings ----------------------------------- The copyright of the programs and the INFINT Unit are held by the author. There is n