Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-27 Thread Olli Niemitalo
Sampo, it is not the poles and zeros that alternate on the real line but
the poles of the two all-pass filter paths. The 90 deg phase difference
band is almost from 0 to Nyquist. In my filter pair they are from 0.001 pi
to 0.999 pi. On z-plane those corner frequencies are at (0.95, 0.003)
and (-0.95, 0.003) so any elliptic or similar function would connect
the two corner frequencies roughly via the real line.

-olli

On Thu, Feb 9, 2017 at 2:57 PM, Sampo Syreeni  wrote:

>
> As I said above, I'm questioning Olli's analysis from a highly
> intuitionistic viewpoint. Typically I'd then be wrong, while Olli does his
> math and can show me to be so. But still, I have to ask. :)
>
> --
> Sampo Syreeni, aka decoy - de...@iki.fi, http://decoy.iki.fi/front
> +358-40-3255353, 025E D175 ABE5 027C 9494 EEB0 E090 8BA9 0509 85C2
> ___
> dupswapdrop: music-dsp mailing list
> music-dsp@music.columbia.edu
> https://lists.columbia.edu/mailman/listinfo/music-dsp
>
>
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread Ethan Duni
> how do you quadrature modulate without Hilbert filters?
>

Perhaps I'm using the wrong term - the operation in question is just the
multiplication of a signal by e^jwn. Or, equivalently, multiplying the real
part by cos(wn) and the imaginary part by sin(wn) - a pair of "quadrature
oscillators."


> i think you can calculate how much energy exists at the negative
> frequencies and that comes out to be an error image signal that also gets
> modulated up or down along with the image you want.
>

Right, to the extent that the LPF fails to completely block the negative
frequencies, they remain as error images and show up in the output. However
it seems easier to track this in the Weaver case, since this error is given
directly by the suppression characteristic of the LPF, rather than via
in-band phase cancellation as in the Hartley/Hilbert case.

My thinking is that the Weaver modulator gets a direct benefit from
oversampling, since the error images get moved further and further out into
the stopband of the LPFs (easing their design constraints), whereas the
Hartley approach does not, since it is stuck trying to maintain a phase
relationship across the signal band, no matter how much it is oversampled.

> i'm looking at the diagram and i think that's how my old Heathkit HW-100
> did it where the image rejection was done with
> piezo-electric-crystal-lattice filters which are BPFs (not LPFs) with
> bad-ass selectivity on both sides.
>

This sound like a third, related method (apparently called the Bandpass
Method). Weaver is kind of the same underlying idea, but it down-modulates
the signal first so that the filter can be done at baseband (as an LPF)
instead of doing it directly on the high frequency signal (then you need a
BPF with tight bandwidth and high center frequency, which is expensive).
The downside is an extra modulator is needed.

E
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread robert bristow-johnson







 Original Message 

Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

From: "Ethan Duni" 

Date: Thu, February 9, 2017 5:06 pm

To: "A discussion list for music-related DSP" 

--



> On Tue, Feb 7, 2017 at 6:49 AM, Ethan Fenn  wrote:

>

>> So I guess the general idea with these frequency shifters is something

>> like:

>>

>> pre-filter -> generate Hilbert pair -> multiply by e^iwt -> take the real

>> part

>>

>> Am I getting that right?

>>

>

> Exactly, this is a single sideband modulation technique, specifically

> called the Hartley Modulator.

>

> I wonder if anyone has compared to the Weaver Modulator approach? That one

> works like this:

>

> input -> quadrature modulate to center image on DC -> (complex) LPF ->

> quadrature modulate back up to desired frequency -> take the real part

>

> Obviously this approach requires two quadrature modulators instead of one,

> and two (real) LPFs instead of one Hilbert transformer. On the other hand,

> LPFs are easier to deal with than Hilbert filters
how do you quadrature modulate without Hilbert filters?
> - we aren't trying to�stick a huge phase transition right at DC,
as long as the difference is 90�. �but the phase difference does have to 
transition
from 90� to 0 (or 180�) at DC. �and most of the music is in the bottom 5 or 6 
octaves. i don't see how that spec is avoided.
> we can use any number of common
> design techniques/topologies, and we don't have the extra constraint of

> needing an allpass response.
well as long as the gains are well-matched and the phase difference is 
virtually 90� at the frequencies of interest, then you can use it for a 
frequency shifter. �but as those requirements are missed, i think you can 
calculate how much energy exists
at the negative frequencies and that comes out to be an error image signal that 
also gets modulated up or down along with the image you want.
> So it's not obvious to me that the two LPFs in
> Weaver aren't actually cheaper than the one Hilbert filter in Hartley, for

> equivalent performance.
i'm looking at the diagram and i think that's how my old Heathkit HW-100 did it 
where the image rejection was done with piezo-electric-crystal-lattice filters 
which are BPFs (not LPFs) with bad-ass selectivity on both sides. �i just 
thought that the sideband
separation filter was highpass for USB and lowpass for LSB and it was done at a 
higher IF frequency, but maybe i'm not remembering it right. �i remember that 
the baseband was supposed to be from 350 Hz to 2450 Hz (2.1 kHz bandwidth). i 
dunno what the IF frequency was but it would have to be
more than 3 kHz (it might have been dozens or hundreds of kHz, i don't 
remember). �and they used the same crystal-lattice filter for USB/LSB, but used 
two IF frequencies that were different by 2.8 kHz
i know the SSB modulator from SSB transceivers of the the 60s and earlier 
didn't have a
Hilbert transform FIR in it. but i forgot sorta how they did it back then. �so 
i gotta figure out how this Weaver works at baseband without the negative 
frequencies interfering. i think i'm beginning to grok it. �i think the 
intermediate signal spectrum is flipped upside-down and gets
flipped back again by the second modulator.
> Also the performance is easier to get a handle on, since the unwanted
> images are controlled directly by the LPFs, rather than relying on phase

> cancellation of in-band components in the image region. Moreover, the

> less-ideal parts of the filter response can be pushed up into the

> transition region (where there is presumably much less signal energy - or

> even effectively none if there is significant oversampling to allow

> headroom for frequency shifting), compared to the Hilbert approach which

> has to try to maintain the correct phase shift all the way across the

> signal band.
yes, it has to do that. �this ham-radio SSB throwback is starting to look more 
attractive than the analytic signal approach.


> Most of the comparisons I've found between Hartley and Weaver are from the

> analog radio domain, and the concerns mostly don't apply to a DSP context

> (things about DC coupling in the quadrature oscillators, building matched

> LPFs with tight tolerance, etc.). Any thoughts?

>
thanks, Ethan, for diverting the solution path a little.



--
r b-j � � � � � � � � �r...@audioimagination.com
"Imagination is more important than knowledge."
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread Ethan Duni
On Tue, Feb 7, 2017 at 6:49 AM, Ethan Fenn  wrote:

> So I guess the general idea with these frequency shifters is something
> like:
>
> pre-filter -> generate Hilbert pair -> multiply by e^iwt -> take the real
> part
>
> Am I getting that right?
>

Exactly, this is a single sideband modulation technique, specifically
called the Hartley Modulator.

I wonder if anyone has compared to the Weaver Modulator approach? That one
works like this:

input -> quadrature modulate to center image on DC -> (complex) LPF ->
quadrature modulate back up to desired frequency -> take the real part

Obviously this approach requires two quadrature modulators instead of one,
and two (real) LPFs instead of one Hilbert transformer. On the other hand,
LPFs are easier to deal with than Hilbert filters - we aren't trying to
stick a huge phase transition right at DC, we can use any number of common
design techniques/topologies, and we don't have the extra constraint of
needing an allpass response. So it's not obvious to me that the two LPFs in
Weaver aren't actually cheaper than the one Hilbert filter in Hartley, for
equivalent performance.

Also the performance is easier to get a handle on, since the unwanted
images are controlled directly by the LPFs, rather than relying on phase
cancellation of in-band components in the image region. Moreover, the
less-ideal parts of the filter response can be pushed up into the
transition region (where there is presumably much less signal energy - or
even effectively none if there is significant oversampling to allow
headroom for frequency shifting), compared to the Hilbert approach which
has to try to maintain the correct phase shift all the way across the
signal band.

Most of the comparisons I've found between Hartley and Weaver are from the
analog radio domain, and the concerns mostly don't apply to a DSP context
(things about DC coupling in the quadrature oscillators, building matched
LPFs with tight tolerance, etc.). Any thoughts?

E
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread gm



Am 09.02.2017 um 14:15 schrieb Theo Verelst:
The idea of estimating a single sine wave frequency, amplitude and 
phase with a short and easy as possible filter appeals to me though.
Did you listen to the example I posted? Do you think it's useful? Or too 
many artefacts?


