Wednesday, January 26, 2011

Designing Complex Systems

What kind of world and nation do we want? What are the realistic possibilities from which we are constrained to choose? Already these are enormously difficult questions. Perhaps foreign relations are the trickiest questions. Our present way of living is deeply intertwined with people all around the world. One simple measure of this is that we import about two trillion dollars of goods, while our total GDP is about fifteen trillion dollars. The more our vital interests are involved with other nations, the more we will find ourselves driven to protect those interests. This activity powerfully shapes our government. On the other hand, it's not as if utter isolation is a real option.

A similar spectrum appears at the national level. Perhaps the Tea Party is a revival of the Confederate ideas that sparked the nineteenth century Civil War. Our public and private institutions are so international that the boundaries between the fifty states are almost invisible. To what extent it could be possible to reconnect institutions to smaller regions, to states or even to cities... it is not clear how this could be done and what the consequences would be. The economic principle of comparative advantage is one demonstration of the more general maxim, "United stand, divided we fall." Yet surely that maxim must have its limits.

What we have now is a way of living that is dominated by global institutions, public and private. It surely makes good sense to avoid concentration of power in any institution, but the protection of our vital interests and the regulation of interactions among such huge players surely requires government at a similar scale. In a different world a small scale government might be effective. In today's world, the only possible government is a large and complex government. The challenge is to find a way to make such a government efficient and effective.

In this project, we don't have to start with a blank sheet of paper. There are many global scale institutions and other systems of great complexity. The pragmatic approach is to study what works elsewhere and what doesn't work.

There are two aspects to building complex systems. The system itself will have some structure, e.g. incorporating hierarchy and repetition. The other aspect is the process of design. Just like there is no single system structure that can serve all purposes, similarly the design process needs to fit the specific problem at hand. Still, there are some generally useful design methods that can be combined and adapted to fit most any problem.

Complex system design generally takes place in a series of phases. Design can be thought of as a series of decisions. The idea behind the phases is to order the decisions as well as possible. The main principle is that a decision is best made when the consequences of the alternatives are as clearly known as possible. For a trivial example, the size and shape of a container is generally best decided upon after the sizes and shapes of the contents are already known, otherwise the contents might well not fit in the container, or it could be unnecessarily large. The usual first phase of designing a complex system is determining what it will be required to do and the constraints put on it by whatever external factors.

Another methodological principle is to identify and resolve risks early. The failure of a crucial component can prevent the system from performing its intended function. The less experience designers have in working with such components, the higher the risk of a design error. In such cases it may be worth while to build prototypes as a way to gain experience before scaling up to the full system.

Complex systems are generally designed by large teams with diverse expertise. Transparency and accountability are necessary in the design process in order for this diversity to remain a strength. For the designed system to cohere, effective communication must be maintained between the various design teams. Hidden decisions become hidden problems that can trigger catastrophic failures.

Any complex system will involve risk and novelty: each unique arrangement of components creates fresh opportunities for unforeseen interactions. To work effectively, a complex system must incorporate ways for its design to be changed as problems are detected, or as system requirements shift. The processes of design, implementation, and deployment cannot be kept completely distinct.

Separation of concerns is a principle that can apply both to system structure and to the design process. If every component of the system is tightly coupled to every other component, the system will be extremely brittle. Most likely some interactions will not be handled correctly and the system won't even work from the start. In any case, any small change in requirements will lead to updates rippling through the whole system, at prohibitive expense. The notion with separation of concerns is to reduce the degree to which system components constrain each other, to reduce the level of coupling between them. The detailed operation of each component can be largely independent of the details of other components, as long as a few basic requirements are met. Changes in the design details of one component can have very little or no impact on the requirements of other components. This lets design teams work more independently with many fewer iterations of rippling changes, and then during implementation and deployment problems can also be identified and fixed with minimal impact.

I starting thinking about government as a complex system when I started hearing about the problems with earmarks in legislation. It seems many such clauses are introduced into bills at the last minute. Legislators vote on bills whose contents they cannot effectively track. This is very much like computer software when configuration management tools are not used. Last minute changes are notoriously buggy but developers always want to get the latest fixes and features into the next product release. The software industry has worked out some effective methods to manage this problem. Perhaps the government can learn something!

Tuesday, January 11, 2011

Solar Fruit Dryer

The current process by which food is provided to most folks in the United States is one that uses large amounts of petroleum, from the farm through the distribution network to the home. As petroleum and other sources of energy get more scarce, we will need to find new ways - and return to old ways - that are less energy-intensive. These changes will be required through all the stages of growing, preserving, and distributing food.




