1
$\begingroup$

Is Hilbert transform not defined for complex signals? In MATLAB, the function hilbert ignores if you give a complex sequence as input. Why?

$\endgroup$
4
$\begingroup$

The Hilbert transform can be applied to complex functions of a real variable. E.g., the Hilbert transform of the complex exponential $e^{j\omega_0t}$, $\omega_0>0$, is given by

$$\mathcal{H}\{e^{j\omega_0t}\}=-je^{j\omega_0t},\qquad\omega_0>0$$

The problem you encounter has to do with Matlab's implementation of the function hilbert.m. It is designed for real-valued input sequences and it will ignore any imaginary part. Note that despite its name this function does not simply return the Hilbert transform of the input vector, but it computes the corresponding analytic signal, i.e. it returns a complex vector, the real part of which is equal to the input vector, and the imaginary part of which is the Hilbert transform of the input vector.

So if for whatever reason you want to compute the Hilbert transform of a complex vector, you need to do the following:

x = ...    % some complex vector
xr = real(x);
xi = imag(x);
xr_ = imag(hilbert(xr));    % Hilbert transform of real part
xi_ = imag(hilbert(xi));    % Hilbert transform of imaginary part
x_ = xr_ + 1i * xi_;        % Hilbert transform of complex vector x
$\endgroup$
  • $\begingroup$ That is a complete and superb answer. Thanks. @Matt L $\endgroup$ – Seetha Rama Raju Sanapala Mar 6 '16 at 18:23
  • $\begingroup$ @SeethaRamaRaju: You're welcome! Good to know that it was helpful. $\endgroup$ – Matt L. Mar 6 '16 at 18:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.