___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread Sampo Syreeni

On 2017-02-07, Theo Verelst wrote:

Like with many transforms, I can't help but practically think that 
it's hard to make a tradeoff between the meaning of the results, such 
as [...]


Here there's an rather simple optimization criterion: a constant 45 
degree phase offset, or perhaps a pair of filters whose relative offset 
is very near to 45 degrees. This stuff isn't really used for sound 
synthesis per se, but as a low level primitive, to get high level 
interesting algorithms.


I like the idea of an IIR filter for frequency analysis, or a bank of 
them with dyadic structure,


Would they have the channels in order, or with half of them frequency 
inverted? What could they be used for?

--
Sampo Syreeni, aka decoy - de...@iki.fi, http://decoy.iki.fi/front
+358-40-3255353, 025E D175 ABE5 027C 9494 EEB0 E090 8BA9 0509 85C2
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread Theo Verelst
Thinking about it, I recall there was some from of transform used for frequency/time 
analysis for instance for radar problems (maybe books from before WWII, or more recent 
frequency/time analyzers) and without checking though it was in popular DSP speak 
something like the Hilbert transform, but it seems that's just about the idea of 
transforming repeating waveforms for the purpose of analyzing harmonics.


It's possible to make a decent short filter that convolutes with a random or prepared 
digital signal such as to create an indication of frequency. From that creating out of 
phase synthesized sine tones shouldn't be a problem either, though I think the accurate 
phase responses required for the binorals of the human hearing a very subtle and the 
inherent results coming from the quickly browsed limited Hilbert transform as the 
projection onto sine and cosine components seem nothing particularly suited to any effect 
I know of at the moment.


I repeat the main problem, unless you'd have prepared and limited the domain of input 
signals available and make credible you can do more accurate matching that way, is that 
unless you do significant upsampling or high frequency sampling, the signal, or it's 
integral usable for convolution  between the samples is only properly reconstructed by a 
long sinc interpolator. Any other filter, by mathematical incongruence and therefor 
strictly logically speaking incorrect, doesn't do a perfect job, no matter how long ou 
search for alternatives.


The idea of estimating a single sine wave frequency, amplitude and phase with a short and 
easy as possible filter appeals to me though. Either there's the possibility of tuning an 
interval to the wavelength, or using some form of filter that outputs an estimate.


T.
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread Sampo Syreeni

On 2017-02-06, Evan Balster wrote:

If there are zeroes on the unit circle in the z-plane, I don't think 
it will be a very good all-pass filter...


The basic thingy with Olli's design, and pretty much every all-pass 
filter -- which Hilbert transformers are -- is to balance poles and 
zeroes in the s-plane (continuous case) or the z-plane (the discrete 
one) so as to yield a transfer function approximating one in argument.


That kind of thing could be arrived at in quite a number of ways. 
Representing different means of approaching an optimum. Olli's 
Differential Evolution took both the zeroes and the poles onto the real 
line, and put them there alternately. I'm not too sure that is the 
optimum setup, because you can build Hilbert transformers from dense 
alternate pairs over other locuses as well.


As I said above, I'm questioning Olli's analysis from a highly 
intuitionistic viewpoint. Typically I'd then be wrong, while Olli does 
his math and can show me to be so. But still, I have to ask. :)

--
Sampo Syreeni, aka decoy - de...@iki.fi, http://decoy.iki.fi/front
+358-40-3255353, 025E D175 ABE5 027C 9494 EEB0 E090 8BA9 0509 85C2
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-09 Thread Sampo Syreeni

On 2017-02-06, robert bristow-johnson wrote:


[...] and analytic signal

     a(t)  =  x(t)  +  j y(t)
           =  g(t) cos(w t)  +  j g(t) sin(w t)
           =  g(t) e^(j w t)

the analytic envelope is

     |a(t)|  =  sqrt( x(t)^2  +  y(t)^2 )
             =  g(t)

so that works great for a single sinusoid.


Indeed. Originally the formula was derived for a single sinusoid. At the 
outset it's very much like you derive group delay from phase delay, 
given a single sinusoid.


However, the formula generalizes just as well. What you have there is a 
single complex sinusoid, with a gain function g(t) (ostensibly an 
exponentially decaying one). Leave that out, and you have a single 
complex sinusoid. Which you can then integrate over frequency to yield 
your typical Fourier transform, in the s-plane, or sum over the unit 
circle in the z-plane to yield the discrete version.


In either case, you have the complex version of Parseval's theorem 
backing you up. Now that we went to the Fourier domain, suddenly even 
those complex sums/integrals work out just fine, as (approximable) sums 
of complex exponentials (over a discrete basis, by the sampling theorem 
and such). Suddenly what you get for an arbitrary sum of exponentials, 
is something whose backwards transform's norm is by Parseval very much 
the same as you had before for a single frequency.


That is why Hilbert-transforms are used to get "instantaneous envelopes" 
even with wideband signals. Basically the pointwise modulus of a Fourier 
transform of an analytical signal does what you did above for a single 
frequency, a sinusoid, while the whole of the Fourier transform does it 
for all frequencies at the same time, and the finally by Parseval even 
the sum/integral actually, first locally but then by extension globally, 
guarantees that the modulus actually follows the whole signal envelope 
as well.


What fucks you up, then, is that a proper Hilbert transform which lets 
you access the analytical continuation of a real signal, is not only an 
acausal operator, but also one which converges rather slowly in (future) 
time. It does so in o(1/t) time/shift, just as the ideal sinc(x) 
interpolation function does; which is rather slow as it goes, especially 
in asymptote.


That then implies that if you try to do "instantaneous envelopes" using 
Hilbert transforms and the analytical signals they imply, you might seem 
to get "something for free". A better and more reactive estimator of 
envelopes. The theory is sound as well, because of what I said above 
about Parseval's theorem. It's just that there's *still* no free lunch: 
if you want to approximate an Hilbert transform pair for real, for any 
given accuracy you'll have to expend o(1/t) delay in order to derive an 
o(1^-at) accuracy class Hilbert transformer (or a pair).)


But once you toss in additional frequency components into x(t), then 
that creates high-frequency components into |a(t)|^2 that don't belong 
in any definition of envelope, no?


If you look at it that way, yes. But isn't that the very reason 
Parseval's theorem is so great? It actually deals away with this kind of 
stuff, and returns the whole deal towards first order analysis over a 
function space.



 what other meaning of "envelope" are you working with, Eric?


Finally, there are other meanings. The psychoacoustical ones in 
particular. Which I'm not too well versed with.

--
Sampo Syreeni, aka decoy - de...@iki.fi, http://decoy.iki.fi/front
+358-40-3255353, 025E D175 ABE5 027C 9494 EEB0 E090 8BA9 0509 85C2___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-07 Thread Risto Holopainen
Yes, there are lots of interesting things that can be done with
frequency shifting. Feedback suppression in a PA system by frequency
shifting was suggested by Manfred Schroeder a long time ago. I have
occasionally found it to be useful to broaden a mono signal by feeding
it through a hilbert transform pair, or actually any pair of allpass
filters. Very small frequency shifts produce slowly moving stereo
images. I have collected some sound examples (mostly using an analog
frequency shifter) here:

http://ristoid.net/modular/freqshift.html

The theoretical exposition is not aimed at readers on this list, but
maybe you can spot some errors.


Risto


Den 2017-02-07 kl. 18:35, skrev STEFFAN DIEDRICHSEN:
> A nice thing are the endless phase shifts, if you feed back a
> frequency shifter. It’s like a Shepard tone. 
> If you have Logic Pro or MainStage, try the RingShifter, it can do
> such tricks. It has 2x6 Allpass filters for the constant phase shift
> and a quadrature oscillator with FM and a delay. 
>
> Steffan 
>
>
>
>> On 07.02.2017|KW6, at 18:25, Eric Brombaugh > > wrote:
>>
>> That's the right idea. In fact if you multiply by e^iw you can get
>> arbitrary phase shifts to move the stereo image around subtly. For
>> this reason, most of the frequency shifters I've worked on have a
>> nonlinear response in the mapping of control voltage that gives fine
>> resolution near DC shift frequency so that you can dial in small
>> offsets for subtle phasing effects.
>>
>> Eric
>
>
>
> ___
> dupswapdrop: music-dsp mailing list
> music-dsp@music.columbia.edu
> https://lists.columbia.edu/mailman/listinfo/music-dsp

___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-07 Thread STEFFAN DIEDRICHSEN
A nice thing are the endless phase shifts, if you feed back a frequency 
shifter. It’s like a Shepard tone. 
If you have Logic Pro or MainStage, try the RingShifter, it can do such tricks. 
It has 2x6 Allpass filters for the constant phase shift and a quadrature 
oscillator with FM and a delay. 