Here is a simple design for a solar fruit dryer. The lower part is a trapezoidal solar collector. The top surface of the collector is clear glass. This covers a space for air to flow, in from the bottom, up through the collector as it is heated, then into the drying chamber above the collector. The bottom surface of this air space is a metal surface painted black, to absorb sunlight and turn it into heat. Below the metal surface is a layer of insulation, so the heat from the metal surface goes into the flowing air above it rather than the outside air below it.

The heated air rises and flows from the solar collector into the drying chamber. This air passes over several trays of drying fruit. The air is dryest as it enters the chamber, so the first tray it encounters is that with the dryest fruit, i.e. the fruit closest to the end of drying process. As the air rises, it passes over successively less dry fruit. Finally the air rise out through the top of the drying chamber and into the chimney.

The chimney is simply a vertical tube that helps the rising air accumulate lifting power to keep the steady movement of air in at the bottom of the solar collector, through the dryer, and out at the top of the chimney.

The drying chamber has a door allowing new trays of fresh fruit to be added at the top and trays of dried fruit to be removed from the bottom. As trays are removed from the bottom, the remaining trays should be shuffled down, creating space at the top for the fresh trays to be added.

The next stage of development of this idea will be to tune the relative sizes of the components, to allow maximum throughput of fruit with the least expense. A moderately sized unit ought to be inexpensive enough to build that this tuning can effectively be done experimentally.

The grand vision is that the dried fruit can be taken by bicycle to local farmstands to be sold, and then fresh fruit to be dried can be brought from the farmstand on the return bike trip. Mix in canoes as needed!

Sunday, January 2, 2011

Twisted Arpeggios

I took some piano lessons in 7th grade and a few guitar lessons in 8th grade, but never attained any real competence in performance. I still have no understanding of music theory at all: counterpoint, harmony, etc. It was sophomore year in college when I learned about the overtone series in a physics class that my fascination with music opened to a deeper dimension. I got out my old guitar - I think I spend a year just tuning that guitar. I also started exploring the mathematics of tuning.

In the spring of junior year I wrote a computer program to search for scales made of equal sized steps. The conventional musical scale has equal steps whose size is a twelfth of an octave. Perhaps some other step size could give a better scale. What would be a good measure for the quality of a scale, or of the step size that generates that scale. With the overtone sequence as the foundation of musical intervals, the answer must be that the scale contains pitches that are close approximations to the just-tuned intervals. In my program I just used the overtone series itself: the scale should contain pitches that closely approximate the pitches in the overtone series. Clearly the lower overtones are more important. So I formed a weighted sum of differences. Each difference was the gap between an overtone pitch and the closest pitch in the scale. The weights decreased as one ascended in the overtone series, in such a way that the sum would converge as one extended the sum to include all of the infinite pitches of the overtone series.

Any fixed step size will generate a scale for which this quality metric can be computed. In my program, I computed this metric for a range of step sizes, e.g. 1.050, 1.051, 1.052,… 1.067, 1.068, 1.069, 1,070. I checked the quality metric for each step size against those of the neighboring step sizes. At the optimum step size, the quality metric will be better than those for both slightly smaller and slightly larger step sizes. I expected to see just one or two step sizes singled out as those with the best quality metric, i.e. those that would generate the best musical scales.

This was 1976, so my program was punched into cards and read into the job queue of the campus mainframe. Half an hour or so later the resulting print-out was tossed into my slot. I was totally surprised - practically a third of the step sizes were the best in their little region. A graph of quality metric against step size would not show any kind of smooth approach to a few optima, but rather be very bumpy. I decreased the step size, so now I would explore step sizes like 1.0500, 1.0501, 1.0502, etc. Another half hour wait in the ready room for my result print-out to get dropped in my slot, and an even bigger surprise - zooming in to finer detail revealed even more local optima! This was one very bumpy curve!

I had the idea of going over to the math department to see if someone could explain to me what was going on. Such a bumpy curve didn't fit the picture I had in my head from basic calculus! But the school year was over. The summer of 1976 took me out to Grand Junction, Colorado, where I was working on historical uranium data with a couple geology professors, Ken Deffeyes and Ian MacGregor. For a little summer reading I brought along Functional Analysis by Riesz and Sz.-Nagy. Amazing! On page 3, there was my musical quality metric, or at least an infinite sum very much like it - given as a classical example of a function that is continuous everywhere but differential nowhere. A very bumpy curve!

