Sawtooth wave
From Free net encyclopedia
The sawtooth wave (or saw wave) is a kind of basic non-sinusoidal waveform. It is named a sawtooth based on its resemblance to the teeth on the blade of a saw.
The usual convention is that a sawtooth wave ramps upward as time goes by and then sharply drops. However, there are also sawtooth waves in which the wave ramps downward and then sharply rises. The latter type of sawtooth wave is called a 'reverse sawtooth wave' or 'inverse sawtooth wave'. The 2 orientations of sawtooth wave sound identical when other variables are controlled.
The piecewise linear function
- <math>x(t) = t - \operatorname{floor}(t)</math>
based on the floor function of time t, is an example of a sawtooth wave with period 1.
A more general form, in the range −1 to 1, and with period a, is
- <math>x(t) = 2 \left( {t \over a} - \operatorname{floor} \left ( {t \over a} + {1 \over 2} \right ) \right )</math>
This sawtooth function has the same phase as the sine function.
A sawtooth wave's sound is harsh and clear and its spectrum contains both even and odd harmonics of the fundamental frequency. Because it contains all the integer harmonics, it is one of the best waveforms to use for constructing other sounds, particularly strings, using subtractive synthesis.
A sawtooth can be constructed using additive synthesis. The infinite Fourier series
- <math>x_\mathrm{sawtooth}(t) = \frac {2}{\pi}\sum_{k=1}^{\infin} \frac {\sin (kt)}{k} </math>
converges to a sawtooth wave. In digital synthesis, the series is only summed over k such that the highest harmonic, Nmax, is less than the Nyquist frequency (half the sampling frequency). This summation can generally be more efficiently calculated using the Fast Fourier transform. If the waveform is digitally created directly in the time domain using a non-bandlimited form, such as y = x - floor(x), infinite harmonics are sampled and the resulting tone contains aliasing distortion.
An audio demonstration of a sawtooth played at 440 Hz (A4) and 880 Hz (A5) and 1760 Hz (A6) is available below. Both bandlimited (non-aliased) and aliased tones are presented.