♪Music, Built

Act X · The Studio and the Stage

Part 54 of 68

Microphones and Loudspeakers

Foundationsstarts at this level38 min of film13 chaptersprerequisites: Part 2, Part 4, Part 8, Part 48, Part 49

How do microphones turn air into voltage and loudspeakers turn it back, and what does each leave out?

Headphones plugged into a microphone socket work: a dynamic transducer runs both ways (e = Bl v, F = Bl i), and an ear question hears one used as a microphone, dull above its resonance. Electrical recording (1925) made the crooner. Dynamic, condenser, ribbon and electret transducers; electrical, mechanical and acoustical circuits. Pressure is omnidirectional, its gradient a figure-8, and A + (1 - A) cos theta makes the family (the hypercardioid's 6.0 dB is the most directional); an ear question hears a piano behind a singer through three patterns (the cardioid 30 dB down). A gradient microphone's bass rises near a point source (1 + 1/(jkr): +20.8 dB at 100 Hz at 5 cm, heard). Thermal noise (-129.7 dBu for 200 ohms) puts a dynamic microphone's floor near 16 dB SPL; a balanced line with 1 per cent imbalance drops hum 40 dB (heard). A woofer's Thiele-Small parameters, a lumped-element simulator of baffle, sealed and vented boxes checked against Small's and Thiele's closed forms (to a tenth of a hertz; B4 flat to 40 Hz), impedance curves, efficiency and the iron law; three loudspeakers heard (phone 844 Hz, bookshelf 98, floor-stander 39). Horns as transformers; crossovers (Butterworth's hole and bump, Linkwitz-Riley flat); amplifier classes. Headphones and a filtered-x LMS canceller (-33 dB below 200 Hz, none above 2 kHz, heard). Arrays steer (eight microphones reject a second singer 6 dB, an ear question); small speakers are linearized.

What you need. Part 2 for spherical waves and the Helmholtz resonator; Part 4 for the missing fundamental; Part 8 for the voice; Part 48 for delta-sigma; Part 49 for filters and sweeps. Circuit analysis, complex impedance, least squares.

Ideas, mathematics and history
transduction both ways, polar patterns, proximity effect, noise, Thiele–Small parameters, boxes and ports, crossovers, amplifiers, headphones
What we build, compute and hear
virtual microphones and loudspeakers; the Tune through a phone speaker and a ported box

What you will be able to do

Foundations

  • Hear a headphone used as a microphone, three patterns with a piano behind the singer, and a walk round a cardioid.
  • Hear the proximity effect at three distances, hum on an unbalanced and a balanced line, and a crossover's hole.
  • Hear a groove through three loudspeakers, a cabin with noise cancelling off and on, and an array steered.

Full course

  • Derive the first-order patterns, their directivity and nulls, and the proximity effect's 1 + 1/(jkr).
  • Simulate a driver in sealed and vented boxes from Thiele-Small parameters and check against Small and Thiele.
  • Compute thermal noise, balanced-line rejection, crossover sums, an FxLMS canceller and a delay-and-sum array.

Research

  • Find how much louder and deeper a small speaker can be made to sound, safely, by control alone.

Practice

  • Choose and place microphones by pattern and proximity, design a box by its parameters, and use balanced lines.

Contents

Each chapter has a home level. Choose a track to see what to read and watch: Foundations 22 min · Full course 35 min · Research 38 min · Practice 35 min.

  1. 0A loudspeaker run backwardsFoundations2 min
  2. 1Transducers and their circuitsFoundations3 min
  3. 2Polar patternsFoundations4 min
  4. 3The proximity effectFoundations3 min
  5. 4Noise and balanced linesFoundations3 min
  6. 5The loudspeaker as a filterPractice3 min
  7. 6Sealed and vented boxesPractice4 min
  8. 7Three loudspeakersFoundations2 min
  9. 8HornsPractice3 min
  10. 9Crossovers and amplifiersPractice3 min
  11. 10Headphones and noise cancellingFoundations3 min
  12. 11Frontier: arrays, beamforming and linearizationResearch3 min
  13. Variation 54, recap and problemsAll tracks2 min

Also on this page: Lecture · Key results · Try it · Lab · Problems · Notes and sources · Build the film.

Lecture

The text of each chapter is the film's narration, as it is spoken, so you can read along or revise without the film. The pictures are in the film. A dashed box stands for a number the film computes when it is rendered (hover over it to see what is computed); the README's figures for each chapter, where it lists them, follow the chapter's text.

A loudspeaker run backwardsFoundations2 min

The microphone changed singing. Now hear an unusual one. The Tune's first phrase, sung twice. Once through a flat reference response. Once through a simulated dynamic headphone used as a microphone. Which was the headphones?

The second: dull, boomy, but unmistakably the voice. A headphone driver is a coil on a diaphragm in a magnet's field. Push the diaphragm with sound and the coil, moving through the field, makes a voltage. But above its resonance the diaphragm's mass resists being pushed, more at every octave, so the highs fall away six decibels an octave. A loudspeaker is a microphone run backwards, and this part is about both.

The microphone changed singing. Before 1925 recording was acoustic: singers bellowed into a horn whose diaphragm cut a groove by sheer pressure. In 1925 major record companies introduced commercial electrical recording, with the condenser microphone Edward Wente had built at Bell Labs in 1916, and an amplifier. The microphone heard a soft voice close to it as well as a loud one far away, and the crooners, Bing Crosby above all, sang quietly and intimately, to a microphone, for millions. A transducer changed what a voice could be.

Here is the plan. Transducers, and the circuits that describe them. Polar patterns, the proximity effect, noise and balanced lines. The loudspeaker as a filter, and its Thiele-Small parameters. Sealed and vented boxes, simulated and checked against their closed forms. Horns, crossovers and amplifiers. And headphones, noise cancelling and arrays.

1Transducers and their circuitsFoundations3 min

How does air become a voltage?

A microphone turns pressure into voltage, in one of a few ways. Dynamic: a coil fixed to the diaphragm moves in a magnet's field and makes a voltage B l times its velocity. Condenser: the diaphragm is one plate of a charged capacitor, and the voltage follows the gap, the design Wente built at Bell Labs in 1916. Ribbon: a thin metal ribbon in a magnet's gap, open to the air on both sides. And the electret, from Gerhard Sessler and James West in 1962: a condenser whose charge is frozen into a plastic film. Electrets became ubiquitous; many current phones instead use MEMS microphones.

The dynamic transducer works both ways. As a microphone, the coil moving at velocity v makes a voltage B l v. As a loudspeaker, a current i in the same coil makes a force B l i. B is the magnet's field and l the length of wire in it, and one number, B l, couples the electrical side to the mechanical both ways. So every dynamic transducer is both: the hook's headphones, and the loudspeaker in your laptop.

The condenser deserves its two lines. A capacitor's capacitance is the permittivity times the area over the gap, and its voltage is the charge over the capacitance. Hold the charge fixed, and a change in the gap makes a proportional change in voltage: an ideal constant-charge linear relation between gap and voltage; the complete microphone also has mechanical and electrical limits. The diaphragm can be a few microns of gold-coated film, light enough to follow the air to the highest frequencies; but the output impedance is enormous, so a transistor inside the body converts it before the cable.

To compute a transducer, treat everything as a circuit. Voltage, force and pressure play the same part; so do current, velocity, and the volume of air moved per second. A mass behaves like an inductance, and so does a slug of air in a port; a spring like a capacitance, and so does a box of air; friction and radiation like resistance. The same equations in three costumes: one circuit simulator solves them all, and this part's does.

Each kind found its job. Dynamic microphones are rugged and need no power: the stage's workhorses. Condensers are light and fast, and need an electrical supply; forty-eight-volt phantom power is common, while other designs use batteries, plug-in power or separate supplies: the studio's choice. Ribbons are delicate and smooth, prized for brass and voices. And each responds either to pressure, or to its gradient, a difference that shapes how they hear direction, which is the next chapter.

2Polar patternsFoundations4 min

Why does a microphone hear some directions and not others?

Direction comes from how the diaphragm meets the air. A pressure microphone's diaphragm is closed at the back, and pressure is the same whichever way the sound comes from: it is omnidirectional. A pressure-gradient microphone is open on both sides and feels the difference between front and back. A wave from the side reaches both sides at once, so there is no difference and no output: the figure-8, cosine theta. Add the two, and at the front they add while at the back they cancel: the cardioid, a half of one plus cosine theta. Mix them in other proportions and you get the whole family.

Here is the family, r of theta equals A plus one minus A cosine theta, with the front at the top. A equals one: the omni, a circle. A half: the cardioid, the heart, with a null straight behind. Less pressure and more gradient: the supercardioid and the hypercardioid, narrower at the front, with a small lobe behind and two nulls off to the sides. And A zero: the figure-8, as loud behind as in front, deaf at the sides.

Hear a cardioid's pattern directly: a singer walking once round it, starting in front.

The voice fades as the singer passes the side, all but vanishes behind, at the null, and returns as the singer comes round to the front: the heart shape, heard.

How directional is each? Average a pattern's squared response over every direction: under an isotropic diffuse-field assumption, this estimates relative reverberant pickup. Its reciprocal is the directivity factor, and in decibels the directivity index. The cardioid and the figure-8 both reach four point eight decibels, rejecting two thirds of the room. The hypercardioid is the most directional of the family, six decibels: in this ideal diffuse-field model it can stand twice as far from an on-axis point source as an omni for the same direct-to-reverberant ratio. And the nulls tell you where to put what you do not want to hear.

Real patterns change with frequency. The first-order family assumes the microphone is small next to the wavelength. A twenty-five millimetre diaphragm is a quarter of a wavelength at about three point four kilohertz, and above that even an omni narrows towards the front, so sound from the side loses its treble. Off-axis sound is duller: a pattern is really a family of patterns, one per frequency. Small-diaphragm microphones keep their pattern higher; large ones colour the room.

Your turn. A singer in front of the microphone, a piano behind and a little to one side, in a lively room. Three microphones, an omni, a cardioid and a figure-8, in some order. Which heard the least piano?

The second, the cardioid: the piano sits near its rear null, decibels down. The omni hears it at full strength along with the most room; the figure-8 hears it almost as loud as the singer, because its back is as live as its front, though it takes in less of the room.

Patterns are chosen for the job. On stage, cardioids and supercardioids, with their nulls aimed at the monitor loudspeakers. In a good room, omnis, for the room's sound as well as the source's. For stereo, two figure-8s crossed at ninety degrees, Alan Blumlein's pair of 1931, capture direction itself. Real microphones follow the first-order family only at low frequencies; at high ones the body and diaphragm narrow them. And a gradient microphone close to its source is not even flat.

3The proximity effectFoundations3 min

Why does a voice grow bass as it nears the microphone?

A gradient microphone has a quirk. A small source, a mouth, sends out a spherical wave: pressure P over r, with the phase turning as k r. The microphone measures its slope, and the slope has two parts: j k, which is all there is far away, and one over r. So close up the response is one plus one over j k r times the far-away response, and the extra part is largest when k r is small: low notes, at short distances.

Here it is for a figure-8. At a metre the rise is small, about a decibel at a hundred hertz. At fifteen centimetres, decibels; at five, : the bass of a voice multiplied tenfold. A cardioid is half gradient, so its rise is gentler, but it is still there.

There are ways to tame it. A bass-cut filter on the microphone or the desk undoes the rise, but only at one distance. Some microphones open several ports at different distances behind the diaphragm, so the rise is spread out and smaller. An ideal pressure omni has no such gradient boost, so it can be used close without boom, at the cost of hearing more of the room. Two diaphragms back to back let a microphone switch patterns, and the gradient part brings the rise with it. Choosing a microphone is often choosing a proximity effect.

Hear it: the tenor at a metre, at fifteen centimetres, and at five. From a metre the voice is plain; at fifteen centimetres it is warmer; at five it is thick and chesty, the sound of a radio announcer leaning into the microphone. Matched in loudness, the change you hear is the balance of bass against everything else.

Performers learned to play it. Singers move closer for intimacy and further back for the loud notes; broadcasters lean in for authority, and podcasters too. Many microphones have a bass-cut switch to undo it. An ideal pressure omni has no pressure-gradient proximity boost, because pressure has no gradient term. The effect is pure geometry: a spherical wave's slope.

4Noise and balanced linesFoundations3 min

How quiet can a microphone be, and how does its signal survive the cable?

Every microphone signal rides on noise, and some of it is unavoidable. The electrons in any resistor jostle with the heat, as John Johnson measured and Harry Nyquist explained in 1928: the noise voltage is the square root of four k T R B. For a two-hundred-ohm microphone over the audio band, microvolts: dBu. This is the thermal-noise contribution of that resistance at this temperature and bandwidth; a preamplifier adds its own noise.

Put it in acoustic terms. A typical dynamic microphone gives two millivolts for one pascal, ninety-four decibels of sound: dBu. The thermal floor is decibels below that, so the floor is like a sound of decibels arriving at the microphone. A very quiet room is about twenty-five; a good condenser's own noise about ten. In many ordinary rooms ambient noise dominates; the balance depends on microphone sensitivity, self-noise and bandwidth.

The balanced line carries one more trick. A condenser needs power, for its polarizing voltage and its impedance converter. Phantom power sends forty-eight volts down both signal wires at once, through matched resistors. The receiver takes the difference, so the power is invisible to it: the same trick as the hum. A dynamic microphone ignores it, because its coil sees no difference between the wires. One cable carries the signal, the power and the rejection of hum.

A microphone's tiny voltage must then cross a long cable past lighting dimmers and transformers. Our symmetric balanced model uses two conductors carrying opposite halves of the signal. Balance means matched impedances to ground; equal and opposite signal voltages are not required. The conductors are twisted together inside a shield. Hum from a transformer lands almost equally on both. The receiver takes the difference: the signal comes back whole, and the hum, the same on both, cancels.

Hear it: the voice down an unbalanced cable past a transformer, then down a balanced one.

Unbalanced, a buzz at fifty hertz and its odd harmonics sits under the voice. Balanced, with the two conductors matched to one per cent, it falls decibels and all but vanishes. This explains the common three-pin balanced XLR connection; other microphone interfaces also exist.

Along the chain the levels climb. Microphone level is millivolts, line level about a volt, speaker level tens of volts. A preamplifier raises the microphone by forty to sixty decibels, as close to it as possible. Every stage should sit well above its noise and well below its clipping, gain staging, which Part 56 takes up. The last stage, the power amplifier, drives the loudspeaker, the other end of the chain.

5The loudspeaker as a filterPractice3 min

Why can't a small loudspeaker play bass?

Now run the transducer the other way. In 1925 Chester Rice and Edward Kellogg built the moving-coil loudspeaker, the design still in almost every speaker: a coil in a magnet's gap, glued to a cone, held by a spider and a surround. Electrically it is the coil's resistance; mechanically, the cone's mass, the suspension's spring and some friction. A mass on a spring has a resonance: below it the spring rules, above it the mass. So a loudspeaker is a high-pass filter, and its resonance sets how low it plays.

A woofer is described by a handful of numbers, named after Neville Thiele and Richard Small, who showed in the 1960s and 1970s how a small set of parameters can describe low-frequency small-signal behavior; excursion limits, heating, breakup and directivity need more information. Its resonance in free air, forty hertz for ours. Three Qs, how sharp the resonance is: from the electrical side, where the motor acts as a brake, from the mechanical side, and in total. V a s, the volume of air as stiff as the suspension, fifty litres. The cone's area, the coil's resistance. From them follow the motor strength, the moving mass and the compliance, and the whole circuit.

The amplifier is part of the loudspeaker. A moving coil is also a generator, and its back voltage drives a current through the amplifier. If the amplifier's output resistance is tiny, that current brakes the cone: electrical damping, the Q e s of the parameters. A valve amplifier with a high output resistance damps less, so the bass rings longer and the response follows the impedance curve. The speaker cable's resistance adds to the coil's. The amplifier and the loudspeaker are one circuit.

The simulator solves the circuit at every frequency. Here is the woofer's electrical impedance on a large baffle: six ohms almost everywhere, but at resonance it rises to ohms, because the cone moves most there, and its moving coil makes a voltage that opposes the current. This peak is how Thiele-Small parameters are measured: using impedance measurements together with additional mass, enclosure or geometrical information to determine all the parameters.

How efficient is it? Small's formula: four pi squared over c cubed, times f s cubed, times V a s, over Q e s. For our woofer, per cent: under one per cent of the amplifier's power becomes sound, and the simulator agrees, about ninety-two decibels at a metre. Hidden in the formula is the loudspeaker designer's iron law, named after Josef Anton Hofmann: deep bass, a small box, high efficiency; choose two. The resonance enters cubed: an octave lower at the same efficiency needs eight times the volume.

6Sealed and vented boxesPractice4 min

Why put a loudspeaker in a box at all?

A loudspeaker needs a box because of its back. A bare cone pushes air forward and pulls it from behind at the same moment. At low frequencies the air simply flows round the edge, and the two sides cancel: an acoustic short circuit. A sealed box traps the back wave, and its air becomes a second spring. A vented box lets the back wave out through a port, in step, at the box's own resonance: Part 2's Helmholtz resonator, inside a loudspeaker.

Put our woofer in sealed boxes of three sizes. The box's air adds stiffness to the suspension, so the resonance rises and sharpens: by the square root of one plus V a s over the box's volume, as Richard Small showed in 1972. Twenty litres: the response bulges before it falls. Fifty: smoother. Two hundred: the gentlest roll-off, but a box the size of a cupboard. Each falls twelve decibels an octave below its resonance: a second-order high-pass.

Check the simulator against the closed forms. For each sealed box, Small's formulas give the minus-three-decibel point; the simulation, which knows nothing of the formulas and only solves the circuit frequency by frequency, lands within a tenth of a hertz. And for the vented box designed by Thiele's fourth-order Butterworth recipe, the closed form says the response is down three decibels exactly at the driver's resonance, forty hertz; the simulation says .

Now open a port. In a box of litres the woofer, sealed, reaches down to hertz. Tune a port so that the box resonates at forty hertz, and below the driver's own resonance the port takes over: its slug of air, pushed by the box's pressure, radiates in step with the cone. The response now reaches hertz, maximally flat, nearly an octave deeper. The price: below the tuning it falls twenty-four decibels an octave, and the cone, no longer held by the box's air, flaps freely.

How long must the port be? The Helmholtz formula of Part 2: the tuning frequency is c over two pi, times the square root of the port's area over the box's volume times the port's effective length. For a port seven centimetres across in our -litre box, tuned to forty hertz, the effective length is centimetres; less the air that moves with the ends of the tube, a tube about centimetres long. It is Part 2's bottle, with the box as the bottle and the port as its neck. Too narrow a port and the air rushes and chuffs; too wide and it will not fit.

The amplifier sees the box too. On an open baffle, one impedance peak at the driver's resonance; in a sealed box, one peak, higher in frequency. In a vented box, two peaks, with the port's tuning in the dip between them, where the port does the work and the cone hardly moves. Builders measure exactly this to check a port's tuning.

7Three loudspeakersFoundations2 min

What does each size of loudspeaker leave out?

Three loudspeakers, simulated with the same circuit. A phone's: a cone of a square centimetre in a tiny sealed chamber, down three decibels at hertz. A sealed bookshelf speaker: hertz. A vented floor-stander: hertz. The bass a speaker can make is set by how much air it can move, the cone's area times its travel, and by the box.

Real loudspeakers are measured, not just simulated. Play Part 49's exponential sweep, record it with a measurement microphone, and deconvolve. Cut the impulse response off before the first reflection from the floor arrives: a gated, quasi-anechoic measurement. The gate's length limits the lowest frequency it can see: five milliseconds, about two hundred hertz. Below that, measure close to the cone, or outdoors on a pole. And measure off axis too, because off-axis radiation contributes strongly to room sound; its share depends on room, distance and directivity.

Hear one groove through each: the phone, the bookshelf speaker, the floor-stander. Through the phone the bass line all but disappears; you hear its upper harmonics and the click of the kick, and your ear rebuilds the rest, Part 4's missing fundamental. The bookshelf speaker gives the bass back but not the lowest thud of the kick; the floor-stander has both.

Engineers live with this. Mixes are checked on small speakers too, so that a bass line survives as harmonics. Phones add a little distortion on purpose, or a virtual-bass processor, to make harmonics the ear can use, and Part 4's missing fundamental does the rest. Room modes can strongly change bass response alongside the speaker's own limits, which is Part 55. And to get more sound out of a small driver, a different shape helps: the horn.

8HornsPractice3 min

How does a horn make a small driver loud?

Efficiency is a matter of matching. A small cone is a poor match for air: air is light, the cone heavy, and most of its motion just sloshes air nearby. The resistance a small piston feels from the air grows as the frequency squared, so at low frequencies it is almost nothing. A horn is a gradual change of area, a small throat opening into a wide mouth, and at the throat the driver pushes a column of air that cannot get out of the way: a better match. It is the gramophone's horn, or a pair of cupped hands.

Here is what the driver sees, as a fraction of the best possible match. A bare piston of the throat's size: its resistance creeps up as frequency squared and only reaches full match high in the treble. An exponential horn, whose area grows by the same factor every few centimetres, as Arthur Webster described in 1919: above a cutoff set by its flare, the throat presents nearly the full match. At two hundred hertz that is decibels better loading. Below cutoff this ideal infinite exponential horn has no propagating resistance; finite horns also have termination effects and resonances, so a bass horn must be enormous.

Horns do a second job. A horn also controls where the sound goes: its walls set the beam's width. A cone beams more as the frequency rises, so a shallow horn around a tweeter can match the woofer's width at the crossover, and then the sound reflected from the walls has the same colour as the direct sound. Many modern loudspeakers use such waveguides for this reason, not for loudness. In a room, even directivity can matter more than a flat response on the axis.

Horns have a long history. The gramophone's horn, from the 1890s to the 1920s, made music loud with no electricity at all, only matching. Western Electric's cinema horns of the late 1920s let a few watts of valve amplifier fill a theatre. Compression drivers and horns still carry the treble at concerts, as Part 59 will show. The cost is size at low frequencies, and a colour some call honk. And no single driver can do everything: hence crossovers.

9Crossovers and amplifiersPractice3 min

How do two drivers become one loudspeaker?

Most loudspeakers use more than one driver. A woofer must be big to move air, and a big cone beams and breaks up at high frequencies; a tweeter is small and light and would tear itself apart on bass. A crossover sends the lows to one and the highs to the other: a low-pass and a high-pass. The two must add back to a flat response, in level and in phase, which is harder than it sounds.

Add the two sections back and see. Two second-order Butterworth filters, in phase: at the crossover each is a quarter turn of phase away from the input in opposite directions, so they arrive half a cycle apart and cancel: a hole. Invert the tweeter and they add, but too well: three decibels too loud at the crossover. Siegfried Linkwitz and Russ Riley's answer, in 1976: square each Butterworth. Each section is six decibels down at the crossover, in phase with the other, and the sum is flat everywhere, to the arithmetic.

Hear the hole: a voice and piano through the in-phase Butterworth pair, then through Linkwitz-Riley.

The difference is subtle: a narrow notch at two kilohertz takes a little presence out of the voice and a little bite out of the hiss, a hollowness more felt than heard. Over a whole loudspeaker, and off axis, such errors add up.

Crossovers moved into software. A passive crossover is coils and capacitors between the amplifier and the drivers; an active one comes before separate amplifiers for each. In software a crossover can be any filter at all, even linear-phase, so that the sections add in time as well as in level. The same processor corrects each driver's own response, and the room's, which is Part 55. The price of linear phase is latency, like Part 53's look-ahead. Loudspeakers have become computers with cones.

The loudspeaker needs power. In a class A amplifier the output transistors always conduct: clean, hot, and at best twenty-five to fifty per cent efficient. Class B uses one transistor for each half of the wave, at best pi over four, seventy-eight and a half per cent, and class A B hides the hand-over between them. Class D switches fully on or off hundreds of thousands of times a second and filters the result: over ninety per cent. It is a fast switching power stage, using pulse-width or related modulation; it is not necessarily a delta-sigma converter: very few levels, very fast, smoothed. Class D is common in phones, smart speakers and powered loudspeakers.

10Headphones and noise cancellingFoundations3 min

Can sound be cancelled with more sound?

Headphones are loudspeakers in miniature. Sealed to the head, the cup is a pressure chamber, so bass needs only a tiny motion. The outer ear's own resonances, which a loudspeaker's sound meets on its way in, are bypassed, and designers tune the response to restore them. There is no room either: the sound sits inside the head unless it is processed, which is Part 55's binaural sound. And the cup lets in the world's noise below a few hundred hertz.

So fight noise with noise. Measure the noise, play its mirror image through the headphone, and at the ear the two cancel. Paul Lueg patented the idea in 1936; it reached aviation headsets in 1989; it is now common in noise-cancelling earbuds. The hard part is that the anti-noise must be exact at the eardrum, through a path that changes every time the headphones move.

Our canceller adapts. An outer microphone hears the noise early; a filter shapes it into anti-noise; the speaker plays it; a microphone inside the cup hears what is left, the error. After every sample, each tap of the filter is nudged against the error, by an amount proportional to the outer signal passed through a model of the speaker-to-ear path. That is the filtered-x LMS algorithm, from Bernard Widrow's least-mean-squares rule of 1960, and it keeps adjusting as the headphones move.

Simulate an aircraft cabin: a drone at ninety-two hertz and its harmonics, rumble, and a little hiss. After the canceller adapts, the lowest band falls decibels, the next , and up to a kilohertz . Above that, little reduction in this simulation: its chosen secondary path, reference preview and adaptive filter limit cancellation. ANC is generally strongest at lower frequencies; passive isolation and seal also matter.

Real headphones use more than one scheme. Feedforward: the outer microphone hears the noise early, as in our simulation. Feedback: a microphone inside the cup cancels whatever arrives, including what the outer one missed. Many ANC designs combine the two. Transparency mode routes outside sound through a shaped microphone feed: the outer microphones are played in, so you hear the world with the cups on. And cancelling only subtracts noise; it does not protect hearing from loud music.

Hear the cabin at the ear, with a voice singing over it: the canceller off, then on.

With the canceller on, the drone and rumble drop away and the voice stands clear, with only a thin hiss left, the part the canceller cannot reach.

11Frontier: arrays, beamforming and linearizationResearch3 min

Can many microphones listen in one direction?

One microphone's pattern is fixed; many can be steered. Put eight in a line, five centimetres apart, delay each so that sound from the chosen direction lines up, and add. At four kilohertz the result is a narrow beam; at five hundred hertz it is barely directional at all, because the array, thirty-five centimetres long, is shorter than the wavelength. Conference systems, smart speakers and phones all do this.

Your turn. Two singers, a tenor straight ahead and a soprano forty degrees to the side. Once one microphone; once eight microphones steered at the tenor. Which was the array?

The second. The soprano is quieter and duller there: overall about decibels down, but much more at her upper harmonics than at her fundamentals, exactly as the pattern predicted. This small conventional delay-and-sum array has little bass directivity; other array designs can trade robustness and noise for more.

Arrays became cheap because microphones became chips. A MEMS microphone is a condenser etched in silicon, a millimetre across, made like any other chip, and production gives compact, consistent sensors, though mismatch and calibration still matter, so arrays of them cost little. Microphone counts vary by device; phones and smart speakers often use several, in a ring, feeding beamformers, cancellers and speech recognizers at once. The microphone has become a sensor array with software behind it.

The second frontier is the loudspeaker itself. A small one driven hard is nonlinear: its motor strength and suspension change with the cone's position, and distortion and compression follow, worst in the bass where the cone travels furthest. Linearization models the driver's nonlinear circuit, tracks it as it heats and ages, and pre-distorts the signal so that the cone moves as intended. Phones and smart speakers do this to sound bigger than they are. It is Part 50's amplifier modelling, run backwards.

A research problem to end on. Take a small driver's nonlinear model: its motor strength and stiffness as functions of position, and the coil's heating. Pre-distort the signal through its inverse, with the parameters estimated while it plays. Measure distortion, excursion and loudness, and listen blind. The question: how much louder and deeper can a given small speaker be made to sound, safely, by control alone? An answer would set the size of every phone and earbud.

Variation 54, recap and problemsAll tracks2 min

Every part ends by doing something to the Tune with what it built. Here it is sung with a piano behind the singer, picked up by an omni, a cardioid and a figure-8; then the cardioid's version played through a phone, a bookshelf speaker and a floor-stander.

Row fifty-four of the ledger. The cardioid takes the piano behind it decibels down; the phone's speaker reaches down to hertz, the floor-stander to .

What did we find? A dynamic transducer works both ways, through one number, B l. Pressure is omnidirectional, its gradient a figure-8, and mixtures make the family. A gradient microphone's bass rises close to the source. Thermal noise sets a floor, and balanced lines reject hum. A loudspeaker is a high-pass filter, which boxes and ports shape as Small and Thiele calculated. And horns match, crossovers sum, and cancellers subtract.

Five problems. One to compute, one to prove, one for your ears, one to build, and a research problem, marked with a star. Solutions are in this part's notes. Pause here.

Where does this come back? In rooms and space, the loudspeaker in a room, and stereo and binaural sound. In recording and mixing, where microphones are chosen and placed. In live sound, with feedback, line arrays and horns. In source separation, with arrays. And in generative audio, with learned models of gear.

And in practice. Singers work the proximity effect, in for warmth and out for power. Engineers aim a cardioid's null at what should not be heard. Speaker builders choose a box by its Thiele-Small parameters and check the port by its impedance. And everyone uses balanced cables, and checks noise-cancelling performance across frequency rather than assuming this model applies to every device.

The books and papers this part follows. The full list, with notes, is in the README.

Where it goes next. The loudspeaker in a room, stereo and binaural sound in Part 55; microphone choice and gain staging in Part 56; feedback and line arrays in Part 59; arrays in source separation in Part 64.

Key results

The part's results in one place, for revision.

Patterns\(\displaystyle r(\theta) = A + (1 - A)\cos\theta, \quad\allowbreak DF = 1/(A^2 + (1 - A)^2/3)\)
Proximity\(\displaystyle |1 + 1/(jkr)| = \sqrt{1 + 1/(kr)^2}\)
Thermal noise\(\displaystyle v_n = \sqrt{4kTRB}\)
Sealed box\(\displaystyle f_c = f_s\sqrt{1 + V_{as}/V_b}, \ Q_{tc} = Q_{ts}\sqrt{1 + V_{as}/V_b}\)
Efficiency\(\displaystyle \eta_0 = (4\pi^2/c^3)\, f_s^3 V_{as}/Q_{es}\)

Try it

Lab 54 · Microphones and loudspeakers, computed

Compute a pattern's directivity and a gradient microphone's proximity effect, put a woofer in sealed and vented boxes and check the simulator against Small's and Thiele's formulas, and cancel a hum adaptively.

Figure produced by Lab 54: Microphones and loudspeakers, computed
Produced by the lab below, seed 0, in 0.3 s.
python -m videos.music.labs 54 needs numpy, scipy, matplotlib · download lab54.py · source on GitHub
pattern A = 0.5: directivity index, distance factor, null                         4.77 dB, 1.73, 180.0
bass gain at 100 Hz at 1 m, 15 cm, 5 cm (dB)                                      0.3, 6.3, 14.9
sealed 30 L: -3 dB simulated / Small's formula                                    80.17 / 80.05 Hz (Qtc 0.59)
vented 30 L tuned to 40 Hz: -3 dB simulated                                       50.93 Hz
canceller: attenuation in the last second                                         -25.2 dB
ear problem: how far is each of the last three from the figure-8? (listen first)  5 cm, 5 cm, 5 cm

A pattern is a mix of pressure and its gradient; the gradient part gains bass near the source. A woofer in a box is a high-pass filter whose corner the box sets, as Small's closed form predicts. An adaptive filter can learn the anti-noise for a periodic hum.
The code (76 lines; it asserts its own result)
"""Lab 54: microphones and loudspeakers, computed: patterns, proximity, a woofer in boxes, and a noise canceller."""

import numpy as np

from videos.coursekit import labs
from explainer.music.monochord import SR, Clip, concat
from explainer.music.monochord import transducer as T

TITLE = "Microphones and loudspeakers, computed"
GOAL = ("Compute a pattern's directivity and a gradient microphone's proximity effect, put a woofer in sealed and vented "
        "boxes and check the simulator against Small's and Thiele's formulas, and cancel a hum adaptively.")
TASKS = [
    "Change A (the pattern). Where is the null, how directional is it, and how much bass does it gain at 5 cm?",
    "Change FS, QES, VAS and VB. Does the simulated -3 dB point still match Small's formula? Then try a vented box.",
    "Change MU and TAPS in the canceller. What makes it converge faster, and what makes it unstable?",
]
A = 0.5
FS, QES, VAS, VB = 40.0, 0.40, 0.050, 0.030
MU, TAPS = 0.01, 64


def run(seed=0):
    rng = np.random.default_rng(seed)
    lab = labs.Lab()
    dv = T.directivity(A)
    lab.row(f"pattern A = {A:g}: directivity index, distance factor, null", f"{dv['DI']:.2f} dB, {dv['distance']:.2f}, {dv['null_deg'] if dv['null_deg'] else 'none'}")
    lab.row("bass gain at 100 Hz at 1 m, 15 cm, 5 cm (dB)", ", ".join(f"{20 * np.log10(abs(T.proximity(np.array([100.0]), r, A)[0])):.1f}" for r in (1.0, 0.15, 0.05)))
    d = T.Driver(fs=FS, Qes=QES, Vas=VAS)
    f = np.geomspace(10, 4000, 4000)
    r = T.response(d, f, {"kind": "sealed", "Vb": VB})
    al = T.sealed_alignment(d, VB)
    lab.row(f"sealed {1000 * VB:.0f} L: -3 dB simulated / Small's formula", f"{T.f_minus(f, r['spl']):.2f} / {al['f3']:.2f} Hz (Qtc {al['Qtc']:.2f})")
    rv = T.response(d, f, {"kind": "vented", "Vb": VB, "fb": FS})
    lab.row(f"vented {1000 * VB:.0f} L tuned to {FS:g} Hz: -3 dB simulated", f"{T.f_minus(f, rv['spl']):.2f} Hz")
    t = np.arange(4 * SR) / SR
    x = np.sin(2 * np.pi * 100 * t) + 0.5 * np.sin(2 * np.pi * 200 * t + 1) + 0.05 * rng.standard_normal(len(t))
    prim = np.zeros(60)
    prim[40] = 1.0
    dn = np.convolve(x, prim)[: len(x)]
    sec = np.zeros(24)
    sec[6] = 0.7
    sec[7] = 0.2
    out = T.fxlms(dn, x, sec, taps=TAPS, mu=MU)
    e = out["e"]
    att = 10 * np.log10(np.mean(e[-SR:] ** 2) / np.mean(dn[-SR:] ** 2))
    lab.row("canceller: attenuation in the last second", f"{att:.1f} dB")
    assert abs(T.f_minus(f, r["spl"]) - al["f3"]) < 0.01 * al["f3"]

    # sound: the hum before and after cancelling; ear problem: a voice-like tone at random distances from a figure-8
    clips = [Clip(0.3 * dn[: 2 * SR] / np.max(np.abs(dn)), SR), Clip(0.3 * e[-2 * SR:] / np.max(np.abs(dn)), SR)]
    tone = sum(np.sin(2 * np.pi * k * 110 * t[: int(1.5 * SR)]) / k for k in range(1, 12))
    answers = []
    for i in range(3):
        rr = [1.0, 0.15, 0.05][int(rng.integers(0, 3))]
        y = T.apply_response(tone, lambda ff, rr=rr: T.proximity(ff, rr, 0.0))
        clips.append(Clip(0.3 * y / np.sqrt(np.mean(y ** 2)) * 0.1, SR))
        answers.append({1.0: "1 m", 0.15: "15 cm", 0.05: "5 cm"}[rr])
    lab.audio = concat(clips, gap=0.6)
    lab.row("ear problem: how far is each of the last three from the figure-8? (listen first)", ", ".join(answers))

    fig, (ax1, ax2) = labs.figure(2)
    ax1.semilogx(f, r["spl"] - r["spl"][-1], color=labs.GOLD, label="sealed")
    ax1.semilogx(f, rv["spl"] - rv["spl"][-1], color="C3", label="vented")
    ax1.set_xlim(10, 1000)
    ax1.set_ylim(-30, 5)
    ax1.set_xlabel("Hz")
    ax1.set_ylabel("dB")
    ax1.legend(fontsize=7)
    ax2.plot(np.arange(len(e)) / SR, e, lw=0.5, color="C0")
    ax2.set_xlabel("s")
    ax2.set_ylabel("error at the ear")
    lab.fig = fig
    lab.note = ("A pattern is a mix of pressure and its gradient; the gradient part gains bass near the source. A woofer in "
                "a box is a high-pass filter whose corner the box sets, as Small's closed form predicts. An adaptive filter "
                "can learn the anti-noise for a periodic hum.")
    return lab

Now change it

  1. Change A (the pattern). Where is the null, how directional is it, and how much bass does it gain at 5 cm?
  2. Change FS, QES, VAS and VB. Does the simulated -3 dB point still match Small's formula? Then try a vented box.
  3. Change MU and TAPS in the canceller. What makes it converge faster, and what makes it unstable?

Problems, with solutions

Try each problem before opening its solution.

  1. Compute. A woofer with fs = 30 Hz, Qts = 0.35 and Vas = 80 L goes in a 40 L sealed box. Find fc and Qtc.

    Solution

    Vas/Vb = 2, so the factor is √3 = 1.732: fc = 30 × 1.732 = 52.0 Hz and Qtc = 0.35 × 1.732 = 0.61.

  2. Prove. Prove that A + (1 − A) cos θ has its greatest directivity at A = 1/4.

    Solution

    The random-energy efficiency is REE(A) = ½∫₀^π (A + (1 − A)cos θ)² sin θ dθ = A² + (1 − A)²/3 (the cross term integrates to zero). Its derivative 2A − 2(1 − A)/3 vanishes at A = 1/4, where REE = 1/16 + 9/48 = 1/4: DF = 4, 6.0 dB, the hypercardioid.

  3. Ear. The lab plays a voice-like tone at random distances from a figure-8; order them, near to far.

    Solution

    The lab prints them. The nearest is the boomiest: its fundamental and second harmonic rise by 15 dB and more against the upper harmonics.

  4. Build. Add a second-order passive crossover to the simulator and find the sum's response with real drivers.

    Where to look. Put the crossover's coils and capacitors in series with each driver's electrical impedance (the simulator's Z against frequency), solve each branch's current, then each driver's pressure; the drivers' impedance is not a resistor, so the filters no longer sit where the formulas put them, which is why designers add a Zobel network.

  5. ★ How much louder and deeper can a small speaker be made to sound, safely, by control alone?

    Where the frontier is. Model a micro-speaker's Bl(x), K(x) and coil heating; estimate them while it plays; pre-distort through the inverse and limit excursion and temperature; measure distortion and loudness, and test blind.

Notes and sources

Sources

  • J. Eargle, The Microphone Book (2nd ed., 2004); L. L. Beranek and T. J. Mellow, Acoustics: Sound Fields and Transducers (2012); H. F. Olson, Acoustical Engineering (1957).
  • E. C. Wente, "A condenser transmitter as a uniformly sensitive instrument for the absolute measurement of sound intensity", Physical Review (1917); G. M. Sessler and J. E. West, "Self-biased condenser microphone with high capacitance", JASA (1962); J. B. Johnson and H. Nyquist, Physical Review (1928).
  • C. W. Rice and E. W. Kellogg, "Notes on the development of a new type of hornless loud speaker", Trans. AIEE (1925); A. N. Thiele, "Loudspeakers in vented boxes" (1961; JAES 1971); R. H. Small, "Closed-box loudspeaker systems" and "Vented-box loudspeaker systems", JAES (1972–73); A. G. Webster, "Acoustical impedance and the theory of horns" (1919).
  • S. H. Linkwitz, "Active crossover networks for noncoincident drivers", JAES (1976).
  • P. Lueg, US patent 2,043,416 (1936); B. Widrow and M. E. Hoff, "Adaptive switching circuits" (1960); S. M. Kuo and D. R. Morgan, Active Noise Control Systems (1996).
  • W. Klippel, "Loudspeaker nonlinearities: causes, parameters, symptoms", JAES (2006); J. Benesty, J. Chen and Y. Huang, Microphone Array Signal Processing (2008).
  • F. E. Toole, Sound Reproduction: The Acoustics and Psychoacoustics of Loudspeakers and Rooms (3rd ed., 2018).
About this partfrom its README

Part 54 of a sixty-eight-part course in music (see the series plan and the syllabus), the first part of Act X, The Studio and the Stage. A compatible dynamic headphone can act as a microphone; this part simulates that response. A loudspeaker is a microphone run backwards. When commercial electrical recording spread in 1925, singers no longer had to fill a hall, helping popularize the intimate voice of the crooner. This part builds both ends of the chain as circuits: patterns and proximity, noise and balanced lines, a lumped-element loudspeaker simulator checked against Small's and Thiele's closed forms, horns, crossovers, an adaptive noise canceller and a steerable array. The tools are Monochord's (explainer/music/monochord/transducer.py); every microphone, cable, box and loudspeaker is simulated.

  • A loudspeaker run backwards. An ear question (the Tune through a flat reference and a simulated dynamic headphone used as a microphone: which was the headphones?); the headphone's response (6 dB less per octave above its 110 Hz resonance); electrical recording and the crooner; the plan.
  • 1. Transducers and their circuits. Dynamic, condenser, ribbon and electret; one number both ways (e = Bl v, F = Bl i); the condenser in two lines; three kinds of circuit; which microphone for which job.
  • 2. Polar patterns. Pressure and its gradient; the first-order family r = A + (1 − A) cos θ; a walk round a cardioid, heard; directivity (cardioid and figure-8 4.8 dB, hypercardioid 6.0, twice an omni's distance); patterns at high frequencies; an ear question (a piano behind a singer through an omni, a cardioid and a figure-8: which heard least? the cardioid, 30 dB down); choosing a pattern.
  • 3. The proximity effect. The gradient of a spherical wave (1 + 1/(jkr)); the bass rise by distance (at 100 Hz: +1.1 dB at 1 m, +11.5 at 15 cm, +20.8 at 5 cm); taming the effect; three distances heard; playing the effect.
  • 4. Noise and balanced lines. Thermal noise (0.25 µV, −129.7 dBu for 200 Ω); a noise budget (a dynamic microphone's floor like 16 dB SPL); phantom power; a balanced line; hum unbalanced and balanced, heard (40 dB less with 1 % imbalance); from millivolts to volts.
  • 5. The loudspeaker as a filter. A mass on a spring with a motor (Rice and Kellogg, 1925); a woofer in Thiele–Small parameters (fs 40 Hz, Qts 0.36, Vas 50 L); the amplifier as a brake; its impedance (66 Ω at resonance); efficiency (0.78 %, 92 dB at 1 m for 2.83 V) and Hofmann's iron law.
  • 6. Sealed and vented boxes. The back of the cone; three sealed boxes; the simulation checked (−3 dB points within 0.1 Hz of Small's formula; Thiele's B4 at 40.0 Hz); the vented box (76 Hz sealed to 40 vented in 35 L); how long is the port?; what the amplifier sees (two impedance peaks).
  • 7. Three loudspeakers. A phone's, a bookshelf speaker and a floor-stander simulated (−3 dB at 844, 98 and 39 Hz); measuring a loudspeaker; one groove through each, heard; bass you cannot hear.
  • 8. Horns. An acoustic transformer; the throat's resistance against a bare piston (19 dB better at 200 Hz above a 109 Hz cutoff); waveguides for tweeters; horns at work.
  • 9. Crossovers and amplifiers. Two drivers, one speaker; adding the sections back (Butterworth in phase: a hole; inverted: +3 dB; Linkwitz–Riley: flat); a hole at the crossover, heard; crossovers in software; amplifier classes.
  • 10. Headphones and noise cancelling. A loudspeaker on the ear; cancelling sound with sound; filtered-x LMS; how much it cancels by band (−33, −28 and −25 dB below 1 kHz; none above 2 kHz); feedforward, feedback and transparency; a cabin heard, off and on.
  • 11. Frontier: arrays, beamforming and linearization. An array's pattern; an ear question (one microphone or eight steered at a tenor beside a soprano?); MEMS microphones; making a small speaker behave; ★ research problem: how much louder and deeper can a small speaker be made to sound, safely, by control alone?
  • Variation 54, recap and problems. The Tune sung with a piano behind, through an omni, a cardioid and a figure-8, then the cardioid's version through a phone, a bookshelf speaker and a floor-stander; the ledger (the cardioid takes the piano 30 dB down; the phone reaches 844 Hz, the floor-stander 39); what we found; five problems; where it comes back; in practice; references; Part 55.
What is computed and built

python -m videos.music.music54.compute (about a minute; Part 7's piano notes take the longest) fills .cache/music54/.

Item What it computes Checked against
hook a dynamic driver as a microphone 6 dB an octave above resonance (tests)
patterns, capture, rotate the first-order family; three patterns in a room; a walk round a cardioid DF = 4 at A = 1/4 (tests)
proximity the gradient of a spherical wave at three distances the closed form (tests)
noise, hum Johnson noise; a noise budget; balanced and unbalanced lines 4kTRB; 40 dB at 1 % (tests)
driver, speakers a lumped-element simulator: baffle, sealed and vented boxes; three loudspeakers Small's and Thiele's closed forms (tests)
horn, crossover, xover throat resistance; crossover sums; a hole heard the cutoff; LR4 flat (tests)
anc, beam a filtered-x LMS canceller; a delay-and-sum array a cancelled tone; the array's gain (tests)
tune54 Variation 54 —

Monochord's tools are held in tests/music/test_transducer.py; this part's claims and clips in tests/music/test_music54.py.

Sounds. Part 8's voice, Part 7's piano and Part 50's groove (Part 40's drums and a plucked bass), passed through simulated microphones, cables, loudspeakers, a canceller and an array.

What the models are, and are not. The microphones are ideal first-order patterns at every frequency (real ones narrow in the treble). The room is a burst of filtered noise, not Part 49's image-source room. The loudspeakers are lumped circuits: no cone break-up, no beaming, no nonlinearity; the treble roll-off is a stated filter. The canceller has a fixed secondary path; real ones move.

Companion material in this repository

The syllabus's plan for this partfrom SYLLABUS.md, the plan of record
  1. Hook: an ear question (which was the headphones?); the headphone's response; electrical recording and the crooner; the plan.
  2. Transducers: four kinds; one number both ways; the condenser; three kinds of circuit; which for which job.
  3. Polar patterns: pressure and gradient; the family; a walk round a cardioid, heard; directivity; high frequencies; an ear question (which heard least piano?); choosing.
  4. The proximity effect: the gradient of a spherical wave; the rise by distance; taming it; three distances heard; playing it.
  5. Noise and balanced lines: thermal noise; a noise budget; phantom power; the balanced line; hum heard; levels.
  6. The loudspeaker as a filter: anatomy; Thiele-Small parameters; damping; impedance; efficiency and the iron law.
  7. Sealed and vented boxes: the back of the cone; sealed boxes; the simulation checked; the vented box; the port; impedance.
  8. Three loudspeakers: simulated; measuring a loudspeaker; a groove through each, heard; bass you cannot hear.
  9. Horns: an acoustic transformer; throat against piston; waveguides; horns at work.
  10. Crossovers and amplifiers: two drivers; the sums; a hole heard; crossovers in software; amplifier classes.
  11. Headphones and noise cancelling: on the ear; sound against sound; filtered-x LMS; by band; schemes; a cabin heard.
  12. Frontier: an array's pattern; an ear question (one microphone or an array?); MEMS; linearization; the research problem.
  13. Variation 54: the Tune through three microphones and three loudspeakers. Outro: problems, payoffs.

Covers: the transduction principles; electrical, mechanical and acoustical circuits; polar patterns; the proximity effect; noise; balanced lines; the loudspeaker as a filter; Thiele–Small parameters; sealed and ported boxes (Part 2's resonator again); horns; crossovers; amplifiers; headphones and noise cancelling. Built and computed: monochord/transducer.py: the first-order patterns with directivity and nulls; the proximity effect (+20.8 dB at 100 Hz at 5 cm); thermal noise and a noise budget; balanced lines (40 dB at 1 % imbalance); a lumped-element loudspeaker simulator checked against Small's sealed-box and Thiele's B4 closed forms (within 0.1 Hz); horn loading; crossovers (Linkwitz–Riley flat); a filtered-x LMS canceller (−25 to −33 dB below 1 kHz); a delay-and-sum array. Variation 54: the Tune through three microphone patterns and three loudspeakers (cardioid 30 dB; phone 844 Hz). Frontier: arrays and beamforming; loudspeaker linearization (open: how far can control alone enlarge a small speaker?). Reading: Eargle, The Microphone Book; Small's papers; Beranek & Mellow.

Build the film

python -m videos.music.music54.compute        # the part's numbers, into .cache/music54
python tools/build.py music54                  # render and assemble the film
EXPLAINER_TTS=silent python tools/qa_scene.py music54 Hook   # one chapter, silent, with a contact sheet

Scenes: videos/music/music54. Setup: see the course page. Source of these notes: the README and the scenes' narration.

Build it
python -m videos.music.music54.compute                          # numbers and sounds (about a minute)
EXPLAINER_TTS=silent python tools/build.py music54 -q l --fps 15   # a silent-narration preview, with the sounds
python tools/qa_sound.py music54 --sync                         # the sound gates
python tools/dead_air.py renders/music54_480p.mp4 --sound music54  # no empty screen; no sound over a still one
python tools/lecture_length.py music54                          # 30 to 60 minutes, listening included
python tools/build.py music54                                   # 1080p30, narrated
python -m pytest -q tests/music                                 # Monochord against its references; this part's claims and clips
python -m videos.music.labs 54                                  # the lab (writes a figure and a short WAV)