I'm trying to run the following sample in sympy
import sympy as sp
from sympy.parsing.sympy_parser import parse_expr
n, L, x = sp.symbols('n L x')
sp.integrate(sp.cos(sp.pi*x/L)**2, (x, -L/2, L/2))
For some reason, it does not actually solve this integral. It just prints out the original integral.
>>> sp.integrate(sp.cos(sp.pi*x/L)**2, (x, -L/2, L/2))
L
-
2
/
|
| 2/pi*x\
| cos |----| dx
| \ L /
|
/
-L
---
2