<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Understanding Soccer</title>
	<atom:link href="http://yaniv.leviathanonline.com/blog/math/understanding-soccer/feed/" rel="self" type="application/rss+xml" />
	<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/</link>
	<description>Strain your Brain</description>
	<lastBuildDate>Tue, 31 Aug 2010 17:39:33 -0700</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>By: sandrar</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-18448</link>
		<dc:creator>sandrar</dc:creator>
		<pubDate>Thu, 10 Sep 2009 21:52:54 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-18448</guid>
		<description>Hi! I was surfing and found your blog post... nice! I love your blog.  :) Cheers! Sandra. R.</description>
		<content:encoded><![CDATA[<p>Hi! I was surfing and found your blog post&#8230; nice! I love your blog.  <img src='http://leviathanonline.com/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  Cheers! Sandra. R.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lucas</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-16204</link>
		<dc:creator>Lucas</dc:creator>
		<pubDate>Wed, 29 Apr 2009 04:18:43 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-16204</guid>
		<description>Could you send the python source code to my e-mail?

Your post is quite perfect...

Thank you!</description>
		<content:encoded><![CDATA[<p>Could you send the python source code to my e-mail?</p>
<p>Your post is quite perfect&#8230;</p>
<p>Thank you!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: TesseractIndic @ foss.in 2008 &#171; Debayan&#8217;s Weblog</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-11641</link>
		<dc:creator>TesseractIndic @ foss.in 2008 &#171; Debayan&#8217;s Weblog</dc:creator>
		<pubDate>Wed, 15 Oct 2008 15:09:00 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-11641</guid>
		<description>[...] my intention is to implement skew removal using Hough transforms. Hough transforms are really good in finding staright lines (among other shapes) in images. So all [...]</description>
		<content:encoded><![CDATA[<p>[...] my intention is to implement skew removal using Hough transforms. Hough transforms are really good in finding staright lines (among other shapes) in images. So all [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: henry</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-9675</link>
		<dc:creator>henry</dc:creator>
		<pubDate>Wed, 09 Jul 2008 22:48:28 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-9675</guid>
		<description>i love the move and learn it every day and just  is afternoon thanks for all you have i used it today on field and is score four goal i and also a football in Nigeria in local club but one day i play like most of the world best e.g messi deco henry e.t.c</description>
		<content:encoded><![CDATA[<p>i love the move and learn it every day and just  is afternoon thanks for all you have i used it today on field and is score four goal i and also a football in Nigeria in local club but one day i play like most of the world best e.g messi deco henry e.t.c</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: free</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-399</link>
		<dc:creator>free</dc:creator>
		<pubDate>Sat, 24 Nov 2007 16:11:00 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-399</guid>
		<description>&lt;strong&gt;greatings&lt;/strong&gt;

exellent</description>
		<content:encoded><![CDATA[<p><strong>greatings</strong></p>
<p>exellent</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dog training</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-393</link>
		<dc:creator>Dog training</dc:creator>
		<pubDate>Fri, 23 Nov 2007 13:48:43 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-393</guid>
		<description>Very interesting... as always! Cheers from -Switzerland-.</description>
		<content:encoded><![CDATA[<p>Very interesting&#8230; as always! Cheers from -Switzerland-.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matan</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-42</link>
		<dc:creator>Matan</dc:creator>
		<pubDate>Sat, 09 Jun 2007 18:14:23 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-42</guid>
		<description>Okay, now I understand the algorithm (and my mistake) - I thought the input you are getting is a list of N points, each represented as a pair of coordinates (x,y), while in reality the input is an nXn grid of white and black points. The proposed algorithm (the hough duality) works for the non-discrete case, but then you&#039;d be stuck with the equaly hard dual problem of getting a list of N lines and trying to find points where maximum number of line intersect. In the discrete case, the dual problem is actually much simpler to solve than the primal problem.

Nice.</description>
		<content:encoded><![CDATA[<p>Okay, now I understand the algorithm (and my mistake) &#8211; I thought the input you are getting is a list of N points, each represented as a pair of coordinates (x,y), while in reality the input is an nXn grid of white and black points. The proposed algorithm (the hough duality) works for the non-discrete case, but then you&#8217;d be stuck with the equaly hard dual problem of getting a list of N lines and trying to find points where maximum number of line intersect. In the discrete case, the dual problem is actually much simpler to solve than the primal problem.</p>
<p>Nice.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: yoni</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-41</link>
		<dc:creator>yoni</dc:creator>
		<pubDate>Tue, 05 Jun 2007 21:08:26 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-41</guid>
		<description>first of all congratulations on the new blog.

this strange duality you described is far bigger than it seems, it goes beyond the R2 plane and into the Rn space.. 
the best thing about it is that the professor responsible for most of the developments in this field called &quot;Parallel coordinates&quot;
is teaching in TAU , his name is Alfred Inselberg and this is his page http://www.math.tau.ac.il/~aiisreal/    
there you can find for example of a sphere in 5d ...

enjoy.</description>
		<content:encoded><![CDATA[<p>first of all congratulations on the new blog.</p>
<p>this strange duality you described is far bigger than it seems, it goes beyond the R2 plane and into the Rn space..<br />
the best thing about it is that the professor responsible for most of the developments in this field called &#8220;Parallel coordinates&#8221;<br />
is teaching in TAU , his name is Alfred Inselberg and this is his page <a href="http://www.math.tau.ac.il/~aiisreal/" rel="nofollow">http://www.math.tau.ac.il/~aiisreal/</a><br />
there you can find for example of a sphere in 5d &#8230;</p>
<p>enjoy.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: yaniv</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-40</link>
		<dc:creator>yaniv</dc:creator>
		<pubDate>Tue, 05 Jun 2007 12:00:32 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-40</guid>
		<description>Hi Matan,

Thank you for your comments.

I have a little problem with the way you analysed the complexity of the algorithm: there are actually several parameters that influence the complexity: w - the number of white pixels, n - the number of lines, m - the number of pixels in the original image, and k - the number of pixels in the hough transformed image. There is a certain correlation between the values of w and n (see below).

Note that finding the intercection of the lines is much easier than what you propose, as when I draw the lines I do not color the buffer with the lines&#039; color, but rather increase the color value already in the transform image. Finding intersections of more than T lines is then as simple as running through the buffer and checking whether a given pixel has a value of more than T (this is the reason the hough images are not monochromatic).

The first step - drawing the lines, takes O(w*k&#039;) where k&#039; is the about sqrt(k) (as drawing a line in an image with k pixels takes about sqrt(k) pixel operations). Then finding the lines takes O(k).

So the total complexity comes to O(w*k&#039;)+O(k). An approximation to the relation between n and w is:
w = n*sqrt(m)
So finally we get that the total complexity is:
O(n*sqrt(m)*sqrt(k) + k)
Assuming that k is small compared to the other numbers, we get:
O(n*sqrt(m))

The naive algorithm you proposed, in these notations, takes O(w*w*w) (since going through all the pairs of points takes w*w and for each pair you have to iterate through all other points). This equals:
O(n*n*n*m*sqrt(m))
Which is much worse than the naive complexity (the ratio is like N to N*N*N).

The improvement you suggested in comment 3 is indeed very similar to the hough transform, although you still need to iterate over all PAIRS of points (and the complexity stays higher).</description>
		<content:encoded><![CDATA[<p>Hi Matan,</p>
<p>Thank you for your comments.</p>
<p>I have a little problem with the way you analysed the complexity of the algorithm: there are actually several parameters that influence the complexity: w &#8211; the number of white pixels, n &#8211; the number of lines, m &#8211; the number of pixels in the original image, and k &#8211; the number of pixels in the hough transformed image. There is a certain correlation between the values of w and n (see below).</p>
<p>Note that finding the intercection of the lines is much easier than what you propose, as when I draw the lines I do not color the buffer with the lines&#8217; color, but rather increase the color value already in the transform image. Finding intersections of more than T lines is then as simple as running through the buffer and checking whether a given pixel has a value of more than T (this is the reason the hough images are not monochromatic).</p>
<p>The first step &#8211; drawing the lines, takes O(w*k&#8217;) where k&#8217; is the about sqrt(k) (as drawing a line in an image with k pixels takes about sqrt(k) pixel operations). Then finding the lines takes O(k).</p>
<p>So the total complexity comes to O(w*k&#8217;)+O(k). An approximation to the relation between n and w is:<br />
w = n*sqrt(m)<br />
So finally we get that the total complexity is:<br />
O(n*sqrt(m)*sqrt(k) + k)<br />
Assuming that k is small compared to the other numbers, we get:<br />
O(n*sqrt(m))</p>
<p>The naive algorithm you proposed, in these notations, takes O(w*w*w) (since going through all the pairs of points takes w*w and for each pair you have to iterate through all other points). This equals:<br />
O(n*n*n*m*sqrt(m))<br />
Which is much worse than the naive complexity (the ratio is like N to N*N*N).</p>
<p>The improvement you suggested in comment 3 is indeed very similar to the hough transform, although you still need to iterate over all PAIRS of points (and the complexity stays higher).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matan</title>
		<link>http://yaniv.leviathanonline.com/blog/math/understanding-soccer/comment-page-1/#comment-37</link>
		<dc:creator>Matan</dc:creator>
		<pubDate>Tue, 05 Jun 2007 08:22:28 +0000</pubDate>
		<guid isPermaLink="false">http://yaniv.leviathanonline.com/blog/math/understanding-soccer/#comment-37</guid>
		<description>Some comments:

1) The suggested algorithm&#039;s compleixty is O(n^2), since you will get in the dual plane n lines and you&#039;ll have to check their intersection

2) The naive algorithm for the original problem takes O(n^3) - you can find the line equation of each pair of points, and then go over all the other points and check if they fall on this line

3) You can easily modify the naive algorithm to be O(n^2) - for example, create a hash that maps line equations to a counter. For every pair of points, create the line equation, search for it in the hash, and increment the counter.

4) In general, the problem of finding intersection points of the lines is exactly the same. It&#039;s naive algorithm would also take O(n^3) because for every pair of lines you&#039;d have to check how many other lines intersect with the same point. You&#039;d have to modify this naive algorithm a bit to find those points in O(n^2). This is a nice algorithm, since it makes a reduction from a problem involving points to a problem involving lines (there are many other examples for this phenomena in Computational Geometry and some of them are much more suprising) In general, since these reductions are very simple, you can always eventually just trivially map the algorithm that works in the dual plane into an equivalent algorithm for solving the primal (original) problem. (and give up the &quot;duality&quot; step of the algorithm)</description>
		<content:encoded><![CDATA[<p>Some comments:</p>
<p>1) The suggested algorithm&#8217;s compleixty is O(n^2), since you will get in the dual plane n lines and you&#8217;ll have to check their intersection</p>
<p>2) The naive algorithm for the original problem takes O(n^3) &#8211; you can find the line equation of each pair of points, and then go over all the other points and check if they fall on this line</p>
<p>3) You can easily modify the naive algorithm to be O(n^2) &#8211; for example, create a hash that maps line equations to a counter. For every pair of points, create the line equation, search for it in the hash, and increment the counter.</p>
<p>4) In general, the problem of finding intersection points of the lines is exactly the same. It&#8217;s naive algorithm would also take O(n^3) because for every pair of lines you&#8217;d have to check how many other lines intersect with the same point. You&#8217;d have to modify this naive algorithm a bit to find those points in O(n^2). This is a nice algorithm, since it makes a reduction from a problem involving points to a problem involving lines (there are many other examples for this phenomena in Computational Geometry and some of them are much more suprising) In general, since these reductions are very simple, you can always eventually just trivially map the algorithm that works in the dual plane into an equivalent algorithm for solving the primal (original) problem. (and give up the &#8220;duality&#8221; step of the algorithm)</p>
]]></content:encoded>
	</item>
</channel>
</rss>
