Hi I'm having some difficulty and a lot of uncertainty trying to use residue theory to compute real integrals. I really hope someone can help me.

The question is:

Use residue theory to compute each of the following real integrals (I attached the integrals in .doc format hope it works) :

maths integration.doc

For those who would prefer not to download the attachment the integrals are as follows:

The integral of xdx/[(x^2+9)(x^2+1)] from -infinity to infinity

The integral of 2sin(theta)/[5-4cos(theta)] from 0 to 2pi

The integral of cos(pi*x)/(x^2-2x+2) from -infinity to infinity

My attempts:

For the first one i started by setting z=x where (-R<=x<=R) and found that the singularities above the x axis are z=3i and z=i I then found the residues at the singularities to be -1/16 and 1/16 and adding them together yields zero also the integral of f(z) around the semicircle above the real axis with radius R is zero so the integral is equal to zero. Is this correct?Is this possible or does this tell us the the improper integral does not exist?help please.

For the second integral I substituted sin(theta)=(z-z^-1)/2i ;cos(theta)=(z+z^-1)/2 and d(theta)=dz/iz I then simplified the integral and found the singularities to be at z=0 z=-2 an z=-1/2. I didn't use x=-2 because it is not on the unit circle. I then found the residues to be 1/2 and -3/10 and the integral equal to [2(pi)i]/5 but the answer to a real integral cannot have an imaginary i in it can it?I've gone over the calculations but I can't seem to find where I've gone wrong.Any help would be great.

For the third one I found the singularity lying above the real axis to be z=1+i I then went to substitute for cos[(pi)(x)]=(z^pi+z^-pi)/2 and I'm stuck there I don't know where to go from here or how to combine the two methods used in the previous two questions to deal with this one.Once again any help would be greatly appreciated.

Thanks in advance.

I apologize for the extra question l won't put more than 2 at a time in the future.