Ibn al-Jazarī › Fountains and flutes › The perpetual flute

Book of Knowledge · Category IV, Chapter 7 · 1206

The perpetual flute: a whistle that breathes water

Two sealed tanks take turns filling with water. The air they push out sounds a whistle, and when one tank is full a floating hollow sphere tips a balance pipe, and the other flute takes over. No bellows, no crank, no hands. Run it in interactive 3D, cut it open, then watch the film.

Updated 2026-10-24 · 5 min read · Interactive model + 4-minute film

3D reconstruction of al-Jazari's perpetual flute: two tanks with spheres in bowls, a balance pipe on a post and a supply channel
Drag to orbit, scroll or pinch to zoom. Watch the chips: which tank fills, which valve is open, which flute plays.Open the 3D model full screen ↗

An instrument for two trumpeters

“It is an instrument for a perpetual flute with two spheres, for two trumpeters, one of whom is silent while the other blows, then the one that was blowing falls silent and the one that was silent blows.” A flautist also plays continuously on the pool, among figures of musicians, but al-Jazarī leaves those out: he describes only the instrument, “for the earlier [workers] made many mistakes”.

The perpetual flute: two tanks, two spheres, the balance pipe and the supply channel
The whole instrument by a pool (sizes are not given in the text; proportions, colours and setting are our reconstruction).

The earlier makers

He names three. A paper by “Apollonius the Indian carpenter” (probably a slip for geometrician, Hill suggests) used a wheel that opened the water outlets every half rotation: too quick, unless the wheel turns more slowly than one imagines. An old instrument known only from a drawing had eight tanks, seven ground valves and four toothed wheels, and still could not change slowly enough. And in Baghdad in 517 AH (1123–24), the eminent inventor Hibat Allah ibn al-Ḥusayn, the astrolabe maker known as al-Badīʿ al-Asṭurlābī, made “a real innovation”, with a cylinder and lead ball, two buckets on chains, three tanks and six ground valves.

Al-Jazarī's design

  1. Two tanks (y and k) side by side, each closed at the top by a cover shaped like a semicircular bowl.
  2. In each bowl lies a light, hollow sphere (w and s) whose lower half almost fills it.
  3. Near the edge of each bowl is a hole (h, m). Through it a chain runs down to the plug of a ground valve (t, l) in the tank's floor.
  4. On the other side of each cover a narrow hole carries a pipe with the flute's jar (z, n): a small whistle.
  5. Between the tanks a firm post (e) carries a transverse pipe on an axle (x), with a funnel (j) on its middle. Each end of the pipe (d, f) has a staple for one of the chains.
A hollow sphere in its bowl, with the jar beside it and the end of the pipe resting on top
A sphere in its bowl; the end of the pipe rests on it. Hill: the jar should not touch the sphere, as the drawing shows.

How it runs

Water flows from the supply channel into the funnel, runs out of the lower end d into the bowl and “is sucked down through hole h”. Valve t is closed, “so the air in tank y is expelled and streams through pipe z. The jar therefore plays like a flute continuously until tank y has filled.” The water then rises in the bowl, “and a little of it lifts the sphere which presses against end d and lifts it. End f sinks and closes valve l.” Now tank k fills and its jar plays, while the raised end d has pulled its chain and opened valve t, so tank y empties. “And so on, as long as water flows from the supply channel.”

Cutaway: one tank filling, the other draining, the pipe tilted onto one sphere
Cut open: tank k fills (its flute plays) while tank y drains through its open valve.
The moment the pipe tips from one sphere to the other
The swap: a floating sphere pushes its end of the pipe past level, and the pipe tips onto the other sphere.

Quick test

What actually makes the flute sound? A, falling water hitting the pipe; B, air pushed out by rising water; or C, the sphere knocking on the jar?

Show the answer

B. Water fills the sealed tank and squeezes the air out through the jar. The sound is the tank breathing out.