It's nice to stumble onto classical results but unfortunately that put an end to strategy number one for discovering new and improved musical scales. Basic calculus can't analyze such functions! Strategy number two then emerged, probably still in undergraduate years. Another way to understand how a good musical scale arises is by looking a commas, rational fractions very close to 1 that are constructed by multiplying and dividing small primes.

One fundamental comma, the syntonic comma 81/80, comes up in tuning a guitar. A guitar can be tuned using harmonics, plucking the strings while touching their nodal points which causes the overtones to sound clearly. Playing the fourth harmonic of the low E string along with the third harmonic of the next A string, one can adjust the string tension to bring these to the same pitch, so the E and A strings will be separated by a just tuned interval of a fourth, i.e. a frequency ratio of 4/3. Of the five intervals separating the six strings of a guitar, four are fourths. The fifth interval, from G to B, is a major third. Here the fourth and fifth harmonics can be used to bring those strings into the corresponding just tuned frequency ratio of 5/4.

This approach to tuning a guitar doesn't quite work, though. There should be two octaves from the low E string to the high E string. But when the five just tuned intervals are stacked, the four fourths and the one major third, the top of the stack doesn't end up quite two octaves above the bottom of the stack. Numerically, (4/3)(4/3)(4/3)(5/4)(4/3) = 320/81, where two octaves should be 324/81. This gap, 324/320 = 81/80, the syntonic comma, is one of the most basic differences between just tuning and equal temperament. Is just tuning right and equal temperament wrong, or what difference does this difference really make? That is a nice question to explore!

Strategy number two involved looking for commas. I wrote a program to explore numbers whose factors were all small primes - as I recall, I limited the primes to 2, 3, 5, and 7. My program constructed these composite numbers in ascending order, and looked for pairs that were especially close. Perhaps those results from 30 years ago are still saved in some box of papers in my storage unit, but the details are long gone from my memory. The one result that I remember is that I became fascinated by an scale with equal steps that divided the interval from the fundamental to the tenth harmonic into 90 equal parts. Curiously, this scale would not have exact octaves. Still, it contained enough good approximations to important just intervals that it should support music.

Inventing musical scales is not much fun until two further problems are solved: one needs a way to play notes from any proposed scale, and one needs a way to arrange those notes into musical patterns. So my next idea was a way to lay out keys on some kind of keyboard instrument to allow performance of music that uses small step sizes. If the keys of such an instrument are laid out in a line in ascending order, there can easily be so many steps in an octave that either the keys will be too narrow to play or the octave will be too wide to reach. So I came up with a two dimensional arrangement, with hexagonal keys covering a flat surface. The pitch of the keys increases to the north and decreases to the south. To the east and west are arrayed keys that have very similar pitch. The fundamental idea is that a very narrow interval is actually quite distant harmonically. The keyboard I proposed arranges the keys according to harmonic relationships. Keys very close in pitch can be quite far apart on the keyboard.

The next problem is then how to compose music in one of these proposed scales. The easiest approach to start with is just to transpose or translate existing music into the new scale. If the new scale is based on the same fundamental intervals, such as perfect fifths and major thirds, as the old music, then the transposition should be simple enough… or so I thought! I took a couple of Bach's Harmonized Chorales and attempted the transposition. For any given note in Bach's score, I needed to select which of several closely spaced microtonal notes should be played. With the harmonic relationships available on my keyboard design, the range of choices was essentially a spectrum of notes separated by syntonic commas. I decided simply to use the color spectrum to add this detail to Bach's score. All notes of a given color would be related by Pythogorean intervals, ratios built from the primes 2 and 3. Each factor of 5 in an interval would shift one color in the spectrum, from blue to green etc. The interval of a syntonic comma is denoted by a simple shift in color with no change of position of the note on the staff. The transposition of Bach's score was simply a matter of copying the score and adding the appropriate colors.

I was amazed, not just because I found the task to be impossible, but also because the attempt seemed to reveal the structure of the music. Right up to near the end, I found it easy to see which colors to use for the notes. But the right near the end, I found conflicting harmonic relationships. It wasn't so much that I couldn't decide which was the right color, but more that the notes seemed to demand two colors at once. This conflict or ambiguity seemed to create a harmonic tension that was fundamental to the structure of Bach's music. Sure enough, the final notes of the compositions were again easy to color - the tension was resolved. That was my music lesson for the year!

About a decade after this, in 1991, I had the good fortune to be able to spend some time working at MIT as a visiting scientist - which also got me a library card! I found in MIT's music library a copy of Easley Blackwood's The Structure of Recognizable Diatonic Tunings. I was amazed to see in this book an exhaustive demonstration of the lesson I had learned from Bach. Blackwood attempts to transpose into just tuning a whole series of classical compositions from Bach to Mahler. He didn't use colors but simply little "+" marks to pick out of that spectrum of alternatives separated by syntonic commas. Blackwood shows that this transposition simply doesn't work. Music in this classical Western tradition creates a sense of tension and movement using the ambiguity introduced by temperament. The ambiguity cannot be removed without destroying the music.

