1
$\begingroup$

Is the Hilbert envelope (analytic signal) feasible to be calculated in audio frames/blocks in real-time, when using FFT with windowing.

What I'm specifically concerned with is that how does it not create or not be able to create discontinuities (in the end points) between successive frames?

$\endgroup$
2
  • $\begingroup$ What do you mean by "real-time"? What is the bandwidth required? The lower the frequency response required, the longer the block size needed to window the transform filter(s) and not have circular or significant windowing artifacts. This adds latency. $\endgroup$
    – hotpaw2
    Commented Jul 27, 2015 at 20:18
  • $\begingroup$ That the algorithm producing the transform is not too slow for e.g. real-time audio use. $\endgroup$
    – mavavilj
    Commented Jul 27, 2015 at 20:31

1 Answer 1

2
$\begingroup$

As with most things in Engineering the answer is "depends on your requirements". In general you can't do a perfect Hilbert transform unless the signal is strictly periodic (see http://andrewduncan.net/air/ ). Since you can't do perfect you need to define what's good enough for your particular application.

For most typically audio applications, that it's pretty straight forward. The Hilbert transform can be represented as a simple linear time invariant filter. Unfortunately the impulse response infinite and non-causal. For an FIR implementation you need to truncate and delay it. The larger your truncation window and your delay the more precise it will be, however it will also become more expensive computationally and the latency goes up.

If your application requires a really long filter (typically when you need high precision at very low frequencies) than FFT can be useful in an overlap add configuration.

If you just care about relative phase and not absolute phase you can run the signal through a set of differential allpass filters, which is a very efficient way of implementing a band limited 90 degree phase shift.

You can also use advanced filter design methods (least square, Parks McLellan etc.) to optimize any Hilbert approximation for your specific requirements.

$\endgroup$
4
  • 1
    $\begingroup$ Could you clarify why'd one want a "band limited 90 degree phase shift"? I thought the Hilbert envelope does full-bandwidth envelope tracking (although of course it can be applied to bandlimited signals as well). But I just don't see where the applications of bandlimited Hilbert envelope are. $\endgroup$
    – mavavilj
    Commented Jul 27, 2015 at 12:37
  • $\begingroup$ Also what's the "simple linear time invariant filter" you're referring to? $\endgroup$
    – mavavilj
    Commented Jul 27, 2015 at 12:40
  • 1
    $\begingroup$ Hilbert transform is only a good choice for envelope detection if the signal is fairly narrow band. For audio it typically doesn't work well. $\endgroup$
    – Hilmar
    Commented Jul 27, 2015 at 15:14
  • 1
    $\begingroup$ The Hilbert transform is a linear operator, i.e. it can be describe with a transfer function and/or an impulse response and can be implemented as a normal filtering operation. In the frequency domain the Hilbert transformer has unit magnitude and 90 degree phase. That's basically what a Hilbert transformer is: a filter that shifts phase by 90 degrees for all frequencies $\endgroup$
    – Hilmar
    Commented Jul 27, 2015 at 15:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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