Limits

  • “Perpetual” means continuous, not perpetual motion: it plays only while someone keeps the supply channel running.
  • The tip is the delicate moment. Al-Jazarī adds that “there is no harm in adding a cylinder with a lead ball in it to pipe d”; in his fountains (Category IV, Chapters 5–6) such a ball rolls to the end that falls. How it was fitted here is our reading.
  • Hill notes that the manuscript drawing is wrong in one detail: the jar did not touch the sphere.
  • No sizes or times are given, so our proportions and the speed of each swap are a reconstruction.

The first self-playing flute?

No. Self-playing instruments were old by 1206: in ninth-century Baghdad the Banū Mūsā brothers described an instrument that played a whole tune by itself, and Hill finds it “a little surprising” that al-Jazarī does not mention it. What al-Jazarī cared about here was timing: not a wheel that switches too fast, but a slow, sure swap, set by how long a tank takes to fill. His next three chapters do the same with two tipping buckets, a balance, and two floats.

Watch the film

Film: al-Jazari's perpetual flute

Questions & answers

What is al-Jazari's perpetual flute with two spheres?

Chapter 7 of Category IV of al-Jazarī's Book of Knowledge (1206) describes an instrument for a perpetual flute, for two trumpeters: one is silent while the other blows, then they swap. Al-Jazarī describes only the instrument, not the musicians on the pool, because, he says, earlier makers had made many mistakes in its construction.

How does it make a sound?

Each of the two tanks is sealed. A narrow pipe on its cover carries the flute's jar, a small whistle made as in Category I, Chapter 1. When water runs into a tank whose valve is shut, the rising water pushes the air out through the jar, and it plays continuously until the tank is full.

How do the two flutes take turns?

A pipe pivots on an axle on a post between the tanks, with a funnel in its middle fed by a supply channel. Water runs out of its lower end into the bowl on top of one tank and down through a hole into it. When that tank is full, the water backs up into the bowl and lifts a light hollow sphere, which pushes the pipe's end up. The pipe tips over onto the other sphere, the other tank fills and its flute plays, and the raised end pulls a chain that opens the ground valve of the first tank so it empties.

Is it a perpetual motion machine?

No. 'Perpetual' here means continuous: al-Jazarī says it runs 'as long as water flows from the supply channel'. Stop the channel and the flutes stop.

Who were the earlier makers?

Al-Jazarī mentions a work by Apollonius the carpenter, whose wheel opened the water outlets every half rotation (too fast, he says), an old drawing with eight tanks and four toothed wheels (still not slow enough), and a paper written in Baghdad in 517 AH (1123–24) by Hibat Allah ibn al-Husayn, the astrolabe maker al-Badīʿ al-Asṭurlābī, which he calls a real innovation.

Was it the first self-playing instrument?

No. In ninth-century Baghdad the Banū Mūsā brothers described an instrument that played a tune by itself. Hill notes that al-Jazarī does not mention it. Al-Jazarī's concern in this chapter is the timing of the alternation: a slow, reliable swap set by how long a tank takes to fill.

How big was it?

The chapter gives no sizes. The proportions, colours and speeds of our model are a reconstruction from the text and from Hill's notes.

Sources

  • Ibn al-Razzāz al-Jazarī, Kitāb fī maʿrifat al-ḥiyal al-handasiyya (The Book of Knowledge of Ingenious Mechanical Devices), 1206, Category IV, Chapter 7 (and Category I, Chapter 1 for the flute's jar). English translation and notes: Donald R. Hill, 1974, pp. 170–171, 264–265 and 275–277.
  • Al-Badīʿ al-Asṭurlābī (Hibat Allāh ibn al-Ḥusayn, d. 1139/40), astrolabe maker of Baghdad.
  • On the Banū Mūsā's self-playing instrument: “The 9th-century Islamic ‘Instrument Which Plays by Itself’”, Hyperallergic.
  • The 3D model is a reconstruction from al-Jazarī's text and Hill's notes; sizes, colours, setting and speeds are illustrative.

Next from the Book of Knowledge

Which machine should we open up next?

More clocks, automata and fountains are on their way. Tell us on YouTube which one you want next.