large file support and exact division

On my machine (OS X 10.9.2/Python 3.4.0 from Homebrew) the script did
not work with a large (> 4GB dump).

The scripts were modified to use mmap instead of reading the whole file
into memory.

Another small patch was needed to fix a division. n/p =  q returned even
results, which was odd. Using gmpy for this division fixes this on my
machine.