Steffan 



> On 07.02.2017|KW6, at 18:25, Eric Brombaugh  wrote:
> 
> That's the right idea. In fact if you multiply by e^iw you can get arbitrary 
> phase shifts to move the stereo image around subtly. For this reason, most of 
> the frequency shifters I've worked on have a nonlinear response in the 
> mapping of control voltage that gives fine resolution near DC shift frequency 
> so that you can dial in small offsets for subtle phasing effects.
> 
> Eric

___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-07 Thread Eric Brombaugh

On 02/07/2017 07:49 AM, Ethan Fenn wrote:

So I guess the general idea with these frequency shifters is something like:

pre-filter -> generate Hilbert pair -> multiply by e^iwt -> take the
real part

Am I getting that right?

Now that I think about it, another application might be in stereo
imaging. Start with a mono signal, generate the Hilbert pair, feed one
to each ear. Now you've got a really wide image without changing the
sound much at all.


That's the right idea. In fact if you multiply by e^iw you can get 
arbitrary phase shifts to move the stereo image around subtly. For this 
reason, most of the frequency shifters I've worked on have a nonlinear 
response in the mapping of control voltage that gives fine resolution 
near DC shift frequency so that you can dial in small offsets for subtle 
phasing effects.


Eric


___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-07 Thread Ethan Fenn
So I guess the general idea with these frequency shifters is something like:

pre-filter -> generate Hilbert pair -> multiply by e^iwt -> take the real
part

Am I getting that right?

Now that I think about it, another application might be in stereo imaging.
Start with a mono signal, generate the Hilbert pair, feed one to each ear.
Now you've got a really wide image without changing the sound much at all.

-Ethan



On Tue, Feb 7, 2017 at 9:20 AM, Theo Verelst  wrote:

> Like with many transforms, I can't help but practically think that it's
> hard to make a tradeoff between the meaning of the results, such as
> frequency and amplitude, some rough estimate of the normally obtained
> accuracy (can you send a CD signal through the DSP stuff, invert back to
> audio samples and find the inverse transform still worth listening to ?),
> and whether you're going to get a measurement that sticks data to certain
> implicit vectors while believing all measurements are accurate.
>
> I like the idea of an IIR filter for frequency analysis, or a bank of them
> with dyadic structure, and some smart interpreter of the measurement
> results, or even an adaptive systematic to very accurately discern between
> frequency, time axis or envelope ("amplitude change", or maybe congruence
> with natural e-powers) from for instance an accurately recorded piano tone.
> It's hard to get as accurate as I would like when you  include signal
> reconstruction in the picture, maybe if you take relatively high sampling
> frequency.
>
> Theo V.
>
> ___
> dupswapdrop: music-dsp mailing list
> music-dsp@music.columbia.edu
> https://lists.columbia.edu/mailman/listinfo/music-dsp
>
>
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-07 Thread Theo Verelst
Like with many transforms, I can't help but practically think that it's hard to make a 
tradeoff between the meaning of the results, such as frequency and amplitude, some rough 
estimate of the normally obtained accuracy (can you send a CD signal through the DSP 
stuff, invert back to audio samples and find the inverse transform still worth listening 
to ?), and whether you're going to get a measurement that sticks data to certain implicit 
vectors while believing all measurements are accurate.


I like the idea of an IIR filter for frequency analysis, or a bank of them with dyadic 
structure, and some smart interpreter of the measurement results, or even an adaptive 
systematic to very accurately discern between frequency, time axis or envelope ("amplitude 
change", or maybe congruence with natural e-powers) from for instance an accurately 
recorded piano tone. It's hard to get as accurate as I would like when you  include signal 
reconstruction in the picture, maybe if you take relatively high sampling frequency.


Theo V.
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread Eric Brombaugh

On Feb 6, 2017, at 11:19 PM, robert bristow-johnson wrote:

> with a harmonic musical note this beat frequency would be the difference 
> between two harmonics, which could be any integer times the fundamental.  
> that's much faster than beating.  an r.m.s. envelope would be the square root 
> of the sum of squares of the amplitudes, g_n(t), of all of the harmonics.
> 

Yes - after I hit "send" I started thinking about that scenario and how the 
magnitude of an analytic signal synthesized from a real audio signal might end 
up with a mass of zero crossings that could really mess up the slower 
"perceived" envelope you're looking for in a musical situation. Audio and Comm 
are similar in so many ways and yet...

> thanks for the info on the dsPIC.

Sure - they're fun little machines and worth considering for low-end stuff. 
I've been doing more with STM32 ARM processors lately - they're faster, have 
decent floating point and are just as easy to use (and also cheap). Probably 
also worth a look...

Eric

___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread robert bristow-johnson

On 2/7/17 12:39 AM, Eric Brombaugh wrote:

On Feb 6, 2017, at 8:24 PM, robert bristow-johnson wrote:


On 02/05/2017 07:52 PM, robert bristow-johnson wrote:

I'm curious what aspects of a music make the complex magnitude of the

analytic signal inappropriate for estimating the envelope? In
communications signal processing we use this often, even for signals
that are fairly wide-band with respect to the sample rate and it seems
to work.
well, with a single sinusoid, there should be no intermodulation product
so the analytic envelope should be exactly correct. but consider:

 x(t) = g1(t) cos(w1 t) + g2(t) cos(w2 t)

which has for it's Hilbert

 y(t) = g1(t) sin(w1 t) + g2(t) sin(w2 t)

and analytic signal
 a(t) = x(t) + j y(t)

 a(t) = g1(t) cos(w1 t) + g2(t) cos(w2 t) + j( g1(t) sin(w1 t) + g2(t) 
sin(w2 t) )

 |a(t)|^2 = |g1(t)|^2 + |g2(t)|^2 + 2 g1(t) g2(t) cos( (w1-w2) t )
the last term on the right needs to be sorta filtered out with a LPF to
get the correct square of envelope, no?

Ah OK - you have a different definition of "envelope" than I do. That's fine.

i'm trying to be as inclusive in the definition of "envelope" as i can be.  
see, if you have a single sinusoid:

  x(t)  =  g(t) cos(w t)

and Hilbert transform

  y(t)  =  g(t) sin(w t)

and analytic signal

  a(t)  =  x(t)  +  j y(t)

=  g(t) cos(w t)  +  j g(t) sin(w t)

=  g(t) e^(j w t)

the analytic envelope is

  |a(t)|  =  sqrt( x(t)^2  +  y(t)^2 )

  =  g(t)


so that works great for a single sinusoid.  but once you toss in additional frequency 
components into x(t), then that creates high-frequency components into |a(t)|^2 that 
don't belong in any definition of envelope, no?  what other meaning of 
"envelope" are you working with, Eric?

I agree with all of your math. I don't agree that the

2 g1(t) g2(t) cos( (w1-w2) t )

term is not part of the square of the envelope.

If you have an analytic signal which is the sum of two complex exponentials as 
you described further above and the g1(t) and g2(t) terms are constant, then 
when you compute the magnitude of the sum you actually do see the result vary 
due to the beating of the two frequencies which is the frequency difference 
term you've proposed to discard. In the communications processing I've worked 
with that variation is a critical part of the envelope so using just the 
magnitude of the analytic signal is sufficient to define the envelope. Perhaps 
in audio processing this isn't the case and the filtering you describe is 
necessary.


good point.  if w1 and w1 are very close to each other, that 
cross-product term represents the "beating" of the two sinusoids and 
they certainly can be alternatively represented as part of an envelope 
of a *single* sinusoid of frequency (w1+w2)/2.


with a harmonic musical note this beat frequency would be the difference 
between two harmonics, which could be any integer times the 
fundamental.  that's much faster than beating.  an r.m.s. envelope would 
be the square root of the sum of squares of the amplitudes, g_n(t), of 
all of the harmonics.


thanks for the info on the dsPIC.

--

r b-j  r...@audioimagination.com

"Imagination is more important than knowledge."



___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread Eric Brombaugh

On Feb 6, 2017, at 8:24 PM, robert bristow-johnson wrote:

> > On 02/05/2017 07:52 PM, robert bristow-johnson wrote:
> >>
> >> > I'm curious what aspects of a music make the complex magnitude of the
> >> analytic signal inappropriate for estimating the envelope? In
> >> communications signal processing we use this often, even for signals
> >> that are fairly wide-band with respect to the sample rate and it seems
> >> to work.
> >> >
> >>
> >> well, with a single sinusoid, there should be no intermodulation product
> >> so the analytic envelope should be exactly correct. but consider:
> >>
> >> x(t) = g1(t) cos(w1 t) + g2(t) cos(w2 t)
> >>
> >> which has for it's Hilbert
> >>
> >> y(t) = g1(t) sin(w1 t) + g2(t) sin(w2 t)
> >>
> >> and analytic signal
> >> a(t) = x(t) + j y(t)
> >>
> >> a(t) = g1(t) cos(w1 t) + g2(t) cos(w2 t) + j( g1(t) sin(w1 t) + g2(t) 
> >> sin(w2 t) )
> >>
> >> |a(t)|^2 = |g1(t)|^2 + |g2(t)|^2 + 2 g1(t) g2(t) cos( (w1-w2) t )
> 
> 
> >> the last term on the right needs to be sorta filtered out with a LPF to
> >> get the correct square of envelope, no?
> >
> > Ah OK - you have a different definition of "envelope" than I do. That's 
> > fine.
> 
> i'm trying to be as inclusive in the definition of "envelope" as i can be.  
> see, if you have a single sinusoid:
> 
>  x(t)  =  g(t) cos(w t)
> 
> and Hilbert transform
> 
>  y(t)  =  g(t) sin(w t)
> 
> and analytic signal
> 
>  a(t)  =  x(t)  +  j y(t)
> 
>=  g(t) cos(w t)  +  j g(t) sin(w t)
> 
>=  g(t) e^(j w t)
> 
> the analytic envelope is
> 
>  |a(t)|  =  sqrt( x(t)^2  +  y(t)^2 )
> 
>  =  g(t)
> 
>  
> so that works great for a single sinusoid.  but once you toss in additional 
> frequency components into x(t), then that creates high-frequency components 
> into |a(t)|^2 that don't belong in any definition of envelope, no?  what 
> other meaning of "envelope" are you working with, Eric?

I agree with all of your math. I don't agree that the

2 g1(t) g2(t) cos( (w1-w2) t )

term is not part of the square of the envelope.

If you have an analytic signal which is the sum of two complex exponentials as 
you described further above and the g1(t) and g2(t) terms are constant, then 
when you compute the magnitude of the sum you actually do see the result vary 
due to the beating of the two frequencies which is the frequency difference 
term you've proposed to discard. In the communications processing I've worked 
with that variation is a critical part of the envelope so using just the 
magnitude of the analytic signal is sufficient to define the envelope. Perhaps 
in audio processing this isn't the case and the filtering you describe is 
necessary.

Eric




___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread Evan Balster
If there are zeroes on the unit circle in the z-plane, I don't think it
will be a very good all-pass filter...  (Because some sinusoid frequencies
would be blocked entirely)

Neat topic so far!  I'd love to see an illustration of this real-line
"zebra stripe" design.  Also wondering what sort of filter a similar
pattern on the imaginary line produces!  (I should improve my own filter
testbed...)

– Evan Balster
creator of imitone 

On Mon, Feb 6, 2017 at 8:57 PM, Sampo Syreeni  wrote:

> On 2017-02-06, Eric Brombaugh wrote:
>
> well, with a single sinusoid, there should be no intermodulation product
>>> so the analytic envelope should be exactly correct.  but consider:
>>>
>> [...]
>
> I might be way off base here, but... As Olli said, both the poles and the
> zeroes sorta "like to be" on the real line.
>
> To me that is kind of a canary. Typically when something works on the real
> line, it tends to work better when distributed over the unit circle. Often
> even reflected over the unit point.
>
> Olli, I *know* this is again highly intuitionistic. But could you still,
> as the kind of guy who actually follows through with his math, check this
> out? I am reasonably, intuitionistically sure, that you started your
> optimization from a local basin. I'm pretty sure there is at least one
> other basin even given your optimization criteria, given by alternating
> zeroes and poles over the left half of the unit circle over the z-plane,
> just as you said they worked alternately over the real line. Or perchance
> over some elliptical locus.
>
> Please, try that original setup as well. Then tell us what your
> optimization machinery did with it. I'm reasonably sure it wouldn't
> converge to what you originally had, even if it converged to *something*
> good. :)
> --
> Sampo Syreeni, aka decoy - de...@iki.fi, http://decoy.iki.fi/front
> +358-40-3255353, 025E D175 ABE5 027C 9494 EEB0 E090 8BA9 0509 85C2
>
> ___
> dupswapdrop: music-dsp mailing list
> music-dsp@music.columbia.edu
> https://lists.columbia.edu/mailman/listinfo/music-dsp
>
>
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread robert bristow-johnson