I figured the book must have been the PhD dissertation of some obscure graduate student who then disappeared back into the woodwork. Another surprise! In the late 1990s I was in a CD store, probably looking for Beethoven - but right alongside, a section for Easley Blackwood's music! He is a distinguished composer as well as a theorist. His book on tunings marked a shift in his career, closing a phase of experimentation with tunings and returning to music very much in the classical tradition.

There are surely many different approaches to the construction of musical scales and no doubt many of them can provide foundations for musical making. If one wants to play in the space created by the ambiguities of temperament, the possibilities of alternative scales does not disappear. Thinking of ambiguity as a resource does, though, shift how one evaluates a scale.

My fascination for the last decade or so has been with the scale that divides an octave into 53 equal intervals. I've already outlined the logic behind 53 at http://www.interdependentscience.com/music/calliopist.html so I won't repeat that discussion here. This tuning gives very good approximations to just tuned thirds and fifths. But what if we want to play the ambiguity game? What new opportunities does this tuning open up?

The syntonic comma is the fundamental interval tempered by the conventional 12 step scale. Each step of the 53 step scale is just about the size of a syntonic comma, i.e. the 53 step scale accurately expresses exactly what the conventional 12 step scale blurs. The music of the 53 step tuning will be something quite different.

What is a comma that the 53 step scale blurs? The kleisma, 15625:15552, is one fundamental such comma. A minor third is 14 steps in this tuning, while a perfect fifth is 31 steps. If six minor thirds are stacked, that makes 84 steps - exactly a octave above a perfect fifth. Curiously, this comma is not tempered in the conventional 12 step scale, where a minor third is 3 steps and a perfect fifth is 7 steps. The stack of six minor thirds is thus 18 conventional steps, one step short of an octave above a perfect fifth. This again shows that music in the 53 step tuning will be quite different than that of the conventional 12 step tuning.

So my project has become a kind of parallel construction: to build up compositional methods for the 53 step tuning that mimic those in the classical western tradition using the 12 step tuning. Another fundamental compositional structure in classical western music is the key signature. For the most part, a segment of music will not use all twelve notes of the full scale, but instead be centered on a subset of seven. There are different ways to think about the way these seven are selected: perhaps there is a starting note and then a stack of six perfect fifths. Or the seven can be seen as three major triads stacked. These two ways to see the structure of the key signature differ by just the syntonic comma that is blurred by the temperament. If we see the white notes of the piano as a stack of perfect fifths F-C-G-D-A-E-B, then the A is four perfect fifths from the F. Alternatively, the white notes could be the three major triads FAC-CEG-GBD, in which case the A is a major third from the F. The just tuned difference between a major third and a stack of four perfect fifths is just the syntonic comma.

Can I construct some subset of the 53 steps of the octave, with a structure based on the kleisma that parallels that of the role of the syntonic comma in the conventional 12 step scale? Here is one attempt. The syntonic comma is four perfect fifths next to a single major third. The kleisma is six minor thirds next to a perfect fourth. Why not construct a key signature based on minor thirds? Take a stack of twelve notes, with a minor third between each neighboring pair. Then each note in the bottom six can be paired with a note in the top six, with the interval of a tempered fourth between each pair. This way, the roles of fifths and thirds is just reversed relative to the convention seven out of twelve key signature. Can a person make music out of this structure?

As a first step, here is a sequence of arpeggios:

http://www.interdependentscience.com/music/arpeggios.mp3

This parallels a conventional sequence like CEG DFA EGB FAC GBD ACE BDF CEG. In the conventional sequence, almost every triad includes a perfect fifth. Only the triad based on B has a flat fifth, because B is at the end of the stack of fifths. In a twisted sort of parallel way, almost every triad in this new sequence includes a minor third. There is just one triad that has a flatter third. I confess, I am just feeling around in the dark here for what might work!

In the conventional sequence, roughly half the triads have a major third from the root while the other half have minor thirds. In a twisted parallel way, this new sequence has about half the triads with fifths from the root and half with fourths.

Does this subset support music? That's not an easy question! Even more importantly, does is support making music that has something to say that couldn't be said in the conventional twelve step scale? That's an even harder question! My main hope is that I can help open up some possibilities enough that others with more compositional talent can explore more deeply.

