Mister Exam

Other calculators

Integral of xcos(npix/2) dx

Limits of integration:

from to
v

The graph:

from to

Piecewise:

The solution

You have entered [src]
  2                 
  /                 
 |                  
 |       /n*pi*x\   
 |  x*cos|------| dx
 |       \  2   /   
 |                  
/                   
0                   
$$\int\limits_{0}^{2} x \cos{\left(\frac{\pi n x}{2} \right)}\, dx$$
The answer (Indefinite) [src]
                          //                 2                           \                                
                          ||                x                            |                                
                          ||                --                  for n = 0|                                
                          ||                2                            |                                
  /                       ||                                             |     //      x        for n = 0\
 |                        ||  //      /pi*n*x\               \           |     ||                        |
 |      /n*pi*x\          ||  ||-2*cos|------|               |           |     ||     /pi*n*x\           |
 | x*cos|------| dx = C - |<  ||      \  2   /               |           | + x*|<2*sin|------|           |
 |      \  2   /          ||2*|<--------------  for pi*n != 0|           |     ||     \  2   /           |
 |                        ||  ||     pi*n                    |           |     ||-------------  otherwise|
/                         ||  ||                             |           |     \\     pi*n               /
                          ||  \\      0           otherwise  /           |                                
                          ||----------------------------------  otherwise|                                
                          ||               pi*n                          |                                
                          \\                                             /                                
$${{4\,\left({{n\,\pi\,x\,\sin \left({{n\,\pi\,x}\over{2}}\right) }\over{2}}+\cos \left({{n\,\pi\,x}\over{2}}\right)\right)}\over{n^2 \,\pi^2}}$$
The answer [src]
/    4      4*sin(pi*n)   4*cos(pi*n)                                  
|- ------ + ----------- + -----------  for And(n > -oo, n < oo, n != 0)
|    2  2       pi*n           2  2                                    
<  pi *n                     pi *n                                     
|                                                                      
|                 2                               otherwise            
\                                                                      
$${{4\,n\,\pi\,\sin \left(n\,\pi\right)+4\,\cos \left(n\,\pi\right) }\over{n^2\,\pi^2}}-{{4}\over{n^2\,\pi^2}}$$
=
=
/    4      4*sin(pi*n)   4*cos(pi*n)                                  
|- ------ + ----------- + -----------  for And(n > -oo, n < oo, n != 0)
|    2  2       pi*n           2  2                                    
<  pi *n                     pi *n                                     
|                                                                      
|                 2                               otherwise            
\                                                                      
$$\begin{cases} \frac{4 \sin{\left(\pi n \right)}}{\pi n} + \frac{4 \cos{\left(\pi n \right)}}{\pi^{2} n^{2}} - \frac{4}{\pi^{2} n^{2}} & \text{for}\: n > -\infty \wedge n < \infty \wedge n \neq 0 \\2 & \text{otherwise} \end{cases}$$

    Use the examples entering the upper and lower limits of integration.