SymPy is a symbolic manipulation package, written in pure Python. Its aim is to become a full featured CAS in Python, while keeping the code as simple as possible in order to be comprehensible and easily extensible.
Homepage: http://sympy.org/
Source Code: http://github.com/sympy/sympy
Mailing list: https://groups.google.com/forum/?fromgroups#!forum/sympy
Examples
>>> from sympy import *
>>> x, y, z, t = symbols('x y z t')
>>> k, m, n = symbols('k m n', integer=True)>>> integrate(exp(x)*x**2, x) â 2 â x âx - 2â x + 2â â â¯
>>> expand((x + y)**3)
3 2 2 3
x + 3â
x â
y + 3â
xâ
y + y
>>> factor(_)
3
(x + y)>>> Sum((-1)**n*x**n/factorial(n), (n, 0, oo)) â ____ â² â² n n â² (-1) â x â± ââââââââ â± n! â± â¾â¾â¾â¾ n = 0 >>> _.doit() -x â¯