�


 Original Message 

Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

From: "Eric Brombaugh" 

Date: Mon, February 6, 2017 11:37 am

To: music-dsp@music.columbia.edu

--



> On 02/05/2017 07:52 PM, robert bristow-johnson wrote:

>>

>> > I'm curious what aspects of a music make the complex magnitude of the

>> analytic signal inappropriate for estimating the envelope? In

>> communications signal processing we use this often, even for signals

>> that are fairly wide-band with respect to the sample rate and it seems

>> to work.

>> >

>>

>> well, with a single sinusoid, there should be no intermodulation product

>> so the analytic envelope should be exactly correct. but consider:

>>

>> � � x(t) = g1(t) cos(w1 t) + g2(t) cos(w2 t)

>>

>> which has for it's Hilbert

>>

>> � � y(t) = g1(t) sin(w1 t) + g2(t) sin(w2 t)

>>

>> and analytic signal

>> � � a(t) = x(t) + j y(t)

>>

>> � � a(t) = g1(t) cos(w1 t) + g2(t) cos(w2 t) + j( g1(t) sin(w1 t) +�g2(t) 
>> sin(w2 t) )

>>

>> � � |a(t)|^2 = |g1(t)|^2 + |g2(t)|^2 + 2 g1(t) g2(t) cos( (w1-w2) t )


>> the last term on the right needs to be sorta filtered out with a LPF to

>> get the correct square of envelope, no?

>

> Ah OK - you have a different definition of "envelope" than I do. That's fine.
i'm trying to be as inclusive in the definition of "envelope" as i can be. 
�see, if you have a single sinusoid:
� � �x(t) �= �g(t) cos(w t)
and
Hilbert transform
� � �y(t) �= �g(t) sin(w t)
and analytic signal
� � �a(t) �= �x(t) �+ �j y(t)
� � � � � �= �g(t) cos(w t) �+ �j g(t) sin(w t)
� � �
� � �= �g(t) e^(j w t)
the analytic envelope is
� � �|a(t)| �= �sqrt( x(t)^2 �+ �y(t)^2 )
� � � � � � �= �g(t)
�
so that works great for a single sinusoid. �but once
you toss in additional frequency components into x(t), then that creates 
high-frequency components into |a(t)|^2 that don't belong in any definition of 
envelope, no? �what other meaning of "envelope" are you working with, Eric?

--
r b-j � � � � � � � � �r...@audioimagination.com
"Imagination is more important than knowledge."
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread Sampo Syreeni

On 2017-02-06, Eric Brombaugh wrote:


well, with a single sinusoid, there should be no intermodulation product
so the analytic envelope should be exactly correct.  but consider: 

[...]

I might be way off base here, but... As Olli said, both the poles and 
the zeroes sorta "like to be" on the real line.


To me that is kind of a canary. Typically when something works on the 
real line, it tends to work better when distributed over the unit 
circle. Often even reflected over the unit point.


Olli, I *know* this is again highly intuitionistic. But could you still, 
as the kind of guy who actually follows through with his math, check 
this out? I am reasonably, intuitionistically sure, that you started 
your optimization from a local basin. I'm pretty sure there is at least 
one other basin even given your optimization criteria, given by 
alternating zeroes and poles over the left half of the unit circle over 
the z-plane, just as you said they worked alternately over the real 
line. Or perchance over some elliptical locus.


Please, try that original setup as well. Then tell us what your 
optimization machinery did with it. I'm reasonably sure it wouldn't 
converge to what you originally had, even if it converged to *something* 
good. :)

--
Sampo Syreeni, aka decoy - de...@iki.fi, http://decoy.iki.fi/front
+358-40-3255353, 025E D175 ABE5 027C 9494 EEB0 E090 8BA9 0509 85C2
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread Eric Brombaugh

On 02/05/2017 07:52 PM, robert bristow-johnson wrote:


 > I'm curious what aspects of a music make the complex magnitude of the
analytic signal inappropriate for estimating the envelope? In
communications signal processing we use this often, even for signals
that are fairly wide-band with respect to the sample rate and it seems
to work.
 >

well, with a single sinusoid, there should be no intermodulation product
so the analytic envelope should be exactly correct.  but consider:

 x(t)  =  g1(t) cos(w1 t)  + g2(t) cos(w2 t)

which has for it's Hilbert

y(t)  =  g1(t) sin(w1 t)  + g2(t) sin(w2 t)

