<?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"
	>
<channel>
	<title>Comments for joeldg - navigating the surface</title>
	<atom:link href="http://blog.peoplesdns.com/comments/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.peoplesdns.com</link>
	<description>all the stuff that doesn't get posted elsewhere</description>
	<pubDate>Sat, 31 Jul 2010 05:38:11 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5</generator>
		<item>
		<title>Comment on mysql latitude/longitude radius by joeldg</title>
		<link>http://blog.peoplesdns.com/archives/24#comment-30668</link>
		<dc:creator>joeldg</dc:creator>
		<pubDate>Thu, 19 Nov 2009 00:40:15 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/?p=24#comment-30668</guid>
		<description>My friend came up with this:

set log_bin_trust_function_creators=TRUE;
DROP FUNCTION IF EXISTS GeoDist;
DELIMITER &#124;
CREATE FUNCTION GeoDist( lat1 FLOAT, lon1 FLOAT, lat2 FLOAT, lon2 FLOAT ) RETURNS float
BEGIN
  DECLARE pi, q1, q2, q3 FLOAT;
  DECLARE rads FLOAT DEFAULT 0;
  SET pi = PI();
  SET lat1 = lat1 * pi / 180;
  SET lon1 = lon1 * pi / 180;
  SET lat2 = lat2 * pi / 180;
  SET lon2 = lon2 * pi / 180;
  SET q1 = COS(lon1-lon2);
  SET q2 = COS(lat1-lat2);
  SET q3 = COS(lat1+lat2);
  SET rads = ACOS( 0.5*((1.0+q1)*q2 - (1.0-q1)*q3) ); 
  RETURN 3963.1676 * rads;
END;
&#124;
DELIMITER ;</description>
		<content:encoded><![CDATA[<p>My friend came up with this:</p>
<p>set log_bin_trust_function_creators=TRUE;<br />
DROP FUNCTION IF EXISTS GeoDist;<br />
DELIMITER |<br />
CREATE FUNCTION GeoDist( lat1 FLOAT, lon1 FLOAT, lat2 FLOAT, lon2 FLOAT ) RETURNS float<br />
BEGIN<br />
  DECLARE pi, q1, q2, q3 FLOAT;<br />
  DECLARE rads FLOAT DEFAULT 0;<br />
  SET pi = PI();<br />
  SET lat1 = lat1 * pi / 180;<br />
  SET lon1 = lon1 * pi / 180;<br />
  SET lat2 = lat2 * pi / 180;<br />
  SET lon2 = lon2 * pi / 180;<br />
  SET q1 = COS(lon1-lon2);<br />
  SET q2 = COS(lat1-lat2);<br />
  SET q3 = COS(lat1+lat2);<br />
  SET rads = ACOS( 0.5*((1.0+q1)*q2 - (1.0-q1)*q3) );<br />
  RETURN 3963.1676 * rads;<br />
END;<br />
|<br />
DELIMITER ;</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on mysql latitude/longitude radius by Roland</title>
		<link>http://blog.peoplesdns.com/archives/24#comment-30601</link>
		<dc:creator>Roland</dc:creator>
		<pubDate>Wed, 01 Apr 2009 09:58:32 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/?p=24#comment-30601</guid>
		<description>here's a fix for the distance:

select asciiname,latitude,longitude, (3963.191 * ACOS(
(SIN(PI()* 40.7383040 /180)*SIN(PI()*latitude/180)) +
(COS(PI()* 40.7383040 /180)*cos(PI()*latitude/180)*COS(PI() * longitude/180-PI()* -73.99319 /180))
)) AS distance
FROM allcountries
WHERE 1=1
AND 3963.191 * ACOS( (SIN(PI()* 40.7383040 /180)*SIN(PI() * latitude/180)) +
(COS(PI()* 40.7383040 /180)*cos(PI()*latitude/180)*COS(PI() * longitude/180-PI()* -73.99319 /180))
) &#60; = 1.5
ORDER BY 3963.191 * ACOS(
(SIN(PI()* 40.7383040 /180)*SIN(PI()*latitude/180)) +
(COS(PI()* 40.7383040 /180)*cos(PI()*latitude/180)*COS(PI() * longitude/180-PI()* -73.99319 /180))
)

works like a charm, thanks for posting this joeldg!</description>
		<content:encoded><![CDATA[<p>here&#8217;s a fix for the distance:</p>
<p>select asciiname,latitude,longitude, (3963.191 * ACOS(<br />
(SIN(PI()* 40.7383040 /180)*SIN(PI()*latitude/180)) +<br />
(COS(PI()* 40.7383040 /180)*cos(PI()*latitude/180)*COS(PI() * longitude/180-PI()* -73.99319 /180))<br />
)) AS distance<br />
FROM allcountries<br />
WHERE 1=1<br />
AND 3963.191 * ACOS( (SIN(PI()* 40.7383040 /180)*SIN(PI() * latitude/180)) +<br />
(COS(PI()* 40.7383040 /180)*cos(PI()*latitude/180)*COS(PI() * longitude/180-PI()* -73.99319 /180))<br />
) &lt; = 1.5<br />
ORDER BY 3963.191 * ACOS(<br />
(SIN(PI()* 40.7383040 /180)*SIN(PI()*latitude/180)) +<br />
(COS(PI()* 40.7383040 /180)*cos(PI()*latitude/180)*COS(PI() * longitude/180-PI()* -73.99319 /180))<br />
)</p>
<p>works like a charm, thanks for posting this joeldg!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on mysql latitude/longitude radius by forever in your debt</title>
		<link>http://blog.peoplesdns.com/archives/24#comment-30573</link>
		<dc:creator>forever in your debt</dc:creator>
		<pubDate>Sun, 15 Feb 2009 00:45:07 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/?p=24#comment-30573</guid>
		<description>thanks for the great info!

I was looking, like others, for this exact same thing.  Quite a lifesaver!</description>
		<content:encoded><![CDATA[<p>thanks for the great info!</p>
<p>I was looking, like others, for this exact same thing.  Quite a lifesaver!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on mysql latitude/longitude radius by Paul Tesar</title>
		<link>http://blog.peoplesdns.com/archives/24#comment-30571</link>
		<dc:creator>Paul Tesar</dc:creator>
		<pubDate>Mon, 02 Feb 2009 11:50:37 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/?p=24#comment-30571</guid>
		<description>Great post, saved me a lot of time and trouble! 
Many thanks for that!!</description>
		<content:encoded><![CDATA[<p>Great post, saved me a lot of time and trouble!<br />
Many thanks for that!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on 3d engines, reviews, first impressions and irritation by NicoeEchaniz</title>
		<link>http://blog.peoplesdns.com/archives/69#comment-25590</link>
		<dc:creator>NicoeEchaniz</dc:creator>
		<pubDate>Thu, 24 Jul 2008 10:25:14 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/archives/69#comment-25590</guid>
		<description>Hi Joel,

I wanted to point out that PyOgre has a successor: python-ogre[1]. It seems to be a very active project that not only wraps Ogre but other useful stuff also.

Another engine worth mentioning in the Python world is soya3d[2]. Though not as complete, stable or well documented it is simple yet quite powerful.

I must also say that what I most liked about Panda, which sets it aside from other options is the complete documentation (targeted at Python programmers from the start).

Lastly I wanted to thank you for taking the time to write those gentoo ebuilds[3] for panda3d and I wanted to let you know that I renamed the 1.5.0 ebuild to 1.5.2 and it worked just fine.


Thanks for your work,

Lwcyphr


[1]http://www.python-ogre.org
[2]href="http://home.gna.org/oomadness/en/soya3d/index.html
[3]http://bugs.gentoo.org/show_bug.cgi?id=144259</description>
		<content:encoded><![CDATA[<p>Hi Joel,</p>
<p>I wanted to point out that PyOgre has a successor: python-ogre[1]. It seems to be a very active project that not only wraps Ogre but other useful stuff also.</p>
<p>Another engine worth mentioning in the Python world is soya3d[2]. Though not as complete, stable or well documented it is simple yet quite powerful.</p>
<p>I must also say that what I most liked about Panda, which sets it aside from other options is the complete documentation (targeted at Python programmers from the start).</p>
<p>Lastly I wanted to thank you for taking the time to write those gentoo ebuilds[3] for panda3d and I wanted to let you know that I renamed the 1.5.0 ebuild to 1.5.2 and it worked just fine.</p>
<p>Thanks for your work,</p>
<p>Lwcyphr</p>
<p>[1]http://www.python-ogre.org<br />
[2]href=&#8221;http://home.gna.org/oomadness/en/soya3d/index.html<br />
[3]http://bugs.gentoo.org/show_bug.cgi?id=144259</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on 3d engines, reviews, first impressions and irritation by NicoeEchaniz</title>
		<link>http://blog.peoplesdns.com/archives/69#comment-25589</link>
		<dc:creator>NicoeEchaniz</dc:creator>
		<pubDate>Thu, 24 Jul 2008 10:22:12 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/archives/69#comment-25589</guid>
		<description>Hi Joel,

I wanted to point out that PyOgre has a successor: &lt;a href="http://www.python-ogre.org" title="python-ogre" rel="nofollow"&gt;python-ogre&lt;/a&gt;. It seems to be a very active project that not only wraps Ogre but other useful stuff also.

Another engine worth mentioning in the Python world is &lt;a href="http://home.gna.org/oomadness/en/soya3d/index.html" title="soya3d" rel="nofollow"&gt;soya3d&lt;/a&gt;. Though not as complete, stable or well documented it is simple yet quite powerful.

I must also say that what I most liked about Panda, which sets it aside from other options is the complete documentation (targeted at Python programmers from the start).

Lastly I wanted to thank you for taking the time to write those &lt;a href="http://bugs.gentoo.org/show_bug.cgi?id=144259" title="gentoo ebuilds" rel="nofollow"&gt;gentoo ebuilds&lt;/a&gt; for panda3d and I wanted to let you know that I renamed the 1.5.0 ebuild to 1.5.2 and it worked just fine.</description>
		<content:encoded><![CDATA[<p>Hi Joel,</p>
<p>I wanted to point out that PyOgre has a successor: <a href="http://www.python-ogre.org" title="python-ogre" rel="nofollow">python-ogre</a>. It seems to be a very active project that not only wraps Ogre but other useful stuff also.</p>
<p>Another engine worth mentioning in the Python world is <a href="http://home.gna.org/oomadness/en/soya3d/index.html" title="soya3d" rel="nofollow">soya3d</a>. Though not as complete, stable or well documented it is simple yet quite powerful.</p>
<p>I must also say that what I most liked about Panda, which sets it aside from other options is the complete documentation (targeted at Python programmers from the start).</p>
<p>Lastly I wanted to thank you for taking the time to write those <a href="http://bugs.gentoo.org/show_bug.cgi?id=144259" title="gentoo ebuilds" rel="nofollow">gentoo ebuilds</a> for panda3d and I wanted to let you know that I renamed the 1.5.0 ebuild to 1.5.2 and it worked just fine.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on 3d engines, reviews, first impressions and irritation by NicoeEchaniz</title>
		<link>http://blog.peoplesdns.com/archives/69#comment-25588</link>
		<dc:creator>NicoeEchaniz</dc:creator>
		<pubDate>Thu, 24 Jul 2008 10:21:07 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/archives/69#comment-25588</guid>
		<description>Hi Joel,

I wanted to point out that PyOgre has a successor: &lt;a href="http://www.python-ogre.org" title="python-ogre" rel="nofollow"&gt;python-ogre&lt;/a&gt;. It seems to be a very active project that not only wraps Ogre but other useful stuff also.

Another engine worth mentioning in the Python world is &lt;a href="http://home.gna.org/oomadness/en/soya3d/index.html" title="soya3d" rel="nofollow"&gt;soya3d&lt;/a&gt;. Though not as complete, stable or well documented it is simple yet quite powerful.

I must also say that what I most liked about Panda, which sets it aside from other options is the complete documentation (targeted at Python programmers from the start).

Lastly I wanted to thank you for taking the time to write those &lt;a href="http://bugs.gentoo.org/show_bug.cgi?id=144259" title="gentoo ebuilds" rel="nofollow"&gt;gentoo ebuilds&lt;/a&gt; for panda3d and I wanted to let you know that I renamed the 1.5.0 ebuild to 1.5.2 and it worked just fine. Check the gentoo bug page for minor modification needed to be able to import direct.

Thanks for your work.

NicEchaniz</description>
		<content:encoded><![CDATA[<p>Hi Joel,</p>
<p>I wanted to point out that PyOgre has a successor: <a href="http://www.python-ogre.org" title="python-ogre" rel="nofollow">python-ogre</a>. It seems to be a very active project that not only wraps Ogre but other useful stuff also.</p>
<p>Another engine worth mentioning in the Python world is <a href="http://home.gna.org/oomadness/en/soya3d/index.html" title="soya3d" rel="nofollow">soya3d</a>. Though not as complete, stable or well documented it is simple yet quite powerful.</p>
<p>I must also say that what I most liked about Panda, which sets it aside from other options is the complete documentation (targeted at Python programmers from the start).</p>
<p>Lastly I wanted to thank you for taking the time to write those <a href="http://bugs.gentoo.org/show_bug.cgi?id=144259" title="gentoo ebuilds" rel="nofollow">gentoo ebuilds</a> for panda3d and I wanted to let you know that I renamed the 1.5.0 ebuild to 1.5.2 and it worked just fine. Check the gentoo bug page for minor modification needed to be able to import direct.</p>
<p>Thanks for your work.</p>
<p>NicEchaniz</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on pics of me.. by Jesse</title>
		<link>http://blog.peoplesdns.com/pics-of-me#comment-25488</link>
		<dc:creator>Jesse</dc:creator>
		<pubDate>Tue, 22 Jul 2008 22:03:17 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/pics-of-me/#comment-25488</guid>
		<description>Hi, Joel!! Nice to see you. :)</description>
		<content:encoded><![CDATA[<p>Hi, Joel!! Nice to see you. <img src='http://blog.peoplesdns.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on pics of me.. by harryb</title>
		<link>http://blog.peoplesdns.com/pics-of-me#comment-25483</link>
		<dc:creator>harryb</dc:creator>
		<pubDate>Tue, 22 Jul 2008 19:38:43 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/pics-of-me/#comment-25483</guid>
		<description>Hi,
I'm building a moboile photo app where users can upload their pic to their blog from cell phone. I'm trying to add GPS data to that pic. But then many phones don't support GPS. I read your blog about fining location via radio towers. Would be interested in helping us?</description>
		<content:encoded><![CDATA[<p>Hi,<br />
I&#8217;m building a moboile photo app where users can upload their pic to their blog from cell phone. I&#8217;m trying to add GPS data to that pic. But then many phones don&#8217;t support GPS. I read your blog about fining location via radio towers. Would be interested in helping us?</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on about by john cring</title>
		<link>http://blog.peoplesdns.com/about#comment-21187</link>
		<dc:creator>john cring</dc:creator>
		<pubDate>Mon, 19 May 2008 21:55:05 +0000</pubDate>
		<guid isPermaLink="false">http://blog.peoplesdns.com/about/#comment-21187</guid>
		<description>Hey, I came across your post on querying a db for coordinates within a pre-determined radius. Is there any way to covert the distance variable into miles so I can show how far away each matching result is from the given coordinates?</description>
		<content:encoded><![CDATA[<p>Hey, I came across your post on querying a db for coordinates within a pre-determined radius. Is there any way to covert the distance variable into miles so I can show how far away each matching result is from the given coordinates?</p>
]]></content:encoded>
	</item>
</channel>
</rss>
