[comp.lang.misc] Bignums, Rationals, Incremental gaussian elimination & simplex

bimandre@saturnus.cs.kuleuven.ac.be (Andre Marien) (02/04/91)

Hello,

I am looking for information on the following topics, and I do not
really know to which newsgroup to limit this message, I send it to a
few of them:

- Infinite Precision Arithmetic (i.e. bignums, rationals and others):
   * Bibliographic references (I am looking for something more recent
     and/or advanced that the volume 2 of D. Knuth book "Seminumerical
     Algorithms" which already contains a great deal of basic material
     on the subject).
   * Packages (any information on existing routines, their
     availability (cost, where, etc.), experience with them would be
     welcome).
   * Hardware assistance (Co-processors specialised to support
     infinite precision arithmetic).

- Algorithms to solve sets of linear equations (=) and inequations (<,
  <=, >, >=) in an INCREMENTAL way.

  The basic stuff for that is obviously gaussian elimination and the
  simplex algorithm but I am faced with the additional constraint that
  the resolution procedure must be incremental, i.e. equations and/or
  inequations can be added AND removed easily. I am looking for
  procedure(s) to check that a set of equations/inequations remains
  solvable (i.e. the set of solutions remains non-empty) whenever a
  new equation or inequation is added to a solvable set.

  The critical point is that adding/removing equations/inequations
  should involve as little overhead as possible.

  Any clue, bibliographic reference ?

Thanks in advance for any help.

Pierre-Joseph GAILLY		E-Mail: pjg@sunbim.be
B.I.M.-Zaventem			Phone : + 32 2 759 59 25 (Bim general)
Leuvensesteeweg 510,		      : + 32 2 719 26 11 (Bim Zaventem)
B-1930 Zaventem			Fax   : + 32 2 725 47 83
Belgique / Belgium

      

bothner@sevenlayer.cs.wisc.edu (Per Bothner) (02/07/91)

In article <1722@n-kulcs.cs.kuleuven.ac.be>, bimandre@saturnus.cs.kuleuven.ac.be (Andre Marien) writes:
>- Infinite Precision Arithmetic (i.e. bignums, rationals and others):
>   * Packages (any information on existing routines, their
>     availability (cost, where, etc.), experience with them would be
>     welcome).

I've been using the Bignum package from DEC's Paris Research Lab.
It has efficient assembler primitives for a number of machines,
and generic C routines for other routines, so you get the best
(more or less) of efficiency and portability. Its primitives
implemenent unsigned arithmetic; on top of that there is a
library that implements signed-magnitude integers (I don't
use the latter).

To get it, either send mail to:
	librarian@decprl.dec.com
or ftp it from sevenlayer.cs.wisc.edu:pub/bignum.tar.Z.
The latter version includes an improved Makefile I wrote
that automatically selects the correct version to compile.

I have a set of C++ classes and routines that implement
generic arithmetic, including two's complement integers
(which gives compatibility with Common Lisp), fractions,
double floats, and complex numbers. It is by no means
"complete", but most of the non-trivial rational and
integer routines are implemented.

The code is in sevenlayer.cs.wis.edu:pub/gennum.[Ch].
Please let me know if you use this code, or improve it.
-- 
	--Per Bothner
bothner@cs.wisc.edu Computer Sciences Dept, U. of Wisconsin-Madison