I have heard that Sage is probably the best program there is for two subjects, number theory and graph theory. See this question on a Sage specific forum, with exact quote from the answer by kcrisman:
"If you are doing graph theory or serious number theory, you shouldn't even be asking the question of which package to use."
In other words. If you are doing graph theory or serious number theory, there is no question that Sage is the best.
It is open source and has many other open source programs built in. It's free, which is much better than Maple or Mathematica. It also uses Python which is a main-stream language so as you work in you are developing a skill that is helpful in other places. You can easily program new functions if you like, and can even contribute them to future versions of Sage if you want.
Here is an algebraic number theory book and elementary number theory book written by the creator of Sage. Both books have Sage code in them. Here is a cryptography book with a Sage appendix.