Complex Numbers in Physics

Here is a chore that every first-year physicist meets: add two oscillations of the same frequency but different phase,

x(t) = 3\cos(\omega t) + 4\cos\!\left(\omega t + \tfrac{\pi}{2}\right).

Do it with trigonometry and you are in for a fight — expand the second cosine with the angle-addition formula, collect the \cos\omega t and \sin\omega t pieces, then wrestle the result back into a single R\cos(\omega t + \phi) by squaring, adding, and taking an arctangent. It works, but it is joyless, and it gets worse with three or four terms.

There is a better way, and it is one of the most useful tricks in all of physics. We represent each oscillation as a rotating arrow in the complex plane — a phasor — and then the horrible trig collapses into ordinary vector addition. The answer above, without a single trig identity, is an amplitude of \sqrt{3^2 + 4^2} = 5 at a phase of \arctan(4/3) \approx 53^\circ. This page is about that idea: writing a real oscillation as the real part of a complex exponential, and letting the easy algebra of complex numbers do the work — then taking the real part at the very end.

The one equation everything hangs on

The engine of the whole method is Euler's formula:

e^{i\theta} = \cos\theta + i\sin\theta.

Read this geometrically. The complex number e^{i\theta} is the point on the unit circle at angle \theta from the positive real axis: its real part is \cos\theta (how far right) and its imaginary part is \sin\theta (how far up). Now let the angle grow steadily with time, \theta = \omega t. Then

e^{i\omega t} = \cos\omega t + i\sin\omega t

is a point that marches around the unit circle at angular speed \omega — a rotating arrow, sweeping out a full turn every period T = 2\pi/\omega. That rotating arrow is the phasor. Everything else follows from watching its shadow.

Because \operatorname{Re}\{e^{i\omega t}\} = \cos\omega t, the projection of the spinning arrow onto the real axis is exactly a cosine oscillation. A simple harmonic motion — a pendulum, a mass on a spring, the voltage in an AC circuit, the electric field of a light wave — is nothing but the shadow of uniform rotation. Complex numbers let us keep track of the whole spinning arrow, which is easy to manipulate, and only drop down to the shadow when we want the physical answer.

Picture it: the arrow and its shadow

The figure below shows the phasor e^{i\theta} as an arrow of length 1 pinned at the origin, together with the two shadows it casts: the horizontal one, \cos\theta, onto the real axis, and the vertical one, \sin\theta, onto the imaginary axis. As \theta = \omega t increases the arrow rotates anticlockwise, and its real shadow slides back and forth exactly like a cosine. Step through the reveal to see each piece.

Keep this picture in mind for the rest of the page. A phasor carries two facts at once — an amplitude (the arrow's length) and a phase (the arrow's starting angle) — bundled into a single complex number. That bundling is the whole reason the algebra gets easier.

Worked example 1 — packaging an oscillation as a phasor

A general oscillation has an amplitude A, a frequency \omega, and a phase offset \phi:

x(t) = A\cos(\omega t + \phi).

Because \cos(\text{anything}) = \operatorname{Re}\{e^{i(\text{anything})}\}, we can write this as the real part of a complex exponential:

x(t) = \operatorname{Re}\!\left\{A\,e^{i(\omega t + \phi)}\right\} = \operatorname{Re}\!\left\{\underbrace{A\,e^{i\phi}}_{\text{complex amplitude }\tilde{A}}\; e^{i\omega t}\right\}.

Look at what just happened. We used the law e^{i(\omega t + \phi)} = e^{i\phi}\,e^{i\omega t} to split off the time part. Everything that makes this particular oscillation what it is — its amplitude A and its phase \phi — is now packed into the single complex number

\tilde{A} = A\,e^{i\phi} = A\cos\phi + i\,A\sin\phi,

called the complex amplitude (or phasor). The universal factor e^{i\omega t} — the same spin shared by every oscillation at this frequency — rides along at the end and is only reinstated when we take \operatorname{Re}\{\cdots\}. The modulus of \tilde{A} gives back the amplitude, |\tilde{A}| = A, and its argument gives back the phase, \arg\tilde{A} = \phi.

Worked example 2 — adding two oscillations is just adding arrows

Now the payoff. Add two oscillations of the same frequency \omega:

x(t) = A_1\cos(\omega t + \phi_1) + A_2\cos(\omega t + \phi_2).

Write each as a real part and pull the common spin out front:

x(t) = \operatorname{Re}\!\left\{\left(A_1 e^{i\phi_1} + A_2 e^{i\phi_2}\right)e^{i\omega t}\right\} = \operatorname{Re}\!\left\{\tilde{A}\,e^{i\omega t}\right\},\qquad \tilde{A} = A_1 e^{i\phi_1} + A_2 e^{i\phi_2}.

The two oscillations combine into a single one whose complex amplitude \tilde{A} is just the sum of the two phasors — literally the tip-to-tail addition of two arrows in the plane. No angle-addition formulas, no collecting terms. Take the concrete case from the hook, 3\cos\omega t + 4\cos(\omega t + \tfrac{\pi}{2}):

