<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>emre şahin's digital garden 🍃 - Computer Science</title>
    <link>https://emresahin.net/categories/computer-science/</link>
    <description>Posts in the Computer Science category</description>
    <language>en</language>
    <managingEditor>contact@emresahin.net (Emre Şahin)</managingEditor>
    <lastBuildDate>Tue, 15 Sep 2026 19:46:32 +0000</lastBuildDate>
    <atom:link href="https://emresahin.net/categories/computer-science/rss.xml" rel="self" type="application/rss+xml"/>
    <item>
      <title>Randomness Course Notes</title>
      <published>2014-02-13T14:00:00+00:00</published>
      <updated>2014-02-13T14:00:00+00:00</updated>
      <author>Emre Şahin</author>
      <pubDate>Thu, 13 Feb 2014 14:00:00 +0000</pubDate>
      <link>https://emresahin.net/randomness-course-notes/</link>
      <guid isPermaLink="true">https://emresahin.net/randomness-course-notes/</guid>
      <description>Definitions of Randomness Kolmogorov Complexity of a sequence = The shortest algorithm that produces it. Martin-Löf A sequence is random if it passes all statistical tests. It cannot be produced by a program shorter than itself. The digits of $\pi$ are not random in this sense. Not just “difficul...</description>
      <category>Computer Science</category>
      <category>Cryptography</category>
      <category>randomness</category>
      <category>algorithms</category>
      <category>complexity</category>
      <content:encoded><![CDATA[<h1 id="definitions-of-randomness">Definitions of Randomness</h1>
<h2 id="kolmogorov">Kolmogorov</h2>
<p>Complexity of a sequence = The shortest algorithm that produces it.</p>
<h3 id="martin-löf">Martin-Löf</h3>
<ul>
<li>A sequence is random if it passes all statistical tests.</li>
<li>It cannot be produced by a program shorter than itself.</li>
</ul>
<p>The digits of $\pi$ are not random in this sense.</p>
<p>Not just “difficult to compute”, there is no consistent way to define the <em>shortest algorithm</em>.</p>
<p>It’s impossible to find a way to ensure that a sequence is random. It’s similar to the halting problem in a way.</p>
<h3 id="my-idea">My Idea</h3>
<p>It might be possible to define an algorithm in terms of a Turing machine. If the instructions of a Turing machine are shorter than the sequence itself, it’s not random.</p>
<h3 id="another-idea">Another idea</h3>
<p>It says $P(b_n | s_{n-1}) = \frac{1}{2}$ for a binary sequence if the random process is ideal. But <em>expecting</em> this might be against randomness.</p>
<h1 id="pseudorandomness">Pseudorandomness</h1>
<p>Producing <em>seemingly</em> random sequences by algorithms, given a <em>secret</em> key.</p>
<p>The sequence is determined and can be inferred with high computing power. But for practical purposes, it’s random.</p>
<h1 id="uses-of-randomness">Uses of Randomness</h1>
<ul>
<li>Randomized Algorithms: When a definite algorithm is too costly, it’s possible to run randomized algorithms for e.g. checking whether a number is prime.</li>
<li>Cryptography: When a message needs to be encrypted with a secure key, the most secure way to produce a key is randomness.</li>
</ul>]]></content:encoded>
    </item>
    <item>
      <title>Paper Review: Polygonal Approximation of Digital Curves to Preserve Original Shapes</title>
      <published>2012-09-18T14:00:00+00:00</published>
      <updated>2012-09-18T14:00:00+00:00</updated>
      <author>Emre Şahin</author>
      <pubDate>Tue, 18 Sep 2012 14:00:00 +0000</pubDate>
      <link>https://emresahin.net/polygonal-approximation-of-digital-curves-lee-lee/</link>
      <guid isPermaLink="true">https://emresahin.net/polygonal-approximation-of-digital-curves-lee-lee/</guid>
      <description>Authors: Daeho Lee, Seung Gwan Lee Keywords: dominant points consecutive vectors toothbrush shape distance metric smallest perpendicular distance Q1: How usual calculation of distance is done? Minor DPs are deleted in approximation. A minor DP is a DP where the perpendicular distance between the ...</description>
      <category>Computer Science</category>
      <category>Paper Review</category>
      <category>image processing</category>
      <category>polygonal approximation</category>
      <category>digital curves</category>
      <category>shape preservation</category>
      <content:encoded><![CDATA[<h1 id="authors-daeho-lee-seung-gwan-lee">Authors: Daeho Lee, Seung Gwan Lee</h1>
<h1 id="keywords">Keywords:</h1>
<ul>
<li>dominant points</li>
<li>consecutive vectors</li>
<li>toothbrush shape</li>
<li>distance metric</li>
<li>smallest perpendicular distance</li>
</ul>
<h1 id="q1-how-usual-calculation-of-distance-is-done">Q1: How usual calculation of distance is done?</h1>
<p>Minor DPs are deleted in approximation. A minor DP is a DP where the
perpendicular distance between the point and the straight line is
minimum.</p>
<pre><code>a a
 b
</code></pre>
<p>Here <code>b</code> is deleted when its distance to the line <code>a-a</code> is minimum.</p>
<p>The perpendicular distance is calculated using</p>
<p>[ d_i = \sqrt{\frac{((x_i - x_a) (y_b - y_a) - (y_i - y_a)
(x_b -x_a))^2}{(x_a - x_b)^2 + (y_a - y_b)^2}} ]</p>
<p>for lines between points $p_a$ and $p_b$ and the point $p_i$.</p>
<h1 id="q2-what-is-a-toothbrush-shape">Q2: What is a toothbrush shape?</h1>
<p>It’s something like</p>
<pre><code>aaaaaa
bbbbbbbbbbbbbbbbbbbbbb
</code></pre>
<p>Hence the toothbrush.</p>
<p>Though I don’t get why is this particularly important.</p>
<h1 id="q3-which-information-is-included-in-distance-metric">Q3: Which information is included in distance metric?</h1>
<p>Angle acuteness is added to the information described above.</p>
<h1 id="q4-how-the-distance-metric-differs-from-others">Q4: How the distance metric differs from others?</h1>
<p>It includes angle acuteness in the metric and the more acute the angle,
the less likely it’s removed from DP set.</p>
<h1 id="q5-whats-baseline-for-performance-and-how-does-this-improve-it">Q5: What’s baseline for performance and how does this improve it?</h1>
<p>As the number of DPs decrease, RMSE of the new metric decreases. For
large number of DPs it doesn’t matter much. (So performance penalty may
not pay off)</p>]]></content:encoded>
    </item>
  </channel>
</rss>
