pi / | | 2 | x *cos(n*x) dx | / -pi
Integral(x^2*cos(n*x), (x, -pi, pi))
// 3 \ || x | || -- for n = 0| || 3 | / || | | ||/sin(n*x) x*cos(n*x) | // x for n = 0\ | 2 |||-------- - ---------- for n != 0 | 2 || | | x *cos(n*x) dx = C - 2*|<| 2 n | + x *|
/ 2 | 4*sin(pi*n) 2*pi *sin(pi*n) 4*pi*cos(pi*n) |- ----------- + --------------- + -------------- for And(n > -oo, n < oo, n != 0) | 3 n 2 | n n < | 3 | 2*pi | ----- otherwise | 3 \
=
/ 2 | 4*sin(pi*n) 2*pi *sin(pi*n) 4*pi*cos(pi*n) |- ----------- + --------------- + -------------- for And(n > -oo, n < oo, n != 0) | 3 n 2 | n n < | 3 | 2*pi | ----- otherwise | 3 \
Use the examples entering the upper and lower limits of integration.