I am working on some sample program and trying to use matrix functionalities offered by Eigen3 library. I want to store high precision integer variable(mpz_t) in a (100,100) matrix. For storing integer, there is already inbuilt data type MatrixXd. Similarly, just wanted it for high precision variables. Please share some advices.
Thanks.
Basically, all you need to do is declare a
Matrix<mpz_class,Dynamic,Dynamic>
matrix. Thempz_class
type is a c++ wrapper aroundmpz_t
such that it behaves like any scalar type.Here is an example: