Monday, 28 July 2014

AirPlay Problem :(

BitPerfect appears to have a problem with AirPlay following the coincidental updates of OS X to version 10.9.4 and iTunes to version 11.3.  It is most likely that the OS X update is responsible, but we can't be sure at this time.  The problem results in there being no sound over AirPlay even though BitPerfect's menu bar icon is green.  Error messages from 'coreaudiod' are sent to the console log every second or two.  We are still trying to get to the bottom of this, and I will post further information here as things become clearer.

Friday, 25 July 2014

The Gold Standard?

Audiophiles often report being able to hear audible effects for which the currently accepted wisdom has no adequate explanation.  In such circumstances, the internet trolls - who are only ever skeptics - can be relied upon to invoke two ideas from medical science to disparage any viewpoints which disturb their comfort zones.  The first is the Double Blind Test (DBT).  According to those “experts”, unless you can demonstrate that a thing is audible via a scientifically-conducted DBT, then you have no basis for claiming that it is at all audible in the first place.  The second is that, when faced with a significant body of opinion that the disputed audibility is in fact real, they will attribute the result to “the placebo effect”, the strong implication being that idiot audiophiles are simply fooling themselves.  Unfortunately, the underlying basis of these invocations almost always goes unchallenged.  Is it right to uphold a DBT as the Gold Standard for determining subjective attributes?  And can the placebo effect be validly raised to explain away subjective observations?  I thought it would be worthwhile to take a closer look at those things.

A medical experiment often involves comparing one thing with another - usually a specific treatment and a placebo.  A DBT is conceived to eliminate two critical sources of bias from the test - those originating from the subject and those originating from the experimenter.  In the medical field, both sources of bias are unusually significant.  The subject clearly has a personal vested interest in the outcome of the test, and knowing whether they are receiving a real treatment or a placebo may compromise its validity.  A medical experimenter is typically a doctor, who has a overarching duty to the patient, and maybe also has a biased interest in the outcome of the experiment.  Bias on either part can destroy the validity of the experiment, and so a DBT is a test regimen which ensures that neither the subjects nor the experimenter are aware which of the test subjects are receiving which of the treatment options, knowledge which could affect the outcome of the experiment.

The first recorded DBTs were done during WWI with patients suffering from “shell shock”, a syndrome with which there was considerable disagreement within the medical profession regarding its interpretation, treatment, and prognosis - it was therefore particularly important that the treating physician be ‘blinded’ from the specifics of the ongoing test.  To be fair, DBTs are used these days in fields other than medicine (although much more rarely), but usually only where there is reason to suspect the influence of experimenter bias.

Incidentally, there is also a “Triple Blind Test” in which the person assessing the results and determining the formal outcome of the experiment is also blind to the details of the experiment.

A key element of a DBT is that the subject must be responsive to the test.  In other words, if we are testing the efficacy of an anti-cancer drug, it is no use using subjects who do not have cancer.  The responsiveness of the patient is usually assured by the fact that patient desires to be cured.  But if the test requires its subjects to walk five miles every day between visits to the clinic, it is important to weed out subjects who are likely to play fast and loose with their obligations to faithfully pursue the prescribed regimen.  Finally, if the outcomes are self-reported (for example, the subjects are asked whether their headaches disappeared), the experiment’s entire outcome relies on the subjects’ ability to self-report, both accurately and consistently.

So there we have the three pillars of a successful DBT.  Both the experimenters and the subjects must be free from bias, and the observed outcomes of the test must be both unambiguous and reliable.  That third requirement is one which high end audio’s internet trolls tend to forget.  It is no use whatsoever constructing a test with great detail paid to the blinding of the subjects and experimenters if the ability of the test methodology to delineate the anticipated outcomes has not been previously established.  In a medical example, this would be like using a DBT to determine whether a certain treatment made the subjects “feel better”.  The experiment would be totally pointless unless we had evidence to show that the methodology of the test can satisfactorily extract from the subjects reliable information as to the extent to which they “feel better”.

In audio, this third requirement is usually the killer.  ‘Blinding’ both the subjects and the experimenters is a trivial thing to do.  Extracting unambiguous test results from the subjects is not, and there are good reasons for this.  For a start, Joe Average is not a good test subject when it comes to detecting subtle differences in audio presentation.  The fact that Joe cannot perceive something is not proof that the thing cannot be perceived, even if you assemble a thousand Joes.  It is necessary to pre-qualify the test subjects, to establish that they can reliably detect the sort of differences that you are looking to test for under the conditions of your test methodology before you include them in the test.  The kind of skeptics who promote the concept of DBTs to resolve audiophile disputes usually find this requirement to be in some way unacceptable (of course), but that’s the truth of it.

Stereophile’s Michael Fremer - a favourite target of the internet trolls - has never made any secret of his willingness to participate in a properly conducted test to determine whether or not he can actually hear the things he claims he can.  He has even volunteered to go head-to-head with the Amazing Randi with $10,000 at stake.  But he has always insisted on having a veto over the methodology.  In other words, he won’t allow himself to be tested under conditions where he doesn’t think he will be able to perform.  He is very open about what he considers those conditions to be.  I find nothing wrong with that, and I fully accept that the more esoteric the differences he is expected to be able to resolve, the more picky his requirements are by necessity going to be.

The other medical tool in the audio skeptic’s armoury is the “Placebo Effect”.  Most people think they know what the placebo effect is, but very few actually do.  In reality, surprisingly little is known about it.  It arose from the first clinical drug trials, when it was discovered that patients tended to improve when treated with sugar pills which had no apparent active medicinal effect.  Such pills - and their procedural analogues - became known as placebos.  Therefore the standard that any drug or procedure had to meet before it could be introduced onto the market was that it had to outperform a placebo.  That is fair enough, but for decades the question was always “how can we make better drugs” and never “how can we make better placebos”.  That is changing, though.

A significant hindrance in pursuing placebos as a treatment was - and is - the troublesome ethical dimension to the debate.  Treating with a placebo would appear to require deliberate deception on the part of the doctor.  But placebo research is now a lot closer to mainstream, and the medical establishment is prepared to at least consider as valid a lot of the research into what the placebo effect actually is.  This research is beginning to deliver some unexpected answers, and while these are interesting they only serve to give rise to some new and unexpected questions.  For example, early studies appear to show that you can actually tell patients that they are taking placebos and yet still observe the same benefits.  Other studies are now looking into the physiological response of patients to placebo treatment, and comparing these responses to responses under other types of stimulus.  Just the simple fact of a doctor displaying a sympathetic and attentive bedside manner turns out to be an effective placebo, which may not be something your budget-constrained Minister of Health wants to hear.  So studies are also looking at the physiological responses of doctors while administering placebo treatments - who knows where that might lead!  With all this new interest, a lot of traditional non-western medicines - acupuncture would be a clear example - are now suggested as being perhaps elaborate protocols for administering the placebo effect.  It is a fascinating topic.  If you are interested to read more, do a Google search for “The Placebo Phenomenon” - the first hit should be from Harvard Magazine.  Read it.

The key takeaway for those who want to invoke the placebo effect in the audiophile debate is that it is a real and quantifiable effect.  Phenomena attributable to the placebo effect are undeniably real - it’s just that you don’t have an adequate explanation as to why.  It is wrong to invoke it in order to imply that something exists only in a person’s imagination, or is a product of self-delusion.  If a person insists that placing an Elvis Presley bobble-head on his amplifier improves the imaging depth of his system, it might be quite reasonable to be a little skeptical, but it would be incorrect to suggest that the placebo effect is responsible.  Actually, by suggesting it is a placebo effect, you are in effect acknowledging that the system’s imaging depth IS improved!  An Elvis bobble-head may be a lot of things, but a placebo probably ain’t one of ‘em.

Wednesday, 23 July 2014

Sports Stars

Here in Canada - and particularly here in Montreal - we love our Hockey.  Ice Hockey, that is.  Hockey is arguably the fastest, most energetic, most physical professional sport on the planet.  With enough moolah in your pockets, you can buy NHL tickets that seat you right up against the glass - less than an inch from the most explosive action in sports.  No professional sport in the world can come close to providing the experiencing of watching an NHL game from one of those seats.

Like most professional sports, if you want to play NHL Hockey you need to be seriously committed from an early age.  You’ll need the right combination of body type, serious skills, unblinking determination - not to mention parental support - if you are to crack the 23-man roster on one of the 30 teams in the National Hockey League.  So many aspire to join those ranks, but so few ever make it.  Every single teenager who plays amateur Major Junior Hockey in the USA or Canada shares that ambition, but in fact less than one in twenty will succeed.

It is like that in other major league sports, too.  Baseball, Football (aka Soccer), Football (aka Football), Tennis, Formula One, Golf, Basketball, Boxing.  But the financial rewards for making it to the pinnacle can be truly staggering.  In all of these professional sports, the top stars earn mind-boggling sums of money.  I suppose that’s fair enough. In all walks of life, those with the greatest skills and steeliest determination tend to make it furthest up the ladder, whether you are a businessman, a doctor, a lawyer - or a sportsman. I  suppose that is something we can all accept.

But yesterday, I heard something in a Ted Talk (it was on the radio so I can’t post a link) that made me stop and think.  In Basketball, as we all know, it pays to be tall.  The shorter you are, the less chance you have of making it to the NBA.  According to Wikipedia, in its entire history, only 24 players 5’ 9” tall (the height of an average American male) have ever made it to the NBA.  Apparently, there are only two such players active today.  Imagine the skill you would need to make it to the NBA as a human being of only average height.  Today, in the NBA, a full 10% of all the players are seven feet tall or more.

Does just being seven feet tall trump all the skill in the world?   Incredibly, it would appear so.  Today, according to the Ted Talk, of all Americans alive today who are seven feet tall, an incredible 17% of them are **ALREADY** playing in the NBA!!  And that’s before we take into account those who are too old (or too young).

Think about that.  If you grow up to be seven feet tall, before we even start to consider any physical skills that you may or may not possess, you already have a better than one-in-five chance of being accepted into a professional cadre whose minimum salary is half a million dollars a year; whose average salary is 5 million dollars a year; and whose top performers pull in more than 20 million dollars a year.

I find that surprisingly disturbing.

Tuesday, 22 July 2014

The Thrill Of The Chase

I had a friend named Steve (not his real name). He was originally my financial adviser, and at one time we got to the point where we started looking at opportunities to go into business together. Steve became disillusioned with the financial advice business which he saw as being over regulated. The role of a financial adviser, as he saw it, had become one of trying to keep up with the ever-increasing mass of regulations, and picking one of an ever-diminishing selection of investment options which the regulations prescribed according to the client’s circumstances. Worse than that, he perceived a widening disconnect between actions that were in the client’s best interests and those that were in the adviser's best interests.

Steve was an archetypical sales guy. The CEO of a company I once worked for told me that there were two types of sales guys, which he called Hunter-Killers and Gardeners. The Hunter-Killer is always on the lookout to close a deal, and if he doesn’t see any kind of a deal in the offing he won’t hesitate to cut bait and go look elsewhere. The Gardener, on the other hand, knows that it is often necessary to cultivate a client over the long term, and to gradually build him up to the point where a deal is ready to be harvested. The Hunter-Killer is in his element with smaller deals, the Gardener with bigger ones. The Hunter-Killer is a big, energetic, bouncy dog, ready to hurtle off at full pace in pursuit of a stick. The Gardener is a cat, hopping up onto your lap, taking its time to get comfortable, and settling down for a long nap accompanied by a loud and satisfied purr. Depending on the kind of business you are in, you need one type of salesman or the other. And often you need both.

Steve was your typical Hunter-Killer. Me, I’m not any kind of salesman. Its not in my makeup. If pushed I could function better as a Gardener than a Hunter-Killer, but that’s just how it is. I am more of a strategist. So Steve and I potentially made for a good team. Steve, the big, energetic, bouncy dog, would hustle off in the direction of a potential business opportunity, and drop it in my lap. I would figure out what was necessary to turn that opportunity into a functioning business. Usually, the opportunity would be flawed, and Steve would immediately hurtle off after another one. The trouble was that to make an opportunity work for Steve, we would have to start up the business on Monday, and Steve would head out on Tuesday and start selling. By Friday I would tell him how much money we had made. Businesses rarely, if ever, work like that, so naturally we never got anything off the ground. But it was an endless source of fascination to examine the surprising variety of opportunities he unearthed, something I look back on with some fondness.

One thing Steve wanted more than anything else was to own a BMW dealership. Actually, he wanted to own a BMW, but projecting that ambition further led him to covet a whole dealership. So he left the financial services company and went to the local BMW dealer to get a job as a salesman. This would be an ideal position, he figured, from which to learn what it would take to acquire a dealership. Unfortunately, BMW are very selective in whom they employ, and salesmen with no experience whatsoever selling cars are not generally welcome. Steve was advised to go get some experience elsewhere. So he got a job with a local GM dealer, who were less picky. By the end of his second month he was their second-highest performing salesman, and from the third month onward became their top performer. Within less than a year he went back to the BMW dealer and was hired on the spot. He became an effective salesman very quickly. But the deal he really wanted to close was to own a dealership. He cozied up to the owner, and the more he learned about how the business worked, the more he realized that it wasn’t going to happen for him. For a start, the buy-in cost alone was so much more that he ever imagined. Why, he asked me with his financial adviser's hat on, if you had that kind of money, would you ever spend it on a BMW dealership?

Steve had one client in his role as financial adviser, who was raking in a lot of money in the used car business. Steve was anxious to know how he did it. The client was equally anxious not to tell him, but Steve is nothing if not persistent, and so he managed to extract an outline of how this man’s business worked. Basically, as he described it, he bought certain specific models of used GM vehicles at auction in Canada and exported them to the southern States where their resale value was a lot higher. Steve and I got together to try and figure out how a business model like that could rake in the amount of money his client was clearing, but the one thing we couldn’t get a handle on was how the business of buying cars at auction worked.

As it happened, at about the same time I was introduced to a guy called Nick (also not his real name) who was in the used car business. His thing was that you told him what vehicle you were looking for - being as specific as you wanted - and he would go out and find one for you, and sell it to you at a good price. Having learned a thing or two from Steve, I pressed Nick for more details on where these cars came form, and learned that he bought them at massive trade-only auctions. I persuaded him to take me to one of these auctions, where I was formally registered as his assistant (you can’t get in if you’re not in the trade). What I found was a facility with thousands upon thousands of used vehicles, virtually all of which would be sold at the upcoming auction. These auctions happened every week. The auction itself was staggering. Vehicles passed through so quickly, and bidding on each one was over in a matter of seconds. If you knew what you were doing, it was possible to come away with a surprisingly good deal. In the end, Nick bought two cars for me this way, which I was pretty happy with.

Steve managed to negotiate a nice little sideline for himself by bringing clients to Nick and arranging financing for their purchases. With Steve plugged in this way, Steve and I were able to glean sufficient information from Nick to establish that Steve’s client, whatever he was doing, was not raking in the cash he said he was by exporting used Chevrolets to Florida! Another business opportunity that fell by the wayside.

But Steve did see an opportunity to acquire for himself the BMW he had always wanted. Steve was a big guy, so the 7-series was his thing. He saw that the 740iL and 750iL, particularly the ones with high mileage, could sometimes be picked up for a song. The value of a 7-series at auction was very mileage dependent, and from his experience at the BMW dealer he knew two things - how to check a BMW’s service history and how the company’s warranty system worked. From his experience in financial services he also knew a third thing - how private car lease financing worked. Prowling the auctions with Nick he looked for high mileage 7-Series Bimmers with spotty service records. He instructed Nick to buy at a particularly low price if the opportunity came up. It did, and Steve became proud owner of a two-year old BMW 740iL. Steve then had Nick wind its clock back from 120,000km to 60,000km, which meant it still had 20,000km before its warranty expired. He arranged lease financing with a fixed buy-back based on a book price which three years down the road would be more than he paid up front for the car. He took the car to a BMW dealership and had them inspect the hell out of it and perform a whole bunch of warranty work including, incredibly enough, a re-spray. Steve apparently had no qualms about any of this.

Thus, in May of 2000, Steve became the proud owner of a near-new BMW 740iL in tip-top condition, and was paying less in lease payments than he was previously paying for the Nissan Maxima that he sold to make room for it. Steve, for one who negotiated so effectively with his cards close to his chest, was surprisingly a man who often wore his heart on his sleeve. We were going for a long drive in the 740iL one day, when he told me what he thought about the whole affair. He had wanted a BMW for so long, he said, that he never thought he would be able to afford one. Now that he had one, and had owned it for several months, he told me that he realized something important. The long-felt desire to own such a fabulous vehicle, and the thrill of the chase to come up with a scheme that actually put one in his garage, were in the end deeper passions than the actual fact of owning the thing. He was quite disappointed that the thrill of the chase and the thrill of the kill were somehow not being satisfied by the subsequent feast. Yes, the BMW as a vehicle was everything he thought it would be. The sound system, I can tell you, was fantastic. But in the end it was just another vehicle that needed to be filled with gas, washed, and driven from place to place. And the jaws of your friends and neighbors would only ever drop once. Not a person to let the grass grow under his feet, he told me he was going to sell it. In fact he had lined up a buyer. More than that, he had put his house on the market and was going to move to Florida. Just like that.

Steve did move to Florida, where, last I heard, he was selling private medical insurance and planning to take a course to get his Real Estate license. My guess is he won’t have had the patience to complete it.

Nick, on the other hand, absconded one day with thousands of dollars of someone’s money, on deposit for a specific vehicle he was tasked to obtain. He hasn’t been heard of since. I’m just glad it wasn’t me that recommended him to the client who got fleeced.

Friday, 18 July 2014

Impulse Response

If you choose to embark upon an entrepreneurial career, you will often find yourself putting together financial spreadsheets to model your business. Investors in particular love to pore over scenarios of how your business might develop, and having a good financial model is an invaluable tool to have at your disposal. Of course, if you’re smart, you’ll want to thoroughly test your spreadsheet to make sure that your financial logic contains no embarrassing errors. One of the techniques for doing that is to enter an arbitrary billion dollars into one of the input cells, and see where else in your spreadsheet unexpected extra billions show up. It is very easy to spot billions of dollars when they start to appear in places they don’t belong. You might say that what you are doing is measuring the “impulse response” of your spreadsheet.

Digital filters are no different. Data goes in one place, and results come out someplace else. In this case, both the inputs and outputs are streams of numbers. Conceptually, digital filters are quite simple things. You take the input value, and add to it bits of the previous input values together with bits of the previous output values. That’s really all there is to it. The filter design tells you how many of the previous input and output values go into the mix, and precisely what fraction of each to use. Some filters only rely on the previous input values, and don’t use the previous output values. Filters that do use the previous output values have an interesting property - each output value contains a little bit of each and every previous input value.

What are the implications when a bit of one input value ends up in each and every one of the subsequent output values? A very easy analysis would be to take a signal comprising digital silence - in effect nothing but zeros - and modify it so that one data point (and only one data point) is at a maximum value. We call this waveform an “Impulse”. We put this data stream through our digital filter and see what comes out the other end. What happens is that the output comprises a stream of zeros up until the time the impulse reaches the input of the filter. After that, the output will comprise a sequence of non-zero values - in effect a series of echoes of the original impulse. This artificial construct - how the residue of one single impulse value in a sea of zeros appears in the output data stream - is called the “impulse response” of the filter. If the filter uses only previous input values and no previous output values, then the echoes will fall to zero as soon as we reach the point where the impulse is no longer one of the previous values that goes into the mix. Such filters are called “Finite Impulse Response” (FIR) filters. If, however, the filter uses previous output values, then the echoes of the impulse will remain within the output signal forever, or at least until such time as its magnitude becomes too small to register. These filters are called “Infinite Impulse Response” (IIR) filters.

An impulse response looks like a waveform. You can easily plot it out. It looks like a waveform precisely because it is a waveform, and you can do anything with it that you can do with any other waveform. Impulse responses have many interesting properties, most of which are beyond the scope of this post. But, as an example, if we take its Fourier transform, the result is the transfer function of the filter, which is to say its frequency and phase responses. This is why the key aspects of a filter’s performance are intimately inter-related. Once you define a filter’s frequency response (for example by defining the characteristics of a low-pass filter) and phase response (for example by specifying linear phase or minimum phase), you will have set in stone its impulse response. In other words, the impulse response (IR) is the direct consequence of the choices you have made in terms of frequency response (FR) and phase response (PR). What it boils down to, is that when it comes to filter design, you only get to specify any two of its IR, PR and FR, and the third will be determined for you.

Tuesday, 15 July 2014

The Most Beautiful Piece of Music Ever Written

They say beauty is in the eye of the beholder. What is beautiful to one person, may not be beautiful to another. However, a significant element of that is cultural. The things we have grown up being told are beautiful are usually the things we hold to be beautiful for the rest of our lives. But those standards evolve over time and place. The ideal classical female figure is apparently somewhat chunky to the modern sensibility, just as today’s anorexic teenaged supermodels would appear emaciated to Da Vinci, Michelangelo, and the Ancient Greeks (although maybe not to Botticelli, whose aesthetic appears to have been somewhat more ‘modern’ with his tall, willowy, long-limbed blondes).

Faces are somewhat different. There is plenty of evidence that the most attractive facial features have remained more or less constant over the ages, with many common traits that can be discerned across both ethnic and cultural boundaries. Symmetry, for example, is a notable common factor. Men and women around the globe tend to find symmetric facial features to be superficially more attractive in the opposite sex.

What about music? Can music be said to be fundamentally beautiful? For sure, there is some music which is very clearly the opposite of beautiful, and people from different cultures can be found to agree on that. After all, there is no requirement for music to be beautiful in order to be good. Music tends to benefit greatly from the creation and resolution of tension, dissonance, and rhythmic discord. But some music is undeniably beautiful, like Schubert’s “Ave Maria”. Who would disagree with that? How about the Ode to Joy from Beethoven’s 9th symphony. Is that beautiful? How about NWA’s “Straight Outta Compton”? The fact that you can discern meaning and feel a powerful connection with a piece of music is not the same thing as finding it beautiful.

What is it about music that makes it beautiful to our ears? Three things tend to stand out. The first is that beauty pretty much always requires a major key. The sort of beauty that makes you smile is inevitably in a major key. The second is that beautiful music tends to have slow tempi and simple rhythmic structures. This is wonderfully expressed by the title of a great Alison Moyet song “I Go Weak In The Presence Of Beauty”. That’s what beauty does. It doesn’t enervate you. It makes you go weak at the knees. The third attribute is that beautiful melodies tend to have arching spans. Most well-known tunes follow a path of adjacent notes up and down the musical scale. The theme from Beethoven’s Ode To Joy that I mentioned earlier follows this path. It may be stirring music, but it is not particularly beautiful. Beautiful music tends to have themes which feature prominent jumps from one note to another some distance away. These jumps - usually jumps up in pitch rather than down - are usually themselves the focal points of the music’s inherent beauty.

There is one piece of music that to my ears epitomizes beauty in music. I first heard it in 1972 when the choir I was in performed a version of it. I think no less of it today than I did then. It is one of my “desert island” pieces. It is, I humbly assert, the most beautiful piece of music ever written. I think it would be terribly sad to go through life without ever hearing it.

“Serenade To Music” was written by the English Composer Ralph Vaughan Williams in 1938. It is scored for an orchestra, solo violin, and 16 vocal soloists, and is a setting of an extract from Shakespeare’s “The Merchant Of Venice”. The solo vocal parts were specifically written for 16 prominent English singers of the day including Isobel Bailie and Heddle Nash, and each part is annotated by the composer with the initials of the designated singer. A recording exists, made shortly after the work’s premiere, by the same performers. It is more of musical and historical than audiophile significance, but captures a wonderful vignette of the ethereal beauty that was soprano Dame Isobel Baillie in her prime. Sergei Rachmaninoff, himself no stranger to musical beauty, attended the premiere (having performed his 2nd Piano Concerto in the first half of the concert) and was said to have broken down in tears at the beauty of the music.

There are precious few recordings of Serenade To Music, and I can’t think why. It is a bucket list composition. The best is Sir Adrian Boult’s 1969 recording with the London Philharmonic on EMI’s HMV label. This is a terrific performance (Boult was an absolute master of Vaughan Williams) marred only by Shirley Minty’s dreadful - and thankfully brief - contribution which literally makes me cringe for a second until she’s finished. I have this on LP only and I don’t know if it is available anywhere for download. The world still awaits a modern digital recording of this stunning work.

It would be worth a little effort on your part - well OK, maybe quite a lot of effort - to seek it out.

Monday, 14 July 2014

Fazed by Phase

In my discussion on square waves, when I mentioned the properties of its Fourier components, I glibly suggested “We’ll ignore phase”.  In truth, we need to look a little more closely at it.   I’ll start by defining phase.

Imagine in your mind’s eye a graph of a sine wave. If this were to represent a sound wave, the vertical axis would represent the air pressure oscillating up and down, and the horizontal axis would represent the passage of time. If you were to capture that sound wave with a microphone, the voltage waveform that the microphone would create would look just the same. Imagine now that you could actually “see” the sound waves, as though they were waves on the surface of a pond. Imagine yourself standing next to the microphone, observing the sound waves as they travel toward you and the mic. Imagine that you can make out the individual peaks and troughs. You can watch an individual peak approach and impinge on the microphone. At the instant it does so, you observe the output voltage of the microphone. You will see that the output voltage also goes through a peak. You watch as the peak passes by and is replaced by its trailing trough, and you observe the voltage from the microphone simultaneously decay from a peak to a trough. I hope this is all pretty obvious.

Now we are going to add a second microphone. Except that we are going to align this one a short distance behind the first one. Now, by the time the peak of the sound wave impinges on the second microphone, it has already passed the first one. The output voltage from the first microphone has already passed its peak and is on its way down to the trough. But the output voltage of the second microphone is only just reaching its peak. Over a period of time, both microphones capture exactly the same oscillating sine wave, but the output of the second is always delayed slightly compared to the output of the first. This is the Phase of the sine wave in action. The phase represents the time alignment. And, as you can work out for yourself, it is not the absolute phase which is important, but the relative differences between phases.

Interesting things happen when we add two nominally identical sine waves together. Let’s specify two sine waves which have the exact same magnitude and frequency, but differ only in phase. I won’t go into the mathematics of this, but what you get depends strongly on the phase difference. If both phases are identical the two sine waves add up, and the result is a sine wave of exactly twice the magnitude of the original. However, if the two sine waves are time aligned such that the peak of one coincides with the trough of the other, then the end result is that both sine waves cancel each other out and you end up with nothing. These two extreme conditions are often referred to as “in-phase” and “out-of-phase”. However, there are a whole spectrum of phase relationships between these two extremes. As the phase difference gradually varies from “in-phase” to “out-of-phase”, so the magnitude of the resultant signal gradually falls from twice that of the original, down to zero.

Lets now go back to the square-wave example of yesterday’s post. Yesterday’s example was concerned with the summing of individual sine waves (a fundamental and its odd harmonics), and how the more of these odd harmonics you added in, the closer the result approached to a square wave. We also saw that by limiting the number of harmonics, what we got was a close approximation to a square wave, but with some leading and trailing edge overshoot, and a bit of ripple. However, in all of that discussion we took no account of phase. Or, more specifically, we allowed for no phase difference between the different harmonics. What happens if we start to introduce phase differences?

The result is that we no longer get a nice clean square wave. As we mess with the phase relationships we get all sorts of odd-looking waveforms, some of them bearing precious little visual relationship to the original square wave. Yet all of these different waveforms comprise the exact same mixture of frequencies. The obvious question arises - do they sound at all different? In other words, can we hear phase relationships? This is a tricky question.

My own experiments have shown me that I have problems detecting any differences between test tones that I have created artificially, comprising identical assemblies of single frequency components added together with different - and sometime arbitrary - phases. But from a psychoacoustical perspective this is perhaps not surprising. Our brains are not wired to recognize test tones, and cannot therefore create a sonic reference from memory with which to compare them, so it is not surprising that I would find it very difficult to hear differences between them.

The conventional wisdom is that relative phase is inaudible, but this is hard to test with anything other than synthesized test tones. With real music there is no possibility to independently adjust the phase of individual frequency components (for reasons I won’t get into here) so the question of the audibility of relative phase is one which remains either unproven, or proven as to its inaudibility, depending on your perspective.