and analytic signal
 a(t)  =  x(t) + j y(t)

 a(t)  =  g1(t) cos(w1 t)  + g2(t) cos(w2 t) + j( g1(t) sin(w1 t)  +
g2(t) sin(w2 t) )

 |a(t)|^2  =  |g1(t)|^2  +  |g2(t)|^2  +  2 g1(t) g2(t) cos( (w1-w2) t )
the last term on the right needs to be sorta filtered out with a LPF to
get the correct square of envelope, no?


Ah OK - you have a different definition of "envelope" than I do. That's 
fine.



 > Yes - the Bode-style frequency shifter is a fun and useful effect.
I've done several of them for modular synthesizers using these IIR
all-pass structures:
 >
 > With a dsPIC - http://www.modcan.com/bmodules/dualfs.html
 >
 > With an STM32F303 - http://modcan.com/emodules/dualfreqshifter.html
 >
 > Also with a dsPIC - http://synthtech.com/eurorack/E560/
 >
 > There are example soundfiles at the above sites showing some of the
subtle and radical variations that are possible with different amounts
of shift, feedback and various shifting waveforms.
 >

kewl.  what kinda number crunching can a dsPIC do?  i know what a PIC
is.  so, how wide is the word and how many MIPS can a dsPIC do?  i guess
it's time for me to google search it.


The Microchip dsPIC processors are about 10-15 years old now. They 
generally have about a 40MIPS instruction rate (although some parts are 
rated to run faster and you can get away with overclocking them) and 
they can do a 16x16->48 MAC in a single cycle with simultaneous operand 
fetching and addressing so convolutions can achieve one tap per clock. 
They're inexpensive (under $10), have a nice complement of peripherals, 
on-chip RAM and Flash memory and the development toolchain is free. Most 
of them have on-chip 12-bit ADCs and some even have 16-bit sigma-delta 
DACs so it's possible to implement a complete audio processing system 
with a single chip (albeit somewhat low SNR).



now, here is the touchy question: care to tell us how you designed the
coefficients for the APF pairs?


I mentioned the general process in an earlier email - started with 
Olli's coefficients, interpolated them from 8 poles to 12 and then 
optimized with simulated annealing to get improved image rejection.


Eric

___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-06 Thread Vadim Zavalishin

Funny that no one mentioned this

https://www.native-instruments.com/fileadmin/ni_media/downloads/pdf/VAFilterDesign_1.1.1.pdf

Particularly, formula 7.43

Regards,
Vadim

--
Vadim Zavalishin
Reaktor Application Architect
Native Instruments GmbH
+49-30-611035-0

www.native-instruments.com
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread robert bristow-johnson







 Original Message 

Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

From: "Eric Brombaugh" 

Date: Sun, February 5, 2017 8:22 pm

To: "A discussion list for music-related DSP" 

--



>

> On Feb 5, 2017, at 12:54 PM, robert bristow-johnson wrote:

>

>> using the analytic filter to get the instantaneous amplitude envelope (and, 
>> also, instantaneous frequency by differentiating phase) is something that 
>> works only with single sinusoids that are AM'd or FM'd. for music, i think i 
>> would LPF the square of the signal (or run an efficient sliding
max algorithm, we discussed this a while back) and work with that.
>

> I'm curious what aspects of a music make the complex magnitude of the 
> analytic signal inappropriate for estimating the envelope? In communications 
> signal processing we use this often, even for signals that are fairly 
> wide-band with respect to the sample rate and it seems to work.

>
well, with a single sinusoid, there should be no intermodulation product so the 
analytic envelope should be exactly correct. �but consider:
�
� � x(t) �= �g1(t) cos(w1 t) �+ g2(t) cos(w2 t)
which has for it's Hilbert
� �
y(t) �= �g1(t) sin(w1 t) �+ g2(t) sin(w2 t)
�

and analytic signal

�

� � a(t) �= �x(t) + j y(t)


� � a(t) �= �g1(t) cos(w1 t) �+ g2(t) cos(w2 t) + j( g1(t) sin(w1 t) �+ g2(t) 
sin(w2 t) )


� � |a(t)|^2 �= �|g1(t)|^2 �+ �|g2(t)|^2 �+ �2 g1(t) 
g2(t) cos( (w1-w2) t )

�

the last term on the right needs to be sorta filtered 
out with a LPF to get the correct square of envelope, no?

�

my feeling is that if we're gonna have to put up with 
the vagaries (delay, etc) of a LPF anyway, better to just square and filter the 
signal.

�

and i dunno what sorta mess this becomes if you had two 
sinusoids and were using the analytic signal to derive the instantaneous 
frequency.



>> but the reason i am most interested is in a frequency shifter. like the ham 
>> radio single-sideband (SSB) thingie. this is not a pitch shifter and detunes 
>> harmonic overtones into the inharmonic. but it is totally glitch-free and 
>> can sometimes be handy to detune something slightly so that
there is not a buildup of energy at a specific frequency (when there is 
feedback of some sort). pitch shifters can do that too, but time-domain pitch 
shifters might have glitches for non-monotonic input and frequency-domain pitch 
shifters have a huge throughput delay. also, this glitch-free
frequency shifting can be slowly modulated. might be useful for chorusing. 
combined with a pitch shifter and pitch detector, you can shift harmonics 
without shifting the fundamental (i.e. pitch it up with a pitch shifter and 
then bring back down the fundamental to the original pitch.)
>

> Yes - the Bode-style frequency shifter is a fun and useful effect. I've done 
> several of them for modular synthesizers using these IIR all-pass structures:

>

> With a dsPIC - http://www.modcan.com/bmodules/dualfs.html

>

> With an STM32F303 - http://modcan.com/emodules/dualfreqshifter.html

>

> Also with a dsPIC - http://synthtech.com/eurorack/E560/

>

> There are example soundfiles at the above sites showing some of the subtle 
> and radical variations that are possible with different amounts of shift, 
> feedback and various shifting waveforms.

>
kewl. �what kinda number crunching can a dsPIC do? �i know what a PIC is. �so, 
how wide is the word and how many MIPS can a dsPIC do? �i guess it's time for 
me to google search it.
now, here is the touchy question: care to tell us how you designed the
coefficients for the APF pairs?

--
r b-j � � � � � � � � �r...@audioimagination.com
"Imagination is more important than knowledge."
�
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread Eric Brombaugh

On Feb 5, 2017, at 12:54 PM, robert bristow-johnson wrote:

> using the analytic filter to get the instantaneous amplitude envelope (and, 
> also, instantaneous frequency by differentiating phase) is something that 
> works only with single sinusoids that are AM'd or FM'd.  for music, i think i 
> would LPF the square of the signal (or run an efficient sliding max 
> algorithm, we discussed this a while back) and work with that.

I'm curious what aspects of a music make the complex magnitude of the analytic 
signal inappropriate for estimating the envelope? In communications signal 
processing we use this often, even for signals that are fairly wide-band with 
respect to the sample rate and it seems to work.

> but the reason i am most interested is in a frequency shifter.  like the ham 
> radio single-sideband (SSB) thingie.  this is not a pitch shifter and detunes 
> harmonic overtones into the inharmonic.  but it is totally glitch-free and 
> can sometimes be handy to detune something slightly so that there is not a 
> buildup of energy at a specific frequency (when there is feedback of some 
> sort).  pitch shifters can do that too, but time-domain pitch shifters might 
> have glitches for non-monotonic input and frequency-domain pitch shifters 
> have a huge throughput delay.  also, this glitch-free frequency shifting can 
> be slowly modulated.  might be useful for chorusing.  combined with a pitch 
> shifter and pitch detector, you can shift harmonics without shifting the 
> fundamental (i.e. pitch it up with a pitch shifter and then bring back down 
> the fundamental to the original pitch.)

Yes - the Bode-style frequency shifter is a fun and useful effect. I've done 
several of them for modular synthesizers using these IIR all-pass structures:

With a dsPIC - http://www.modcan.com/bmodules/dualfs.html

With an STM32F303 - http://modcan.com/emodules/dualfreqshifter.html

Also with a dsPIC - http://synthtech.com/eurorack/E560/

There are example soundfiles at the above sites showing some of the subtle and 
radical variations that are possible with different amounts of shift, feedback 
and various shifting waveforms.

Eric
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread robert bristow-johnson







 Original Message 

Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

From: "Ethan Fenn" 

Date: Sun, February 5, 2017 1:39 pm

To: music-dsp@music.columbia.edu

--



> Some very interesting references.

>

> I'm curious what uses people find for the Hilbert transform for in audio.

> An instantaneous amplitude envelope, for use in compressors and other