Here, though, is my first attempt to create some music using this structure:

http://www.soundclick.com/bands/page_songInfo.cfm?bandID=784761&songID=7607461

I should note here that very likely none of these ideas at all were first proposed by me. The scale with 53 steps per octave has a very long history - centuries and likely millennia. Decades ago Shohé Tanaka named the kleisma and noted its importance in the 53 step scale. Fewer decades ago Larry Hanson selected a subset of the 53 notes that was very similar to the set of twelve that I proposed. See:

http://anaphoria.com/hanson.pdf

I learned a lot of this history from the microtuning group on yahoo:

http://launch.groups.yahoo.com/group/MakeMicroMusic/

Thursday, October 28, 2010

A Few Decades of Bicycles

When I told my friend David that I have my eye on a new bicycle, he asked if this fascination with bikes was a new thing. That got me thinking about my bikes and biking over the years, so I thought I'd put some of that into words.

I lived in England with my parents and siblings in 1965 and 1966. That was a major watershed. My childhood memories are clearly divided into before, during, and after. I was nine years old when we moved to England, so I was already a bit of a big kid and enjoying bike riding. I still have my bike license plate from 1964. I must have had a coaster brake single speed bike, but I remember nothing about it. I do remember riding down Elmwood Ave. to the other end, which must have been all of twenty blocks! But that freedom to explore is a memory I still cherish.

We got two bikes in England; they must have been for my sisters. I remember my older sister's bike especially, because it had a front hub dynamo. They've been around a long time! And both bikes had hand brakes. Those were really nice bicycles! I spent most of my time in a boarding school there and didn't ride much at all. I do remember a bit of riding on the left side of the road, borrowing my older sister's bike.

When we moved from England back to Ohio, to Bath, somehow I caught the trend and begged my Dad for a Schwinn Sting-Ray. He was generous enough to indulge me - a five speed derailleur with a monster shifter on the top tube. But soon after that I met my best friend of those days, Mark Laessig. Mark died tragically young, at maybe 27. I was in contact with him shortly before cancer took him, when he was designing supersonic jet engines at NASA. But even in 8th grade he was obviously brilliant. Somehow in 1969 he had some kind of real racing bike, with drop bars, toe clips, and Campagnolo shifters front and rear. I only had that Sting-Ray a few months before I pulled off the banana seat and replaced it with something much more conventional. The high rise bars got pushed far forward to get me into a conventional posture.

Oh, I rode that bike a lot! Just to ride to Mark's house was a good ride - up Bath Hill, to start with! The biggest ride I remember was Mark and I riding to Nelson Ledges State Park. Looking on a map now - wow, that was over 40 miles! I bonked on the return trip and Mark's Mom rescued us, so it was probably only a 60 mile day. With some hiking and bouldering in the park, too!

Over Spring Break, 1969, we moved to Lake Forest, Illinois. Kiddle's was the bike shop there. I am proud to say that my first W-2 was from Kiddle's. I didn't work there more than a few months. The owner even offered to send me to the Schwinn Repair School in Chicago! But, sad to say, we were already planning our move away from Lake Forest by then.

Soon after our arrival in Lake Forest, I got the Raleigh catalog from Kiddle's and studied it thoroughly. I decided the Super Course was the bike for me and somehow saved up the money to buy one - surely with help from my parents, though I sure don't remember the specifics anymore! I know I rode that bike to summer school and over to Lake Forest college all the time. A side note - that was at the beginning of my computing experience - I was a regular on the IBM 1130 at Lake Forest college. I was fascinated by the closed solutions for cubic and quartic equations and had those written up in Fortran. I don't think I ever bothered to check my solutions, though! I try to do better nowadays!

The really big ride I remember from those days was a three day camping trip. I think there were four of us: John Gwynn, John Evers, Mark Recktenwald, and myself. We rode from Lake Forest up into Wisconsin, somewhere around Lake Geneva. We all would have liked to visit the Yerkes Observatory there but we just didn't have time. We must have been a sight, our tents and sleeping bags crudely strapped on our bike racks! I remember pulling into a Wisconsin State Campground in the dark, and the ranger's office was closed. We were all top students, but I think Mark was deputized to write the note: "We, a group of campers..." We found the picnic area and set up our tents well away from the RVs with their blaring radios or whatever people used in 1970. I also remember riding with a stomach ache from eating under-cooked pancakes from our campground breakfast. Were we cooking with Sterno?

