<?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>Ersin Er</title>
	<atom:link href="http://ersiner.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://ersiner.net</link>
	<description>Computer Scientist &#38; Software Engineer</description>
	<lastBuildDate>Thu, 06 Oct 2011 15:50:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>TAOCP by Knuth are quite something to read</title>
		<link>http://ersiner.net/2011/10/06/taocp-by-knuth-are-quite-something-to-read/</link>
		<comments>http://ersiner.net/2011/10/06/taocp-by-knuth-are-quite-something-to-read/#comments</comments>
		<pubDate>Thu, 06 Oct 2011 15:50:39 +0000</pubDate>
		<dc:creator>ersiner</dc:creator>
				<category><![CDATA[English Posts]]></category>
		<category><![CDATA[algorithms]]></category>
		<category><![CDATA[books]]></category>
		<category><![CDATA[knuth]]></category>
		<category><![CDATA[taocp]]></category>

		<guid isPermaLink="false">http://ersiner.net/?p=80</guid>
		<description><![CDATA[It&#8217;s been almost one year since I wrote my last blog post. I hope to write more frequently in the future on topics like in this post. About one month ago I received my copy of The Art of Computer Programming, &#8230; <a href="http://ersiner.net/2011/10/06/taocp-by-knuth-are-quite-something-to-read/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><em>It&#8217;s been almost one year since I wrote my <a title="Case Mapping for Turkish in Haskell" href="http://ersiner.net/2010/09/27/case-mapping-for-turkish-in-haskell/">last blog post</a>. I hope to write more frequently in the future on topics like in this post.</em></p>
<p>About one month ago I received my copy of<a href="http://www.amazon.com/Art-Computer-Programming-Combinatorial-Algorithms/dp/0201038048"> The Art of Computer Programming, Volume 4A: Combinatorial Algorithms, Part 1</a> by <a href="http://www-cs-faculty.stanford.edu/~uno/">Donald Knuth</a> from Amazon. I wasn&#8217;t expecting to read it from cover to cover but I wanted to see what Knuth&#8217;s work look like because there are very hot discussions on the Internet about whether Knuth&#8217;s work are <a href="http://stackoverflow.com/questions/36746/the-art-of-computer-programming-what-can-i-get-from-reading-the-lot">worth reading</a>. Knuth himself also has <a href="http://markharrison.net/stackoverflow/knuth/">joined</a> one of such <a href="http://stackoverflow.com/questions/13222/how-many-people-actually-read-the-art-of-computer-programming-books">discussions</a>.</p>
<p>The first thing I noticed when I opened the book was that some pages were really math-heavy. It was a frightening first contact. However when I tried to read some parts I saw that it was not that <em>bad</em> and most of the stuff was explained in plain English and most mathematical stuff belong to proofs of given theorems. On the other hand the volume I got was particularly interesting for me because it&#8217;s about a useful, fun and challenging topic, <em><a href="http://en.wikipedia.org/wiki/Combinatorics">Combinatorial Algorithms</a></em> which Knuth himself also states as <em>&#8220;The kind of programming I like best&#8221;</em>.</p>
<p>A few days after I got the book (what a coincidence!) I needed an algorithm for finding combinations (of <em>m</em>) of integers whose sum was equal to a given number <em>n</em>. The algorithm I needed was <em><a href="http://en.wikipedia.org/wiki/Partition_(number_theory)">Integer Partitioning</a></em> which I was able to discover thanks to the extended index at the end of the book (and Google of course). I just put the book nearby and implemented the algorithm in Java even without understanding it completely; it was a quite straightforward process.</p>
<p>I am now a happier developer as I have been able to utilize Knuth&#8217;s work for a real world case :-)</p>
<p>I may write more about the algorithm-to-Java transformation process later as it was also an interesting experience.</p>
<p>Finally, greetings to my colleague, Derya Susman who shared this joyful experience with me ;-)</p>
]]></content:encoded>
			<wfw:commentRss>http://ersiner.net/2011/10/06/taocp-by-knuth-are-quite-something-to-read/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Case Mapping for Turkish in Haskell</title>
		<link>http://ersiner.net/2010/09/27/case-mapping-for-turkish-in-haskell/</link>
		<comments>http://ersiner.net/2010/09/27/case-mapping-for-turkish-in-haskell/#comments</comments>
		<pubDate>Mon, 27 Sep 2010 00:49:38 +0000</pubDate>
		<dc:creator>ersiner</dc:creator>
				<category><![CDATA[English Posts]]></category>
		<category><![CDATA[haskell]]></category>
		<category><![CDATA[i18n]]></category>

		<guid isPermaLink="false">http://ersiner.net/?p=9</guid>
		<description><![CDATA[Turkish is generally challenging for i18n related software particularly because of its special case for the I, ı, İ, i letters. The problem is discussed in detail here. Haskell has recently got complete support for various Unicode services through text &#8230; <a href="http://ersiner.net/2010/09/27/case-mapping-for-turkish-in-haskell/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Turkish is generally challenging for i18n related software particularly because of its special case for the <em>I</em>, <em>ı</em>, <em>İ</em>, <em>i</em> letters. The problem is discussed in detail <a href="http://www.i18nguy.com/unicode/turkish-i18n.html">here</a>.</p>
<p>Haskell has recently got complete support for various Unicode services through <a href="http://hackage.haskell.org/package/text">text</a> and <a href="http://hackage.haskell.org/package/text-icu">text-icu</a> packages. Some recent updates to <a href="http://www.serpentine.com/blog/2010/09/01/major-version-of-the-haskell-text-library-0-8-0-0">text</a> and <a href="http://www.serpentine.com/blog/2010/09/10/updated-icu-bindings-for-haskell-0-4-0-0">text-icu</a> are explained in the <a href="http://www.serpentine.com/blog/">author&#8217;s blog</a>.</p>
<p>The following is a Haskell code snippet which shows an example of case mapping for Turkish using the mentioned packages.</p>
<div class="codecolorer-container haskell dawn codecolorer-noborder" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:100%;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br /></div></td><td><div class="haskell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #06c; font-weight: bold;">import</span> Data<span style="color: #339933; font-weight: bold;">.</span>Text <span style="color: green;">&#40;</span>pack<span style="color: #339933; font-weight: bold;">,</span> unpack<span style="color: green;">&#41;</span><br />
<span style="color: #06c; font-weight: bold;">import</span> Data<span style="color: #339933; font-weight: bold;">.</span>Text<span style="color: #339933; font-weight: bold;">.</span>ICU <span style="color: green;">&#40;</span>LocaleName<span style="color: green;">&#40;</span>Locale<span style="color: green;">&#41;</span><span style="color: #339933; font-weight: bold;">,</span> toLower<span style="color: green;">&#41;</span><br />
<br />
main <span style="color: #339933; font-weight: bold;">=</span> <span style="color: #06c; font-weight: bold;">do</span><br />
&nbsp; <span style="color: #06c; font-weight: bold;">let</span> trLocale <span style="color: #339933; font-weight: bold;">=</span> Locale <span style="background-color: #3cb371;">&quot;tr-TR&quot;</span><br />
&nbsp; <span style="color: #06c; font-weight: bold;">let</span> upStr <span style="color: #339933; font-weight: bold;">=</span> <span style="background-color: #3cb371;">&quot;ÇIİĞÖŞÜ&quot;</span><br />
&nbsp; <span style="color: #06c; font-weight: bold;">let</span> lowStr <span style="color: #339933; font-weight: bold;">=</span> unpack <span style="color: #339933; font-weight: bold;">$</span> toLower trLocale <span style="color: #339933; font-weight: bold;">$</span> pack upStr<br />
&nbsp; <span style="font-weight: bold;">putStrLn</span> <span style="color: #339933; font-weight: bold;">$</span> <span style="background-color: #3cb371;">&quot;toLower &quot;</span> <span style="color: #339933; font-weight: bold;">++</span> upStr <span style="color: #339933; font-weight: bold;">++</span> <span style="background-color: #3cb371;">&quot; gives &quot;</span> <span style="color: #339933; font-weight: bold;">++</span> lowStr</div></td></tr></tbody></table></div>
<p>The program simply outputs (as expected):</p>
<div class="codecolorer-container text dawn codecolorer-noborder" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:100%;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">toLower ÇIİĞÖŞÜ gives çıiğöşü</div></td></tr></tbody></table></div>
<p>Perhaps one thing that needs to be explained regarding this code is that <em>pack</em> and <em>unpack</em> are used there for converting from String to Text and vise-versa as required by the packages we use.</p>
<p>Although the code is a little bit imperative (well, I am new to Haskell ;-) ) it should give an idea of how to use the functionality for Turkish or any other language or locale.</p>
]]></content:encoded>
			<wfw:commentRss>http://ersiner.net/2010/09/27/case-mapping-for-turkish-in-haskell/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>First Post</title>
		<link>http://ersiner.net/2010/09/27/first-post/</link>
		<comments>http://ersiner.net/2010/09/27/first-post/#comments</comments>
		<pubDate>Sun, 26 Sep 2010 23:55:26 +0000</pubDate>
		<dc:creator>ersiner</dc:creator>
				<category><![CDATA[English Posts]]></category>

		<guid isPermaLink="false">http://ersiner.net/?p=7</guid>
		<description><![CDATA[&#8230; is here.]]></description>
			<content:encoded><![CDATA[<p>&#8230; is here.</p>
]]></content:encoded>
			<wfw:commentRss>http://ersiner.net/2010/09/27/first-post/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>İlk Gönderi</title>
		<link>http://ersiner.net/2010/09/27/ilk-gonderi/</link>
		<comments>http://ersiner.net/2010/09/27/ilk-gonderi/#comments</comments>
		<pubDate>Sun, 26 Sep 2010 23:55:03 +0000</pubDate>
		<dc:creator>ersiner</dc:creator>
				<category><![CDATA[Türkçe Gönderiler]]></category>

		<guid isPermaLink="false">http://ersiner.net/?p=5</guid>
		<description><![CDATA[&#8230; burada.]]></description>
			<content:encoded><![CDATA[<p>&#8230; burada.</p>
]]></content:encoded>
			<wfw:commentRss>http://ersiner.net/2010/09/27/ilk-gonderi/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

