I am back with another problem. This problem is very similar to the last problem I had. I know Nyquist can be used in many ways. My question is, since I can generate exponential wind-ups now, is there a code someone has done and tested that can generate exponential wind-downs?
What I do now is generate many chirps of varying lengths back to back, and that takes ages and is usually incorrect according to TheWoog34. I want my synths to be correct with the timing of everything and how things are done.
Yes steve it would be for siren synthesizing. The code I’m using for wind-ups is the same as the code that you linked in the second link. I was figuring, if there was some way to reverse the coding to reverse the way it generates (generates a wind-down rather than a wind-up), it might work the way I would like it to. Maybe I’ll have to learn basic Nyquist coding and code one myself somehow.
Have a play with this code.
It is just the basic sawtooth version so you will get some aliasing distortion (the distortion will sound similar to tuning in a short-wave radio)…
There is an additional control “opt” which may be set to 1, 2 or 3 to give different pitch change curves. Are any of those close to what you need?
(setq start-freq 1320) ; initial frequency - Hz
(setq final-freq 440) ; final frequency - Hz
(setq initial-amp 0.5) ; initial amplitude on a scale 0 to 1
(setq final-amp 0.5) ; final amplitude on a scale 0 to 1
(setq opt 1) ; pitch curve can be 1, 2 or 3
(setq hz1 start-freq)
(setq hz2 final-freq)
(setq iamp (max (min initial-amp 1) 0))
(setq famp (max (min final-amp 1) 0))
(mult (pwlv iamp 1 famp)
(- hz1 hz2)
(1 (sum -1 (pwev 1 1 0.01)))
(2 (pwlv 0 1 -1))
(T (mult -1 (pwev 0.1 1 1))))))
It depends on the siren. Some sirens, such as the ACA Hurricane, STL-10 and STH-10 have VERY long wind-downs that aren’t exactly logarithmic but they aren’t linear either. Thunderbolts tend to have quick logarithmic wind-downs.
Oh, Steve, is there any audacity plugin that can be like a “low-pass fade-in” - it starts at a low-pass filter of your choice and gradually becomes less low-passed? When sirens spin, the sound is low-passed more as the siren rotor gets slower. The “low-pass fade” could apply to wind-downs as well as wind-ups.
Also, one more question. The exponential wind-up coding that you gave me on the forums a while ago is amazingly perfect for synthesizing single phase sirens - the motor starts torque-y and winds up slower and slower until it peaks. However, most sirens were made with 3 phase motors which gives them a fairly linear wind-up. Unlike the linear chirp option in Audacity, 3 phase sirens tend to have this smooth “pitch curve” right as it peaks while the linear chirp in Audacity jumps right up to full speed.
Here’s a siren with a wind-up that can be completely accurately reproduced using the linear chirp generator in Audacity - http://www.youtube.com/watch?v=X2MlmcY8UZU - notice the difference right near the end of the wind-up.
I figured out how to manually do the wind-up: this is a little time consuming but it DOES work. Simply combine the regular chrip generator with the exponential chirp nyquist coding. I also found other programs that can do the low-pass curve.
Could you point me towards a plugin that is like the HQ tone plugin except it generates chirps instead? Non-aliased waveforms are a lot easier to work with.
Thank you for the tremendous amount of help you have given us so far, Steve. I’ll be sure to give you plenty of credit in my latest synth I’m working on.