in the following picture:
http://www.soundonsound.com/sos/Mar02/images/synth4.gif
how do i make a frequency shifter ? is this the same as the pitch shifter that i can rip from the pd docs, or is there a simpler way??
cheers.
hard off wrote:
in the following picture:
http://www.soundonsound.com/sos/Mar02/images/synth4.gif
how do i make a frequency shifter ? is this the same as the pitch shifter that i can rip from the pd docs, or is there a simpler way??
cheers.
Frequency shifting (adding each partial's frequency by an offset) isn't the same as pitch shifting (multiplying each partial's frequency by a ratio).
The objects hilbert~ and complex-mod~ will help you, as they helped me when I tried to make a snare drum following that tutorial, I'll see if I can find the patches sometime later today.
Claude
Claude Heiland-Allen wrote:
Frequency shifting (adding each partial's frequency by an offset) isn't the same as pitch shifting (multiplying each partial's frequency by a ratio).
Oh yes, absolutely correct! Thx for reminding!
The objects hilbert~ and complex-mod~ will help you, as they helped me when I tried to make a snare drum following that tutorial
This definitely seems like overkill if what you need are two or three triangle waves with a frequency offset in order to produce an inharmonic spectrum, which is what is shown in that diagram regardless of what (hardware-emulating) functions they have recommended to get that result.
best, d.
yeah i think the tutorial is for hardware.
I would simply use two
more triangle oscillators in place of the pitch shifters, and set the frequencies using a bit of math based on the frequency of the first triangle oscillator.<<
derek, this is the answer i had hoped for. the snare drum is already sounding really good. i'm so surprised...
if you could help me with the math required, i would be very grateful.
hard off wrote:
I would simply use two
more triangle oscillators in place of the pitch shifters, and set the frequencies using a bit of math based on the frequency of the first triangle oscillator.<<
if you could help me with the math required, i would be very grateful.
It's simpler than you might think... Take the number that is providing the frequency for the first triangle oscillator and add (or subtract) 175 and 224 to (from) it and use this number to set the frequency of the other two. I'm not sure which direction the frequency shifter is supposed to go in this diagram, so try either adding or subtracting. Also what is not clear is if the original triangle wave is heard in your diagram, or only the two pitch shifted ones, so either you will only hear the frequency-shifted pair or you will hear all three mixed with your two sinus waves.
[number box\ <---set master frequency | | | | [+ 175] [+ 224] <---set shifted frequencies | | | | | [triangle~] | [triangle~] [triangle~]
Where [triangle~] is an abstraction you have made which produces a nice, bandwidth-limited triangle wave ;-)
If my cheap ASCII art doesn't come through, let me know and I'll be less lazy and patch it...
Hope this is clear enough, d.
I had no idea what you guys were talking about, but I tried it and it sounds wicked. Where did you pick up this idea?
-Chuckk
On 11/24/06, derek holzer derek@x-i.net wrote:
hard off wrote:
I would simply use two
more triangle oscillators in place of the pitch shifters, and set the frequencies using a bit of math based on the frequency of the first triangle oscillator.<<
if you could help me with the math required, i would be very grateful.
It's simpler than you might think... Take the number that is providing the frequency for the first triangle oscillator and add (or subtract) 175 and 224 to (from) it and use this number to set the frequency of the other two. I'm not sure which direction the frequency shifter is supposed to go in this diagram, so try either adding or subtracting. Also what is not clear is if the original triangle wave is heard in your diagram, or only the two pitch shifted ones, so either you will only hear the frequency-shifted pair or you will hear all three mixed with your two sinus waves.
[number box\ <---set master frequency | | | | [+ 175] [+ 224] <---set shifted frequencies | | | | | [triangle~] | [triangle~] [triangle~]
Where [triangle~] is an abstraction you have made which produces a nice, bandwidth-limited triangle wave ;-)
If my cheap ASCII art doesn't come through, let me know and I'll be less lazy and patch it...
Hope this is clear enough, d.
-- derek holzer ::: http://www.umatic.nl ---Oblique Strategy # 112: "Magnify the most difficult details"
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
if you could help me with the math required, i would be very grateful.
I think what they're talking about here (single side-band modulation)
works this way. We take our original spectrum which has two sides,
each the conjugate of the other.
/\ /
___//_____|____/_/___
we get rid of one side, to get the complex representation
/\
__________|____/_/___
In the time domain this is a complex valued signal. To shift all the frequencies by a certain amount we convolve in the frequency domain by an impulse given by the fourier transform of e^(2*pi*i*f) where f is the frequency to shift by. This looks like, in the frequency domain:
|
__________|__|________
Convolution in the frequency domain (with a single sided spectrum) shifts all the frequencies to the right. Conv. in the frequency domain is the same as multiplication in the time domain. So we can do this operation as complex multiplication of our two complex signals. Resulting spectrum
/\
__________|______/_/\_
Then, just throw away the imaginary part and multiply by two, and there you have a real-valued signal. Let's see here...I got a little patch put together for demonstration purposes, using hilbert~ Don't rightly know why it won't work well with the osc~ set to 0? Chuck
attached is my snare drum which uses the freqshift~ external (http://www.weiss-archiv.de or cvs)
and the kick drum i did the other day.
these both took me way too long, but they sound good. particularly when run through analogue distortion.
Hallo, hard off hat gesagt: // hard off wrote:
attached is my snare drum which uses the freqshift~ external (http://www.weiss-archiv.de or cvs)
and the kick drum i did the other day.
these both took me way too long, but they sound good. particularly when run through analogue distortion.
Indeed these are nice drums. I made some small changes so that no exotic externals are used anymore: freqshift~ was replaced by two additional phasors, and the triangle-generation uses the [min~] algorithm instead of one using [abs~]. Additionally I replaced creb's [ead~] with a [vead~] abstraction that provides better timing thanks to [vline~]
Frank Barknecht _ ______footils.org_ __goto10.org__
cheers frank. i remember the discussion about ead~ well, so it's good to have that vead~ as an abstraction.
there is also a glitch in the snare drum subpatch -- i accidentally left in a loose dac~ next to the output~.
after having a good listen,
it doesn't sound as good as it did with [freqshift~]. i don't understand the maths behind that so no idea why, but it's obvious to my ears. its especially clear when you increase the attack time.
This is a great thread, everyone! I hope to see MUCH more discussion like this in the future, since it's such a great hands on way to learn both synthesis and Pd.
Thanks for sharing your secrets rather than "playing trumpet with a hanky over your hand."
~Kyle
On 11/27/06, hard off hard.off@gmail.com wrote:
after having a good listen,
it doesn't sound as good as it did with [freqshift~]. i don't understand the maths behind that so no idea why, but it's obvious to my ears. its especially clear when you increase the attack time.
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
On Mon, 27 Nov 2006 12:43:08 -0600 "Kyle Klipowicz" kyleklip@gmail.com wrote:
"playing trumpet with a hanky over your hand."
Where does that come from Kyle? Is it something a (in)famous musician actually used to do? I have a feeling I've heard it before.
I remember watching Ken Burns' "Jazz," and they talked about how early Jazz musicians would wear handkerchiefs over their hands while playing, to keep imitators from copping their style.
~Kyle
On 11/28/06, padawan12 padawan12@obiwannabe.co.uk wrote:
On Mon, 27 Nov 2006 12:43:08 -0600 "Kyle Klipowicz" kyleklip@gmail.com wrote:
"playing trumpet with a hanky over your hand."
Where does that come from Kyle? Is it something a (in)famous musician actually used to do? I have a feeling I've heard it before.
Hallo, hard off hat gesagt: // hard off wrote:
after having a good listen,
it doesn't sound as good as it did with [freqshift~]. i don't understand the maths behind that so no idea why, but it's obvious to my ears. its especially clear when you increase the attack time.
I couldn't compare because I don't have [freqshift~] (yet). You could try to write both a phasor~-generated triangle and a freqshifted version into two tables and compare. Maybe it's the aliasing?
Frank Barknecht _ ______footils.org_ __goto10.org__
On Tue, 2006-11-28 at 00:29 +0100, Frank Barknecht wrote:
Hallo, hard off hat gesagt: // hard off wrote:
after having a good listen,
it doesn't sound as good as it did with [freqshift~]. i don't understand the maths behind that so no idea why, but it's obvious to my ears. its especially clear when you increase the attack time.
I couldn't compare because I don't have [freqshift~] (yet). You could try to write both a phasor~-generated triangle and a freqshifted version into two tables and compare. Maybe it's the aliasing?
i just superficially followed this thread, so maybe i am talking bullshit:
how can a frequency shifted (not a pitch shifted) triangle be written into a table? i mean, when each partial of the triangle is shifted by a certain value, then all partials won't fit anymore into the same table boundaries, will they?
roman
Ciao
___________________________________________________________ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de
works like a charm now. ... and i think nearly everyone who posted in this thread was hitting on some good idea. the only one i didn't follow up was the [hilbert~] one, and that was what i needed to eliminate the need for the freqshift~ external.
cheers everyone. now i can go on to part 2 of that tutorial and make some snare drums using different methods.
(revised patch attached to this mail)
If all you want to do is generate two different simple waveforms that are shifted 175 and 224 Hz from the original, I would simply use two more triangle oscillators in place of the pitch shifters, and set the frequencies using a bit of math based on the frequency of the first triangle oscillator. I suspect this diagram could represent a hardware synth, where three oscillators is about the max you can get without a huge modular system.
Digital pitch shifting uses either FFT or other windowed procedures which sometimes doesn't always transpose a sound that smoothly and without some artifacts.
best, d.
hard off wrote:
in the following picture:
http://www.soundonsound.com/sos/Mar02/images/synth4.gif
how do i make a frequency shifter ? is this the same as the pitch shifter that i can rip from the pd docs, or is there a simpler way??