tags:

views:

246

answers:

2

I installed gmpy-1.11rc1.win32-py2.6.exe, but can't figure out how to use it, I can see some exported functions like mpz, mpq, mpf, etc., but how do I call a function like mpz_probab_prime_p() in GNU MP C library?

I looked at gmpy on Google Code, but still can't figure out. I couldn't find gmpy's documentation anywhere either. Thanks.

+2  A: 

You can find the docs here.

jbochi
+2  A: 

For now the txt file jbochi mentions is all there is -- and unfortunately it's not structured in the terms the OP requires, i.e., showing what underlying GMP functions are used in each gmpy-exposed function or method. If you're a GMP expert you can search the gmpy code here -- specifically in this file, which implements MPZ functionality, you'll see the call you seek at line 1538 (within the is_prime function/method).

I did recently acquire site gmpy.org with the idea of developing better online docs, but haven't gotten started yet (of course I could equally well use the wiki pages at gmpy's google code hosting site) -- as always in open source, volunteers are welcome!-)

Alex Martelli