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

<channel>
	<title>What I Learned Today &#187; programming</title>
	<atom:link href="http://christiansons.net/mike/blog/tag/programming/feed/" rel="self" type="application/rss+xml" />
	<link>http://christiansons.net/mike/blog</link>
	<description>Mike Christianson&#039;s journal of Java, Ant, SVN, Jetty, cygwin and other stuff.</description>
	<lastBuildDate>Wed, 04 Aug 2010 22:24:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Processing, week 3</title>
		<link>http://christiansons.net/mike/blog/2009/03/processing-week-3/</link>
		<comments>http://christiansons.net/mike/blog/2009/03/processing-week-3/#comments</comments>
		<pubDate>Wed, 11 Mar 2009 16:09:16 +0000</pubDate>
		<dc:creator>Mike Christianson</dc:creator>
				<category><![CDATA[processing]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://blog.christiansons.net/?p=298</guid>
		<description><![CDATA[It&#8217;s been a week and a half since my Processing, week 2 post and I&#8217;m still not done with chapter four, &#8220;Time Series.&#8221; Oh, well. I&#8217;ve been noticing that my Processing programs use a lot of CPU &#8212; about 35% on my dual-core, 2 GHz machine. And that&#8217;s for a program which just displays static [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a week and a half since my <a href="http://christiansons.net/2009/02/processing-week-2/">Processing, week 2 post</a> and I&#8217;m still not done with chapter four, &#8220;Time Series.&#8221;  Oh, well.</p>
<p>I&#8217;ve been noticing that my Processing programs use a lot of CPU &#8212; about 35% on my dual-core, 2 GHz machine.  And that&#8217;s for a program which just displays static data, like the one below.<span id="more-298"></span></p>
<p style="border: thin dashed;">Update: thanks to a helpful suggestion, I was able to decrease CPU usage significantly.  To find out how, read the <a href="#comments">comments section</a>.</p>
<p><applet code="sketch_mar09a.class" archive="/mike/blog/wp-content/uploads/2009/03/sketch_mar09a.jar" width="600" height="400"><br />
Oops, your browser does not have a Java Plug-in. <a href="http://java.sun.com/products/plugin/downloads/index.html" title="Download Java Plug-in">Get the latest Java Plug-in here.</a> Or, if you have Java but can&#8217;t use the Plug-in, feel free to download the <a href="http://christiansons.net/mike/blog/wp-content/uploads/2009/03/sketch_mar09a.jar">program as an executable jar</a>.<br />
</applet></p>
<p>This program, from <a href="http://www.amazon.com/Visualizing-Data-Ben-Fry/dp/0596514557/?tag=wiltblog-20">Visualizing Data</a>, plots some US beverage consumption stats over a period of time.  Clicking anywhere within the app switches the subject beverage.</p>
<p>Unless I&#8217;m missing something, the excessive CPU usage is due to constant re-draw.  The book puts all drawing code within the <tt><a href="http://processing.org/reference/draw_.html">draw()</a></tt> method which is called repeatedly, up to 60 times per second (by default).  Setting the <tt><a href="http://processing.org/reference/frameRate_.html">frameRate()</a></tt> to 30 fps improves the matter, but only marginally.    </p>
<p>As I was putting in the reference link for <tt>draw()</tt>, I noticed the documentation indicates its continuous execution can be disabled with <tt><a href="http://processing.org/reference/noLoop_.html">noLoop()</a></tt>.  That&#8217;s great, but has the side effect of disabling key or mouse events.</p>
<p>For now I&#8217;m willing to overlook this CPU usage &#8220;problem&#8221; but I hope the book addresses it soon.  </p>
]]></content:encoded>
			<wfw:commentRss>http://christiansons.net/mike/blog/2009/03/processing-week-3/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Processing, week 2</title>
		<link>http://christiansons.net/mike/blog/2009/02/processing-week-2/</link>
		<comments>http://christiansons.net/mike/blog/2009/02/processing-week-2/#comments</comments>
		<pubDate>Sun, 01 Mar 2009 04:26:33 +0000</pubDate>
		<dc:creator>Mike Christianson</dc:creator>
				<category><![CDATA[processing]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://blog.christiansons.net/?p=265</guid>
		<description><![CDATA[Today marks the second week I have been learning Processing, a Java-based language for &#8220;program[ming] images, animation, and interactions.&#8221; In other words, I want to learn how to make useful, pretty graphics. Over the past year I had seen Processing mentioned here-and-there in various articles, but what piqued my interest was a visualization of US [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.amazon.com/Visualizing-Data-Ben-Fry/dp/0596514557/?tag=wiltblog-20"><img alt="" src="http://processing.org/img/learning/books/visualizing-data" title="Visualizing Data by Ben Fry" class="alignright" width="110" height="138" /></a>
<p>Today marks the second week I have been learning <a href="http://processing.org/">Processing</a>, a Java-based language for &#8220;program[ming] images, animation, and interactions.&#8221;  In other words, I want to learn how to make useful, pretty graphics.  <img src='http://christiansons.net/mike/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Over the past year I had seen Processing mentioned here-and-there in various articles, but what piqued my interest was a <a href="http://benfry.com/zipdecode/">visualization of US zipcodes</a>.  Check it out; it&#8217;s awesome.</p>
<p>My guide, at least for now, is <a href="http://www.amazon.com/Visualizing-Data-Ben-Fry/dp/0596514557/?tag=wiltblog-20">Visualizing Data by Ben Fry</a>.  I just completed reading the third chapter and thought I&#8217;d share an example program.<span id="more-265"></span></p>
<div id="sketch_feb28a_container">
<p>
<applet code="sketch_feb28a.class" archive="/mike/blog/wp-content/uploads/2009/02/sketch_feb28a.jar" width="600" height="400"><br />
Oops, your browser does not have a Java Plug-in. <a href="http://java.sun.com/products/plugin/downloads/index.html" title="Download Java Plug-in">Get the latest Java Plug-in here.</a> Or, if you have Java but can&#8217;t use the Plug-in, feel free to download the <a href="http://christiansons.net/mike/blog/wp-content/uploads/2009/02/sketch_feb28a.jar">program as an executable jar</a>.<br />
</applet>
</p>
</div>
<p>The above Processing program plots data on a US map.  The data are random numbers, associated with each state, which are displayed as colored circles of varying sizes.  Colors are based on sign; size based on magnitude.  Moving the mouse cursor over a circle displays the state name and the random value.</p>
<p>Obviously, this is a very simple visualization but it&#8217;s not hard to see the potential for powerful visualizations.  I&#8217;m already coming up with other data to visualize with this&#8230; such as displaying the difference between the current and average daily temperature for a state.</p>
<p>Oh, before you get to comfortable with that static graphic, click anywhere on the map.  Neat, huh?  A new random number is generated and the graphic is animated from the old value.</p>
<p>Over the course of this coming week I will read the fourth chapter, &#8220;Time Series,&#8221; about displaying data which changes over time.  I can&#8217;t wait to see what program the book will have me work on.</p>
]]></content:encoded>
			<wfw:commentRss>http://christiansons.net/mike/blog/2009/02/processing-week-2/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Eckel: six hiring points</title>
		<link>http://christiansons.net/mike/blog/2009/01/eckel-six-hiring-points/</link>
		<comments>http://christiansons.net/mike/blog/2009/01/eckel-six-hiring-points/#comments</comments>
		<pubDate>Thu, 15 Jan 2009 21:17:06 +0000</pubDate>
		<dc:creator>Mike Christianson</dc:creator>
				<category><![CDATA[career]]></category>
		<category><![CDATA[bruceeckel]]></category>
		<category><![CDATA[hiring]]></category>
		<category><![CDATA[interview]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://blog.christiansons.net/?p=40</guid>
		<description><![CDATA[Following Java Posse Roundup 2008, Bruce Eckel wrote an excellent article outlining six things that you should test for when hiring someone.  It contains the collective wisdom of the conference attendees, as articulated by Bruce, which I could not hope to improve upon. The original points are numbered, one through six, but are not listed [...]]]></description>
			<content:encoded><![CDATA[<p>Following <a href="http://www.javaposse.com/index.php?post_id=314840">Java Posse Roundup 2008</a>, Bruce Eckel wrote an excellent article outlining <a href="http://www.artima.com/weblogs/viewpost.jsp?thread=228097">six things that you should test for when hiring someone</a>.  It contains the collective wisdom of the conference attendees, as articulated by Bruce, which I could not hope to improve upon.</p>
<p>The original points are numbered, one through six, but are not listed in any particular order.  Were I to give them an order based on importance, they would be arranged as follows.</p>
<ol>
<li>Are you toxic?</li>
<li>Can you learn?  Can you solve problems?</li>
<li>Critical thinking.  Can you change?</li>
<li>Technical knowledge.</li>
</ol>
<p>Ok, I cheated; it&#8217;s hard to put them in an absolute order.  All are important and relate to each other in some manner.  All software developers &#8212; and managers thereof &#8212; should read the original!</p>
]]></content:encoded>
			<wfw:commentRss>http://christiansons.net/mike/blog/2009/01/eckel-six-hiring-points/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Facts about software engineering</title>
		<link>http://christiansons.net/mike/blog/2008/11/facts-about-software-engineering/</link>
		<comments>http://christiansons.net/mike/blog/2008/11/facts-about-software-engineering/#comments</comments>
		<pubDate>Mon, 24 Nov 2008 23:45:04 +0000</pubDate>
		<dc:creator>Mike Christianson</dc:creator>
				<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://blog.christiansons.net/?p=36</guid>
		<description><![CDATA[Robert L. Glass, in 2001, authored a collection of facts about software engineering titled Frequently Forgotten Fundamental Facts about Software Engineering.  Glass wrote: I don&#8217;t expect you to agree with all these facts; some of them might even upset you. Great! Then we can begin a dialog about which facts really are facts and which [...]]]></description>
			<content:encoded><![CDATA[<p><a title="web site of Robert L. Glass" href="http://www.robertlglass.com/about">Robert L. Glass</a>, in 2001, authored a collection of facts about software engineering titled <a href="http://www2.computer.org/portal/web/buildyourcareer/fa035">Frequently Forgotten Fundamental Facts about Software Engineering</a>.  Glass wrote:</p>
<blockquote><p>I don&#8217;t expect you to agree with all these facts; some of them might even upset you. Great! Then we can begin a dialog about which facts really are facts and which are merely figments of my vivid loyal opposition imagination!</p></blockquote>
<p>In that spirit, I have selected one each of my favorite requirement and estimation facts.</p>
<blockquote><p><strong>RD2</strong>. When a project moves from requirements to design, the solution process&#8217;s complexity causes an explosion of &#8220;derived requirements.&#8221; The list of requirements for the design phase is often 50 times longer than the list of original requirements.</p></blockquote>
<p>Indeed, suddenly a large body of previously-unknown work is materialized, complexity increases again, and the schedule doesn&#8217;t adjust (see ES2).  The knee-jerk reaction, of course, is to spend hour-after-hour and day-after-day coming up with an exhaustive list of requirements.  The process can be infinitely long (see  <a title="wikipedia: analysis paralysis" href="http://en.wikipedia.org/wiki/Analysis_paralysis">analysis paralysis</a>) and may only reach its end by artificial means.  This problem alone may be one of the strongest arguments against <a title="wikipedia: waterfall model" href="http://en.wikipedia.org/wiki/Waterfall_model">waterfall</a>-style development.</p>
<blockquote><p><strong>ES2</strong>. Most software estimates are performed at the beginning of the life cycle. This makes sense until we realize that this occurs before the requirements phase and thus before the problem is understood. Estimation therefore usually occurs at the wrong time.</p></blockquote>
<p>Another good argument against waterfall.  The risk inherent in this nearly inverse ordering is significantly reduced when software is produced in a more agile fashion.  That is to say, analyzing requirements and producing estimates iteratively allows the risk to be mitigated incrementally.</p>
]]></content:encoded>
			<wfw:commentRss>http://christiansons.net/mike/blog/2008/11/facts-about-software-engineering/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