> envelope-driven effects? Or something else?
using the analytic filter to get the instantaneous amplitude envelope (and, 
also, instantaneous frequency by differentiating phase) is something that works 
only with single sinusoids that are AM'd or FM'd. �for music, i think i would 
LPF
the square of the signal (or run an efficient sliding max algorithm, we 
discussed this a while back) and work with that.
it can also be used to measure phase shift from input to output in a noisy 
environment at specific frequencies (without the phase lag vs. phase lead 
ambiguity).
but
the reason i am most interested is in a frequency shifter. �like the ham radio 
single-sideband (SSB) thingie. �this is not a pitch shifter and detunes 
harmonic overtones into the inharmonic. �but it is totally glitch-free and can 
sometimes be handy to detune something slightly so that
there is not a buildup of energy at a specific frequency (when there is 
feedback of some sort). �pitch shifters can do that too, but time-domain pitch 
shifters might have glitches for non-monotonic input and frequency-domain pitch 
shifters have a huge throughput delay. �also, this
glitch-free frequency shifting can be slowly modulated. �might be useful for 
chorusing. �combined with a pitch shifter and pitch detector, you can shift 
harmonics without shifting the fundamental (i.e. pitch it up with a pitch 
shifter and then bring back down the fundamental to the
original pitch.)



--
r b-j � � � � � � � � �r...@audioimagination.com
"Imagination is more important than knowledge."
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread Ethan Fenn
Some very interesting references.

I'm curious what uses people find for the Hilbert transform for in audio.
An instantaneous amplitude envelope, for use in compressors and other
envelope-driven effects? Or something else?

-Ethan



On Sun, Feb 5, 2017 at 10:13 AM, Eric Brombaugh  wrote:

