[eigen] Arbitrary precision arithmetic support in Eigen

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


Hello Everyone!

First of all I would like to thank all the developers for the this beautifully designed and implemented library!
I've learned a lot looking over it.

I'm developer of C++ interface for the arbitrary precision floating point arithmetic library MPFR: http://www.holoborodko.com/pavel/?page_id=12.

During last year I've received couple of questions from the users on how to use my wrapper together with Eigen. There was discussion in KDE forum on the topic but it seems that not all problems were solved: http://forum.kde.org/viewtopic.php?f=74&t=43643.

Recently the most complete (hopefully:)) bridge for embedding mpreal type into Eigen was created.
Please check home page under "Software using MPFR C++" for header file mpreal_eigen.h:
http://www.holoborodko.com/pavel/?page_id=12.

So, now user can equip Eigen with arbitrary precision arithmetic by:
1. Installing  MPFR and GMP libraries.
2. Using MPFR C++ interface (mpreal.h, mpreal.cpp) along with header file mpreal_eigen.h
3. Using mpreal type (provided by MPFR C++) instead of built-in type double or float.

Precision (number of bits used for significant) can be setup globally by mpreal::set_default_prec().
For instance double has only 53 bits precision with machine epsilon 1e-16 (maximum 16 correct digits).
Using mpreal user can do calculations with any precision, e.g. 1024 bits with machine epsilon 1e-309 (309 correct digits).

I would appreciate if someone who intensively use/develop Eigen would test how MPFR C++ works with Eigen.

Any suggestions for improvement, test reports, etc.  are very very welcome.

Also I would appreciate if Eigen webpage or documentation will reference such possibility on using arbitrary precision arithmetic.
I think, this option could be very useful for the users.

Besides reference on my site would give me huge support and motivation for further improvement.

All the best,

Pavel Holoborodko.
http://holoborodko.com/pavel/

P.S.
I'm planning to release new version of MPFR C++ soon based on _expression_ templates inspired by Eigen.



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/