In 1971 we moved to Fort Wayne. My main riding partner there was Mike Short. Ah, I remember attempting a century then. I bonked at about mile 85 and took the sag wagon the rest of the way. I had the patch from that ride on the knee of my blue jeans for a few years after: "I rode to Hell and back!". I hear there's another town not too far away, also in Michigan, that's called Nirvana. We didn't get there, though! I remember too riding many times from our house in the southwest suburbs, down US 24 past the intersection with I-69, into the center of Fort Wayne, to hang out at the library. I got some good use out of my Super Course!

In 1973 I left home to go to college at Princeton in New Jersey. I locked my bike up in the cloisters of Holder Hall with a cheap cable lock and didn't really ride at all or pay attention to the bike. I guess it was early spring before I noticed that the bike was gone. It was a nice bike but I hadn't been riding it so it wasn't a huge tragedy.

I think it was at the end of first semester sophomore year - my physics lab partner told me he was selling his racing bike. He was upgrading to a Masi, as I recall. Wow, the bikes that were appearing in those days! So I bought his Legnano. Campagnolo Nuevo Record derailleurs, center-pull brakes - probably Weinberg - and sew-up tires! I think I bought that bike immediately after Christmas break. I took it out on a ride... all the way out, a freezing rain began. I remember coming back toward Princeton on Route 206 and slipping and falling and landing sprawled out on the highway. It was busy enough with tractor-trailors and every kind of traffic, but somehow right that moment an angel must have been watching. I got back up and tried to walk with the bike but the road was so slippery I couldn't even walk on it!

Probably my longest ride in Princeton was out to the ocean, to Asbury Park. I remember riding over through Lambertville and down along the Delaware River, too.

Ah, the summer of 1976, I worked out in Grand Junction, Colorado. I was doing some programming work for Ken Deffeyes and Ian MacGregor, two geology professors. Mostly we'd commute by car, from the Mesa College dormitories where we stayed, to the ERDA labs where we worked. But for a week or two I was on my own. I recall that I borrowed a bike from one of the ERDA administrators for my commuting in that interval. I remember riding a bit on the back roads around the edges of Grand Junction.

I moved to Philadelphia in 1977 for graduate school. I remember taking the Legnano out for longer rides - sometimes for laps of the classic East and West River Drives, other times out to West Chester or Paoli. The Legnano isn't any kind of urban utility bike, though! I know I used a variety of old coaster brake bikes that seemed to appear out with people's trash from time to time. I remember riding no-hands in the middle of the night on one such bike, from 3rd and South St., after seeing some jazz, back to home in West Philadephia. Riding no hands up over the South St. bridge was the biggest challenge but not so difficult. I really pooled my pennies at one point and bought a new Panasonic five-speed urban bike. This bike was a bit of a technology experiment - the freewheel mechanism was in the bottom bracket, so you could shift the derailleur while you were coasting! But this bike got stolen after less than a year. Better to use a junk bike for running errands!

In 1982 I moved up to Poughkeepsie, NY, to work for IBM. My Dad loaned me his Schwinn Collegiate 5-speed bike to get around until I could afford a car. I remember riding that bike from downtown Poughkeepsie, where I lived, to the IBM education building south of the main site. I remember holding a duffle bag with my laundry across the handlebars, riding to the laundromat. How long did it take me to get that Schwinn back to my Dad? I still had the Legnano then, too. I remember riding up to Rosendale and then around the back side of the Shawangonks and then up and over, by Mohonk Mountain House. That Legnano did not have low gears! I remember riding up to Rhinebeck, too.

I spent a year or so in Cambridge, MA, in 1991. Already I had some kind of mountain bike. I remember riding that in Dutchess County a bit and how much more work it was to ride than the Legnano. But for the potholes and trolley tracks of the Boston area, the mountain bike worked great. I doubt that I even brought the Legnano to Boston - it must have stayed in Poughkeepsie.

I was on a long meditation retreat from late 1992 through early 1996. I stored a lot of my stuff but I sold a lot too - both the mountain bike and the Legnano moved on. My sister worked for a while at Bicycling magazine in Emmaus, PA. I think that's where the Legnano went.

I headed to the Portland, OR, area after retreat. I was low enough on funds and Portland looked like a good bike riding town, so my plan was to do without a car. I stayed a month or so beforehand with my sister in California. I found a Trek 520 there and had it shipped up to Oregon. I wish I had waited and bought my 520 up in Oregon, but I wasn't sure what would be in stock etc. and I didn't want to risk being without wheels.

The 520 served me quite well in Portland. I could ride over the West Hills from Hillsboro, where I lived, into downtown Portland, load up with books at Powell's, and haul them home. Usually coming home I would take Terwilliger and Beaverton-Hillsdale Highway. Up and over Cornell going west with panniers full of books - too much for me! I remember too some rides into the countryside. I especially remember my one ride up Laurelwood Hill. I had no idea what I was getting myself into! But it was a clear day, and at the top I was rewarded with a spectular view of five peaks - Ranier, St. Helens, Adams, Hood, Jefferson. Wow!

Somehow in Portland - well, I had a good job and so I could afford it - but I worked my way up to three bikes: a folding bike and a bombproof Amsterdam city bike along with the 520.

In 2007 I moved back east, into the Catskills Mountains. Lots of busy narrow twisty roads here! But slowly I am working out routes to get places while avoiding the most dangerous roads. This past spring I was delivering census questionnaires. My sweetheart's teenage son has a mountain bike which I used for a decent fraction of the work. Those fat tires and low gears are really handy for the private roads that snake up the valleys here! So that has got me thinking about a bike I can use for grocery shopping, for hauling real cargo up the mountain slopes - up Dug Hill Road!

Friday, August 20, 2010

Pythagorean Shifts

I see that the Yamaha CP1 electronic piano can be switched to play in Pythagorean tuning. This means that fifths are true, i.e. a frequency ratio of 3/2. This is about 2 cents sharper than an equal tempered fifth - a cent is 1% of a half step. Of course, if you follow the circle of fifths and every fifth is 2 cents sharper than equal tempered, the circle will not actually close. The last fifth must be 22 cents flat! Thus, the Pythagorean tuning can be diagrammed with:



I don't see in the CP1 manual which fifth they chose to be flat, so I just took a guess.

This choice of the flat fifth might be something a performer would like to vary, even during a performance. How should the tuning of the piano best change when the performer shifts the flat fifth up or down a fifth?

One approach would just be to shift the whole diagram over a fifth - to keep the same set of differences from equal temperament, but just to shift the assignment of those differences a fifth. This can be diagrammed with:


This is clearly not very satisfactory. Every note on the piano gets adjusted - most notes a flattened two cents, but then one note is sharpened by twenty two cents. This global shuffling could be disruptive in the middle of a performance.

Another approach is simply to sharpen a single note by twenty four cents:


The great advantage of this approach is that, when shifting the flattened fifth one step around the circle of fifths, only one note is changed: the eleven others are left unaltered. This should eliminate any sense of disruption during a performance.

However, with this approach, the whole set of differences from equal temperament drifts sharp by two cents. Shifting again and again in the same direction would just keep sharpening the tuning of the piano. But that is the nature of real Pythagorean tuning: the circle of fifths just doesn't close!

Of course the performer would also have the inverse option, to move the flattened fifth back in the circle of fifths. Again eleven note are unaltered, and then one note would be flattened by twenty four cents.

It looks like this approach to dynamically shifts for Pythagorean tuning could be implemented naturally on the Yamaha Motif XS synthesizer, using the stock tuning controls.

Step one is just to work with Pythagorean tuning, to explore the musical value of the just tuned perfect fifths, and then to see how that awkward very flat fifth gets in the way. Then one can start to explore how dynamically shifted tuning allows one to push the piano past its usual limits - it's as if the piano actually has more keys than twelve per octave!

Wednesday, August 18, 2010

Dynamically Tuned Piano

Tuning a keyboard instrument such as a piano so that each half step has exactly the same frequency ratio is the tuning system known as equal temperament. In equal temperament, a sequence of notes can be shifted up or down the keyboard by any number of steps, and the harmonic relationships between the notes will not be changed. This symmetry is a big advantage for equal temperament.

As discussed by Kyle Gann, there are subtly different tunings that have some other advantages. The fundamental problem with equal temperament, or really with any tuning system, is that the mathematical ratios underlying harmony can be combined in an infinite variety which would require densely packed notes infinitesimally spaced, if the mathematical ratios were to be represented precisely by the tuning system. For a tuning system to provide only a manageable set of notes to a performer, some or all of the intervals will have to be adjusted, or tempered.

Any tuning system that is not equal tempered will not be symmetrical, by that very inequality. A sequence of notes will sound somewhat different if it is shifted up or down the keyboard. For example, the fifth from C to G might be slightly different than the fifth from E to B. A musical piece will have a slightly different character when transposed to a different key.

This variety of character opens up an interesting musical possibility. Given modern keyboard technology, the pitch of any note on a keyboard can be shifted slightly in an instant. To change the character of a piece of music, one could leave the music in the same key, but just tweak the tuning of the instrument on the fly, during a performance.

