So I decided to use the scale A1-C4 with only the "white piano keys" to start. This would make simple tunes possible without getting prohibitively expensive. The problem with that is the note number (e.g., -9 for C4) is not a simple progression. I had to keep the piano keyboard in my head the whole time I was making up the list. You can see the spreadsheet I used here. (Also included in Excel format in Files.)
In good ol' Physics 101, you may have learned how to calculate the resonant frequency of a pipe. Basically, the resonant frequency is the lowest note that the air in the pipe will naturally vibrate at. This is related to the wavelength of the frequency, which is dictated by the speed of sound in air. A pipe open at both ends will resonate with half a wavelength; a pipe stopped at one end, with one-quarter wavelength. The speed of sound in air is about 343 meters/second.
I decided to work with stopped pipes, because I could get low notes with shorter pipes(-> less material -> lower cost). Open pipes seemed to have a somewhat "sweeter" sound, but the sound was also more raw and less defined, because the resonance is not as strong-- the sound bounces between air masses at both ends as opposed to an actual solid barrier at one end. So I felt the quarter pipes also made the note more obvious.
Thus, to find the length of a pipe to produce a specific frequency, I used the equation:
where l is pipe length in meters, 343 is the speed of sound in meters/second, and f is the frequency in Hz (1/seconds). Again, see the spreadsheet.
The calculated diameters was based on traditional organ pipe diameters, which is extra confusing, but the math really isn't any worse than the rest of it. I ignored the diameters entirely in version 1.0. The "first and last" jazz was a crude attempt to find a way to avoid wasting material by pairing up short and long tubes. It really didn't help.
I had been collecting cardboard tubes of many sizes for some time. I used cardboard tubes of sufficient diameter to jam the cap gun into the mouth, about 2-1/2" to 3" in diameter. I didn't have enough cardboard tubes, so I also bought some ten-foot lengths of 3-inch diameter polyethylene drainage pipe with some end caps to match. To cut them to length, I marked the length to the nearest millimeter with a tape measure, then used a hand mitre saw and mitre box to try to get a nice perpendicular cut. The saw and box were cheap, and the box was not deep enough, so it didn't work too well. Moreover, those paper tubes are a lot harder to cut with a hand saw than you might think. The end result was not-terribly-accurate tube lengths and a surprising amount of damage to the mitre box. I labeled the tubes with their respective notes.
To stop the tubes, I used squares of double-thick cardboard hot-glued to one end. Some of the plastic pipe I just capped with plastic caps designed for the purpose, but I didn't have enough, so some plastic tubes were stopped with cardboard and hot glue as well.
To test them out, I would snap my fingers in the mouth of the tube, about 3-4 inches in. The notes were clear. I also got excellent sound just by striking the stopped end with a finger, tempting me to just make a set of tuned drums. But then there would be no explosions. True to the nature of sound, the longest pipes that sounded the lowest notes sounded the most out of tune, as the ear is very sensitive to small changes at the low end. The others sounded pretty good.
I practiced a simplified version of Beethoven's "Ode to Joy" (from his Ninth Symphony), considering it the most noble of melodies. I then performed it for extended family at a gathering. The tubes did a poor job of standing upright, so I decided to play them horizontally. I physically arranged most of the tubes on a large round patio table, largest on the left to smallest on the right, then fixed them in place with duct tape. I didn't have room for all the tubes, so I left out a few unnecessary for the song.
I decided to play with my back to the audience, not out of bashfulness, but out of two considerations: 1) I didn't feel like pointing a toy gun at them, and 2) I figured the sound would be louder reflected out of the open ends of the tubes at the audience. True to form, the gun fired weakly or failed to fire several times, leading to a few awkward moments. This might have been exacerbated by the use of hot glue to stick strip caps together, a last-minute decision. . Nevertheless, the audience was entertained and mildly amazed, and I was encouraged to "keep [the Explodophone]" and not discard it. Again, this was all the encouragement I needed.