\tilde{A} = 3e^{i\cdot 0} + 4e^{i\pi/2} = 3 + 4i.

The resultant amplitude and phase drop straight out of the modulus and argument:

A = |\tilde{A}| = \sqrt{3^2 + 4^2} = 5,\qquad \phi = \arg\tilde{A} = \arctan\!\frac{4}{3} \approx 53.1^\circ,

so x(t) = 5\cos(\omega t + 53.1^\circ). A page of trigonometry has become a right triangle. This is exactly the reasoning behind wave interference, the addition of AC voltages, and the superposition of light — add the phasors, read off length and angle.

Worked example 3 — why calculus turns into algebra

The second great convenience is what happens when you differentiate. Watch the time derivative of the spinning factor:

\frac{d}{dt}\,e^{i\omega t} = i\omega\,e^{i\omega t}.

Differentiating with respect to time does nothing but multiply by i\omega. A derivative — an operation of calculus — has become plain multiplication by a number. Geometrically, multiplying by i = e^{i\pi/2} rotates a phasor by 90^\circ, which is exactly the quarter-cycle head start that velocity has on displacement, and the factor \omega scales it up. Two derivatives multiply by (i\omega)^2 = -\omega^2, so a differential equation like the one for a mass on a spring,

m\ddot{x} + kx = 0,\qquad x = \operatorname{Re}\{\tilde{A}\,e^{i\omega t}\},

turns into the purely algebraic condition (-m\omega^2 + k)\tilde{A} = 0, giving \omega = \sqrt{k/m} at once. This is the whole basis of AC circuit analysis: replace the awkward calculus of capacitors and inductors (i \to C\,dV/dt, V \to L\,dI/dt) with multiplication by a complex impedance Z, and Ohm's law \tilde{V} = Z\,\tilde{I} handles resistors, capacitors, and inductors on the same footing — with Z_C = 1/(i\omega C) and Z_L = i\omega L. Differential equations become arithmetic.

See the projection move

The chart shows two physical oscillations, A_1\cos(\omega t) and A_2\cos(\omega t + \phi), together with their sum. Each is the real shadow of a rotating phasor; their sum is the shadow of the single resultant phasor \tilde{A} = A_1 + A_2 e^{i\phi}. Slide the phase \phi and the amplitudes and watch the resultant swell (constructive, phasors aligned) or shrink (destructive, phasors opposed) — interference, in one moving picture. The horizontal axis is \omega t in radians.

Set \phi = 0 and the two waves march in step, so the sum has amplitude A_1 + A_2 — perfectly constructive. Push \phi to \pi and they fight, so the sum has amplitude |A_1 - A_2| — destructive, vanishing entirely when the amplitudes match. Every value in between is a phasor sum, and the resultant is always a clean cosine of the same frequency.

The complex exponential is a bookkeeping device, not a claim about reality. The physical quantity — the displacement, the voltage, the field — is always the real part, x(t) = \operatorname{Re}\{\tilde{A}\,e^{i\omega t}\}, and it is a perfectly ordinary real number at every instant. We carry the imaginary part along only because it is the convenient other half of the rotating arrow: it stores the \sin component (the phase information) so that multiplication and differentiation stay simple. The trick works because the operations we use — adding, differentiating, multiplying by real constants — all commute with taking the real part: doing the algebra first and taking \operatorname{Re} at the end gives the same answer as working with real cosines throughout, only far less painfully. The i is scaffolding; the building it helps you raise is entirely real.

Never forget to take the real part at the end. The single most common slip is to compute happily in complex numbers and then quote the raw complex result as the physical answer. The measurable oscillation is x(t) = \operatorname{Re}\{\tilde{A}\,e^{i\omega t}\} — not \tilde{A}\,e^{i\omega t} itself, which is a spinning complex number, not something a voltmeter or a ruler could ever read.

Two related traps. First, the real-part shortcut is only safe for linear operations. Adding phasors, scaling them, differentiating them — all fine. But \operatorname{Re}\{z\}^2 \ne \operatorname{Re}\{z^2\}, so anything nonlinear — computing instantaneous power P = VI, or a v^2 term — must be done after returning to real quantities, or with extra care using conjugates. Second, electrical engineers write the imaginary unit as j (because i already means current) and often use e^{-j\omega t} with the opposite sign convention. It is the same physics — just check whose convention you are reading before you trust a sign on a phase.

Almost everywhere a wave appears. In optics, the amplitude and phase of light are a complex number, and interference and diffraction are phasor sums. In quantum mechanics the wavefunction \psi = |\psi|\,e^{i\theta} is irreducibly complex — here the complex number is not a convenience but the physics itself, and the phase governs interference of probability amplitudes. In signal processing the Fourier transform decomposes any signal into rotating phasors e^{i\omega t} of every frequency. In control theory and vibrations, resonance and damping live in the complex frequency plane. The humble idea "an oscillation is the shadow of a spinning arrow" is one of the great unifying threads running through all of physics.