# Is it possible to generate a perfect sawtooth wave?

I was wondering if it is possible to generate a perfect sawtooth wave (Wikipedia). Because in nature everything is continuous and therefore for example a common speaker would be unable to produce such a sound (the membrane would have to move back immediately).

PS: It shouln't really matter if we listen to a perfect sawtooth wave or a approximated (contiuous) one as those two waves would only differ at frequencies too high for us to hear, right?

• "those two waves would only differ at frequencies too high for us to hear, right?" ...Both too high and too quiet. – user45266 Mar 13 '19 at 4:36
• See "Gibbs Overshoot Phenomenon" if you're into math. – Carl Witthoft Mar 13 '19 at 15:16

No, it’s not. It might not even be possible to create one that only has undetectable differences. The truth is, each different oscillator design and even each different software synth algorithm or sample is slightly off from a sawtooth in different ways, which is why you can hear the difference between a Moog sawtooth and a Sequential Circuits sawtooth, for example.

This is true at the electrical level before you even get to the speaker. As you note, once the waveform is amplified and used to drive a speaker, it gets even further distorted from the theoretical shape.

That’s the agony and the ecstasy of synthesis - the imperfections make it what it is.

• Hey, imperfections, so to speak, in sound output from real instruments make them what they are :-) . It just gets worse when you try to synthesize the wave pattern "imperfections" of a real instrument in your software toolset. – Carl Witthoft Mar 13 '19 at 15:18

It's not possible to generate a perfect acoustic sawtooth, partly for the reasons that you stated (that a conventional transducer would have to move with infinite speed), but also because once a pressure change is sufficiently abrupt, it starts behaving differently to normal sound waves - see https://en.wikipedia.org/wiki/Shock_wave. So it wouldn't even be possible for that waveform to propagate in the air as a cohesive sound wave.

It shouldn't really matter if we listen to a perfect sawtooth wave or a approximated (continuous) one as those two waves would only differ at frequencies too high for us to hear, right?

In the spirit in which you mean the question, I think that's correct. The approximate sawtooth might not deafen or kill you like a shock wave would, but I expect most audiences would accept that particular artistic compromise.

• Yeah, I for one can live without my eardrums being subjected to infinite g-forces. – Scott Wallace Mar 13 '19 at 14:42

One can come close with a beam chopper. Take a beam of light (or rubidium atoms as we used to do in the lab) and pass it through fast-spinning fan. The fan blades chop really quickly approximating a square wave.

As pointed out Phong, I gave a method for generating a square wave rather than a sawtooth wave. However, one can run the output of the square wave into an operational amplifier (which produces the time integral of its input) and get a sawtooth wave out. The sawtooth wave (y=x)is the integral of the square wave (y=1).