Ask Your Question
0

Import GMP library

asked 2011-10-11 20:37:36 +0200

wassim gravatar image

I have already installed the GMP library, Now i want to import this library to sage project i tried to put :

  import libgmpxx.so.4

  libgmpxx.so.4.path.append('usr/local/lib/')

but it does'nt work unfortunately, how can i do that. regards

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
2

answered 2011-10-12 02:17:17 +0200

Jason Grout gravatar image

What are you trying to do with the library? You can't import it like that, but you can interact with it as a C library using Cython. You'd have to "cimport" a specific function from the gmp header files.

Sage comes with MPIR (a fork of GMP) and uses that to implement the RealNumbers.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-10-11 20:37:36 +0200

Seen: 665 times

Last updated: Oct 12 '11