> Yes, I'm using the Hilbert transform to generate an analytic signal for
> use in a Bode-style frequency shifter and also in single-sideband modulator
> and demodulators. The image rejection metric is a critical aspect of the
> performance of these systems and is related to the error from true 90deg
> phase shift.
>
> For my optimization I started with the original 8th order set that was
> given and then used a polynomial curve fit to interpolate those values from
> 8th order to 12th order. Then using those values as a starting point, I
> went into an iterated optimization which dithered the coefficients and
> evaluated the phase shift error, saving any set that reduced the error. The
> end result provided a noticeable improvement in the image rejection and
> I've been using those coefficients in some of my radio designs. One of them
> is in github here:
>
> https://github.com/emeb/iceRadio/blob/master/MCU/f303_ice5_rxadc/audio.c
>
> As I said earlier, this approach to extending the performance of the
> filter is rather "brute force and ignorance", but it got the job done and
> the shift from 8 to 12 poles didn't present a significant increase in the
> computational cost - I've been using ARM Cortex M4F processors with
> single-precision floating point hardware to implement these filters and
> they work well.
>
> Eric
>
> On Feb 4, 2017, at 11:25 PM, robert bristow-johnson wrote:
>
> >
> > by "image rejection", do you mean, for an analytic filter:
> >
> > a[n] = x[n] + j*y[n]
> >
> >where y[n] = Hilbert{ x[n] }
> >
> > the gain difference between the positive and negative frequencies?
> >
> > i guess you're right.  looks like -44 dB on Olli's graph.  that's not so
> great, i guess.
> >
> > is your optimized filter 8th order?  8 real poles or are there some
> complex-conjugate poles in there? i haven't groked why Olli seems to think
> that real poles, symmetrical about the origin, is the best way. it seems
> like a restriction that might cause one to miss the optimum.
> >
> > can you tell us how you designed or optimize the pole loci, Eric?  other
> than some kinda brute force method (perhaps Greg's FDLS) i am still
> thinking about how to approach that.  APFs so the gains stay 1 and we don't
> care about the phase as long as the difference is 90°.  still don't know
> how i might set up an optimization problem.  probably the best measure is
> the negative frequency rejection with regard to the positive frequency gain.
> >
> > r b-j
> >
> >
> >
> >  Original Message
> 
> > Subject: Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs
> > From: "Eric Brombaugh" 
> > Date: Sat, February 4, 2017 10:28 pm
> > To: r...@audioimagination.com
> > music-dsp@music.columbia.edu
> > 
> --
> >
> > > IIRC, when I implemented Olli's coefficients I was seeing about 40dB
> image rejection. My optimized filter gave more like 58dB.
> > >
> > > Eric
> > >
> > > On Feb 4, 2017, at 7:25 PM, robert bristow-johnson wrote:
> > >
> > >>
> > >> sunuvubych Olli. i shoulda known about this.
> > >>
> > >> i dunno Eric, 2/100 radian is about ±0.5°. that's what Olli is
> indicating on Figure 3. appears to be an 8th-order using 4 pole pairs about
> the origin on the real line. (i'm just now groking his design methodology.)
> and he seems to have exceedingly low amplitude variation in the Analytic
> Filter magnitude response. dunno what is lackluster about that. (but i
> haven't checked this out, yet.)
> > >>
> > >> i know that because you can sorta treat group delay (which is a
> function solely of phase) like gain in an all-pass filter, for the purposes
> of optimal filter design technique (like Parks-McClellan or Prony). maybe
> that's what Olli is doing.
> > >>
> > >>
> > >> --
> > >>
> > >> r b-j r...@audioimagination.com
> > >>
> > >> "Imagination is more important than knowledge."
> > >>
> > >>
> > >>
> > >> ---

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread Eric Brombaugh
Yes, I'm using the Hilbert transform to generate an analytic signal for use in 
a Bode-style frequency shifter and also in single-sideband modulator and 
demodulators. The image rejection metric is a critical aspect of the 
performance of these systems and is related to the error from true 90deg phase 
shift.

For my optimization I started with the original 8th order set that was given 
and then used a polynomial curve fit to interpolate those values from 8th order 
to 12th order. Then using those values as a starting point, I went into an 
iterated optimization which dithered the coefficients and evaluated the phase 
shift error, saving any set that reduced the error. The end result provided a 
noticeable improvement in the image rejection and I've been using those 
coefficients in some of my radio designs. One of them is in github here:

https://github.com/emeb/iceRadio/blob/master/MCU/f303_ice5_rxadc/audio.c

As I said earlier, this approach to extending the performance of the filter is 
rather "brute force and ignorance", but it got the job done and the shift from 
8 to 12 poles didn't present a significant increase in the computational cost - 
I've been using ARM Cortex M4F processors with single-precision floating point 
hardware to implement these filters and they work well.

Eric

On Feb 4, 2017, at 11:25 PM, robert bristow-johnson wrote:

>  
> by "image rejection", do you mean, for an analytic filter:
> 
> a[n] = x[n] + j*y[n]
> 
>where y[n] = Hilbert{ x[n] }
> 
> the gain difference between the positive and negative frequencies? 
> 
> i guess you're right.  looks like -44 dB on Olli's graph.  that's not so 
> great, i guess.
> 
> is your optimized filter 8th order?  8 real poles or are there some 
> complex-conjugate poles in there? i haven't groked why Olli seems to think 
> that real poles, symmetrical about the origin, is the best way. it seems like 
> a restriction that might cause one to miss the optimum.
> 
> can you tell us how you designed or optimize the pole loci, Eric?  other than 
> some kinda brute force method (perhaps Greg's FDLS) i am still thinking about 
> how to approach that.  APFs so the gains stay 1 and we don't care about the 
> phase as long as the difference is 90°.  still don't know how i might set up 
> an optimization problem.  probably the best measure is the negative frequency 
> rejection with regard to the positive frequency gain.
> 
> r b-j
> 
>  
> 
>  Original Message 
> Subject: Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs
> From: "Eric Brombaugh" 
> Date: Sat, February 4, 2017 10:28 pm
> To: r...@audioimagination.com
> music-dsp@music.columbia.edu
> --
> 
> > IIRC, when I implemented Olli's coefficients I was seeing about 40dB image 
> > rejection. My optimized filter gave more like 58dB.
> >
> > Eric
> >
> > On Feb 4, 2017, at 7:25 PM, robert bristow-johnson wrote:
> >
> >>
> >> sunuvubych Olli. i shoulda known about this.
> >>
> >> i dunno Eric, 2/100 radian is about ±0.5°. that's what Olli is indicating 
> >> on Figure 3. appears to be an 8th-order using 4 pole pairs about the 
> >> origin on the real line. (i'm just now groking his design methodology.) 
> >> and he seems to have exceedingly low amplitude variation in the Analytic 
> >> Filter magnitude response. dunno what is lackluster about that. (but i 
> >> haven't checked this out, yet.)
> >>
> >> i know that because you can sorta treat group delay (which is a function 
> >> solely of phase) like gain in an all-pass filter, for the purposes of 
> >> optimal filter design technique (like Parks-McClellan or Prony). maybe 
> >> that's what Olli is doing.
> >>
> >>
> >> --
> >>
> >> r b-j r...@audioimagination.com
> >>
> >> "Imagination is more important than knowledge."
> >>
> >>
> >>
> >>  Original Message 
> >> Subject: Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs
> >>
> From: "Eric Brombaugh" 
> >> Date: Sat, February 4, 2017 8:55 pm
> >> To: music-dsp@music.columbia.edu
> >> --
> >>
> >> > The original Csound source has a set of coefficients for this type of
> >> > hilbert transform but they don't say how the coeffi

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread Olli Niemitalo
typofix: "and their companion poles" -> "and their companion zeros"

-olli

On Sun, Feb 5, 2017 at 1:52 PM, Olli Niemitalo  wrote:

> 90 deg phase difference all-pass filter pairs... Lemme wave my hands a bit:
>
> It's been years, but I recall I first tried a structure with complex
> conjugate pairs of poles (and their companion poles to make the filters
> all-pass). Globally optimizing that using Differential Evolution, the poles
> "wanted to be" near the real line. The ripples in the phase response
> difference of the optimized filters got finer by having two real poles in
> place of each complex conjugate pair of poles. The real poles and real
> zeros of the two filter paths alternate on the real line like a zebra
> stripe black pearl white pearl necklace. One of the paths is delayed
> (z^-1) by one sample, which gives the "center pearl" pole. I think the
> alternating order reflects the fact that a first-order all-pass filter
> gives a 180 deg phase shift end-to-end, and alternating the poles of the
> two paths corrects the phase response difference up and down so that we can
> stay approximately half-way between 0 deg and 180 deg, at 90 deg. One
> optimization here was to make the filter requirements symmetric around
> frequency pi/4, so that each positive pole can have a negative companion
> pole. This symmetry simplifies the all-pass filter computation.
>
> Artur Krukowski's papers were always over my head.
>
> -olli
>
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread Olli Niemitalo
90 deg phase difference all-pass filter pairs... Lemme wave my hands a bit:

It's been years, but I recall I first tried a structure with complex
conjugate pairs of poles (and their companion poles to make the filters
all-pass). Globally optimizing that using Differential Evolution, the poles
"wanted to be" near the real line. The ripples in the phase response
difference of the optimized filters got finer by having two real poles in
place of each complex conjugate pair of poles. The real poles and real
zeros of the two filter paths alternate on the real line like a zebra
stripe black pearl white pearl necklace. One of the paths is delayed
(z^-1) by one sample, which gives the "center pearl" pole. I think the
alternating order reflects the fact that a first-order all-pass filter
gives a 180 deg phase shift end-to-end, and alternating the poles of the
two paths corrects the phase response difference up and down so that we can
stay approximately half-way between 0 deg and 180 deg, at 90 deg. One
optimization here was to make the filter requirements symmetric around
frequency pi/4, so that each positive pole can have a negative companion
pole. This symmetry simplifies the all-pass filter computation.

Artur Krukowski's papers were always over my head.

-olli
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread Laurent de Soras

robert bristow-johnson wrote:


cool, so it appears from your comments to be real poles.
complex conjugate poles are not considered in the design.  i
wonder why that is?


I’m not the author of the formula, I just implemented it
and don’t understand how it produces these filters.
I guess the poles are real in both all-pass filter chains,
but once they are summed, the resulting filter exhibits
complex conjugate poles.




___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread robert bristow-johnson



�
cool, so it appears from your comments to be real poles. �complex conjugate 
poles are not considered in the design. �i wonder why that is?
r b-j


 Original Message 

Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

From: "Laurent de Soras" 

Date: Sun, February 5, 2017 3:03 am

To: r...@audioimagination.com

music-dsp@music.columbia.edu

--



> robert bristow-johnson wrote:

>>

>> so Olli, how do you get your coefficients? (if i may ask?)

>

> If I may reply, I wrote long time ago a C++ library implementing

> this kind of polyphase halfband filter, including a coefficient

> calculator involving elliptic stuff (way beyond my knowledge).

> Check the PolyphaseIir2Designer class:

> <http://ldesoras.free.fr/prod.html#src_hiir>

>

> There is also an ARM/NEON implementation below, not published in

> the main release yet:

> <https://github.com/EleonoreMizo/pedalevite/tree/master/src/hiir>

>

>





--
r b-j � � � � � � � � �r...@audioimagination.com
"Imagination is more important than knowledge."
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-05 Thread Laurent de Soras

robert bristow-johnson wrote:


so Olli, how do you get your coefficients?  (if i may ask?)


If I may reply, I wrote long time ago a C++ library implementing
this kind of polyphase halfband filter, including a coefficient
calculator involving elliptic stuff (way beyond my knowledge).
Check the PolyphaseIir2Designer class:


There is also an ARM/NEON implementation below, not published in
the main release yet:


___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-04 Thread Eric Brombaugh
IIRC, when I implemented Olli's coefficients I was seeing about 40dB image 
rejection. My optimized filter gave more like 58dB.

Eric

On Feb 4, 2017, at 7:25 PM, robert bristow-johnson wrote:

>  
> sunuvubych Olli. i shoulda known about this.
> 
> i dunno Eric, 2/100 radian is about ±0.5°.  that's what Olli is indicating on 
> Figure 3.  appears to be an 8th-order using 4 pole pairs about the origin on 
> the real line. (i'm just now groking his design methodology.) and he seems to 
> have exceedingly low amplitude variation in the Analytic Filter magnitude 
> response.  dunno what is lackluster about that. (but i haven't checked this 
> out, yet.)
> 
> i know that because you can sorta treat group delay (which is a function 
> solely of phase) like gain in an all-pass filter, for the purposes of optimal 
> filter design technique (like Parks-McClellan or Prony). maybe that's what 
> Olli is doing.
> 
> 
> --
> 
> r b-j  r...@audioimagination.com
> 
> "Imagination is more important than knowledge."
> 
> 
> 
> -------- Original Message 
> Subject: Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs
> From: "Eric Brombaugh" 
> Date: Sat, February 4, 2017 8:55 pm
> To: music-dsp@music.columbia.edu
> --
> 
> > The original Csound source has a set of coefficients for this type of
> > hilbert transform but they don't say how the coefficients were derived
> > and the performance is fairly lackluster. The only reference I've come
> > across for this was Olli Niemitalo's:
> >
> > http://yehar.com/blog/?p=368
> >
> > He gives a bit of theory, but the filter pair he provides doesn't give
> > great performance.
> >
> > I was able to use Olli's filter as a starting point for optimization of
> > a higher order AP set that gave almost 20dB better image rejection. I
> > interpolated the originals to a higher order and then used simulated
> > annealing with a cost function that included the bandwidth and image
> > rejection. Rather brute-force, but it worked.
> >
> > Eric
> >
> >
> > On 02/04/2017 04:32 PM, robert bristow-johnson wrote:
> >> hey guys,
> >>
> >> what's the best online reference you can tell me for theory and practice
> >> of designing APF pairs with ± 45° phase (+ a linear phase that
> >> represents causality delay) to result in a Hilbert pair for audio
> >> processing. i know how to do this for FIR and to use half-band
> >> symmetry, but i wanna make a MATLAB program where i can specify order
> >> and come up with an optimal pair of IIR APFs that have virtually 90°
> >> phase difference over the widest possible frequency range. also some
> >> discussion of error metric would be good (how do we decide what is
> >> "optimal"?). eventually, i wanna compare computational effort with the
> >> half-band FIR Hilbert transformer.
> >>
> >> anyone have a good, definitive reference?
> >>
> >> thanks.
> >>
> >> --
> >>
> >> r b-j r...@audioimagination.com
> >>
> >> "Imagination is more important than knowledge."
> >>
> >>
> >>
> >> ___
> >> dupswapdrop: music-dsp mailing list
> >> music-dsp@music.columbia.edu
> >> https://lists.columbia.edu/mailman/listinfo/music-dsp
> >>
> >
> > ___
> > dupswapdrop: music-dsp mailing list
> > music-dsp@music.columbia.edu
> > https://lists.columbia.edu/mailman/listinfo/music-dsp
> >
> >
> 
> ___
> dupswapdrop: music-dsp mailing list
> music-dsp@music.columbia.edu
> https://lists.columbia.edu/mailman/listinfo/music-dsp

___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-04 Thread robert bristow-johnson



�
you know it's embarrassing to rediscover you've been somewhere before, after 
totally forgetting about it.
so Olli, how do you get your coefficients? �(if i may ask?)
r b-j�



 Original Message 

Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

From: "robert bristow-johnson" 

Date: Sat, February 4, 2017 9:25 pm

To: music-dsp@music.columbia.edu

--



>

>

>

> �

> sunuvubych Olli. i shoulda known about this.

> i dunno Eric, 2/100 radian is about �0.5�. �that's what Olli is indicating on 
> Figure 3. �appears to be an 8th-order using 4 pole pairs about the origin on 
> the real line. (i'm just now groking his design

> methodology.) and he seems to have exceedingly low amplitude variation in the 
> Analytic Filter magnitude response. �dunno what is lackluster about that. 
> (but i haven't checked this out, yet.)

> i know that because you can sorta treat group delay (which is a function 
> solely of phase) like

> gain in an all-pass filter, for the purposes of optimal filter design 
> technique (like Parks-McClellan or Prony). maybe that's what Olli is doing.

>

> --

> r b-j � � � � � � � � �r...@audioimagination.com

> "Imagination is more important than knowledge."

>

>

>

>

> ------------ Original Message 

>

> Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

>

>

From: "Eric Brombaugh" 

>

> Date: Sat, February 4, 2017 8:55 pm

>

> To: music-dsp@music.columbia.edu

>

> --

>

>

>

>> The original Csound source has a set of coefficients for this type of

>

>> hilbert transform but they don't say how the coefficients were derived

>

>> and the performance is fairly lackluster. The only reference I've come

>

>> across for this was Olli Niemitalo's:

>

>>

>

>> http://yehar.com/blog/?p=368

>

>>

>

>> He gives a bit of theory, but the filter pair he provides doesn't give

>

>> great performance.

>

>>

>

>> I was able to use Olli's filter as a starting point for optimization of

>

>> a higher order AP set that gave almost 20dB better image rejection. I

>

>> interpolated the originals to a higher order and then used simulated

>

>> annealing with a cost function that included the bandwidth and image

>

>> rejection. Rather brute-force, but it worked.

>

>>

>

>> Eric

>

>>

>

>>

>

>> On 02/04/2017 04:32 PM, robert bristow-johnson wrote:

>

>>> hey guys,

>

>>>

>

>>> what's the best online reference you can tell me for theory and practice

>

>>> of designing APF pairs with � 45� phase (+ a linear phase that

>

>>> represents causality delay) to result in a Hilbert pair for audio

>

>>> processing. i know how to do this for FIR and to use half-band

>

>>> symmetry, but i wanna make a MATLAB program where i can specify order

>

>>> and come up with an optimal pair of IIR APFs that have virtually 90�

>

>>> phase difference over the widest possible frequency range. also some

>

>>> discussion of error metric would be good (how do we decide what is

>

>>> "optimal"?). eventually, i wanna compare computational effort with the

>

>>> half-band FIR Hilbert transformer.

>

>>>

>

>>> anyone have a good, definitive reference?

>

>>>

>

>>> thanks.

>

>>>

>

>>> --

>

>>>

>

>>> r b-j r...@audioimagination.com

>

>>>

>

>>> "Imagination is more important than knowledge."

>

>>>

>

>>>

>

>>>

>

>>> ___

>

>>> dupswapdrop: music-dsp mailing list

>

>>> music-dsp@music.columbia.edu

>

>>> https://lists.columbia.edu/mailman/listinfo/music-dsp

>

>>>

>

>>

>

>> ___

>

>> dupswapdrop: music-dsp mailing list

>

>> music-dsp@music.columbia.edu

>

>> https://lists.columbia.edu/mailman/listinfo/music-dsp

>

>>

>

>>

> ___

> dupswapdrop: music-dsp mailing list

> music-dsp@music.columbia.edu

> https://lists.columbia.edu/mailman/listinfo/music-dsp
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-04 Thread robert bristow-johnson



�
sunuvubych Olli. i shoulda known about this.
i dunno Eric, 2/100 radian is about �0.5�. �that's what Olli is indicating on 
Figure 3. �appears to be an 8th-order using 4 pole pairs about the origin on 
the real line. (i'm just now groking his design
methodology.) and he seems to have exceedingly low amplitude variation in the 
Analytic Filter magnitude response. �dunno what is lackluster about that. (but 
i haven't checked this out, yet.)
i know that because you can sorta treat group delay (which is a function solely 
of phase) like
gain in an all-pass filter, for the purposes of optimal filter design technique 
(like Parks-McClellan or Prony). maybe that's what Olli is doing.

--
r b-j � � � � � � � � �r...@audioimagination.com
"Imagination is more important than knowledge."




 Original Message --------

Subject: Re: [music-dsp] � 45� Hilbert transformer using pair of IIR APFs

From: "Eric Brombaugh" 

Date: Sat, February 4, 2017 8:55 pm

To: music-dsp@music.columbia.edu

--



> The original Csound source has a set of coefficients for this type of

> hilbert transform but they don't say how the coefficients were derived

> and the performance is fairly lackluster. The only reference I've come

> across for this was Olli Niemitalo's:

>

> http://yehar.com/blog/?p=368

>

> He gives a bit of theory, but the filter pair he provides doesn't give

> great performance.

>

> I was able to use Olli's filter as a starting point for optimization of

> a higher order AP set that gave almost 20dB better image rejection. I

> interpolated the originals to a higher order and then used simulated

> annealing with a cost function that included the bandwidth and image

> rejection. Rather brute-force, but it worked.

>

> Eric

>

>

> On 02/04/2017 04:32 PM, robert bristow-johnson wrote:

>> hey guys,

>>

>> what's the best online reference you can tell me for theory and practice

>> of designing APF pairs with � 45� phase (+ a linear phase that

>> represents causality delay) to result in a Hilbert pair for audio

>> processing. i know how to do this for FIR and to use half-band

>> symmetry, but i wanna make a MATLAB program where i can specify order

>> and come up with an optimal pair of IIR APFs that have virtually 90�

>> phase difference over the widest possible frequency range. also some

>> discussion of error metric would be good (how do we decide what is

>> "optimal"?). eventually, i wanna compare computational effort with the

>> half-band FIR Hilbert transformer.

>>

>> anyone have a good, definitive reference?

>>

>> thanks.

>>

>> --

>>

>> r b-j r...@audioimagination.com

>>

>> "Imagination is more important than knowledge."

>>

>>

>>

>> ___

>> dupswapdrop: music-dsp mailing list

>> music-dsp@music.columbia.edu

>> https://lists.columbia.edu/mailman/listinfo/music-dsp

>>

>

> ___

> dupswapdrop: music-dsp mailing list

> music-dsp@music.columbia.edu

> https://lists.columbia.edu/mailman/listinfo/music-dsp

>

>
___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-04 Thread Eric Brombaugh
The original Csound source has a set of coefficients for this type of 
hilbert transform but they don't say how the coefficients were derived 
and the performance is fairly lackluster. The only reference I've come 
across for this was Olli Niemitalo's:


http://yehar.com/blog/?p=368

He gives a bit of theory, but the filter pair he provides doesn't give 
great performance.


I was able to use Olli's filter as a starting point for optimization of 
a higher order AP set that gave almost 20dB better image rejection. I 
interpolated the originals to a higher order and then used simulated 
annealing with a cost function that included the bandwidth and image 
rejection. Rather brute-force, but it worked.


Eric


On 02/04/2017 04:32 PM, robert bristow-johnson wrote:

hey guys,

what's the best online reference you can tell me for theory and practice
of designing APF pairs with ± 45° phase (+ a linear phase that
represents causality delay) to result in a Hilbert pair for audio
processing.  i know how to do this for FIR and to use half-band
symmetry, but i wanna make a MATLAB program where i can specify order
and come up with an optimal pair of IIR APFs that have virtually 90°
phase difference over the widest possible frequency range.  also some
discussion of error metric would be good (how do we decide what is
"optimal"?).  eventually, i wanna compare computational effort with the
half-band FIR Hilbert transformer.

anyone have a good, definitive reference?

thanks.

--

r b-j  r...@audioimagination.com

"Imagination is more important than knowledge."



___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp



[music-dsp] ± 45° Hilbert transformer using pair of IIR APFs

2017-02-04 Thread robert bristow-johnson



�
hey guys,
what's the best online reference you can tell me for theory and practice of 
designing APF pairs with � 45� phase (+ a linear phase that represents 
causality delay)�to result in a Hilbert pair for audio processing. �i know how 
to do this for FIR
and to use half-band symmetry, but i wanna make a MATLAB program where i can 
specify order and come up with an optimal pair of IIR APFs that have virtually 
90� phase difference over the widest possible frequency range. �also some 
discussion of error metric would be good (how do we decide
what is "optimal"?). �eventually, i wanna compare computational effort with the 
half-band FIR Hilbert transformer.
anyone have a good, definitive reference?
thanks.
--
r b-j � � � � � � � �
�r...@audioimagination.com
"Imagination is more important than knowledge."___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp