How do I find the Hilbert transform (qudrature) of a discrete signal by convolution with a Hilbert kernel? Given a discrete real signal $ f_{re}(t) $ the (complex) analytic signal is given by:
$ x(t) = f_{re}(t) + j*f_{im}(t) $.
I want to calculate $f_{im}(t)$: the quadrature by convolving with a Hilbert kernel of size 2*n+1:
$f_{im}(t) = H*f_{re}(t)$
$H=[H_{-n},H_{-n+1},..,H_0,H_{n-1},H_n]$
According to &quot;Complex seismic trace analysis&quot;,M. T. Taner*, F. Koehler*, and R. E. Sheriff;
$ H_i = 2*sin^2(\pi i/2)/(\pi i), H_0 = 0$
for $ n = \infty $.
I want to use a finite length kernel, e.g. n=16.
Do I need to taper the kernel from the equation above with a window?
How do I normalize the odd (antisymmetric) result kernel?
Am I right in assuming that calculating the quadrature by convolving with H introduces a smoothing?
If so; should I also smooth the real signal, e.g. by a gaussian kernel of size 2n+1?
EDIT:
In Matlab there is a function called &quot;firpm&quot; that creates a &quot;Parks-McClellan optimal equiripple FIR filter&quot;.
It seems this is generally considered the &quot;optimal&quot; FIR approximation to an IIR?
Does this mean that using the simple coefficient equation from &quot;Complex seismic trace analysis&quot; is too simplistic?
EDIT2:
regarding the normalization: I tested in Matlab and found that convolving with a kernel calculated from the simple coefficient equation gave good results in the case of the input signal being a sine. However I had to divide by a factor m to get correct normalization:
H5 = [-0.0000   -0.6366  0    0.6366    0.0000]: m = 0.1271
H7 = [-0.2122 -0.0000 -0.6366  0  0.6366 0.0000 0.2122]: m=0.2525 

What is the general formulae for m?
EDIT 3:
The ideal kernel would have constant magnitude response. However it seems that since my kernel will be of finite size; it will act as an bandpass filter, and therefore I need to look out for bandpass ripple.
The solution seems to be a magnitude response that rolls of gently at the low and high frequencies. The &quot;simple coefficient equation&quot; is quite good in this respect; it does not introduce a lot of ripple, instead the shorter the kernel the earlier it starts rolling off. As an example here is the 19 point kernel:

In comparison the 19 point kernel from Matlabs firpm does not roll of at high frequencies (!?) but otherwise have roughly the same amount of ripple as my simple kernel:

My conclusion so far thus seem to be: no the &quot;simple coefficient equation&quot; gives a good approximation to the optimal FIR for the Hilbert convolution operator. The &quot;Parks-McClellan optimal equiripple FIR filter&quot; might be slightly more &quot;optimal&quot; but the difference is neglible, at least for reasonably large kernels (say 19 points and upwards). Anything I am forgetting? I will therefore move on with this approach. Only remaining problem: how do I normalize?
The short answer: with a finite convolution you can't calculate the Hilbert transform exactly.

The long answer: You will have to make approximations and decide what types and amounts of error you can live with. This will depend heavily on the application, the signals itself and what you are trying to do with the results. This paper may give good guidance on math and potential trade offs http://www.andrewduncan.ws/air/index.html

Per se, the Hilbert Transform is not a smoothing operation. For example the HT of a cosine is a sine, which isn't any smoother.