<?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>Blog Without An Important Name &#187; Science</title>
	<atom:link href="http://www.kallisti.net.nz/blog/category/science/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.kallisti.net.nz/blog</link>
	<description>I am not an IP address! I am a free 'blog!</description>
	<lastBuildDate>Mon, 22 Jun 2009 05:02:52 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Thesis Submitted!</title>
		<link>http://www.kallisti.net.nz/blog/2009/05/thesis-submitted/</link>
		<comments>http://www.kallisti.net.nz/blog/2009/05/thesis-submitted/#comments</comments>
		<pubDate>Tue, 26 May 2009 13:15:00 +0000</pubDate>
		<dc:creator>Robin</dc:creator>
				<category><![CDATA[Artificial Intelligence]]></category>
		<category><![CDATA[eMusic/J]]></category>

		<guid isPermaLink="false">http://www.kallisti.net.nz/blog/?p=88</guid>
		<description><![CDATA[I meant to post this here a while back, but kinda forgot to. Anyway, on Monday last week I finally submitted my thesis. The title is &#8220;The Impact of Representation on the Evolution of Genetic Algorithms.&#8221; Now I just need to sit back and wait until the examiners get it, mark it, and probably send [...]]]></description>
			<content:encoded><![CDATA[<p>I meant to post this here a while back, but kinda forgot to. Anyway, on Monday last week I finally submitted my thesis. The title is &#8220;The Impact of Representation on the Evolution of Genetic Algorithms.&#8221; Now I just need to sit back and wait until the examiners get it, mark it, and probably send me corrections to make prior to it being accepted. I&#8217;m going to try for the August graduation, but that is perhaps a bit too hopeful unless the marking happens faster than I expect it will.</p>
<p>Unfortunately, the plans for work I had lined up in the Netherlands didn&#8217;t pan out due to the immigration system there making it very difficult for a relatively small company to get a work permit for a foreign employee. As such, I&#8217;m still looking for work, although I have enough here to tide me over for as long as I need it. That said, I&#8217;m definitely looking to get out of Dunedin, and ideally New Zealand, in the relatively short term. So if you have any ideas, let me know!</p>
<p>For now, I have my regular work, which I&#8217;m doing fairly short hours on right now, and a contract job for Naxos (again) upgrading their version of eMusic/J to match their new requirements. It&#8217;s good work, and the improvements will flow back into the normal version. It&#8217;ll be nice to finally get another release of that out the door, it&#8217;s been on something of a hiatus while I finished the thesis.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.kallisti.net.nz/blog/2009/05/thesis-submitted/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Extension to the &#8216;Shunting Yard&#8217; algorithm to allow variable numbers of arguments to functions</title>
		<link>http://www.kallisti.net.nz/blog/2008/02/extension-to-the-shunting-yard-algorithm-to-allow-variable-numbers-of-arguments-to-functions/</link>
		<comments>http://www.kallisti.net.nz/blog/2008/02/extension-to-the-shunting-yard-algorithm-to-allow-variable-numbers-of-arguments-to-functions/#comments</comments>
		<pubDate>Sun, 17 Feb 2008 23:53:18 +0000</pubDate>
		<dc:creator>Robin</dc:creator>
				<category><![CDATA[Comp Sci]]></category>
		<category><![CDATA[Work]]></category>

		<guid isPermaLink="false">http://www.kallisti.net.nz/blog/2008/02/extension-to-the-shunting-yard-algorithm-to-allow-variable-numbers-of-arguments-to-functions/</guid>
		<description><![CDATA[Here&#8217;s something a bit more computer-sciencey than usual. For something at work, I have had to implement a function parser, so you can type &#8216;1+2*b&#8216; and it&#8217;ll work it all out, with correct operator precedence and so forth. To do this, I use a three-step process:

Tokenise the input, and at the same time convert any [...]]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s something a bit more computer-sciencey than usual. For something at work, I have had to implement a function parser, so you can type &#8216;<tt>1+2*b</tt>&#8216; and it&#8217;ll work it all out, with correct operator precedence and so forth. To do this, I use a three-step process:</p>
<ol>
<li>Tokenise the input, and at the same time convert any variables found to their numeric values</li>
<li>Convert the input tokens to RPN using the <a href="http://en.wikipedia.org/wiki/Shunting_yard_algorithm">Shunting Yard algorithm</a></li>
<li>Evaluate the RPN form of the equation using an RPN parser, which is really easy to write</li>
</ol>
<p>This did the job nicely, however the time came when it had to be extended, and able to accept functions, such as &#8216;<tt>max(1,2,3)</tt>&#8216;. The standard shunting yard algorithm can handle functions, but with the restriction that the number of arguments to them is known (really, this is a limitation of the RPN algorithm, but it&#8217;s at this point in the process that we need to deal with the problem). In this case, I wanted to handle functions with a variable number of arguments, so &#8216;<tt>max(1,2)</tt>&#8216; would work, and so would &#8216;<tt>max(1,2,3,4,5)</tt>&#8216;. To do this, I extended the standard algorithm. Below is the algorithm from Wikipedia. My additions are in <b>bold</b>. This requires two more stacks, a &#8216;<tt>were values</tt>&#8216; stack, and an &#8216;<tt>arg count</tt>&#8216; stack. It also requires that you can attach the number of arguments to an instance of a function. In my case, I did it with a small class that took the function and an argument count, with one of these created during tokenisation for each function encountered.</p>
<ul>
<li>While there are tokens to be read:</li>
</ul>
<dl>
<dd>
<ul>
<li>Read a token.</li>
<li>If the token is a number, then add it to the output queue. <b>If the <tt>were values</tt> stack has a value on it, pop it and push <tt>true</tt>.</b></li>
<li>If the token is a function token, then push it onto the stack. <b>Push 0 onto the <tt>arg count</tt> stack. If the <tt>were values</tt> stack has a value on it, pop it and push <tt>true</tt>. Push <tt>false</tt> onto <tt>were values</tt>.</b></li>
<li>If the token is a function argument separator (e.g., a comma):</li>
</ul>
<dl>
<dd>
<ul>
<li>Until the topmost element of the stack is a left parenthesis, pop the element onto the output queue. If no left parentheses are encountered, either the separator was misplaced or parentheses were mismatched. <b>Pop <tt>were values</tt> into <i>w</i>. If <i>w</i> is true, pop <tt>arg count</tt> into <i>a</i>, increment <i>a</i> and push back into <tt>arg count</tt>. Push <tt>false</tt> into <tt>were values</tt>.</b></li>
</ul>
</dd>
</dl>
<ul>
<li>If the token is an operator, o<sub>1</sub>, then:</li>
</ul>
<dl>
<dd>
<ul>
<li>while there is an operator, o<sub>2</sub>, at the top of the stack, and either</li>
</ul>
<dl>
<dd>
<dl>
<dd>
<dl>
<dd>o<sub>1</sub> is associative or left-associative and its precedence is less than (lower precedence) or equal to that of o<sub>2</sub>, or</dd>
<dd>o<sub>1</sub> is right-associative and its precedence is less than (lower precedence) that of o<sub>2</sub>,</dd>
</dl>
</dd>
<dd>pop o<sub>2</sub> off the stack, onto the output queue;</dd>
</dl>
</dd>
</dl>
<ul>
<li>push o<sub>1</sub> onto the operator stack.</li>
</ul>
</dd>
</dl>
<ul>
<li>If the token is a left parenthesis, then push it onto the stack.</li>
<li>If the token is a right parenthesis:</li>
</ul>
<dl>
<dd>
<ul>
<li>Until the token at the top of the stack is a left parenthesis, pop operators off the stack onto the output queue.</li>
<li>Pop the left parenthesis from the stack, but not onto the output queue.</li>
<li>If the token at the top of the stack is a function token
<ul>
<li><b>Pop stack into <i>f</i></b></li>
<li><b>Pop <tt>arg count</tt> into <i>a</i></b></li>
<li><b>Pop <tt>were values</tt> into <i>w</i></b></li>
<li><b>If <i>w</i> is true, increment <i>a</i></b></li>
<li><b>Set the argument count of <i>f</i> to <i>a</i></b></li>
<li><b>Push <i>f</i> onto output queue</b></li>
</ul>
</li>
<li>If the stack runs out without finding a left parenthesis, then there are mismatched parentheses.</li>
</ul>
</dd>
</dl>
</dd>
</dl>
<ul>
<li>When there are no more tokens to read:</li>
</ul>
<dl>
<dd>
<ul>
<li>While there are still operator tokens in the stack:</li>
</ul>
<dl>
<dd>
<ul>
<li>If the operator token on the top of the stack is a parenthesis, then there are mismatched parenthesis.</li>
<li>Pop the operator onto the output queue.</li>
</ul>
</dd>
</dl>
</dd>
</dl>
<ul>
<li>Exit.</li>
</ul>
<p>Note that because I didn&#8217;t feel like correctly listifying most of it, consider an <b>if</b> to apply to the end of that sentence only. Operation order is usually important.</p>
<p>With this done, the part of the <a href="http://en.wikipedia.org/wiki/Reverse_Polish_notation#The_postfix_algorithm">RPN algorithm</a> that says:<br />
<blockquote>It is known that the function takes <b>n</b> arguments.</p></blockquote>
<p> can now be satisfied.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.kallisti.net.nz/blog/2008/02/extension-to-the-shunting-yard-algorithm-to-allow-variable-numbers-of-arguments-to-functions/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>CACert points</title>
		<link>http://www.kallisti.net.nz/blog/2007/01/cacert-points/</link>
		<comments>http://www.kallisti.net.nz/blog/2007/01/cacert-points/#comments</comments>
		<pubDate>Mon, 22 Jan 2007 02:49:42 +0000</pubDate>
		<dc:creator>Robin</dc:creator>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[Sysadmin]]></category>

		<guid isPermaLink="false">http://www.kallisti.net.nz/blog/2007/01/cacert-points/</guid>
		<description><![CDATA[I now have the maximum possible number of assurance points for CACert, 150. This means two things. One is that I can now get SSL and email certificates that last two years, and the other is that I can now allocate points to others.
So if anyone who happens to be in the same place as [...]]]></description>
			<content:encoded><![CDATA[<p>I now have the maximum possible number of assurance points for <a href="https://www.cacert.org/">CACert</a>, 150. This means two things. One is that I can now get SSL and email certificates that last two years, and the other is that I can now allocate points to others.</p>
<p>So if anyone who happens to be in the same place as me (generally Dunedin, but right now various bits of Australia) wants some, they should get in touch.</p>
<p>A nice side effect is that there is now enough people in Dunedin to get another person up to the required 100 points so they can then allocate them, so the region can now bootstrap itself fairly easily.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.kallisti.net.nz/blog/2007/01/cacert-points/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Paypal sending fake-looking emails</title>
		<link>http://www.kallisti.net.nz/blog/2006/12/paypal-sending-fake-looking-emails/</link>
		<comments>http://www.kallisti.net.nz/blog/2006/12/paypal-sending-fake-looking-emails/#comments</comments>
		<pubDate>Thu, 14 Dec 2006 21:12:33 +0000</pubDate>
		<dc:creator>Robin</dc:creator>
				<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://www.kallisti.net.nz/blog/2006/12/paypal-sending-fake-looking-emails/</guid>
		<description><![CDATA[Someone at paypal doesn&#8217;t get phishing, and is sending out emails that look like they really could be scams. Not only that, but the email shouldn&#8217;t even be sent, according to the paypal preferences.
read more&#160;&#124;&#160;digg story
]]></description>
			<content:encoded><![CDATA[<p>Someone at paypal doesn&#8217;t get phishing, and is sending out emails that look like they really could be scams. Not only that, but the email shouldn&#8217;t even be sent, according to the paypal preferences.</p>
<p><a href="http://tikitu.justlol.net/wordpress/2006/12/14/fine-print-a-scam-a-shame/">read more</a>&nbsp;|&nbsp;<a href="http://digg.com/security/Paypal_sending_fake_looking_emails">digg story</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.kallisti.net.nz/blog/2006/12/paypal-sending-fake-looking-emails/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Evolutionary art</title>
		<link>http://www.kallisti.net.nz/blog/2006/05/evolutionary-art/</link>
		<comments>http://www.kallisti.net.nz/blog/2006/05/evolutionary-art/#comments</comments>
		<pubDate>Tue, 23 May 2006 04:19:34 +0000</pubDate>
		<dc:creator>Robin</dc:creator>
				<category><![CDATA[Artificial Intelligence]]></category>

		<guid isPermaLink="false">http://www.kallisti.net.nz/blog/2006/05/evolutionary-art/</guid>
		<description><![CDATA[Found on Digg:
&#8220;Once enough votes have been collected, the genetic algorithm gets to work. It picks the good images and breeds them using either mutation or crossing-over. Since the images&#8217; genes are just trees, it is simple to cross-over two of them and produce new ones.&#8221;
It&#8217;s a nice idea, similar-but-different to what I&#8217;m planning on [...]]]></description>
			<content:encoded><![CDATA[<p>Found on Digg:<br />
&#8220;Once enough votes have been collected, the genetic algorithm gets to work. It picks the good images and breeds them using either mutation or crossing-over. Since the images&#8217; genes are just trees, it is simple to cross-over two of them and produce new ones.&#8221;</p>
<p>It&#8217;s a nice idea, similar-but-different to what I&#8217;m planning on <a href="http://www.kallisti.net.nz/RobinsStuff/BiomorphLearningNeuralNetwork">trying to implement</a> one day. I&#8217;m skeptical about how well it&#8217;ll work when faced with multiple people having disparate ideas of what looks good, along with people trying to game the system a bit. But for something fun, it&#8217;s interesting. They&#8217;ve also implemented it, which is something I haven&#8217;t gotten around to yet <img src='http://www.kallisti.net.nz/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
<a href="http://artdent.homelinux.net/evolve/">the site</a> (<a href="http://artdent.homelinux.net/evolve/about/">more description</a>) | <a href="http://digg.com/design/Evolutionary_art_(vote_for_the_good_pictures)">digg story</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.kallisti.net.nz/blog/2006/05/evolutionary-art/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Coding with a LISP</title>
		<link>http://www.kallisti.net.nz/blog/2006/03/coding-with-a-lisp/</link>
		<comments>http://www.kallisti.net.nz/blog/2006/03/coding-with-a-lisp/#comments</comments>
		<pubDate>Sat, 11 Mar 2006 13:19:49 +0000</pubDate>
		<dc:creator>Robin</dc:creator>
				<category><![CDATA[Artificial Intelligence]]></category>
		<category><![CDATA[Books]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://www.kallisti.net.nz/blog/2006/03/coding-with-a-lisp/</guid>
		<description><![CDATA[A few years ago, I learnt LISP at university. Just for a semester, write a poetry generator, things like that. All pretty simple. I didn&#8217;t get into it much at the time, beyond what I had to, but I do remember thinking that it looked like quite a powerful and fun language. 
A while ago, [...]]]></description>
			<content:encoded><![CDATA[<p>A few years ago, I learnt LISP at university. Just for a semester, write a poetry generator, things like that. All pretty simple. I didn&#8217;t get into it much at the time, beyond what I had to, but I do remember thinking that it looked like quite a powerful and fun language. </p>
<p>A while ago, someone on Slashdot mentioned LISP and referred to a book that was online for learning it. So I checked it out, and it seems to be pretty good. I&#8217;m about half way through it. It has the large amount of basic instruction in the language, which is always necessary. However, after a while of that, it has a chapter on &#8216;Practical&#8217; stuff, which involves implementing actual code, which is a good change, and a nice place to read chunks of code, put them into the interpreter, and play with them a bit.</p>
<p>Normally when reading books on programming languages, I get frustrated when they start explaining &#8220;This is a variable. You can store values in them. You can also change them. &#8230;&#8221;, as it&#8217;s a concept I&#8217;ve seen over and over, and so is quite boring. This isn&#8217;t the case here, I don&#8217;t know if it&#8217;s because LISP is different enough from the languages I usually use that it seems new, or the book just manages to avoid these kinds of problems.</p>
<p>If I see it lying around (or maybe even if I don&#8217;t, and I just get paid enough one day), I think I might pick up a dead tree copy.</p>
<p>Oh, and the book itself? <a href="http://www.gigamonkeys.com/book/">Practical Common Lisp</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.kallisti.net.nz/blog/2006/03/coding-with-a-lisp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Neural Network Learning Tastes</title>
		<link>http://www.kallisti.net.nz/blog/2005/12/neural-network-learning-tastes/</link>
		<comments>http://www.kallisti.net.nz/blog/2005/12/neural-network-learning-tastes/#comments</comments>
		<pubDate>Sun, 25 Dec 2005 11:25:51 +0000</pubDate>
		<dc:creator>Robin</dc:creator>
				<category><![CDATA[Artificial Intelligence]]></category>
		<category><![CDATA[Comp Sci]]></category>
		<category><![CDATA[Science]]></category>

		<guid isPermaLink="false">http://www.kallisti.net.nz/blog/?p=7</guid>
		<description><![CDATA[A little project I&#8217;m working on at the moment: creating a neural network that will (maybe) learn the aesthetic tastes of a person.
There are two parts to this, the first creates tree-like shapes (what Richard Dawkins calls biomorphs in his book The Blind Watchmaker). Here is an online demo of these biomorphs. My version is [...]]]></description>
			<content:encoded><![CDATA[<p>A little project I&#8217;m working on at the moment: creating a neural network that will (maybe) learn the aesthetic tastes of a person.</p>
<p>There are two parts to this, the first creates tree-like shapes (what Richard Dawkins calls <i>biomorphs</i> in his book <i>The Blind Watchmaker</i>). Here is <a href="http://www.rennard.org/alife/english/biomgb.html">an online demo of these biomorphs</a>. My version is going to allow for significantly more complex biomorphs.</p>
<p>When interacting with the program, the user selects the biomorphs that they like, and that is used as the progenitor of the next batch. Mutation is then applied to these, and the set of modified versions is presented to the user to select the next &#8216;best&#8217; one.</p>
<p>The other part of this program is the neural network. It will be trained on the user&#8217;s input and selections, and after a while it will be allowed to run on its own, selecting what it thinks is the best based on its training. After running for a while (several dozen generations or so), the results will be displayed.</p>
<p>The point of this (aside from the fun of implementing it) is to see how well the neural network can pick up the &#8217;styles&#8217; that the user was going for, and thus to see if it can end up knowing what people like.</p>
<p>Here are <a href="http://www.kallisti.net.nz/RobinsStuff/BiomorphLearningNeuralNetwork">the current details on the design of this</a>. These designs are getting updated over time. Comments/suggestions/whatever are welcome.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.kallisti.net.nz/blog/2005/12/neural-network-learning-tastes/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