This is analogous to an orchestral harp. A harp has only seven strings. One can use the pedals of the harp to sharpen or flatten strings, one pitch class at a time, so the harp can be played in the different keys. My proposal here is to take a keyboard that can has twelve pitch classes available, and to use a pedal, or perhaps hand operated controls, to shift one or more of those twelve pitch classes slightly sharper or flatter, to make available multiple non-equal temperaments during a performance.

Here is one concrete proposal for a set of operations to shift tunings. Studying Kyle Gann's presentation of Young's Well Temperament from 1799, one can see that the deviation of the pitches of the various notes from equal temperament follows a simple pattern when plotted along the sequence of fifths:



Typically one will want to shift the meanings of the notes, the harmonic structure, by a fifth. One could just shift the tuning pattern directly:


This shift leaves four pitch classes unaltered, sharpens four, and flattens four. One problem with this shift is that the four unaltered pitch classes are in two separate pairs. Musically, probably only two are significant at any time.

One can also provide two alternatives: shifting up


and shifting down



These two shifts also leave four pitch classes unaltered, but the four pitch classes are all together in the circle of fifths, and so would generally work better as a tonal center during a shift.

A complete system could provide these three alternative shifts when moving up a fifth, and the corresponding three when moving down a fifth, for a total of six single step possibilities. Each step could be repeated indefinitely. Shifting over repeatedly would bring one back to the same tuning after twelve shifts. Shifting up or down repeatedly would keep sharpening or flattening notes, so the whole tuning would be drifting up or down in pitch. Of course, a more typical usage would likely be to shift up when moving a fifth in one direction, then to shift down when moving a fifth in the other direction, which would return the keyboard to the starting tuning.

Monday, May 17, 2010

Who Shall We Blame?

It's anybody's guess at this point, what damage the on-going Deepwater Horizon oil spill will cause. Even long after the flow has stopped and the oil has dissipated and settled, much of the damage will be deep underwater, and much of the damage will be blended in with the side effects of so many other industrial processes, that we will never be able to assess the impact with much precision. But it's clear that the damage will be severe. Surely, someone must pay the price. Surely we have the right and duty to insure justice is served.

I don't know much about the theory or practice of law. It certainly seems valuable to have some social mechanisms to discourage harmful behavior, along with those to encourage helpful behavior. But any such mechanisms will inevitably be very crude. The realities of harmful and helpful behaviors get exquisitely subtle, while the political and bureaucratic mechanisms of the law are dreadfully gross. The situation is the same with charity. It's good that we have charitable institutions, but a cornerstone of society is built of the charitable actions of individuals at the personal level. Another cornerstone is formed by our personal actions of encouragement and discouragement, and our personal evaluation of the helpful and harmful character of actions.

There will surely be plenty of blame passed around for this oil spill. Any operation of this scale and complexity will include many mistakes and oversights. Usually there isn't such a catastrophe to provoke their being brought to light. Now we have a catastrophe. We will hear about the mistakes. However the legal system decides to assign the blame, though, we would be wise to look carefully at the deeper patterns underlying the situation.

The real situation is not properly characterized as a single blown-out well spewing thousands of barrels of oil each day into the Gulf of Mexico. The real situation is that such catastrophes have become a daily routine in our world. Do the tar sand operations in Alberta, operating as planned, do much less damage than this accidentally blown out well? Or look at the damage from the strip mining of coal, or... anyone with their eyes open can extend this list indefinitely.

We can blame corporations, or the financiers, or the government. But Pogo really hit the point: "We have met the enemy, and he is us." It's not just how each of us damages the planet through our individual actions of driving a car, etc. It's not even just how our demand for goods and services drives others to meet our demands through damaging actions. We are all members of the global community, participants in a grand shared imagination of the facts and values that constitute our world, our reality. We are all responsible for bringing into reality the kind of world we have, of daily ecological catastrophe. We all have the responsibility to change, to cultivate a new vision.

It might be that, in a world where risking such catastrophes is unacceptable, the price of gasoline is more like ten dollars per gallon rather than three, and due to that we all experience many constraints on our travels and on the availability of goods and services. Perhaps we can see that by paying such a price we will have purchased a planet that can provide our great grandchildren with an environment in which they can thrive. We might think that we have stumbled upon a remarkable bargain, and celebrate.

Just as the tone and character of our individual life is built up of moments of experience and response that flow from one to the next, so our society and culture are constituted by nothing other than our momentary celebrations and condemnations flowing from individual to individual and recycling through the networks of our communities. We each have the power and responsibility to steer not only our individual responses but those at every scale in the world in which we live.

This is our catastrophe. It is up to each of us to create a world where such catastrophes are vanishingly rare, instead of the daily routine.