<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Dahnielson</title>
	<atom:link href="http://en.dahnielson.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://en.dahnielson.com</link>
	<description>Misleading the public since 1979</description>
	<lastBuildDate>Mon, 08 Apr 2013 07:57:55 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>Decoupling</title>
		<link>http://en.dahnielson.com/2012/01/decoupling/</link>
		<comments>http://en.dahnielson.com/2012/01/decoupling/#comments</comments>
		<pubDate>Thu, 12 Jan 2012 11:45:50 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[Besserwisser]]></category>
		<category><![CDATA[Decoupling]]></category>
		<category><![CDATA[Linked data]]></category>
		<category><![CDATA[Templates]]></category>
		<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/?p=485</guid>
		<description><![CDATA[I would like to talk to you about something that has been on my mind lately: Decoupling. No, it&#8217;s not any particularly new concept and something I&#8217;ve been practicing as a software developer over the past ten years. What I have been thinking about is its application to the web, our software stacks and how [...]]]></description>
				<content:encoded><![CDATA[<p><img src="http://en.dahnielson.com/wp-content/uploads/2012/01/scepka.png" alt="" width="530" height="250" class="aligncenter size-full wp-image-511" /> I would like to talk to you about something that has been on my mind lately: Decoupling. No, it&#8217;s not any particularly new concept and something I&#8217;ve been practicing as a software developer over the past ten years. What I have been thinking about is its application to the web, our software stacks and how I would like to take it further in my own work.</p>
<p>In computer science <em>coupling</em> is the term used to describe how much one piece of code relies on another piece of code and knowledge about the inner workings of that code to be able to use it. Decoupling is the process of separating them so that their functionality will be more self contained.</p>
<p>Decoupling is a good practice as it makes the individual parts easier to maintain and change. In software development we usually start with doing the simplest thing that could possibly work. As long as something delivers what its users expect, implementation does not matter. You could start with a simple, but inefficient implementation just to get things going, and then switch to a more efficient when you need to start to scale without your users being any wiser. Put in other words: The higher degree in wich something is coupled the harder it gets to do something simple.</p>
<p><span id="more-485"></span> A motivation for decoupling in web development is friction. Friction, used more or less in the following sense was something I first encountered in a blog post by <a href="http://www.gyford.com/">Phil Gyford</a>. Friction is an excellent word to describe the resistance to start doing something. Be it writing this blog post, creating and improving a design or implementing a new system. Before I start work on something I tend to sense what is needed to do the job, usually stuff start to pile up and the works begin to feel overwhealming. Even the simplest thing instinctively feels hard to do. That&#8217;s friction.</p>
<p>The more something is coupled, the more it provides friction for me to start working on it.</p>
<p>To me there are currently two cases of friction due to coupling in developing for the web: Design of the front-end with templates and the relationship between the back-end and the front-end in a content management system or any complex web application.</p>
<h2 id="toc-templates">Templates</h2>
<p>You don&#8217;t mix business logic and presentation in a modern web application. In fact you usually separate the business logic and its constraints into a model, that is modified depending on the input by a controller and rendered by a view. The model-view-controller pattern. A way to decouple the components of an application. The problem is that not all web applications separate the view into templates as cleanly as I would wish. There is still too much logic in there, while not being business logic, it is still logic and that increase the friction to design and template the front-end.</p>
<p>All I want is to start write HTML, style it with CSS and progressively enhance the user experience with JavaScript without having to care about the web application or CMS. Sure, I could just start authoring regular HTML documents and convert them to the template system when I&#8217;m finished. The trouble is, you are usually never finished. Design is an iterative process.</p>
<p>The largest producer of friction for me right now is systems developed in <a href="http://php.net/">PHP</a>. They tend to use PHP as well as their template language, which is understandable as it is simple and in a sense efficient. However this means that you have to run the system to see what your templates will look like. This is not so much of a problem in development frameworks like <a href="http://rubyonrails.org/">Ruby on Rails</a> or <a href="http://djangoproject.com/">Django</a> as the framework provides a simple web server that run the application during development. In other words less friction. But in PHP there is no such thing, you have to set up a separate and full blown web server environment yourself. Friction.</p>
<p>The solution is to use a template language that not only can be used by the web application or CMS but that also include a static page generator. Using the static page generator and dummy data as a development environment without having to run the whole system. Decoupling the template authoring from the underlying system.</p>
<p>This is the reason why I have been using <a href="http://mustache.github.com/">Mustache</a>.</p>
<p>There are a lot of template languages, most of them try to do too much, Mustache on the other hand, try to do less. That way Mustache takes things a bit further. All it provides is variables, iteration through lists and conditionals for sections. The source of the data is decoupled from the templates. </p>
<p>My initial attraction was also the fact that there is implementations of Mustache in a wide variety of programming languages. Meaning I can use it in all my projects. I can even switch programming language or mix them in a project but still use Mustache as template language and even use the same templates. A lot less friction. Don&#8217;t you say?</p>
<h2 id="toc-linked-data">Linked Data</h2>
<p>The next thing is the relationship between the back-end and the front-end. This might not matter for most simple web applications, blogs and brochure sites but for any larger operation that will use and reuse its conent in different formats and context, this become a critical component of the architecture in the long run.</p>
<p>The problem is that in most content management systems and other web applications the front and the back is usually tightly coupled. What I ideally want is to use the right tool and the best tools for each job. I want to use the best system to manage the back-end and the ability to create different and new front-ends. In other words decouple them.</p>
<p>The solution is to create an API that the back-end can provide the front-end with. To me the ideal pattern for such an API is the concept of <a href="http://en.wikipedia.org/wiki/Linked_Data">Linked Data</a>. The concept of linked data and the principles it is built on are fairly obvious when you start to think about it. You use URIs to identify things, as keys, and the URIs should be HTTP URIs so that they be looked up and you can get useful data back about the things in a standard format, and most importantly: provide links to other related URIs to expose more data. This is pretty much how we think the web already should work. The difference with linked data is to make sure that this is how machines also should be able to use the web.</p>
<p>Instead of hooking your front-end directly to a SQL database, or using some RPC calls to connect to the back-end. Why not expose your data as linked data and provide it serialized in the format or formats of your choice: JSON, XML or even human readable HTML?</p>
<p>If you are already planning to create an Open API for your content or service, why not use it yourself internally as part of your architecture? That way you can be asserted it will be the best API for your service as you will be your own hardest critic and super user. That is what the BBC are doing with their <a href="http://www.bbc.co.uk/programmes/developers">Programmes</a> service. It is an Open API based on Linked Data  that BBC are using themselves to power all their sites. It&#8217;s what provide data to station and program sites. It&#8217;s what the iPlayer is just a front-end for.</p>
<p>Be your own API client.</p>
<h2 id="toc-putting-the-two-together">Putting the two together</h2>
<p>Over the past ten years we have been used to web sites that dynamically update parts of their pages using asynchronous JavaScript callbacks to the server. (Does anyone still call it Ajax or has this become too common for a buzzword?) If you already have your content provided as linked data serialized as JSON for your regular front, you already have the data accessible in a format that any additional JavaScript-driven front end will be happy with. Less friction.</p>
<p>With Mustache you don&#8217;t have to parse and populate the templates only on the server side. You can do it right there in the browser using a JavaScript implementation of Mustache. That is what <a href="http://engineering.twitter.com/2010/09/tech-behind-new-twittercom.html">Twitter have been doing</a> with <a href="http://twitter.github.com/hogan.js/">Hogan.js</a>.</p>
<p>How cool is that?</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2012/01/decoupling/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>And we&#8217;re back (once again)!</title>
		<link>http://en.dahnielson.com/2012/01/and-were-back-once-again/</link>
		<comments>http://en.dahnielson.com/2012/01/and-were-back-once-again/#comments</comments>
		<pubDate>Sat, 07 Jan 2012 23:28:07 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Excuses]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/?p=317</guid>
		<description><![CDATA[The infrequent visitor to this site might have noticed that I haven&#8217;t posted anything since, like, forever. Or put in other words, er, numbers: 2009. Much has happened since then. I begun studying at Linköping university. Was supposed to have a bachelor in history by now. (I am still working on it.) But instead been [...]]]></description>
				<content:encoded><![CDATA[<p>The infrequent visitor to this site might have noticed that I haven&#8217;t posted anything since, like, forever. Or put in other words, er, numbers: 2009.</p>
<p>Much has happened since then. I begun studying at <a href="http://liu.se">Linköping university</a>. Was supposed to have a bachelor in history by now. (I am still working on it.) But instead been <a href="http://vastgota.nation.liu.se">drinking beer</a>, passing law exams with flying colors and involving myself with student associations, <a href="http://stuff.liu.se">unions</a> and politics.</p>
<p>During 2010 I was responsible for <a href="http://sekel.studorg.liu.se">my student associations</a> website and publicizing the organisation (something I continued doing during 2011 despite me having moved on to another position on the board of directors) and simply didn&#8217;t have much time to work on my own projects. And as the following chart now shall amply demonstrate, I simply fell off the internet:</p>
<p><img src="http://en.dahnielson.com/wp-content/uploads/2012/01/stats2011-540x200.png" alt="" title="Stats for 2011" width="540" height="200" class="alignnone size-large wp-image-319" /></p>
<p>The reason being me moving to a new host about a year ago. I finally stopped whining about the poor shared hosting at <a href="http://surftown.se">Surftown</a> (the price went up every year without any improvement in service) and moved to a virtual private server at <a href="http://slicehost.com">Slicehost</a>. For some reason, that I today cannot fathom, I just couldn&#8217;t be asked to upload this, my bloggy thing in the English vernacular, to the new server.</p>
<p>So there you have it. My excuse. Now bugger off!</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2012/01/and-were-back-once-again/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The #spectrial</title>
		<link>http://en.dahnielson.com/2009/02/the-spectrial/</link>
		<comments>http://en.dahnielson.com/2009/02/the-spectrial/#comments</comments>
		<pubDate>Tue, 17 Feb 2009 21:29:50 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[From the hip]]></category>
		<category><![CDATA[Spectrial]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/?p=282</guid>
		<description><![CDATA[Following The Pirate Bay court case during the two last days has been like watching a special needs team play a NBA team, were former do all scoring in their own goal while the latter sits comfortably cheer leading from the sidelines.]]></description>
				<content:encoded><![CDATA[<p>Following The Pirate Bay court case during the two last days has been like watching a special needs team play a NBA team, were former do all scoring in their own goal while the latter sits comfortably cheer leading from the sidelines.</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2009/02/the-spectrial/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Now I&#8217;m pissed&#8230; someone is using my email adress in SPAM</title>
		<link>http://en.dahnielson.com/2008/11/now-im-pissed-someone-is-using-my-email-adress-in-spam/</link>
		<comments>http://en.dahnielson.com/2008/11/now-im-pissed-someone-is-using-my-email-adress-in-spam/#comments</comments>
		<pubDate>Fri, 07 Nov 2008 12:02:30 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/2008/11/now-im-pissed-someone-is-using-my-email-adress-in-spam.html</guid>
		<description><![CDATA[Some Russian fellows appears to be using my email address as the from address in SPAM messages about a business course. I&#8217;m getting &#8220;mail delivery failed&#8221; messages en masse.]]></description>
				<content:encoded><![CDATA[<p>Some Russian fellows appears to be using my email address as the from address in SPAM messages about a business course. I&#8217;m getting &#8220;mail delivery failed&#8221; messages <em>en masse</em>.</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2008/11/now-im-pissed-someone-is-using-my-email-adress-in-spam/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>My Playground</title>
		<link>http://en.dahnielson.com/2008/06/my-playground/</link>
		<comments>http://en.dahnielson.com/2008/06/my-playground/#comments</comments>
		<pubDate>Sun, 01 Jun 2008 18:34:52 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Music]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/2008/06/my-playground.html</guid>
		<description><![CDATA[Playground (not suitable for children under 30 year).]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/dahnielson/2535757369/"><img src="http://farm3.static.flickr.com/2215/2535757369_97c1c67121.jpg" alt="IMG_0247" /></a></p>
<p>Playground (not suitable for children under 30 year).</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2008/06/my-playground/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>The Cupertino Effect In Action</title>
		<link>http://en.dahnielson.com/2008/03/the-cupertino-effect-in-action/</link>
		<comments>http://en.dahnielson.com/2008/03/the-cupertino-effect-in-action/#comments</comments>
		<pubDate>Tue, 25 Mar 2008 23:59:53 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[From the hip]]></category>
		<category><![CDATA[Computer]]></category>
		<category><![CDATA[Language]]></category>
		<category><![CDATA[Writing]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/2008/03/the-cupertino-effect-in-action.html</guid>
		<description><![CDATA[Was recently affected by the Cupertino effect: &#8220;bounce of ranging monkeys&#8221; instead of &#8220;bunch of raging monkeys&#8221; and &#8220;historical impotence&#8221; in place of &#8220;historical importance&#8221;.]]></description>
				<content:encoded><![CDATA[<p>Was recently affected by the <a href="http://itre.cis.upenn.edu/~myl/languagelog/archives/002911.html">Cupertino effec</a>t: &#8220;bounce of ranging monkeys&#8221; instead of &#8220;bunch of raging monkeys&#8221; and &#8220;historical impotence&#8221; in place of &#8220;historical importance&#8221;.</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2008/03/the-cupertino-effect-in-action/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Anechoic Sampled Instruments and Reverberation</title>
		<link>http://en.dahnielson.com/2008/03/anechoic-sampled-instrument-and-reverberation/</link>
		<comments>http://en.dahnielson.com/2008/03/anechoic-sampled-instrument-and-reverberation/#comments</comments>
		<pubDate>Sun, 23 Mar 2008 17:59:39 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[Essays]]></category>
		<category><![CDATA[Acoustics]]></category>
		<category><![CDATA[Music]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/2008/03/anechoic-sampled-instrument-and-reverberation.html</guid>
		<description><![CDATA[I had a disturbing dream the other night that I was modeling a reverb of an anechoic room. Been occupied a little bit too much by acoustics, reverberation and instruments samples, have we? The Problem With Sampled Instruments and Reverberation One problem with adding reverberation to instruments samples is that said samples normally already contain [...]]]></description>
				<content:encoded><![CDATA[<p>I had a disturbing dream the other night that I was modeling a reverb of an anechoic room. Been occupied a little bit too much by acoustics, reverberation and instruments samples, have we?</p>
<p><span id="more-272"></span></p>
<h3 id="toc-the-problem-with-sampled-instruments-and-reverberation">The Problem With Sampled Instruments and Reverberation</h3>
<p>One problem with adding reverberation to instruments samples is that said samples normally already contain reverberation to some degree. Wet sampled instruments (at least historically including many orchestra libraries) contain a high degree of reverberation, even if many of them have been edited to contain an optional release tail. The same is true for instruments sampled dry, although they are sampled in rooms with very short reverberation times (a low RT60 value) so that the recording only will contain <em>first</em> and <em>early reflections</em> whose desirable levels are figured out during instrument and microphone placement. </p>
<p>But adding reverb to a sample already containing reverberation will cause <a href="http://www.realtraps.com/art_spaces.htm">comb filtering</a> to some degree depending on sound source and reverb characteristics. One solution would be to sample the instruments in an anechoic chamber (e.g. <a href="http://theremin.music.uiowa.edu/MIS.html">Musical Instrument Samples</a> from the Electronic Music Studios, University of Iowa) or at least in a hemi-anechoic or free-field chamber (see David A. Nelson, <a href="http://zone.ni.com/devzone/cda/tut/p/id/264"><em>Acoustic Test Chambers and Environments</em></a>, National Instruments, November 15, 2006). </p>
<h3 id="toc-the-problem-with-acoustic-instruments-and-radiation">The Problem With Acoustic Instruments and Radiation</h3>
<p>But anechoic recording has its own set of limitations. For instance microphone placement in relation to the radiation of sound by acoustic instruments (Scott Wilkinson, <a href="http://emusician.com/tutorials/resonance_and_radiation/">&#8220;Resonance and Radiation&#8221;</a>, Electronic Musician, September, 1994) need to be taken into account. In an anechoic chamber sound radiated as non-<em>direct sound</em> will not be reflected back and recorded by the microphone like in a studio or auditorium. This is especially troublesome with bowed strings having shifting radiation patterns depending on the tone being played.</p>
<p><img src="http://en.dahnielson.com/wp-content/uploads/2008/03/cello-radiation.png" /><br />
<em>Principal sound radiation patterns for the cello.</em></p>
<h3 id="toc-conclusion">Conclusion</h3>
<p>An omni-directional source, like a starter pistol or carbon arc, is regularly used as impulse during the recording of room impulse responses. After convolution with a sample the output will be analog to the sample being played back as an omi-directional sound source in the room. To be precise: the impulse response will contain all characteristics of the impulse source, room, microphone and signal chain. An instrument that naturally focus its sound forward (as principal radiation pattern), and being mic&#8217;ed accordingly when sampled, will then radiate the same principal sound level and frequencies in all directions in the reverberation model. This is however countered under normal circumstances by subjectively balance the dry signal, representing the direct sound, with the wet signal, produced by the reverb, in the mix. </p>
<p>With synthesized impulse responses it would be possible to take the orientation of the sound source and its radiation pattern into account (Perry R. Cook and Dan Trueman, <a href="http://www.cs.princeton.edu/~prc/ism98fin.pdf"><em>A Database of Measured Musical Instrument Body Radiation Impulse Responses, and Computer Applications for Exploring and Utilizing the Measured Filter Functions</em></a>, Princeton University, 1998) and filter the dry input to simulate the non-direct sound being radiated and reflected back to the microphone.</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2008/03/anechoic-sampled-instrument-and-reverberation/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Home Studio Acoustics: The Basics</title>
		<link>http://en.dahnielson.com/2008/03/home-studio-acoustics-the-basics/</link>
		<comments>http://en.dahnielson.com/2008/03/home-studio-acoustics-the-basics/#comments</comments>
		<pubDate>Tue, 18 Mar 2008 15:38:25 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Acoustics]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Music]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/2008/03/home-studio-acoustics-the-basics.html</guid>
		<description><![CDATA[There are two extremes to studio building: The situation were you are stuck with a room and have to do the best of the situation, and the situation were you have total control and can do the best you can afford. In here I try to examen the first and most common situation and how [...]]]></description>
				<content:encoded><![CDATA[<p>There are two extremes to studio building: The situation were you are stuck with a room and have to do the best of the situation, and the situation were you have total control and can do the best you can afford. In here I try to examen the first and most common situation and how you deal with it in three easy steps. While I&#8217;m going to approach a room that isn&#8217;t necessarily allocated as studio all the basics will still be the same when you slide across the scale to the other extreme.</p>
<p>Just let us clear up one thing right away: Acoustic treatment and sound isolation are two completely different concepts. When you design a studio from scratch you will take both into account from the start of the design process. But with that said it&#8217;s worth to know that an acoustically pleasing space will let you play back sound at lower volume with better definition and do not exaggerate lower frequencies and make the room sound less loud. So even without any special sound isolation just treating it acoustically will probably make your neighbors happy.</p>
<p>So let&#8217;s get cracking!</p>
<p><span id="more-271"></span></p>
<h3 id="toc-the-right-room-shape-and-size">The Right Room: Shape and Size</h3>
<p>This is the step where you find out how bad the room you&#8217;re stuck with are, or if you are lucky, help you choose a better room.</p>
<p>To start with the room need to have a rectangular shape. There are nothing wrong with angeled walls and ceilings, as long as they deflect the sound instead of focusing it, but their behavior is harder to calculate and predict. On the other hand the worst shape would be a perfect cube. Ideally the ratio between the height, width and length of the room should <em>not</em> be multiples of each other. So a rectangular room with <em>1.0:2.0:4.0</em> as ratio is likewise hopeless.</p>
<p>Unless you can build a new room from scratch, knowing about the perfect room ratios such as the preferred <em>1.00:1.14:1.39</em> ratio (in addition to <em>1.00:1.28:1.54</em> and <em>1.00:1.60:2.33</em>) developed by <a href="http://link.aip.org/link/?JASMAN/37/413/1">L.W. Sepmeyer in 1965</a> or the other preferred <em>1:1.4:1.9</em> ratio (in addition to <em>1:1.3:1.9</em>, <em>1:1.5:2.1</em> and 122 other ranked ratios) developed by  <a href="http://scholar.google.com/scholar?hl=en&#038;lr=&#038;client=&#038;q=author%3AMM+author%3ALouden+ratios&#038;as_ylo=&#038;as_yhi=&#038;btnG=Search">M.M. Louden in 1971</a> is a bit overkill. But if you are really into it the paper <a href="http://www.rpginc.com/news/library/roomsizer.pdf"><em>Determining Optimum Room Dimensions for Critical Listening Environments: A New Methodology</em></a> (Cox et al., 2001) will probably be of interest.</p>
<p>OK, back to our more or less ideal room. Despite what anyone might tell you: size <em>do</em> matter. A smaller room will be more difficult to treat and sound worse than a large. It&#8217;s hard to have a too big room, and if you do, that&#8217;s a pleasant problem. A good room should at least have a minimum volume of 72 m<sup>3</sup>.</p>
<p>So why do the room size and ratio matter? </p>
<p>The problem is called <em>standing waves</em>. When sound reflects off walls opposite each other a wave of equal distance is formed, basically a copy of the sound wave will come traveling from the other direction, these twin waves are called a standing wave. If you stand at the height point of an in phase standing wave the volume of the waves frequency will double. But if you stand at the same point in an out of phase standing wave the twin waves will cancel each other out and you won&#8217;t hear any of them at all.</p>
<p><img class="centered" src="http://en.dahnielson.com/wp-content/uploads/2008/03/standing_waves.png" alt="Standing waves." /></p>
<p>All rooms have standing waves, the question is how to deal with it? This is where room size and ratio enters the picture. The frequency of the standing waves depend on the distance between opposing walls, not to forget floor and ceiling, in a room. The formula for finding the fundamental frequency of a room dimension is quite simple:</p>
<p><em>f</em> = <em>V</em>/2<em>d</em></p>
<p>Where <em>f</em> is the fundamental frequency,  <em>V</em> the velocity of sound (344 m/s) and <em>d</em> the dimension. A 8 m long room will have a fundamental frequency of 22 Hz in that dimension, but the same phenomenon will also occur in all the octaves of the frequency affecting the harmonics of 44 Hz, 66Hz and 88 Hz and so on as well. The further apart your walls are the lower the fundamental frequency will be and the harmonics closer together making the average room response fairly flat. That&#8217;s why size matters!</p>
<p>So if your room was square that would mean you have the same fundamental frequency in the length dimension and the width dimension as well. The resulting standing waves would be in phase and out of phase with each other making the cancellation effect even noticeable. Since we have to factor in the harmonics just adjusting the room ratio to multiples of each other won&#8217;t help either, in a <em>1.0:2.0</em> room the first harmonic of longitudinal standing wave will have the same frequency as the lateral fundamental frequency.</p>
<p>In most cases the room you are stuck with will probably not fall into the worst case scenario category, so this is nothing to lay awake worrying about in the middle of the night. Most rooms will need acoustic treatment for the low-end anyway. But if you live in a tiny cube then you might want start planning a move.</p>
<h3 id="toc-the-right-place-listening-position-and-monitor-placement">The Right Place: Listening Position and Monitor Placement</h3>
<p>Hopefully, you will now have found out how well your chosen studio room are in terms of dimension. Now it&#8217;s time to place the two most important components in the room: your ears and a pair of near field monitors.</p>
<p>The first rule of placement in a studio is symmetry. As you probably already gathered from the discussion about ratios the shorter wall define the &#8220;width&#8221; of the studio and you will face one of the short end walls. Exactly which one is decided by the position of entries and doors into the room. Ideally you should have the entry door at the rear of the studio either on the back or side wall.</p>
<p>The placement of the monitors are inherently coupled to the listening position (&#8220;the sweet spot&#8221;). It means we first need to select the optimal listening position and then place the monitors relative to it. </p>
<p>So where is the optimal position?</p>
<p>Yet again the frequencies of the room, the room mode, play a big role because the <em>least</em> optimal position will be in a <em>null</em>. That is were waves of the rooms fundamental frequency or its harmonics crosses the null. <!-- Finding out where they are is easy, you don't even need to care what the actual frequencies are. The fundamental frequency null will be in the middle between two opposing walls, the first harmonic will have its nulls in the middle between the fundamental null and the walls, the second harmonic will have its additional nulls in the middle between the other nulls and so on. --></p>
<p><img class="centered" src="http://en.dahnielson.com/wp-content/uploads/2008/03/room_nulls_new.png" alt="Room nulls." /></p>
<p><em>Plotted above are the fundamental frequency of a room dimension (in red) and its first three harmonics. The longitudinal nulls are located where the waves cross the dotted line.</em></p>
<p>This makes it obvious that sitting spot on center is the least desirable position and once you factor in both the lateral as well as longitudinal nulls the picture becomes even more complicated. So there need to be compromises. One obvious compromise made in almost every studio is that you <em>will</em> be sitting straight in the middle between the side walls to avoid unbalanced stereo imaging. In the same spirit it&#8217;s easy to rely on Wes Lachot&#8217;s so called &#8220;38 percent rule&#8221; that states that the best listening position is 38% into the length of the room.</p>
<p>The logic behind the rule is simple: if you plot the first five or six harmonics you will notice that the position least affected by nulls will be 38% into the room. What you might already have figured out is that the actual distance between the 38% length of the room and the disastrous 50% spot will increase with the length of the room giving more leeway between nulls as the room size increases.  So yet again, size matters!</p>
<p><img class="centered" src="http://en.dahnielson.com/wp-content/uploads/2008/03/monitor_placement_top.png" alt="Monitor placement, top view." /></p>
<p>Now that we have found our listening position we can start to place the monitors. For stereo imaging the ideal monitor position will place the listener and monitors at points on an equilateral triangle. The listeners point should be behind the head, so that the ears are touching the sides, and the monitors should be placed somewhere along the sides between the listener and the front wall. Exact placement require some slight experimentation, just remember to avoid the obvious nulls. You can also make use of the <a href="http://www.barefootsound.com/homerecording_images/Wall_Bounce_Calculator_2D.xls">Wall Bounce Calculator</a> (Excel) to  figure how sound waves reflected by the front wall will affect the sound.</p>
<p>Make sure the monitors isn&#8217;t exactly midway between floor and ceiling in a null. If that&#8217;s the case it better to rise them slightly higher and tilt them down, as long as the distance between your ears and tweeter and woofer is being equal. </p>
<p>It should also be pointed out that monitors should <em>not</em> sit on the console or desk but behind it placed on heavy decoupled stands. This will save you from unwanted early reflection problems caused by the console or desktop and stop vibrations from one monitor affect the other. Securely mounted monitors will give you a better sound definition. Consider the tiny distances that the woofer cone and tweeter dome move in normal use, if the monitor vibrates, either by its own or outside disturbance, the movement will subtract from the bass output and may cancel the tweeter altogether. Place a small piece of Tack-It under each monitor corner to prevent them from moving.</p>
<h3 id="toc-the-right-treatment-rearrange-and-place-furniture">The Right Treatment: Rearrange and Place Furniture</h3>
<p>Unless you&#8217;re lucky enough to have an allocated room for your studio it&#8217;s likely that it already will contain a set of furniture unrelated to music production that need to be re-arranged and turned into ad-hoc acoustic treatments. But keep in mind that any control room with self respect should at least have a sofa at the back of the room that&#8217;s not only comfy but also doubles as an acoustic treatment.</p>
<p>First of all, try to arrange everything in the room symmetrically. E.g. if you have curtains on the right wall then hang some, or another material with the same absorption/reflection properties, on the opposing left wall.</p>
<p>Start at the back of the room. Do the room contain any bookcases? Then put them all against the back wall and possibly fill the space behind the books with cloth. They will work as an improvised bass trap because <em>bass absorption = mass</em> and the uneven front surface will do some minor diffusion in the higher frequencies. Next put a bed or sofa in front of them that will help absorb both high and low frequencies.</p>
<p>After having the back of the room sorted out it&#8217;s time to treat the front of the room to create a reflection free zone. The idea is to prevent so called <em>early reflections</em> from interfering with the stereo image. This happen when sound from the monitors arrives at your ears through two different paths: one directly and the other after being reflected by nearby surfaces such as desktop, floor, ceiling as well as side walls. All the early reflection points are somewhere between the listening position and the monitors, so any ad-hoc treatment doesn&#8217;t need to be very exact, just drape heavy cloth a decimeter or so distanced from the wall and put a carpet on the floor. This will not be a perfect solution but will serve its purpose until you can replace it with proper wall hung traps and clouds in the ceiling.</p>
<h3 id="toc-conclusion">Conclusion</h3>
<p>It&#8217;s easy to fool yourself by thinking that draping you room in cloth and putting up foam and egg cartoon on the walls will solve all your problems. Quite the opposite actually. Such treatments is really bad  and will only take care of the high frequencies efficiently and none of the lower ones making the room sound boomy. The room size and shape, placement of monitors and listening position are equally important as any other treatment. </p>
<p>As a final touch clap your hands at the listening position and listen to the reverberation and possible flutter echo or ringing to determine how well the treatments have worked and find additional problem spots.</p>
<p>In the next installment I will discuss some simple purpose built broadband traps that anyone can make and the theory behind their placement.</p>
<h3 id="toc-acknowledgment">Acknowledgment</h3>
<p>Thanks to <a href="http://www.ethanwiner.com/">Ethan Winer</a> and <a href="http://www.johnlsayers.com/">John Sayers</a> and everyone at the <a href="http://www.johnlsayers.com/phpBB2/index.php">Recording Studio Design Forum</a> and their selfless efforts to spread proper information about studio acoustics.</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2008/03/home-studio-acoustics-the-basics/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Forbidden to throw yourself in front of the train</title>
		<link>http://en.dahnielson.com/2008/03/forbidden-to-throw-yourself-in-front-of-the-train/</link>
		<comments>http://en.dahnielson.com/2008/03/forbidden-to-throw-yourself-in-front-of-the-train/#comments</comments>
		<pubDate>Thu, 06 Mar 2008 13:04:36 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[From the hip]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/2008/03/forbidden-to-throw-yourself-in-front-of-the-train.html</guid>
		<description><![CDATA[Here&#8217;s a type of sign I can&#8217;t remember seeing anywhere else like London, Paris, Milano, L.A. or the few cities with subways I&#8217;ve visited (realize that NYC and Berlin is missing and that I need to book a vacation). Is this symptomatically Swedish or am I just prejudiced? Sign found at the end of platforms [...]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.flickr.com/photos/dahnielson/2314563082/"><img src="http://farm4.static.flickr.com/3085/2314563082_52a3b9a98e.jpg" alt="Förbjudet att kasta sig framför tåget" /></a></p>
<p>Here&#8217;s a type of sign I can&#8217;t remember seeing anywhere else like London, Paris, Milano, L.A. or the few cities with subways I&#8217;ve visited (realize that NYC and Berlin is missing and that I need to book a vacation). Is this symptomatically Swedish or am I just prejudiced?</p>
<p>Sign found at the end of platforms in Stockholm&#8217;s subway system.</p>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2008/03/forbidden-to-throw-yourself-in-front-of-the-train/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Incontinental</title>
		<link>http://en.dahnielson.com/2008/02/incontinental/</link>
		<comments>http://en.dahnielson.com/2008/02/incontinental/#comments</comments>
		<pubDate>Sun, 10 Feb 2008 20:55:07 +0000</pubDate>
		<dc:creator>Anders Dahnielson</dc:creator>
				<category><![CDATA[From the hip]]></category>
		<category><![CDATA[Humour]]></category>

		<guid isPermaLink="false">http://en.dahnielson.com/2008/02/incontinental.html</guid>
		<description><![CDATA[Of course Germans have jokes. They&#8217;re just not funny.]]></description>
				<content:encoded><![CDATA[<blockquote><p>
Of course Germans have jokes. They&#8217;re just not funny.
</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://en.dahnielson.com/2008/02/incontinental/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
