Hi there. I'm starting with the Fourier transforms, and I'm having some trouble with my first exercise on this topic.

The problem says: Given $\displaystyle f(x)=H(x)-H(x-l)$ (H(x) is the Heaviside unit step function).

a) Consider the odd extension for f and find its Fourier integral representation.

b) Using the previous incise calculate the value for $\displaystyle \int_0^{\infty}\frac{1-cos (\omega l)}{\omega}\sin (\omega l) d\omega$

Well, for a) I think I should get the fourier transfor for the sign function, I don't know if this is right, but anyway I've defined the function like this:

$\displaystyle g(x)=\begin{Bmatrix}{ 0}&\mbox{ if }& x>l\\1 & \mbox{if}& 0<x<l\\-1 & \mbox{if}& -l<x<0\\0 & \mbox{if}& x<-l\end{matrix}$

Then the Fourier integral representation:

$\displaystyle g(x)=\displaystyle\frac{1}{2\pi}\displaystyle\int_ {-\infty}^{\infty}\displaystyle\int_{-\infty}^{\infty}g(x)e^{-i \omega x}dx e^{i \omega x}d\omega$

But g(x) is odd, then:

$\displaystyle g(x)=\displaystyle\frac{1}{2\pi}\displaystyle\int_ {-\infty}^{\infty} 2 \displaystyle\int_{0}^{\infty}g(x)(-i)\sin(\omega x)}dx e^{i \omega x}d\omega=\displaystyle\frac{-i}{\pi}\displaystyle\int_{-\infty}^{\infty}\displaystyle\int_{0}^{\infty}g(x) \sin(\omega x)}dx e^{i \omega x}d\omega=\displaystyle\frac{-i}{\pi}\displaystyle\int_{-\infty}^{\infty} \left ( \displaystyle\int_{0}^{\infty} \sin(\omega x)}dx - \displaystyle\int_{-\infty}^{0} \sin(\omega x)}dx\right ) e^{i \omega x}d\omega=\displaystyle\frac{-i}{\pi}\displaystyle\int_{-\infty}^{\infty} \left ( \cos(\omega x)} |_0^{\infty} - \cos(\omega x)}|_{-\infty}^{0} \right ) e^{i \omega x}d\omega=\displaystyle\frac{-i}{\pi}\displaystyle\int_{-\infty}^{\infty} \left ( \frac{2}{\omega}-\displaystyle\lim_{c \to{+}\infty}{}\cos{\omega c}-\displaystyle\lim_{c \to{-}\infty}{}\cos{\omega c}}\right ) e^{i \omega x}d\omega$

And the thing is that the integral for the cosine diverges as I see it, but I'm probably doing something wrong.

Help please