Monthly Archives: January 2015

How To Install the GMP Library on Ubuntu

how to install gmp ubuntu

In my Data Structures and Algorithms II class (more like Algorithms and Algorithms class), our professor assigned us to write a RSA encryption program to complement our coursework on modular arithmetic and primality testing. Because we needed large numbers (1024 bits) which would absolutely not fit inside normal primitive data types, we were suggested to use the GMP library for C++, or BigInteger for Java. Being a C++ guy, I choose GMP. Now, what I found out while writing this lab was that installing GMP was actually harder than writing the program! To cut to the chase, here is how to download and install GMP onto your Ubuntu system. This …

Continue reading

Posted in C++, Programming.