import matplotlib
if not hasattr(matplotlib.RcParams, "_get"):
matplotlib.RcParams._get = dict.get
5.2 The phasor#
Now we bring the complex plane back into a sound context. Recall the basic sinusoid, the most elementary periodic sound. In Chapter 1 we wrote it as \(a\sin(\omega t + \phi)\), but here we will use the cosine form for now:
These forms are interchangeable: \(\cos(\omega t) = \sin(\omega t + \pi/2)\), so switching to cosine just amounts to a particular initial phase.
Tip
Here \(\omega\) is angular frequency, in units of \(\frac{\text{radians}}{\text{second}}\). If you’re rusty on angular frequency, revisit Frequency and angular frequency. We will use angular frequency regularly from here on, since it spares us from writing \(2\pi f\) everywhere.
Suppose we want to transform this basic sinusoid so that it operates in the complex plane. How might we do that? We apply Euler’s formula. Starting from \(e^{j\theta} = \cos\theta + j\sin\theta\), we multiply both sides by \(a\) and then let the angle vary with time as \(\theta(t) = \omega t\):
What have we accomplished? Two things:
We brought our basic sinusoid into the complex plane by complementing it with an analytical tool, the term \(j\, a\sin(\omega t)\). The basic sinusoid is always real-valued, while this tool is always imaginary-valued, and it is always exactly \(\pi/2\) radians “out of phase” with the basic sinusoid.
We used Euler’s formula to fold the two real sinusoids into a single, compact complex sinusoid, \(a\, e^{j\omega t}\).
What does a complex sinusoid look like? It is a vector of length \(a\) that rotates counterclockwise, tracing the outline of a circle of radius \(a\) in the complex plane. As it rotates, its real part traces a cosine and its imaginary part traces a sine:
Fig. 19 A complex sinusoid, or phasor, \(a\, e^{j\omega t}\) at one instant (here \(a = 1\)). Left: in the complex plane it is a rotating vector. Middle and right: its real and imaginary parts, projected out over time, are a cosine and a sine. The phasor completes one full rotation every \(1/f\) seconds, where \(f = \omega / 2\pi\).#
A complex sinusoid is very commonly called a phasor. Plainly, a phasor is just a fancy way to draw a circle over and over.
Definition 15 (Phasor (complex sinusoid))
A phasor is a complex sinusoid: a function of time parameterized by an amplitude \(a\) and an angular frequency \(\omega\),
It traces a circle of radius \(a\) in the complex plane, completing one revolution every \(1/f\) seconds (where \(f = \omega / 2\pi\)). Its real part is a cosine and its imaginary part is a sine.
The subscripts \(a\) and \(\omega\) are fixed parameters that pick out which phasor we mean, exactly as \(a\) and \(f\) parameterize the basic sinusoid. The lone input to the function is still time \(t\).
Important
Like the basic sinusoid, a phasor is a function of time, not of frequency. The only difference is that it rotates in the complex plane rather than oscillating along a single real axis.
Take time to study this. Deriving the phasor is the main reason we reviewed the complex plane. The complex sinusoid is perhaps the single most important expression in computer music. It captures the periodic essence of sound in the basic sinusoid, and, as we will now see, it gives rise to the Fourier transform that uncovers a unique sinusoidal recipe for any sound.