<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>The Endeavour</title>
	
	<link>http://www.johndcook.com/blog</link>
	<description>The blog of John D. Cook</description>
	<pubDate>Wed, 15 Jul 2009 15:31:30 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/TheEndeavour" type="application/rss+xml" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com" /><item>
		<title>I owe Microsoft Word an apology</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/1k3eBAbqVKQ/</link>
		<comments>http://www.johndcook.com/blog/2009/07/15/microsoft-word-equation-editor/#comments</comments>
		<pubDate>Wed, 15 Jul 2009 15:29:52 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Math]]></category>

		<category><![CDATA[Typography]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2660</guid>
		<description><![CDATA[I tried to use the Equation Editor in Microsoft Word years ago and hated it. It was hard to use and produced ugly output. I tried it again recently and was pleasantly surprised. I&#8217;m using Word 2007. I don&#8217;t remember what version I&#8217;d tried before.
I&#8217;ve long said that  math written in Word is ugly, [...]]]></description>
			<content:encoded><![CDATA[<p>I tried to use the Equation Editor in Microsoft Word years ago and hated it. It was hard to use and produced ugly output. I tried it again recently and was pleasantly surprised. I&#8217;m using Word 2007. I don&#8217;t remember what version I&#8217;d tried before.</p>
<p>I&#8217;ve long said that  math written in Word is ugly, and it usually is. But the fault lies with users, like myself, not with Word. I realize now that the problem is that most people writing math in Word are not using the Equation Editor. LaTeX produces ugly math too when people do not use it correctly, though this happens less often.</p>
<p>Math typography is subtle. For example, mathematical symbols are set in an italic font that is not quite the same as the italic font used in prose. Also, word-like symbols such as &#8220;log&#8221; or &#8220;cos&#8221; are not set in italics. I imagine most people do not consciously notice these conventions — I never noticed until I learned to use LaTeX — but subconsciously notice when the conventions are violated. The conventions of math typography give clues that help readers distinguish, for example, the English indefinite article &#8220;a&#8221; from a variable named &#8220;a&#8221; and to distinguish the symbol for maximum from the product of variables &#8220;m&#8221;, &#8220;a&#8221;, and &#8220;x.&#8221;</p>
<p>Microsoft&#8217;s Equation Editor typesets math correctly. Word documents usually do not, but only because folks usually do not use the Equation Editor. In the following example, I set the same equation three times: using ordinary text, using ordinary italic for the &#8220;x&#8221;, and finally using the Equation Editor.</p>
<p style="text-align:center"><img src="http://www.johndcook.com/wordmath.png" alt="screen shot of trig identity using MS Word" width="297" height="174" /></p>
<p>Note that the &#8220;x&#8221; in the third version is not the same as the italic &#8220;x&#8221; in the second version. The prose in this example is set in Calibri font and the Equation Editor uses Cambria Math font. Also, I did not tell Word to format &#8220;sin&#8221; and &#8220;cos&#8221; one way and &#8220;x&#8221; another or tell it what font to use; I simply typed <code>sin^2 x + cos^2 x = 1</code> into the Equation Editor and it formatted the result as above. I haven&#8217;t used it much, but the Equation Editor seems to be more capable and easier to use than I thought.</p>
<p>Here are a few more examples of Equation Editor output.</p>
<p style="text-align:center"><img src="http://www.johndcook.com/wordmath2.png" alt="examples of math using Word: Gaussian integral, Fourier series, quadratic equation" width="389" height="248" /></p>
<p>I still prefer using LaTeX for documents containing math symbols. I&#8217;ve used LaTeX for many years and I can typeset equations very quickly using it. But I&#8217;m glad to know that Word can typeset equations well and that the process is easier than I thought.</p>
<p>I tried out the Equation Editor because <a href="http://www.twitter.com/afwings">Bob Matthews</a> suggested I try <a href="http://www.dessci.com/en/products/mathtype/default.htm">MathType</a>, a third-party equation editor add-on for Microsoft Word. I haven&#8217;t tried MathType yet but from what I hear it produces even better output.</p>
<p><strong>Related post</strong>: <a href="http://www.johndcook.com/blog/2008/04/03/microsoft-word-and-latex/">Contrasting Microsoft Word and LaTeX</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/1k3eBAbqVKQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/15/microsoft-word-equation-editor/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/15/microsoft-word-equation-editor/</feedburner:origLink></item>
		<item>
		<title>Ever feel like a newspaper?</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/GelcYM22TNw/</link>
		<comments>http://www.johndcook.com/blog/2009/07/13/ever-feel-like-a-newspaper/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 22:18:10 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Business]]></category>

		<category><![CDATA[Productivity]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2586</guid>
		<description><![CDATA[Why are newspapers going out of business? The simple explanation is that newspaper owners are stupid; the world around them is changing and they&#8217;re oblivious. Michael Nielsen has a more interesting explanation. He says that newspapers are in trouble not because they&#8217;re stupid now but because they&#8217;ve been smart in the past.
Nielsen argues that newspapers [...]]]></description>
			<content:encoded><![CDATA[<p>Why are newspapers going out of business? The simple explanation is that newspaper owners are stupid; the world around them is changing and they&#8217;re oblivious. <a href="http://michaelnielsen.org/blog/is-scientific-publishing-about-to-be-disrupted/">Michael Nielsen</a> has a more interesting explanation. He says that newspapers are in trouble not because they&#8217;re stupid now but because they&#8217;ve been smart in the past.</p>
<p>Nielsen argues that newspapers are locked into their current business models because they have been so successful. Any small changes will make their businesses less profitable. I don&#8217;t know enough about the newspaper industry to say whether Nielsen is right, though I find his argument plausible. (His article is entitled <a href="http://michaelnielsen.org/blog/is-scientific-publishing-about-to-be-disrupted/">Is scientific publishing about to be disrupted?</a> However, it is about much more than scientific publishing.)</p>
<p>Nielsen argues that newspapers are standing on the top of one hill and profitable online news sources are standing on a higher hill, a hill that didn&#8217;t exist 20 years ago. In mathematical lingo, both businesses are at local maxima. Newspapers are trapped because they can&#8217;t improve their situation without first making it worse. Anyone who leads a newspaper down its hill in order to climb a new hill will be fired before he starts gaining altitude again.</p>
<p>I don&#8217;t care that much about newspapers, but Nielsen&#8217;s article struck me because it provides an explanation for many other situations. I feel like some areas of my life are stuck at a local maximum: there&#8217;s plenty of room for improvement, but not by making small changes.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/GelcYM22TNw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/13/ever-feel-like-a-newspaper/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/13/ever-feel-like-a-newspaper/</feedburner:origLink></item>
		<item>
		<title>Random inequalities VIII: folded normals</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/i_SWvi26ekU/</link>
		<comments>http://www.johndcook.com/blog/2009/07/13/random-inequalities-folded-normal/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 21:48:37 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Math]]></category>

		<category><![CDATA[Probability and Statistics]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2651</guid>
		<description><![CDATA[Someone who ran into my previous posts on random inequalities asked me how to compute random inequalities for  folded normals. (A folded normal random variable is the absolute value of a normal random variable.) So the question is how to compute
Pr(&#124;X&#124; &#62; &#124;Y&#124;)
where X and Y are normally distributed. Here&#8217;s my reply as a [...]]]></description>
			<content:encoded><![CDATA[<p>Someone who ran into my previous posts on random inequalities asked me how to compute random inequalities for  folded normals. (A folded normal random variable is the absolute value of a normal random variable.) So the question is how to compute</p>
<p style="padding-left: 30px;">Pr(|X| &gt; |Y|)</p>
<p>where X and Y are normally distributed. Here&#8217;s my reply as a short tech report: <a href="http://www.bepress.com/mdandersonbiostat/paper52">Inequality probabilities for folded normal random variables</a>.</p>
<p><strong>Previous posts in this series</strong>:</p>
<p><a href="http://www.johndcook.com/blog/2008/07/26/random-inequalities-i/">Introduction</a><br />
<a href="http://www.johndcook.com/blog/2008/07/26/random-inequalities-ii-analytical-results/">Analytical results</a><br />
<a href="http://www.johndcook.com/blog/2008/07/26/random-inequalities-iii-numerical-results/">Numerical results</a><br />
<a href="http://www.johndcook.com/blog/2008/08/09/random-inequalities-iv-cauchy-distributions/">Cauchy distributions</a><br />
<a href="http://www.johndcook.com/blog/2008/08/21/random-inequalities-v-beta-distributions/">Beta distributions</a><br />
<a href="http://www.johndcook.com/blog/2008/08/30/random-inequalities-vi-gamma-distributions/">Gamma distributions</a><br />
<a href="http://www.johndcook.com/blog/2008/09/06/random-inequalities-vii-three-or-more-variables/">Three or more random variables</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/i_SWvi26ekU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/13/random-inequalities-folded-normal/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/13/random-inequalities-folded-normal/</feedburner:origLink></item>
		<item>
		<title>F# may succeed where others have failed</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/ynEUWNaVCOk/</link>
		<comments>http://www.johndcook.com/blog/2009/07/13/f-sharp/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 14:25:07 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Software development]]></category>

		<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2646</guid>
		<description><![CDATA[Philip Wadler wrote an article a decade ago entitled Why no one uses functional languages. He begins the article by explaining that yes, there have been a number of large successful projects developed in  functional programming languages. But compared to the number of programmers who work in procedural languages, the number working in functional [...]]]></description>
			<content:encoded><![CDATA[<p>Philip Wadler wrote an article a decade ago entitled <a href="http://portal.acm.org/citation.cfm?id=286387">Why no one uses functional languages</a>. He begins the article by explaining that yes, there have been a number of large successful projects developed in  functional programming languages. But compared to the number of programmers who work in procedural languages, the number working in functional languages is essentially zero. The reasons he listed fall into eight categories.</p>
<ol>
<li>Lack of compatibility with existing code</li>
<li>Limited library support compared to popular languages</li>
<li>Lack of portability across operating systems</li>
<li>Small communities and correspondingly little community support</li>
<li>Inability to package code well for reuse</li>
<li>Lack of sophisticated tool support</li>
<li>Lack of training for new developers in functional programming</li>
<li>Lack of popularity</li>
</ol>
<p>Most of these reasons do not apply to Microsoft&#8217;s new functional language F# since it is built on top of the .NET framework. For example, F# has access to the enormous Common Language Runtime library and smoothly interoperates with anything developed with .NET. And as far as tool support, Visual Studio will support F# starting with the 2010 release. Even portability is not a barrier:  <a href="http://mono-project.com/Main_Page">The Mono Project</a> has been quite successful in porting .NET code to non-Microsoft platforms. (Listen to this <a href="http://hanselminutes.com/default.aspx?showID=186">Hanselminutes interview with Aaron Bockover</a> for an idea how mature Mono is.)</p>
<p>The only issues that may apply to F# are training and popularity. Programmers receive far more training in procedural programming, and the popularity of procedural programming is self-reinforcing. Despite these disadvantages, interest in functional programming in general is growing. And when programmers want to learn a functional programming language, I believe many will choose F#.</p>
<p>It will be interesting to see whether F# catches on. It resolves many of the accidental difficulties of functional programming, but the intrinsic difficulties remain. Functional programming requires a different mindset, one that programmers have been reluctant to adopt. But now programmers have a new incentive to give functional languages a try: multi-core processors.</p>
<p>Individual processor cores are not getting faster, but we&#8217;re getting more of them per box. We have to write multi-threaded code to take advantage of extra cores, and multi-threaded programming in procedural languages is hard, beyond the ability of most programmers. Strict functional languages eliminate many of the difficulties with multi-threaded programming, and so it seems likely that at least portions of systems will be written in functional languages.</p>
<p><strong>Related post</strong>: <a href="http://www.johndcook.com/blog/2009/03/23/functional-in-the-small-oo-in-the-large/">Functional in the small, OO in the large</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/ynEUWNaVCOk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/13/f-sharp/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/13/f-sharp/</feedburner:origLink></item>
		<item>
		<title>Weekend miscellany</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/IKnCksFse1c/</link>
		<comments>http://www.johndcook.com/blog/2009/07/11/weekend-miscellany-2/#comments</comments>
		<pubDate>Sat, 11 Jul 2009 13:42:20 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Creativity]]></category>

		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2605</guid>
		<description><![CDATA[Here are a few eclectic links for the weekend.
How globes are made. You might enjoy watching this with your children.
Jason Fried presentation on the 37 Signals approach to small business. My favorite line: &#8220;Tomorrow doesn&#8217;t happen unless you get today right.&#8221; You do not want to watch this one with your children.
A lot of people [...]]]></description>
			<content:encoded><![CDATA[<p>Here are a few eclectic links for the weekend.</p>
<p><a href="http://sortingoutscience.net/2009/07/10/casual_friday_--_how_globes_are_made/">How globes are made</a>. You might enjoy watching this with your children.</p>
<p><a href="http://www.37signals.com/svn/posts/1798-jasons-talk-at-big-omaha-2009">Jason Fried presentation</a> on the 37 Signals approach to small business. My favorite line: &#8220;Tomorrow doesn&#8217;t happen unless you get today right.&#8221; You do <em>not</em> want to watch this one with your children.</p>
<p>A lot of people <a href="http://www.youtube.com/watch?v=o4MwTvtyrUQ&amp;feature=player_embedded">don&#8217;t know what a web browser is</a>.</p>
<p><object width="360" height="245" data="http://www.youtube.com/v/o4MwTvtyrUQ&amp;hl=en&amp;fs=1&amp;rel=0" type="application/x-shockwave-flash"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://www.youtube.com/v/o4MwTvtyrUQ&amp;hl=en&amp;fs=1&amp;rel=0" /><param name="allowfullscreen" value="true" /></object></p>
<p>Scientific American podcast <a href="http://www.scientificamerican.com/podcast/episode.cfm?id=atul-gawande-redux-09-07-01">interview</a> with Atul Gawande, author of <a href="http://www.amazon.com/gp/product/B001C304DC?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=B001C304DC">Complications</a> and <a href="http://www.amazon.com/gp/product/B000QCSAB8?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=B000QCSAB8">Better</a>. Among other things, Gawande explains how process improvements, not new science, have caused a dramatic decrease in battlefield fatalities.</p>
<p><a href="http://www.noop.nl/2009/07/your-project-will-suffer-from-power-laws.html">Software projects and power laws</a>. The probability distributions for delays have thick tails.</p>
<p>A quick comparison of <a href="http://legallad.quickanddirtytips.com/Canada.aspx">US and Canadian law</a>.</p>
<p>Two math blog carnivals came out this week: <a href="http://topologicalmusings.wordpress.com/2009/07/05/the-54th-carnival-of-mathematics/">Carnival of Mathematics</a> and<br />
<a href="http://mathmamawrites.blogspot.com/2009/07/math-teachers-at-play-11.html">Math Teachers at Play</a>. Anyone know when or where the next Carnival of Mathematics will be?</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/IKnCksFse1c" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/11/weekend-miscellany-2/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/11/weekend-miscellany-2/</feedburner:origLink></item>
		<item>
		<title>Emily Dickinson versus Paris Hilton</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/8BrV0nKgPWs/</link>
		<comments>http://www.johndcook.com/blog/2009/07/09/emily-dickinson-versus-paris-hilton/#comments</comments>
		<pubDate>Thu, 09 Jul 2009 13:37:05 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2601</guid>
		<description><![CDATA[Mark Helprin discusses the decline of serious political discourse in America in his excellent book Digital Barbarism. Earlier generations were more patient, &#8220;primed to deliberate rather than merely to react.&#8221; He summarizes his argument by comparing Emily Dickinson and Paris Hilton.
That is not to say that all Americans were models of dignity and concentration, but [...]]]></description>
			<content:encoded><![CDATA[<p>Mark Helprin discusses the decline of serious political discourse in America in his excellent book <a href="http://www.amazon.com/gp/product/B0026SCN9K?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=B0026SCN9K">Digital Barbarism</a>. Earlier generations were more patient, &#8220;primed to deliberate rather than merely to react.&#8221; He summarizes his argument by comparing Emily Dickinson and Paris Hilton.</p>
<blockquote><p>That is not to say that all Americans were models of dignity and concentration, but by and large they were quite different from what we are now. &#8230; Rather than a massive comparison, suffice it to say that although today not everyone is like Paris Hilton, and in the nineteenth century not everyone was like Emily Dickinson, each of these is far more characteristic of her age than would be the other, and that this is self-evident along with all it implies.</p></blockquote>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/8BrV0nKgPWs" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/09/emily-dickinson-versus-paris-hilton/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/09/emily-dickinson-versus-paris-hilton/</feedburner:origLink></item>
		<item>
		<title>My mathematical opposite</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/JsBDcyFiuyA/</link>
		<comments>http://www.johndcook.com/blog/2009/07/08/my-mathematical-opposite/#comments</comments>
		<pubDate>Wed, 08 Jul 2009 15:53:37 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Math]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2622</guid>
		<description><![CDATA[Eugenia Cheng may be my mathematical opposite. She did a great interview with Peter Rowlett in which she bubbles over with enthusiasm for category theory. She explains that she couldn&#8217;t stand applied math, but stuck with math because she believed there was something there she could love. The further she moved from applicable math, the [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://cheng.staff.shef.ac.uk/">Eugenia Cheng</a> may be my mathematical opposite. She did a great <a href="http://travelsinamathematicalworld.blogspot.com/2009/06/podcast-episode-34-eugenia-cheng.html">interview</a> with Peter Rowlett in which she bubbles over with enthusiasm for category theory. She explains that she couldn&#8217;t stand applied math, but stuck with math because she believed there was something there she could love. The further she moved from applicable math, the happier she became. Abstract algebra was a big improvement, but still too concrete. When she discovered category theory, she was home.</p>
<p>Category theory is a sort of meta-mathematics. It aims to identify patterns across diverse areas of math the way a particular area of math may identify patterns in nature. I like the idea of category theory, but I get that deer-in-the-headlights look in my eyes almost immediately when I look at category theory in any detail.</p>
<p>I enjoy pure math, though I prefer analysis to algebra. I even enjoyed my first abstract algebra class, but when I ran into category theory I knew I&#8217;d exceeded my abstraction tolerance. I moved more toward the applied end of the spectrum the longer I was in college. Afterward, I moved so far toward the applied end that you might say I fell off the end and moved into things that are so applied that they&#8217;re not strictly mathematics: mathematical modeling, software development, statistics, etc. I call myself a <a href="http://www.johndcook.com/veryappliedmath.html">very applied mathematician</a> because I actually apply math and don&#8217;t just study areas of math that could potentially be applied.</p>
<p>I appreciate Eugenia Cheng&#8217;s enthusiasm even though I don&#8217;t share her taste in math. I have long intended to go back and learn a little category theory. It would be great mental exercise precisely because it is so foreign to my way of thinking. Cheng&#8217;s interview inspired me to give it one more try.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/JsBDcyFiuyA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/08/my-mathematical-opposite/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/08/my-mathematical-opposite/</feedburner:origLink></item>
		<item>
		<title>How Michelangelo worked</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/JumPkfAw9Ss/</link>
		<comments>http://www.johndcook.com/blog/2009/07/07/how-michelangelo-worked/#comments</comments>
		<pubDate>Wed, 08 Jul 2009 01:25:18 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Creativity]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2616</guid>
		<description><![CDATA[
The following quote from Irving Stone describes how Michelangelo worked on his Pietà.
He carved in a fury from first light to dark, then threw himself across his bed, without supper and fully clothed, like a dead man. He awoke around midnight, refreshed, his mind seething with sculptural ideas, craving to get at the marble.
]]></description>
			<content:encoded><![CDATA[<p style="text-align:center"><img src="http://www.johndcook.com/pieta.jpg" alt="Michelangelo's Pieta&lt;/ins&gt;" width="288" height="289" /></p>
<p>The following quote from Irving Stone describes how Michelangelo worked on his <a href="http://en.wikipedia.org/wiki/Pieta">Pietà</a>.</p>
<blockquote><p>He carved in a fury from first light to dark, then threw himself across his bed, without supper and fully clothed, like a dead man. He awoke around midnight, refreshed, his mind seething with sculptural ideas, craving to get at the marble.</p></blockquote>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/JumPkfAw9Ss" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/07/how-michelangelo-worked/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/07/how-michelangelo-worked/</feedburner:origLink></item>
		<item>
		<title>ACID versus BASE for database transactions</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/jJWw5Dtmvlo/</link>
		<comments>http://www.johndcook.com/blog/2009/07/06/brewer-cap-theorem-base/#comments</comments>
		<pubDate>Mon, 06 Jul 2009 14:57:02 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Software development]]></category>

		<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2607</guid>
		<description><![CDATA[Database developers all know the ACID acronym. It says that database transactions should be:

Atomic: Everything in a transaction succeeds or the entire transaction is rolled back.
Consistent: A transaction cannot leave the database in an inconsistent state.
Isolated: Transactions cannot interfere with each other.
Durable: Completed transactions persist, even when servers restart etc.

These qualities seem indispensable, and yet [...]]]></description>
			<content:encoded><![CDATA[<p>Database developers all know the ACID acronym. It says that database transactions should be:</p>
<ul>
<li><strong>A</strong>tomic: Everything in a transaction succeeds or the entire transaction is rolled back.</li>
<li><strong>C</strong>onsistent: A transaction cannot leave the database in an inconsistent state.</li>
<li><strong>I</strong>solated: Transactions cannot interfere with each other.</li>
<li><strong>D</strong>urable: Completed transactions persist, even when servers restart etc.</li>
</ul>
<p>These qualities seem indispensable, and yet they are incompatible with availability and performance in very large systems. For example, suppose you run an online book store and you proudly display how many of each book you have in your inventory. Every time someone is in the process of buying a book, you lock part of the database until they finish so that all visitors around the world will see accurate inventory numbers. That works well if you run <a href="http://www.imdb.com/title/tt0128853/">The Shop Around the Corner</a> but not if you run Amazon.com.</p>
<p>Amazon might instead use cached data. Users would not see not the inventory count at this second, but what it was say an hour ago when the last snapshot was taken. Also, Amazon might violate the &#8220;I&#8221; in ACID by tolerating a small probability that simultaneous transactions could interfere with each other. For example, two customers might both believe that they just purchased the last copy of a certain book. The company might risk having to apologize to one of the two customers (and maybe compensate them with a gift card) rather than slowing down their site and irritating myriad other customers.</p>
<p>There is a computer science theorem that quantifies the inevitable trade-offs. <a href="http://www.julianbrowne.com/article/viewer/brewers-cap-theorem">Eric Brewer&#8217;s CAP theorem</a> says that if you want consistency, availability, and partition tolerance, you have to settle for two out of three. (For a distributed system, <em>partition tolerance</em> means the system will continue to work unless there is a total network failure. A few nodes can fail and the system keeps going.)</p>
<p>An alternative to ACID is BASE:</p>
<ul>
<li><strong>B</strong>asic <strong>A</strong>vailability</li>
<li><strong>S</strong>oft-state</li>
<li><strong>E</strong>ventual consistency</li>
</ul>
<p>Rather than requiring consistency after every transaction, it is enough for the database to eventually be in a consistent state. (Accounting systems do this all the time. It&#8217;s called &#8220;closing out the books.&#8221;) It&#8217;s OK to use stale data, and it&#8217;s OK to give approximate answers.</p>
<p>It&#8217;s harder to develop software in the fault-tolerant BASE world compared to the fastidious ACID world, but Brewer&#8217;s CAP theorem says you have no choice if you want to scale up. However, as Brewer points out in this <a href="http://www.cs.berkeley.edu/~brewer/cs262b-2004/PODC-keynote.pdf">presentation</a>, there is a continuum between ACID and BASE. You can decide how close you want to be to one end of the continuum or the other according to your priorities.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/jJWw5Dtmvlo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/06/brewer-cap-theorem-base/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/06/brewer-cap-theorem-base/</feedburner:origLink></item>
		<item>
		<title>Weekend miscellany</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/6Hyl98G3VbY/</link>
		<comments>http://www.johndcook.com/blog/2009/07/04/weekend-miscellany/#comments</comments>
		<pubDate>Sat, 04 Jul 2009 12:17:52 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2579</guid>
		<description><![CDATA[Software
Here&#8217;s an old NBC news report speculating about technology in the year 2000. Apparently &#8220;something called the Internet&#8221; will be important. HT: Sorting out Science.

The Mono project, an open source rewrite of Microsoft&#8217;s .NET framework, is more mature than I thought. From Hanselminutes.
&#8220;Cloud&#8221; is a good metaphor for most of what I hear about &#8220;cloud [...]]]></description>
			<content:encoded><![CDATA[<h3>Software</h3>
<p>Here&#8217;s an old NBC news report speculating about technology in the year 2000. Apparently &#8220;something called the Internet&#8221; will be important. HT: <a href="http://sortingoutscience.net/2009/07/03/casual_friday_--_something_called_the_internet/">Sorting out Science</a>.</p>
<p><object width="450" height="296" data="http://www.hulu.com/embed/BV_Mi__S3HrepdyafmX1uA" type="application/x-shockwave-flash"><param name="allowFullScreen" value="true" /><param name="src" value="http://www.hulu.com/embed/BV_Mi__S3HrepdyafmX1uA" /><param name="allowfullscreen" value="true" /></object></p>
<p>The Mono project, an open source rewrite of Microsoft&#8217;s .NET framework, is more mature than I thought. From <a href="http://hanselminutes.com/default.aspx?showID=186">Hanselminutes</a>.</p>
<p>&#8220;Cloud&#8221; is a good metaphor for most of what I hear about &#8220;cloud computing&#8221; because it&#8217;s so nebulous. But <a href="http://www.dotnetrocks.com/default.aspx?showNum=459">Michael Stiefel</a> has some solid things to say on the subject.</p>
<p><a href="http://norvig.com/python-iaq.html">Python Infrequently Answered Questions</a></p>
<p>Quote from <a href="http://wordaligned.org/articles/europython-2009">Word Aligned blog</a> &#8220;One day software will be the most reliable component of every product which contains it.&#8221; &#8212; Tony Hoare. I&#8217;m not as optimistic as Mr. Hoare, or I at least thing &#8220;one day&#8221; is far away.</p>
<p>Joakim Karlsson says in his post <a href="http://jkarlsson.com/blog/2009/06/24/the-locality-of-code-changes/">The Locality of Code Changes</a> &#8220;The probability that you will change a piece of code in the near future increases when you make changes to that code or to code in its vicinity.&#8221;</p>
<h3>Economics</h3>
<p>The best explanation I&#8217;ve seen for <a href="http://michaelnielsen.org/blog/is-scientific-publishing-about-to-be-disrupted/">why newspapers are dying</a></p>
<p><a href="http://www.newyorker.com/arts/critics/books/2009/07/06/090706crbo_books_gladwell">Malcolm Gladwell&#8217;s rebuttal</a> to Chris Anderson&#8217;s &#8220;Free&#8221; thesis</p>
<p><a href="http://www.econtalk.org/archives/2009/06/helprin_on_copy.html">EconTalk interview</a> with Mark Helprin on copyright</p>
<h3>Math and statistics</h3>
<p>In <a href="http://rjlipton.wordpress.com/2009/07/03/is-pnp-an-ill-posed-problem/">Is P = NP an ill-posed problem?</a> Dick Lipton contrasts the Riemann hypothesis and the question of whether P = NP.</p>
<p><a href="http://www.stat.columbia.edu/~cook/movabletype/archives/2009/06/visualizing_tab.html">Visualizing correlations</a></p>
<h3>Music, coffee, and physics</h3>
<p><a href="http://listverse.com/2009/06/30/10-best-uses-of-classical-music-in-classic-cartoons/">Classical music in cartoons</a></p>
<p><a href="http://www.webdesignerdepot.com/2009/07/50-beautifully-delicious-coffee-designs/">Latte art</a></p>
<p>Fun with an MRI machine. NB: The block is aluminum, not iron. Magnets don&#8217;t attract aluminum. But aluminum can conduct a current induced by a magnetic field. HT: <a href="http://ovablastic.blogspot.com/2009/01/mri-magic.html">Ovablastic</a>.</p>
<p><object width="425" height="344" data="http://www.youtube.com/v/fxC-AEC0ROk&amp;color1=0xb1b1b1&amp;color2=0xcfcfcf&amp;hl=pt-br&amp;feature=player_embedded&amp;fs=1" type="application/x-shockwave-flash"><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://www.youtube.com/v/fxC-AEC0ROk&amp;color1=0xb1b1b1&amp;color2=0xcfcfcf&amp;hl=pt-br&amp;feature=player_embedded&amp;fs=1" /><param name="allowfullscreen" value="true" /></object></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/6Hyl98G3VbY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/04/weekend-miscellany/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/04/weekend-miscellany/</feedburner:origLink></item>
		<item>
		<title>Robust, scalable, and the keyboard works</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/1a1Nah2Q02E/</link>
		<comments>http://www.johndcook.com/blog/2009/07/03/open-solaris/#comments</comments>
		<pubDate>Fri, 03 Jul 2009 11:48:22 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Computing]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2577</guid>
		<description><![CDATA[Glynn Foster from Sun talks about OpenSolaris on FLOSS Weekly episode 75. After explaining how Solaris has always been a robust, scalable operating system, Foster brags that now on a Toshiba laptop with OpenSolaris pre-installed &#8221; &#8230; the volume works, and the keys work&#8230;&#8221; Then host Jono Bacon laughs &#8220;The keys work?!&#8221; The dialog starts [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://blogs.gnome.org/gman">Glynn Foster</a> from Sun talks about <a href="http://www.opensolaris.org/">OpenSolaris</a> on <a href="http://twit.tv/floss75">FLOSS Weekly episode 75</a>. After explaining how Solaris has always been a robust, scalable operating system, Foster brags that now on a Toshiba laptop with OpenSolaris pre-installed &#8221; &#8230; the volume works, and the keys work&#8230;&#8221; Then host <a href="http://www.jonobacon.org/">Jono Bacon</a> laughs &#8220;The keys work?!&#8221; The dialog starts at about 23:30 into the podcast.</p>
<p>The other host, Leo Laporte, mumbled &#8220;so cool&#8221; after Glynn Foster says &#8220;the volume works&#8221; and apparently would have let him get away with saying &#8220;the keys work.&#8221; But Jono Bacon is the community manager for <a href="http://www.ubuntu.com/">Ubuntu</a>, a Linux distribution that cares more about whether the volume and keyboard work than whether the OS scales.</p>
<p>It was amusing to listen to Glynn Foster and Jono Bacon personify their respective operating system&#8217;s priorities, server performance for Solaris and desktop experience for Ubuntu. Foster says that OpenSolaris used to be a royal pain to install and configure but now it has gotten much better. I don&#8217;t know how well Ubuntu scales — I imagine it&#8217;s not nearly as scalable as OpenSolaris — but it was designed from the beginning to be easy to install.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/1a1Nah2Q02E" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/03/open-solaris/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/03/open-solaris/</feedburner:origLink></item>
		<item>
		<title>Three rules of thumb</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/JnkEIMh_8ng/</link>
		<comments>http://www.johndcook.com/blog/2009/07/01/three-rules-of-thumb/#comments</comments>
		<pubDate>Wed, 01 Jul 2009 12:04:03 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Computing]]></category>

		<category><![CDATA[Math]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2550</guid>
		<description><![CDATA[Here are three rules of thumb for back-of-the-envelope estimates:

Duff&#8217;s rule: Pi seconds is a nanocentury.
Hopper&#8217;s rule: Light travels one foot in a nanosecond.
Rule of 72: An investment at n% interest will double in 72/n years.

How might you use these? How accurate are they?
Duff&#8217;s rule comes in handy when converting from times measured in seconds to [...]]]></description>
			<content:encoded><![CDATA[<p>Here are three rules of thumb for back-of-the-envelope estimates:</p>
<ol>
<li>Duff&#8217;s rule: Pi seconds is a nanocentury.</li>
<li>Hopper&#8217;s rule: Light travels one foot in a nanosecond.</li>
<li>Rule of 72: An investment at n% interest will double in 72/n years.</li>
</ol>
<p>How might you use these? How accurate are they?</p>
<p><strong>Duff&#8217;s rule</strong> comes in handy when converting from times measured in seconds to times measured on calendars. This may not sound useful, but it often happens in software. For example, if a task takes a second to complete, how long would it take to do it a billion times? Well, a billion seconds, obviously. But how long is that in familiar terms? Duff&#8217;s rule says a century is about 3.14 billion seconds, so a billion seconds would be something like 30 years.</p>
<p>How accurate is Duff&#8217;s rule? A year is 31,536,000 seconds, whereas Duff&#8217;s rule would estimate 31,415,927 seconds, so it underestimates the number of seconds in a year by about 0.4%.</p>
<p><strong>Hopper&#8217;s rule</strong> is useful in electrical engineering. For example, you might need to know how long it would take a radio signal to travel between a transmitter and receiver. Hopper&#8217;s rule can explain why computer chip clock rates are not increasing. Electrical signals travel at some fraction of the speed of light, and current chip designs are limited by whether a signal can move across the chip during a clock cycle.</p>
<p>How accurate is Hopper&#8217;s rule? Light travels 299,792,458 meters per second. That corresponds to 0.983 feet per nanosecond, so Hopper&#8217;s rule overestimates by about 1.7%.</p>
<p>Here is a terrific video of Grace Hopper explaining Hopper&#8217;s rule to David Letterman, around 4:25. (Thanks Bill!) </p>
<p><object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/57bfxsiVTd4&#038;hl=en&#038;fs=1&#038;rel=0"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/57bfxsiVTd4&#038;hl=en&#038;fs=1&#038;rel=0" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed></object></p>
<p>The <strong>Rule of 72</strong> is obviously useful in financial estimates. For example, $1000 invested at 6% interest will become $2000 in 72/6 = 12 years.</p>
<p>How accurate is the rule of 72? The value of an initial investment <em>P</em> at time <em>t</em> with under a continuous interest rate <em>r</em> is <em>P</em> exp(<em>rt</em>). Solving exp(<em>rt</em>) = 2 for <em>t</em> gives <em>t</em> = log 2 / <em>r</em>. If we express <em>r</em> as a percentage, we have to multiply <em>t</em> by 100. This says that for continuously compounded interest, the rule of 72 would be exact if &#8220;72&#8243; were replaced with 100 log 2 = 69.3. So for continuous interest, the rule overestimates the doubling time by 0.72/log 2 or about 4%. So why use 72 rather than 69.3? There are two reasons. First, 72 is easy to work with mentally since it is divisible by lots of small integers. Second, interest is often compounded periodically — say annually or monthly — rather than continuously.</p>
<p>The doubling time is longer for investments with periodic interest rather than continuous interest. The overestimate from using 72 rather than 69.3 is partially canceled out by the accounting for the longer doubling time for periodic compounding and so 72 may work better than 69.3. Exactly how accurate the rule of 72 is for periodically compounded interest depends on the interest rate and the compounding period.</p>
<p><strong>Related post</strong>:</p>
<p><a href="http://www.johndcook.com/blog/2009/06/29/bancrofts-rule/">Bancroft&#8217;s rule</a> (rule of thumb for estimating linear regression)</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/JnkEIMh_8ng" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/07/01/three-rules-of-thumb/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/07/01/three-rules-of-thumb/</feedburner:origLink></item>
		<item>
		<title>Privacy</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/4YiOPN4yLd0/</link>
		<comments>http://www.johndcook.com/blog/2009/06/30/privacy/#comments</comments>
		<pubDate>Wed, 01 Jul 2009 02:10:32 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2563</guid>
		<description><![CDATA[From Digital Barbarism by Mark Helprin:
I do not want my life history in the hands of either J. Edgar Hoover or Walt Disney, thank you very much.
]]></description>
			<content:encoded><![CDATA[<p>From <a href="http://www.amazon.com/gp/product/0061733113?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=0061733113">Digital Barbarism</a> by Mark Helprin:</p>
<blockquote><p>I do not want my life history in the hands of either J. Edgar Hoover or Walt Disney, thank you very much.</p></blockquote>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/4YiOPN4yLd0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/30/privacy/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/30/privacy/</feedburner:origLink></item>
		<item>
		<title>Incredibly simple approximation</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/TlLeHUWFFPc/</link>
		<comments>http://www.johndcook.com/blog/2009/06/29/bancrofts-rule/#comments</comments>
		<pubDate>Mon, 29 Jun 2009 20:37:41 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Statistics]]></category>

		<category><![CDATA[Probability and Statistics]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2556</guid>
		<description><![CDATA[Suppose you need to find the slope of a line through a set of data. You can get a surprisingly good approximation by simply fitting a line to the first and last points. This is known as &#8220;Bancroft&#8217;s rule.&#8221; It seems too good to be true. Of course just fitting a line to just two [...]]]></description>
			<content:encoded><![CDATA[<p>Suppose you need to find the slope of a line through a set of data. You can get a surprisingly good approximation by <strong>simply fitting a line to the first and last points</strong>. This is known as &#8220;Bancroft&#8217;s rule.&#8221; It seems too good to be true. Of course just fitting a line to just two points is not as good as using all the data, but unless you have a fairly large amount of data, it&#8217;s not too much worse either. It&#8217;s good enough for a quick estimate.</p>
<p>Just how good is this estimate compared to using all the data? We&#8217;ll look at the technical details of an example below.</p>
<p>Suppose you have a regression model <em>y</em> = α + β<em>x</em> + ε where ε is random noise. Suppose ε is normally distributed with mean 0 and variance σ<sup>2</sup>. Let b be the least squares estimator of β. The variance in b is</p>
<p style="text-align:center"><img src="http://www.johndcook.com/bvariance.gif" alt="\frac{\sigma^2}{\sum_{i=1}^n (x_i - \bar{x})^2}" width="106" height="42" /></p>
<p>Now suppose we have observations <em>y</em><sub>i</sub> corresponding to <em>x</em><sub>i</sub> = 0, 1, 2, &#8230;, 2<em>n</em>. The average value of <em>x</em> is <em>n</em>, and the denominator in the expression for the variance of the slope estimator is 2(1<sup>2</sup> + 2<sup>2</sup> + 3<sup>2</sup> + &#8230; + <em>n</em><sup>2</sup>) = (2<em>n</em><sup>3</sup> + 3<em>n</em><sup>2</sup> + <em>n</em>)/3. If we just use the data at <em>x</em> = 0 and <em>x</em> = 2<em>n</em>, the denominator is (0 - <em>n</em>)<sup>2</sup> + (2<em>n</em> - <em>n</em>)<sup>2</sup> = 2<em>n</em><sup>2</sup>.</p>
<p>If we divide the estimator variance based on Bancroft&#8217;s rule by the estimator variance using all the data, the σ<sup>2</sup> terms cancel and we are left with <em>n</em>/3 + 1/2 + 1/6<em>n</em>. So Bancroft&#8217;s rule increases the variance in the estimate for the slope by roughly <em>n</em>/3 compared to using all the data. Thus it increases the confidence interval by roughly the square root of <em>n</em>/3. So if you had 12 data points, the confidence interval would be about twice as wide. Said another way, the estimate based on all the data is only twice as good as the estimate based on just the first and last points.</p>
<p><strong>Related posts:</strong></p>
<p><a href="http://www.johndcook.com/blog/2009/06/25/probability-approximation/">Probability mistake can give a good approximation</a><br />
<a href="http://www.johndcook.com/blog/2009/02/10/rolling-dice-for-normal-samples/">Rolling dice for normal samples</a><br />
<a href="http://www.johndcook.com/blog/2008/07/10/approximate-problems-and-approximate-solutions/">Approximate problems and approximate solutions</a><br />
<a href="http://www.johndcook.com/blog/2008/10/20/comparing-two-ways-to-fit-a-line-to-data/">Comparing two ways to fit a line to data</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/TlLeHUWFFPc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/29/bancrofts-rule/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/29/bancrofts-rule/</feedburner:origLink></item>
		<item>
		<title>Eclectic links</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/c5UgDP_moLw/</link>
		<comments>http://www.johndcook.com/blog/2009/06/26/eclectic-links/#comments</comments>
		<pubDate>Fri, 26 Jun 2009 12:48:20 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2554</guid>
		<description><![CDATA[Food
Espresso cheat sheet
Too much salt, sugar, and fat
Software development
Hanselminutes interview with Michael Feathers
How SQLite is tested (including 45 million lines of test code)
Math/Stat
Math Teachers at Play blog carnival #10
Defining values of statisticians
Travels in a Mathematical World podcast on category theory
Misc
Email reminder service 3mindme.com
ASCAP and ringtones
Sites to make RSS feeds from pages: feed43.com, page2rss.com
]]></description>
			<content:encoded><![CDATA[<h3>Food</h3>
<p><a href="http://www.makemymood.com/wp-content/uploads/2009/06/cafedes.jpg">Espresso cheat sheet</a><br />
Too much <a href="http://itc.conversationsnetwork.org/shows/detail4105.html">salt, sugar, and fat</a></p>
<h3>Software development</h3>
<p><a href="http://www.hanselminutes.com/default.aspx?showID=183">Hanselminutes interview</a> with <a href="http://www.amazon.com/gp/product/B0017DQ8KU?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=B0017DQ8KU">Michael Feathers</a><br />
<a href="http://www.sqlite.org/testing.html">How SQLite is tested</a> (including 45 million lines of test code)</p>
<h3>Math/Stat</h3>
<p><a href="http://homeschoolmath.blogspot.com/2009/06/math-teachers-at-play-10.html">Math Teachers at Play</a> blog carnival #10<br />
<a href="http://www.stat.columbia.edu/~cook/movabletype/archives/2009/06/the_defining_va.html">Defining values of statisticians</a><br />
<a href="http://www.travelsinamathematicalworld.co.uk/">Travels in a Mathematical World</a> podcast on <a href="http://travelsinamathematicalworld.blogspot.com/2009/06/podcast-episode-34-eugenia-cheng.html"></a><a href="http://travelsinamathematicalworld.blogspot.com/2009/06/podcast-episode-34-eugenia-cheng.html">category theory</a><a href="http://cheng.staff.shef.ac.uk/"></a></p>
<h3>Misc<a href="http://itc.conversationsnetwork.org/shows/detail4105.html"></a></h3>
<p>Email reminder service <a href="http://3mindme.com/">3mindme.com</a><br />
<a href="http://www.eff.org/deeplinks/2009/06/ascap-wants-be-paid-">ASCAP and ringtones</a><br />
Sites to make RSS feeds from pages: <a href="http://www.feed43.com/">feed43.com</a>, <a href="http://page2rss.com/">page2rss.com</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/c5UgDP_moLw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/26/eclectic-links/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/26/eclectic-links/</feedburner:origLink></item>
		<item>
		<title>Probability mistake can give a good approximation</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/pFFaI1or1c8/</link>
		<comments>http://www.johndcook.com/blog/2009/06/25/probability-approximation/#comments</comments>
		<pubDate>Thu, 25 Jun 2009 20:12:59 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Math]]></category>

		<category><![CDATA[Probability and Statistics]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2545</guid>
		<description><![CDATA[If you run into someone on the street, the probability that the other person shares your birthday is 1/365. If you run into five people, the probability that at least one of them shares your birthday is 5/365, right?
The answer 5/365 is quite accurate, but not exactly correct. It&#8217;s good enough for this problem since [...]]]></description>
			<content:encoded><![CDATA[<p>If you run into someone on the street, the probability that the other person shares your birthday is 1/365. If you run into five people, the probability that at least one of them shares your birthday is 5/365, right?</p>
<p>The answer 5/365 is quite accurate, but not exactly correct. It&#8217;s good enough for this problem since there are other practical difficulties besides the quality of the approximation. For example, the problem implicitly assumes there are 365 days in a year, i.e. that no one is ever born on Leap Day.</p>
<p>Now think about a similar problem. Suppose the chance of rain is 40% each day for the next three days. Does that mean there is a 120% chance that it will rain at least one of the next three days? That can&#8217;t be. In fact, the chance of some rain over the next three days is 78.4%.</p>
<p>The following rule appears to be correct for birthdays but not for predicting rain.</p>
<p style="padding-left: 30px;">If the probability of a success in one attempt is <em>p</em>, then the probability of at least one success in <em>n</em> attempts is <em>np</em>.</p>
<p>Why does this rule hold sometimes and not at other times? If the probability of success on each attempt is <em>p</em>, the probability of failure on each attempt is (1-<em>p</em>). The probability of n failures in a row is (1-<em>p</em>)<sup>n</sup> and so the probability of at least one success is 1 - (1-<em>p</em>)<sup>n</sup>. That&#8217;s the right way to approach the birthday example and the rain example. In the birthday example, <em>p</em> = 1/365 and so the probability of running into at least one person in five who shares your birthday is 1 - (364/365)<sup>5</sup> = 0.013624. And 5/365 = 0.013699 is a very good approximation. In the rain example, <em>p</em> = 0.4 and the probability of at least one day of rain out of the next three is 1 - 0.6<sup>3</sup> = 0.784. The difference between the birthday example and the rain example is the size of <em>p</em>. The following equation, based on the binomial theorem, explains why.</p>
<p style="text-align:center"><img src="http://www.johndcook.com/binomialapprox.gif" alt="1 - (1-p)^n = np - {n \choose 2}p^2 + {n \choose 3} p^3 - {n \choose 4}p^4 + \cdots" width="378" height="41" /></p>
<p>When we use <em>np</em> as our approximation, we&#8217;re ignoring the terms involving <em>p</em><sup>2</sup> and higher powers of <em>p</em>. When <em>p</em> is small, higher powers of <em>p</em> are very small and can be ignored. That&#8217;s why the approximation worked well for <em>p</em> = 1/365. But when <em>p</em> is large, say <em>p</em> = 0.4, the error is large; the terms involving higher powers of <em>p</em> are important in that case. Notice also that the size of <em>n</em> matters. The birthday example breaks down when <em>n</em> is large. If you run into 400 people, it is likely that one of them will share your birthday, but far from certain. The probability in that case is about 2/3,  not 400/365.</p>
<p>When <em>p</em> and <em>n</em> are both small, the probability of at least one success out of n tries is approximately <em>np</em>. We can say more. Because the first term the approximation drops from the equation above has a negative sign, our approximation is also an upper bound. This says <em>np</em> slightly over-estimates the probability.</p>
<p>Now how small do <em>p</em> and <em>n</em> have to be? If you calculate the approximation <em>np</em> and get a small answer, then it&#8217;s a good answer. Why? The error in the <em>np</em> approximation is roughly <em>n</em>(<em>n</em>-1)<em>p</em><sup>2</sup>/2, which is less than (<em>n</em><em>p</em>)<sup>2</sup>. And if <em>n</em><em>p </em>is small, (<em>n</em><em>p</em>)<sup>2</sup> is very small.</p>
<p>See <a href="http://www.johndcook.com/blog/2009/01/12/sales-tax-included/">Sales tax included</a> for a similar discussion. That also post looks at a common mistake and explains why it makes a good approximation under some circumstances and not under others.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/pFFaI1or1c8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/25/probability-approximation/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/25/probability-approximation/</feedburner:origLink></item>
		<item>
		<title>Optical illusion, mathematical illusion</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/pYy8d0L3mzs/</link>
		<comments>http://www.johndcook.com/blog/2009/06/24/optical-illusion/#comments</comments>
		<pubDate>Wed, 24 Jun 2009 19:44:16 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Graphics]]></category>

		<category><![CDATA[Math]]></category>

		<category><![CDATA[Integration]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2541</guid>
		<description><![CDATA[Someone sent me a link to an optical illusion while I was working on a math problem. The two things turned out to be related.
In the image below, what look like blues spiral and green spirals are actually exactly the same color. The spiral that looks blue is actually green inside, but the magenta stripes [...]]]></description>
			<content:encoded><![CDATA[<p>Someone sent me a link to an optical illusion while I was working on a math problem. The two things turned out to be related.</p>
<p>In the image below, what look like blues spiral and green spirals are actually exactly the same color. The spiral that looks blue is actually green inside, but the magenta stripes across it make the green look blue. I know you don&#8217;t believe me; I didn&#8217;t believe it either. See this <a href="http://blogs.discovermagazine.com/badastronomy/2009/06/24/the-blue-and-the-green/">blog post</a> for an explanation, including a magnified close-up of the image. Or open it in an image editor and use a color selector to see for yourself.</p>
<p style="text-align:center"><img src="http://www.johndcook.com/spiralillusion.gif" alt="" width="344" height="351" /></p>
<p>My math problem was also a case of two things that look different even though they are not. Maybe you can think back to a time as a student when you knew your answer was correct even though it didn&#8217;t match the answer in the back of the book. The two answers were equivalent but written differently. In an algebra class you might answer 5 / √ 3 when the book has 5 √ 3 / 3. In trig class you might answer 1 - cos<sup>2</sup>x when the book has sin<sup>2</sup>x. In a differential equations class, equivalent answers may look very different since arbitrary constants can obfuscate differences.</p>
<p>In my particular problem, I was looking at weights for Gauss-Hermite integration. I was trying to reconcile two different expressions for the weights, one in some software I&#8217;d written years ago and one given in <a href="http://www.amazon.com/gp/product/0486612724?ie=UTF8&amp;tag=theende-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0486612724">A&amp;S</a>. I thought I&#8217;d found a bug, at least in my comments if not in my software. My confusion was analogous to not recognizing a trig identity.  I wish I could say that the optical illusion link made me think that the two expressions may be the same and they just look different because of a mathematical illusion. That would make a good story. Instead, I discovered the equivalence of the two expressions by brute force, having Mathematica print out the values so I could compare them. Only later did I see the analogy between my problem and the optical illusion.</p>
<p>In case you&#8217;re interested in the details, my problem boiled down to the equivalence between H<sub>n+1</sub>(x<sub>i</sub>)<sup>2</sup> and 4n<sup>2</sup>H<sub>n-1</sub>(x<sub>i</sub>)<sup>2</sup> where H<sub>n</sub>(x) is the <em>n</em>th <a href="http://en.wikipedia.org/wiki/Hermite_polynomial">Hermite polynomial</a> and x<sub>i</sub> is the <em>i</em>th root of H<sub>n</sub>. Here&#8217;s why these are the same. The Hermite polynomials satisfy a recurrence relation H<sub>n+1</sub>(x) = 2x H<sub>n</sub>(x) - 2n H<sub>n-1</sub>(x) for all x. Since H<sub>n</sub>(x<sub>i</sub>) = 0, H<sub>n+1</sub>(x<sub>i</sub>) = -2nH<sub>n-1</sub>(x<sub>i</sub>). Now square both sides.</p>
<p><strong>Related post</strong>: <a href="http://www.johndcook.com/blog/2008/02/16/orthogonal-polynomials/">Orthogonal polynomials</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/pYy8d0L3mzs" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/24/optical-illusion/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/24/optical-illusion/</feedburner:origLink></item>
		<item>
		<title>John Tukey’s median of medians</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/H-yZxPREl6w/</link>
		<comments>http://www.johndcook.com/blog/2009/06/23/tukey-median-ninther/#comments</comments>
		<pubDate>Tue, 23 Jun 2009 17:50:02 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Statistics]]></category>

		<category><![CDATA[Probability and Statistics]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2535</guid>
		<description><![CDATA[Yesterday I got an email from Jestin Abraham asking a question about Tukey&#8217;s &#8220;median of medians&#8221; paper from 1978. (The full title is &#8220;The Ninther, a Technique for Low-Effort Robust (Resistant) Location in Large Samples.&#8221;) Jestin thought I might be familiar with the paper since I&#8217;ve written about Tukey several times, but I&#8217;d never heard [...]]]></description>
			<content:encoded><![CDATA[<p>Yesterday I got an email from Jestin Abraham asking a question about Tukey&#8217;s &#8220;median of medians&#8221; paper from 1978. (The full title is &#8220;The Ninther, a Technique for Low-Effort Robust (Resistant) Location in Large Samples.&#8221;) Jestin thought I might be familiar with the paper since I&#8217;ve written about Tukey several times, but I&#8217;d never heard of it.</p>
<p>Tukey&#8217;s &#8220;ninther&#8221; or &#8220;median of medians&#8221; procedure is quite simple. Understanding the problem he was trying to solve is a little more difficult.</p>
<p>Suppose you are given nine data points: y<sub>1</sub>, y<sub>2</sub>, &#8230;, y<sub>9</sub>. Let y<sub>A</sub> be the median of the first three samples, y<sub>B</sub> the median of the next three samples, and y<sub>C</sub> the median of the last three samples. The &#8220;ninther&#8221; of the data set is the median of y<sub>A</sub>, y<sub>B</sub>, and y<sub>C</sub>, hence the &#8220;median of medians.&#8221; If the data were sorted, the ninther would simply be the median, but in general it will not be.</p>
<p>For example, suppose your data are 3, 1, 4, 4, 5, 9, 9, 8, 2.  Then</p>
<p style="padding-left: 30px;">y<sub>A </sub>= median( 3, 1, 4 ) = 3<br />
y<sub>B </sub>= median( 4, 5, 9 ) = 5<br />
y<sub>C</sub> = median( 9, 8, 2 ) = 8</p>
<p>and so the ninther is median( 3, 5, 8 ) = 5. The median is 4.</p>
<p>That&#8217;s Tukey&#8217;s solution, so what was his problem? First of all, he&#8217;s trying to find an estimate for the central value of a large data set. Assume the data come from a symmetric distribution so that the mean equals the median. He&#8217;s looking for a <a href="http://www.johndcook.com/blog/2009/03/11/robust-statistics/">robust estimator</a> of the mean, an estimator resistant to the influence of outliers. That&#8217;s why he&#8217;s using an estimator that is more like the median than the mean.</p>
<p>Why not just use the median? Computing the sample median requires storing all data points and then sorting them to pick the middle value. Tukey wants to do his computation in one pass without storing the data. Also, he wants to do as few comparisons and as few arithmetic operations as possible. His ninther procedure uses no arithmetic operations and only order comparisons. He shows that it uses only about 1.1 comparisons per data point on average and 1.33 comparisons per data point in the worst case.</p>
<p>How well does Tukey&#8217;s ninther perform? He shows that if the data come from a normal distribution, the ninther has about 55% efficiency relative to the sample mean. That is, the variances of his estimates are a little less than twice the variances of estimates using the sample mean. But the purpose of robust statistics is efficient estimation in case the data <em>do not</em> come from a normal distribution but from a distribution with thicker tails. The relative efficiency of the ninther improves when data do come from distributions with thicker tails.</p>
<p>Where do large data sets come in? So far we&#8217;ve only talked about analyzing data sets with nine points. Tukey&#8217;s idea was to use the ninther in conjunction with the median. For some large number <em>M</em>, you could estimate the central value of 9<em>M</em> data points by applying the ninther to groups of 9 points and take the median of the <em>M</em> ninthers. This still requires computing the median of <em>M</em> points, but the memory requirement has been reduced by a factor of 9. Also, the sorting time has been reduced by more than a factor of 9 since sorting <em>n</em> points takes time proportional to <em>n</em> log <em>n</em>.</p>
<p>For even larger data sets, Tukey recommended breaking the data in to sets of 81 points and computing the ninther of the ninthers. Then 81<em>M</em> data points could be processed by storing and sorting <em>M</em> values.</p>
<p>Tukey gave <em>M</em> = 1,000,000 as an example of what he called an &#8220;impractically large data set.&#8221; I suppose finding the median of 81 million data points was impractical in 1978, though it&#8217;s a trivial problem today. Perhaps Tukey&#8217;s ninther is sill useful for an embedded device with extremely limited resources that must process enormous amounts of data.</p>
<p><strong>Other posts on robust statistics</strong>:</p>
<p><a href="http://www.johndcook.com/blog/2009/03/11/robust-statistics/">Canonical examples from robust statistics</a><br />
<a href="http://www.johndcook.com/blog/2009/03/06/student-t-distribution-mean-median/">Efficiency of median versus mean</a></p>
<p><strong>Other posts on John Tukey</strong>:</p>
<p><a href="http://www.johndcook.com/blog/2008/07/10/approximate-problems-and-approximate-solutions/">Approximate problems and approximate solutions</a><br />
<a href="http://www.johndcook.com/blog/2009/02/20/john-tukey-and-aristotle/">John Tukey and Aristotle</a><br />
<a href="http://www.johndcook.com/blog/2008/03/08/tukey-tallying/">Tukey tallying</a><br />
<a href="http://www.johndcook.com/blog/2009/03/30/when-discoveries-stay-discovered/">When discoveries stay discovered</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/H-yZxPREl6w" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/23/tukey-median-ninther/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/23/tukey-median-ninther/</feedburner:origLink></item>
		<item>
		<title>Interview with Dan Bricklin</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/P2A4EyHD56M/</link>
		<comments>http://www.johndcook.com/blog/2009/06/22/dan-bricklin-interview/#comments</comments>
		<pubDate>Mon, 22 Jun 2009 17:36:43 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Business]]></category>

		<category><![CDATA[Software development]]></category>

		<category><![CDATA[Books]]></category>

		<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2528</guid>
		<description><![CDATA[Dan Bricklin is best known for creating VisiCalc along with Bob Frankston in 1979. Since that time he has been active as a software developer and entrepreneur. His new book is Bricklin on Technology.

I quoted Dan Bricklin in a blog post a few weeks ago and he left a couple comments in the discussion. This [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://en.wikipedia.org/wiki/Dan_Bricklin">Dan Bricklin</a> is best known for creating <a href="http://www.danbricklin.com/visicalc.htm">VisiCalc</a> along with Bob Frankston in 1979. Since that time he has been active as a software developer and entrepreneur. His new book is <a href="http://www.amazon.com/gp/product/0470402377?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=0470402377">Bricklin on Technology</a>.</p>
<p style="text-align:center"><a href="http://www.amazon.com/gp/product/0470402377?ie=UTF8&amp;tag=theende-20&amp;linkCode=as2&amp;camp=1789&amp;creative=9325&amp;creativeASIN=0470402377"><img src="http://www.johndcook.com/514efhtSuML._SL160_.jpg" border="0" alt="Bricklin on Technology" /></a><img style="border:none !important; margin:0px !important;" src="http://www.assoc-amazon.com/e/ir?t=theende-20&amp;l=as2&amp;o=1&amp;a=0470402377" border="0" alt="" width="1" height="1" /></p>
<p>I quoted Dan Bricklin in a blog post <a href="http://www.johndcook.com/blog/2009/05/14/would-you-rather-have-a-chauffeur-or-a-ferrari/">a few weeks ago</a> and he left a couple comments in the discussion. This started an email correspondence that lead to the following interview.</p>
<p><strong>JC: Do you ever feel that the fame of VisiCalc has overshadowed some of your more recent accomplishments?</strong></p>
<p>DB: It had better. VisiCalc was a pretty big thing to have done, and I&#8217;m very happy that I had the opportunity to make such a big contribution to the world. On the other hand, I frequently run into people who remember me because of some of my other products, especially Dan Bricklin&#8217;s Demo, or my writings that had a major impact on their work, so I know it&#8217;s not all that I&#8217;ve done of interest. Having done VisiCalc has opened many doors for me, and I surely appreciate that. I wouldn&#8217;t call it overshadowed, I&#8217;d call it added to and enhanced.</p>
<p><strong>JC: What would your 30-second bio be without VisiCalc?</strong></p>
<p>DB: I am a long-term toolmaker and commentator in the area of the personal use of computing power. I&#8217;ve stayed current in the technology area, and continually programmed and developed products in the latest genre, and shared my observations through blogging, podcasting, and other means, including a book.</p>
<p><strong>JC: What are you doing these days as a programmer?  As an entrepreneur?</strong></p>
<p>DB: I have been working on an Open Source JavaScript-based spreadsheet called SocialCalc. It is being used throughout the world on the One Laptop Per Child&#8217;s XO computer, as well as by enterprise social-software company Socialtext, which paid for much of its development. I also serve on a few high-tech boards, and do a variety of types of consulting, including speaking engagements. I plan to continue developing software of various sorts and consulting.</p>
<p><strong>JC: What trends do you see in software development?</strong></p>
<p>DB: Software development is pervading more and more fields as a major component. We have moved from the computer being an adjunct to other means of expression or deployment to being the only or dominant means. The use of major system components, be they libraries or services, has continued to grow.</p>
<p><strong>JC: Every time a new technology comes out, someone asks what the killer app will. That is, what application will do for the new technology what VisiCalc did for personal computers. Could you comment on some other &#8220;killer apps&#8221; since VisiCalc?</strong></p>
<p>DB: I viewed VisiCalc as an app that made buying it and the whole system needed to run it an extremely simple decision. I saw it as having a &#8220;two week payback&#8221; for buying the whole system. That came from being two orders of magnitude better than what was used before. In VisiCalc&#8217;s case, you could use paper and pencil, taking at least 100 times as long to do the same thing, or, in those days, a timesharing system at a few thousand dollars a month (at least).</p>
<p>Similarly compelling applications since VisiCalc (for businesses) were desktop publishing, email, and mobile computing (like the Blackberry, Treo, and now iPhone). For the home, initially CD-ROM encyclopedias were a pretty compelling reason for homes with children to buy a PC (less than the cost of a paper encyclopedia and a bookcase to hold it but you could also use it for word processing), then the combination of email and the web with an always-connected Internet connection.</p>
<p><strong>JC: The personal computer had a killer app and became popular. Are we reading too much into history by expecting that every technology must have a killer app before it can take off?</strong></p>
<p>DB: You only need something that justifies buying a whole system if the sum of other applications or other reasons don&#8217;t cause the purchase on their own. For the iPhone, for some people, just having a large catalog of things you might want (those long tail apps I discuss in Chapter 7 of my book) may be enough.</p>
<p><strong>JC: What do you think of open source business models?  Ad sponsored, freemium, selling support/consulting services, etc.</strong></p>
<p>DB: As I point out in Chapter 2 of my book where I talk about artists getting paid, there are many ways to make money. A &#8220;business model&#8221; is just saying here is how the pieces of what I do fit together and end up making enough money to meet the needs I have. This includes the cost structure as well as the sources of revenue and desired results. All long term endeavors, be they mainly based on developing or using Open Source or proprietary source or a mixture, look to different mixtures. They have historically used selling support, relationships with other companies (which advertising is a variant of), and other techniques as part of their mix. Open Source just gives us other options, including on the cost side. Also, as Prof. Ariely explains in the interview I did with him (Chapter 5) once you move into the realm of &#8220;free&#8221;, and when you appropriately invoke &#8220;community&#8221;, both of which Open Source can do, you get added benefits in your relationship with other people that can leverage your marketing and other costs.</p>
<p><strong>JC: What did you learn in the process of writing your book? In particular, could you say a little bit about typography?</strong></p>
<p>DB: Most of what I went through is in my essay on the topic, <a href="http://www.bricklin.com/bontech/blog-to-book.html">Turning My Blog Into A Book</a>. I think that typography is important, and we&#8217;ve seen that as web pages have moved from very basic to better layout to full use of CSS. Typography is a way of expressing ideas and information outside of the direct flow of what you are saying. It is very valuable. Just as a well-delivered speech can convey much more than just the raw words, appropriate use of typographical techniques can convey much more than simple text.</p>
<p><strong>Related posts</strong>:</p>
<p><a href="http://www.johndcook.com/blog/2009/05/14/would-you-rather-have-a-chauffeur-or-a-ferrari/">Would you rather have a chauffeur or a Ferrari?</a><br />
<a href="http://www.johndcook.com/blog/2009/06/04/software-challenges/">Two kinds of software challenges</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/P2A4EyHD56M" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/22/dan-bricklin-interview/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/22/dan-bricklin-interview/</feedburner:origLink></item>
		<item>
		<title>Conservation of attractive profits</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/_VBy5HBzv18/</link>
		<comments>http://www.johndcook.com/blog/2009/06/22/conservation-of-attractive-profits/#comments</comments>
		<pubDate>Mon, 22 Jun 2009 14:46:22 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Business]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2520</guid>
		<description><![CDATA[Tim O&#8217;Reilly talked about the &#8220;law of conservation of attractive profits&#8221; in a recent interview on the FLOSS Weekly podcast. Clayton Christensen explained this law in an HBR report in 2004. It says that when one thing becomes modular and commoditized, another thing becomes valuable.
O&#8217;Reilly argues that just as computers made out of commodity hardware [...]]]></description>
			<content:encoded><![CDATA[<p>Tim O&#8217;Reilly talked about the &#8220;law of conservation of attractive profits&#8221; in a recent <a href="http://www.podtrac.com/pts/redirect.mp3/twit.cachefly.net/FLOSS-073.mp3">interview</a> on the FLOSS Weekly podcast. Clayton Christensen explained this law in an <a href="http://harvardbusinessonline.hbsp.harvard.edu/b02/en/common/item_detail.jhtml;jsessionid=BBBMPLJXGRIWKAKRGWDSELQBKE0YIISW?id=R0402A&amp;_requestid=72208">HBR report</a> in 2004. It says that when one thing becomes modular and commoditized, another thing becomes valuable.</p>
<p>O&#8217;Reilly argues that just as computers made out of commodity hardware made software more valuable, now commodity software and open standards have made data more valuable.</p>
<p>Taking this line of reasoning one step further, open data makes analysis more valuable. Good news for experts in statistics and machine learning.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/_VBy5HBzv18" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/22/conservation-of-attractive-profits/feed/</wfw:commentRss>
<enclosure url="http://www.podtrac.com/pts/redirect.mp3/twit.cachefly.net/FLOSS-073.mp3" length="55197742" type="audio/mpeg" />
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/22/conservation-of-attractive-profits/</feedburner:origLink></item>
		<item>
		<title>The Endeavour is now a podcast</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/-fkZlw8esII/</link>
		<comments>http://www.johndcook.com/blog/2009/06/20/endeavour-podcast/#comments</comments>
		<pubDate>Sat, 20 Jun 2009 16:49:30 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2516</guid>
		<description><![CDATA[This blog is now available as a podcast. I&#8217;m experimenting with the Odiogo service to automatically create an audio version of the blog text. The speech quality is surprisingly good, much better than the Windows speech synthesizer.
You can listen from the web page or subscribe to the podcast via iTunes etc. Let me know what [...]]]></description>
			<content:encoded><![CDATA[<p>This blog is now available as a podcast. I&#8217;m experimenting with the Odiogo service to automatically create an audio version of the blog text. The speech quality is surprisingly good, much better than the <a href="http://www.johndcook.com/blog/2008/10/03/experimenting-with-out-speech-in-powershell/">Windows speech synthesizer</a>.</p>
<p>You can listen from the web page or <a href="http://podcasts.odiogo.com/the-endeavour/podcasts-html.php">subscribe to the podcast</a> via iTunes etc. Let me know what you think.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/-fkZlw8esII" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/20/endeavour-podcast/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/20/endeavour-podcast/</feedburner:origLink></item>
		<item>
		<title>Miscellaneous links</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/wX7WgDMIOCQ/</link>
		<comments>http://www.johndcook.com/blog/2009/06/20/miscellaneous-links-2/#comments</comments>
		<pubDate>Sat, 20 Jun 2009 11:48:57 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2506</guid>
		<description><![CDATA[What it&#8217;s like to run a marathon in space.
Mathematical artwork from Chris Henden:
finite projective plane
balanced incomplete block design
binomial expansion
(A lot of mathematical art is gimmicky. Interesting, but not beautiful. Chris Henden&#8217;s work is beautiful. I believe people would enjoy it who had no appreciation for the math that inspired the artwork. Here are a couple [...]]]></description>
			<content:encoded><![CDATA[<p>What it&#8217;s like to <a href="http://science.nasa.gov/headlines/y2009/15jun_running.htm">run a marathon in space</a>.</p>
<p>Mathematical artwork from Chris Henden:<br />
<a href="http://www.oddnumber.co.uk/2009/02/11/finite-projective-plane-of-order-3/">finite projective plane</a><br />
<a href="http://www.oddnumber.co.uk/2009/02/07/a-balanced-incomplete-block-design/">balanced incomplete block design</a><br />
<a href="http://www.oddnumber.co.uk/2008/02/17/binomial-expansion/">binomial expansion</a><br />
(A lot of mathematical art is gimmicky. Interesting, but not beautiful. Chris Henden&#8217;s work is beautiful. I believe people would enjoy it who had no appreciation for the math that inspired the artwork. Here are a couple non-mathematical pieces by the same artist: <a href="http://www.oddnumber.co.uk/2009/01/26/back/">life drawing</a>, <a href="http://www.oddnumber.co.uk/2009/01/25/looking-at-abu-dhabi/">Abu Dhabi</a>.)</p>
<p><a href="http://www.stat.columbia.edu/~cook/movabletype/archives/2009/06/unconvincing_to.html">Andrew Gelman&#8217;s take</a> on the statistics of the recent election in Iran. Note that he says &#8220;let me emphasize that I&#8217;m not saying that I think nothing funny was going on in the election. As I wrote, I&#8217;m commenting on the statistics.&#8221;</p>
<p><a href="http://www.chron.com/disp/story.mpl/headline/metro/6477669.html">Interview</a> with James Olson, author of <a href="http://www.amazon.com/gp/product/080189056X?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=080189056X">Making Cancer History</a>, a history of M. D. Anderson Cancer Center. (See related <a href="http://www.johndcook.com/blog/2009/04/23/cartoon-about-my-job/">cartoon</a>.)</p>
<p>Long list of use <a href="http://serverfault.com/questions/3780/useful-commandline-commands-on-windows">useful command line commands</a> on Windows.</p>
<p><a href="http://secretgeek.net/pareto_recurse.asp">Recursing over the Pareto Principle</a>. Humorous look at taking the <a href="http://www.johndcook.com/blog/2009/02/03/obstacles-to-applying-pareto-rule/">Pareto Principle</a> (a.k.a. 80-20 rule) too far.</p>
<p><a href="http://pl.atyp.us/wordpress/?page_id=1277">Server design</a>, a blog post about &#8220;the Four Horsemen of Poor Performance.&#8221;<br />
<a href="http://www.oddnumber.co.uk/2008/02/17/binomial-expansion/"></a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/wX7WgDMIOCQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/20/miscellaneous-links-2/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/20/miscellaneous-links-2/</feedburner:origLink></item>
		<item>
		<title>Backup and recovery</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/_KvVEVsvAk0/</link>
		<comments>http://www.johndcook.com/blog/2009/06/18/backup-and-recovery/#comments</comments>
		<pubDate>Fri, 19 Jun 2009 00:30:18 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Computing]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2504</guid>
		<description><![CDATA[Paul Randal had the following to say about database backup and recovery in his interview with .NET Rocks.
Don&#8217;t ever, ever plan a backup strategy. Plan a restore strategy.
The point of a backup is to be able to restore data when necessary. That sounds obvious, but it&#8217;s easy to lose site of. Too many companies backup [...]]]></description>
			<content:encoded><![CDATA[<p>Paul Randal had the following to say about database backup and recovery in his <a href="http://www.dotnetrocks.com/default.aspx?showNum=455">interview</a> with .NET Rocks.</p>
<blockquote><p>Don&#8217;t ever, ever plan a backup strategy. Plan a restore strategy.</p></blockquote>
<p>The point of a backup is to be able to restore data when necessary. That sounds obvious, but it&#8217;s easy to lose site of. Too many companies backup their data, or <em>think</em> that they back up their data, but don&#8217;t have much of a recovery plan. Or they have a recovery plan but they haven&#8217;t rehearsed it. Until you rehearse your recovery plan, you don&#8217;t know whether it&#8217;s going to work, you don&#8217;t know how long it&#8217;s going to take, and you don&#8217;t know whether you need to invest in hardware to speed it up.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/_KvVEVsvAk0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/18/backup-and-recovery/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/18/backup-and-recovery/</feedburner:origLink></item>
		<item>
		<title>The most subtle of the seven deadly sins</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/pKBvEfE7fJU/</link>
		<comments>http://www.johndcook.com/blog/2009/06/17/sloth/#comments</comments>
		<pubDate>Wed, 17 Jun 2009 17:06:50 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<category><![CDATA[Productivity]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2465</guid>
		<description><![CDATA[Six of the seven deadly sins are easy to define, but one is more subtle. The seven deadly sins are

lust
gluttony
greed
sloth
wrath
envy
pride.

Sloth is the subtle one.
I discovered recently that I didn&#8217;t know what sloth meant. When I first heard of the seven deadly sins, I thought it was odd that sloth was on the list. How would [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Six of the seven deadly sins</strong> are easy to define, but one is more subtle. The seven deadly sins are</p>
<ol>
<li>lust</li>
<li>gluttony</li>
<li>greed</li>
<li>sloth</li>
<li>wrath</li>
<li>envy</li>
<li>pride.</li>
</ol>
<p><strong>Sloth</strong> is the subtle one.</p>
<p>I discovered recently that <strong>I didn&#8217;t know what sloth meant</strong>. When I first heard of the seven deadly sins, I thought it was odd that sloth was on the list. How would you know whether you&#8217;re sufficiently active to avoid sloth? It turns out that the original idea of sloth was only indirectly related to activity.</p>
<p>The idea of a list of deadly sins started in the 4th century and has changed over time. The word in the middle of the list was &#8220;acedia&#8221; before it became &#8220;sloth,&#8221; and the word &#8220;sloth&#8221; has taken on a different meaning since then. So what is acedia? According to Wikipedia,</p>
<blockquote><p>Acedia is a word from ancient Greek describing a state of listlessness or torpor, of not caring or not being concerned with one&#8217;s position or condition in the world. It can lead to a state of being unable to perform one&#8217;s duties in life. Its spiritual overtones make it related to but distinct from depression.</p></blockquote>
<p>In short, &#8220;sloth&#8221; did not mean inactivity but rather a state of apathy. As Os Guinness says in his book <a href="http://www.amazon.com/gp/product/0849944376?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=0849944376">The Call</a></p>
<blockquote><p>&#8230; sloth must be distinguished from idling, a state of carefree living that can be admirable, as in friends lingering over a meal &#8230; [Sloth] can reveal itself in <a href="http://www.johndcook.com/blog/2008/04/02/being-busy/">frenetic activism</a> as easily as in lethargy &#8230; It is a condition of explicitly spiritual dejection &#8230; inner despair at the worthwhileness of the worthwhile &#8230;</p></blockquote>
<p>Sloth and rest could look the same externally while proceeding from opposite motivations. One person could be idle because he lacked the faith to do anything, while another person could be idle because he had faith that his needs would be met even if he rested a while. The key to avoiding sloth is not the proper level of activity but the proper attitude of the heart.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/pKBvEfE7fJU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/17/sloth/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/17/sloth/</feedburner:origLink></item>
		<item>
		<title>Questioning the Hawthorne effect</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/RLDaksXUGtA/</link>
		<comments>http://www.johndcook.com/blog/2009/06/16/hawthorne-effect/#comments</comments>
		<pubDate>Tue, 16 Jun 2009 13:08:32 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Business]]></category>

		<category><![CDATA[Science]]></category>

		<category><![CDATA[Productivity]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2496</guid>
		<description><![CDATA[The Hawthorne effect is the idea that people perform better when they&#8217;re being studied. The name comes from studies conducted at Western Electric&#8217;s Hawthorne Works facility. Increased lighting improved productivity in the plant. Later, lowering the lighting also increased productivity. The Hawthorne effect says that the productivity increase wasn&#8217;t due to changes in lighting per [...]]]></description>
			<content:encoded><![CDATA[<p>The Hawthorne effect is the idea that people perform better when they&#8217;re being studied. The name comes from studies conducted at Western Electric&#8217;s Hawthorne Works facility. Increased lighting improved productivity in the plant. Later, <em>lowering</em> the lighting also increased productivity. The Hawthorne effect says that the productivity increase wasn&#8217;t due to changes in lighting <em>per se</em> but either the variety of changing something about the plant or the attention that workers got by being measured, a sort of placebo effect.</p>
<p>The Alternative Blog has a post this morning entitled <a href="http://alternablog.wordpress.com/2009/06/16/hawthorn-effect-debunked/">Hawthorne effect debunked</a>. The original Hawthorne effect was apparently due to a flaw in the study design; correcting for that flaw eliminates the effect.</p>
<p>The term &#8220;debunked&#8221; in the post title may imply too much. The effect in the <em>original studies</em> may have been debunked, but that does not necessarily mean there is no Hawthorne effect. Perhaps there are good examples of the Hawthorne effect elsewhere. On the other hand, I expect closer examination of the data could debunk other reported instances of the Hawthorne effect as well.</p>
<p>The Hawthorne effect makes sense. It has been ingrained in pop culture. I heard a reference to it on a podcast just this morning before reading the blog post mentioned above. Everyone knows it&#8217;s true. And maybe it is. But at a minimum, there is at least one example suggesting the effect is not as wide-spread as previously thought.</p>
<p>It would be interesting to track the popularity of the Hawthorne effect in scholarly literature and in pop culture. If the effect becomes less credible in scholarly circles, will it also become less credible in pop culture? And if so, how quickly will pop culture respond?</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/RLDaksXUGtA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/16/hawthorne-effect/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/16/hawthorne-effect/</feedburner:origLink></item>
		<item>
		<title>The Unix Programming Environment</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/NgGenoxTxcI/</link>
		<comments>http://www.johndcook.com/blog/2009/06/15/joel-spolsky-books/#comments</comments>
		<pubDate>Mon, 15 Jun 2009 19:51:53 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Computing]]></category>

		<category><![CDATA[Books]]></category>

		<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2471</guid>
		<description><![CDATA[Joel Spolsky recommends the following books to self-taught programmers who apply to his company and need to fill in some gaps in their training.

Structure and Interpretation of Computer Programs
The C Programming Language
The Unix Programming Environment
Introduction to Algorithms

The one that has me scratching my head is The Unix Programming Environment, first published in 1984. After listening [...]]]></description>
			<content:encoded><![CDATA[<p>Joel Spolsky <a href="http://itc.conversationsnetwork.org/shows/detail4144.html">recommends</a> the following books to self-taught programmers who apply to his company and need to fill in some gaps in their training.</p>
<ol>
<li><a href="http://www.amazon.com/gp/product/0262011530?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=0262011530">Structure and Interpretation of Computer Programs</a></li>
<li><a href="http://www.amazon.com/gp/product/0131103628?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=0131103628">The C Programming Language</a></li>
<li><a href="http://www.amazon.com/gp/product/013937681X?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=013937681X">The Unix Programming Environment</a></li>
<li><a href="http://www.amazon.com/gp/product/0262032937?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=0262032937">Introduction to Algorithms</a></li>
</ol>
<p>The one that has me scratching my head is <em>The Unix Programming Environment, </em>first published in 1984. After listening to Joel&#8217;s podcast, I thumbed through my old copy of the book and thought &#8220;Man, I could never work like this.&#8221; Of course I <em>could </em>work like that, because I did, back around 1990. But the world has <em>really</em> changed since then.</p>
<p>I appreciate history and <a href="http://www.johndcook.com/blog/2009/01/19/c-s-lewis-on-reading-old-books/">old books</a>. I see the value in learning things you might not directly apply. But imagine telling twentysomething applicants to go read an operating system book that was written before they were born. Most would probably think you&#8217;re insane.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/NgGenoxTxcI" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/15/joel-spolsky-books/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/15/joel-spolsky-books/</feedburner:origLink></item>
		<item>
		<title>Upcoming Y2K-like problems</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/TEh-f9FyQe8/</link>
		<comments>http://www.johndcook.com/blog/2009/06/13/upcoming-y2k-like-problems/#comments</comments>
		<pubDate>Sat, 13 Jun 2009 13:47:46 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Computing]]></category>

		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Twitter]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2487</guid>
		<description><![CDATA[The world&#8217;s computer systems kept working on January 1, 2000 thanks to billions of dollars spent on fixing old software. Two wrong conclusions to draw from Y2K are

The programmers responsible for Y2K bugs were losers.
That&#8217;s all behind us now.

The programmers who wrote the Y2K bugs were highly successful: their software lasted longer than anyone imagined [...]]]></description>
			<content:encoded><![CDATA[<p>The world&#8217;s computer systems kept working on January 1, 2000 thanks to billions of dollars spent on fixing old software. Two wrong conclusions to draw from Y2K are</p>
<ol>
<li>The programmers responsible for Y2K bugs were losers.</li>
<li>That&#8217;s all behind us now.</li>
</ol>
<p>The programmers who wrote the Y2K bugs were <strong>highly successful</strong>: their software lasted longer than anyone imagined it would. The two-digit dates were only a problem because their software was still in use decades later. (OK, some programmers were still writing Y2K bugs as late as 1999, but I&#8217;m thinking about COBOL programmers from the 1970&#8217;s.)</p>
<p>Y2K may be behind us, but we will be facing Y2K-like problems for years to come. Twitter just faced a Y2K-like problem last night, the so called <strong>Twitpocalypse</strong>. Twitter messages were indexed with a signed 32-bit integer. That means the original software was implicitly designed with a limit of around two billion messages. Like the COBOL programmers mentioned above, Twitter was more successful than anticipated. Twitter fixed the problem without any disruption, except that some third party Twitter clients need to be updated.</p>
<p>We are running out of <strong>Internet addresses</strong> because these addresses also use 32-bit integers. To make matters worse, an Internet address has an internal structure that greatly reduces the number of possible 32-bit addresses. <a href="http://www.johndcook.com/blog/2008/04/17/ipv6/">IPv6</a> will fix this by using 128-bit addresses.</p>
<p>The US will run out of <strong>10-digit phone numbers</strong> at some point, especially since not all 10-digit combinations are possible phone numbers. For example, the first three digits are a geographical area code. One area code can run out of 7-digit numbers while another has numbers left over.</p>
<p>At some point the US will run out of <strong>9-digit social security numbers</strong>.</p>
<p>The original Unix systems counted time as the number of seconds since January 1, 1970, stored in a signed 32-bit integer. On <strong>January 19, 2038</strong>, the number of seconds will exceed the capacity of such an integer and the time will roll over to zero, i.e. it will be January 1, 1970 again. This is more insidious than the Y2K problem because there are many software date representations in common use, including the old Unix method. Some (parts of) software will have problems in 2038 while others will not, depending on the whim of the programmer when picking a way to represent dates.</p>
<p><strong>There will always be Y2K-like problems</strong>. Computers are finite. Programmers have to guess at limitations for data. Sometimes these limitations are implicit, and so we can pretend they are not there, but they are. Sometimes programmers guess wrong because their software succeeds beyond their expectations.</p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/TEh-f9FyQe8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/13/upcoming-y2k-like-problems/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/13/upcoming-y2k-like-problems/</feedburner:origLink></item>
		<item>
		<title>Timed exams</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/Ud-SF_bIDMo/</link>
		<comments>http://www.johndcook.com/blog/2009/06/12/timed-exams/#comments</comments>
		<pubDate>Fri, 12 Jun 2009 12:39:46 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<category><![CDATA[Education]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2477</guid>
		<description><![CDATA[I ran across a blog post this morning that makes some excellent points about timed exams. Here are three points from Jon Dron&#8217;s blog post What exams have taught me:

that slow, steady, careful work is not worth the hassle — a bit of cramming (typically one-three days seemed to work for me) in a mad [...]]]></description>
			<content:encoded><![CDATA[<p>I ran across a blog post this morning that makes some excellent points about timed exams. Here are three points from Jon Dron&#8217;s blog post <a href="http://community.brighton.ac.uk/jd29/weblog/45251.html">What exams have taught me</a>:</p>
<ul>
<li>that slow, steady, careful work is not worth the hassle — a bit of cramming (typically one-three days seemed to work for me) in a mad rush just before the event works much more effectively and saves a lot of time</li>
<li>the corollary — adrenalin is necessary to achieve anything worth achieving</li>
<li>that the most important things in life generally take around three hours to complete</li>
</ul>
<p>As Marshal McLuhan said, the medium is the message. That is, the context of a message may speak louder than its content. Still, I&#8217;d like to defend timed exams in a limited context. You need to have quick recall of some facts. There are some skills you need to practice to the point that they are second nature. Not because these things are ultimately important but so you don&#8217;t have to think about them and can move on to other things.</p>
<p>Joel Spolsky gave an example along these lines in his recent podcast. He said that Serge Lang once began a calculus class with an algebra quiz, one expression to simplify. Thirty seconds into the quiz, it made everyone stop and turn in their work. At the end of the year, he compared the final grades to the grades on his algebra quiz. The students who got A&#8217;s in freshman calculus were almost exactly the same as those who were able to simply the algebra expression quickly. (The story begins around 8:12 in the <a href="http://itc.conversationsnetwork.org/audio/download/ITC.SO-Episode57-2009.06.09.mp3">audio file</a>. It&#8217;s also on the <a href="https://stackoverflow.fogbugz.com/default.asp?W29060">transcript wiki</a>.)</p>
<p>There are a couple ways to interpret this anecdote. One is that Lang&#8217;s exams measured quick reaction time and that students who were able to do algebra quickly were also able to do calculus quickly and thus succeed on Lang&#8217;s exams. There may be some truth to that. But I think more fundamentally, those who had mastered algebra were able to pay attention to the new material. Because algebra was second nature to these students, they could think about calculus.</p>
<p>I agree that typical hour-long exams are artificial and create some perverse incentives. I see a place for leisurely evaluation: take-home exams, projects, portfolios, etc. But I also see a place for timed evaluation, even quiz show-like rapid recall, though such evaluation need not factor into assigning grades.  I think Jon Dron&#8217;s criticism is that timed exams are usually not created deliberately. I don&#8217;t think he would necessarily find fault with someone explicitly identifying a list of fundamental skills and explaining that these need to be performed quickly. I believe his criticism is that everything is evaluated in a rush by default.</p>
<p>Thanks to Daniel Lemire for pointing out Jon Dron&#8217;s post. Read Daniel&#8217;s commentary <a href="http://www.daniel-lemire.com/blog/archives/2009/06/12/death-to-the-3-hour-exam/">here</a>.</p>
<p><strong>Related posts</strong>:</p>
<p><a href="http://www.johndcook.com/blog/2009/03/03/evaluate-people-at-their-best/">Evaluate people at their best or at their worst?</a><br />
<a href="http://www.johndcook.com/blog/2009/05/17/dont-standardize-education-personalize-it/">Don&#8217;t standardize education, personalize it</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/Ud-SF_bIDMo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/12/timed-exams/feed/</wfw:commentRss>
<enclosure url="http://itc.conversationsnetwork.org/audio/download/ITC.SO-Episode57-2009.06.09.mp3" length="33210441" type="audio/mpeg" />
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/12/timed-exams/</feedburner:origLink></item>
		<item>
		<title>Create offline, analyze online</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/SgwSsefI-wY/</link>
		<comments>http://www.johndcook.com/blog/2009/06/11/create-offline-analyze-online/#comments</comments>
		<pubDate>Thu, 11 Jun 2009 13:50:56 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Creativity]]></category>

		<category><![CDATA[Productivity]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2459</guid>
		<description><![CDATA[Sitting at a computer changes the way you think. You need to know when to walk away from the computer and when to come back.
I think mind mapping software is a bad idea. Mind maps are supposed to capture free associations. But the very act of sitting down at a computer puts you in an [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Sitting at a computer changes the way you think</strong>. You need to know when to walk away from the computer and when to come back.</p>
<p>I think mind mapping software is a bad idea. Mind maps are supposed to capture free associations. But the very act of sitting down at a computer puts you in an analytical frame of mind. In other words, mind mapping is a right-brain activity, but sitting at a computer encourages left-brain thinking. Mind mapping software might be a good way to digitize a map after you&#8217;ve created it on paper, but I don&#8217;t think it&#8217;s a good way to create a map.</p>
<p>When I need to sort out projects and priorities, I do it on paper. After that I may type up the results. I like to <em>capture</em> ideas on paper or on my <a href="http://www.amazon.com/gp/product/B000OVPB9K?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=B000OVPB9K">voice recorder</a> but then <em>store</em> them online.</p>
<p>When I do math, I scribble on paper, then type up my results in LaTeX. Scribbling helps me generate ideas; LaTeX helps me find errors. I&#8217;ve found that fairly short cycles of scribbling and typing work best for me, a few cycles a day.</p>
<p>In the past, we did a lot of things on paper because we had no choice. Today we do a lot of things on computers today just because we can. It&#8217;s going to take a while to sift through the new options and decide which ones are worthwhile and which are not.</p>
<p><strong>Recommended books</strong></p>
<p>Daniel Pink&#8217;s book <a href="http://www.amazon.com/gp/product/1594481717?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=1594481717">A Whole New Mind</a> has a good discussion of left-brain versus right-brain thinking. As he points out, the specialization between the left and right hemispheres of the brain is more complicated than once thought. However, the terms &#8220;left-brain&#8221; and &#8220;right-brain&#8221; are still useful metaphors even if they&#8217;re not precise neuroscience.</p>
<p>Also, to read more on how computers influence our thinking, see Andy Hunt&#8217;s book <a href="http://www.amazon.com/gp/product/1934356050?ie=UTF8&amp;tag=theende-20&amp;linkCode=xm2&amp;camp=1789&amp;creativeASIN=1934356050">Pragmatic Thinking and Learning</a>.</p>
<p><strong>Related posts</strong></p>
<p><a href="http://www.johndcook.com/blog/2008/12/02/stimulating-work-environment/">A stimulating work environment</a><br />
<a href="http://www.johndcook.com/blog/2009/04/02/living-within-chosen-limits/">Living within chosen limits</a><br />
<a href="http://www.johndcook.com/blog/2009/04/21/tim-brays-high-tech-monastic-cell/">Tim Bray&#8217;s high-tech monastic cell</a><br />
<a href="http://www.johndcook.com/blog/2008/07/08/whats-wrong-with-paper/">What&#8217;s wrong with paper?</a><br />
<a href="http://www.johndcook.com/blog/2008/07/15/getting-to-the-bottom-of-things/">Getting to the bottom of things</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/SgwSsefI-wY" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/11/create-offline-analyze-online/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/11/create-offline-analyze-online/</feedburner:origLink></item>
		<item>
		<title>A couple thoughts on typography</title>
		<link>http://feedproxy.google.com/~r/TheEndeavour/~3/hTHlc5qh4g8/</link>
		<comments>http://www.johndcook.com/blog/2009/06/10/a-couple-thoughts-on-typography/#comments</comments>
		<pubDate>Wed, 10 Jun 2009 18:17:44 +0000</pubDate>
		<dc:creator>John</dc:creator>
		
		<category><![CDATA[Typography]]></category>

		<guid isPermaLink="false">http://www.johndcook.com/blog/?p=2453</guid>
		<description><![CDATA[Font embedding not such a good idea?
The most recent Boag World podcast interviewed Mark Boulton. Boulton has a contrarian opinion on font embedding. Nearly all web designers are excited about font embedding (the ability to have fonts download on-the-fly if a page uses a font not installed on the user&#8217;s computer). Bolton&#8217;s not so sure [...]]]></description>
			<content:encoded><![CDATA[<h3>Font embedding not such a good idea?</h3>
<p>The most recent Boag World podcast interviewed <a href="http://boagworld.com/podcast/169">Mark Boulton</a>. Boulton has a contrarian opinion on font embedding. Nearly all web designers are excited about font embedding (the ability to have fonts download on-the-fly if a page uses a font not installed on the user&#8217;s computer). Bolton&#8217;s not so sure this is a good idea. Fonts are designed for a purpose, and most fonts were designed for print. The handful of fonts that were designed first for online viewing (<a href="http://www.microsoft.com/typography/web/fonts/verdana/default.htm">Verdana</a>, Georgia, etc.) are widely installed. If font embedding were a way to broaden the pallet of fonts designed for use on a computer monitor, that would be great. But the most likely use of font embedding would be to allow designers to use more fonts online that were not designed to be used online.</p>
<h3>Comic Sans and dyslexia</h3>
<p>Comic Sans is terribly overused. It&#8217;s not a bad font, but it&#8217;s often used in inappropriate contexts and has become a cliché for poor typographical taste.</p>
<p>However, I heard somewhere that people with dyslexia can read Comic Sans more easily than most other fonts. I think the explanation was that the font breaks some typical symmetries. For example, a &#8220;p&#8221; is not an exact mirror image of a &#8220;q.&#8221; (The former has a more pronounced serif on top.) On the other hand, the &#8220;b&#8221; and &#8220;d&#8221; do look like near mirror images. I wonder whether anyone has designed a font specifically to help people with dyslexia. Maybe such  fonts would exaggerate the asymmetries that were accidental in the design of Comic Sans. Delivering such fonts would be a good application of font embedding.</p>
<p><strong>Update</strong>: Karl Ove Hufthammer left a comment pointing out <a href="http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&amp;item_id=andika">Andika</a>, a font with &#8220;easy-to-perceive letterforms that will not be readily confused with one another.&#8221; Here&#8217;s a <a href="http://scripts.sil.org/cms/scripts/render_download.php?site_id=nrsi&amp;format=file&amp;media_id=AndikaBasic_TypeSample&amp;filename=AndikaBasic_TypeSample.pdf">sample</a>.</p>
<p><strong>Related posts</strong></p>
<p><a href="http://www.johndcook.com/blog/2009/03/12/periodic-table-of-typefaces/">Periodic table of typefaces</a><br />
<a href="http://www.johndcook.com/blog/2008/12/15/fonts-translations-python/">Things that work best when you don&#8217;t notice them</a><br />
<a href="http://www.johndcook.com/blog/2008/10/31/changing-the-r-console-fonts/">Better R console fonts</a></p>
<img src="http://feeds.feedburner.com/~r/TheEndeavour/~4/hTHlc5qh4g8" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.johndcook.com/blog/2009/06/10/a-couple-thoughts-on-typography/feed/</wfw:commentRss>
		<feedburner:origLink>http://www.johndcook.com/blog/2009/06/10/a-couple-thoughts-on-typography/</feedburner:origLink></item>
	</channel>
</rss>
