Have you ever thought to outsource your program's mathematical processes? Mathematica provides MathLink, which allows Mathematica programs to communicate with external programs or vice versa. MathLink can be used with programs written in C, Java, or other languages.