Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

triangulation

34 views
Skip to first unread message

Shi Mu

unread,
Nov 9, 2005, 7:14:22 AM11/9/05
to Salvatore, pytho...@python.org
is there any sample code to triangulation? many thanks!

Robert Kern

unread,
Nov 9, 2005, 7:47:18 AM11/9/05
to pytho...@python.org
Shi Mu wrote:
> is there any sample code to triangulation? many thanks!

Triangulation of what? Scattered points in a plane? 2D manifolds
embedded in a 3D space?

Delaunay triangulations? Constrained triangulations?

--
Robert Kern
rk...@ucsd.edu

"In the fields of hell where the grass grows high
Are the graves of dreams allowed to die."
-- Richard Harter

Shi Mu

unread,
Nov 9, 2005, 1:29:12 PM11/9/05
to Robert Kern, pytho...@python.org

Kristian Zoerhoff

unread,
Nov 9, 2005, 1:38:52 PM11/9/05
to Shi Mu, pytho...@python.org, Robert Kern
On 11/9/05, Shi Mu <samrobe...@gmail.com> wrote:
> Delaunay triangulations
>
> On 11/9/05, Robert Kern <rober...@gmail.com> wrote:
> > Shi Mu wrote:
> > > is there any sample code to triangulation? many thanks!
> >
> > Triangulation of what? Scattered points in a plane? 2D manifolds
> > embedded in a 3D space?
> >
> > Delaunay triangulations? Constrained triangulations?

Googling "delaunay triangulation python" gives this as the first hit:

http://www.python.org/pypi/Delny/0.1.0a2

--
Kristian

kristian.zoerhoff(AT)gmail.com
zoerhoff(AT)freeshell.org

Jorgen Grahn

unread,
Nov 9, 2005, 4:12:05 PM11/9/05
to
On Wed, 9 Nov 2005 04:14:22 -0800, Shi Mu <samrobe...@gmail.com> wrote:
> is there any sample code to triangulation? many thanks!

Don;t know if this is what you're looking for, but I have some code here:

http://www.algonet.se/~jgrahn/comp/projects/geese-1.6.tar.gz

find(neighbors)

Find a (x, y) coordinate of a point, based on a sequence of (x, y, d) -
neighbor coordinates and their individual distances from the desired
point.

It's completely unsupported, and probably sucks badly. But it works for my
purposes, and there are unit tests.

/Jorgen

--
// Jorgen Grahn <jgrahn@ Ph'nglui mglw'nafh Cthulhu
\X/ algonet.se> R'lyeh wgah'nagl fhtagn!

Robert Kern

unread,
Nov 9, 2005, 5:45:55 PM11/9/05
to pytho...@python.org
Shi Mu wrote:
> Delaunay triangulations

Besides Delny, which runs the external program qhull to do its
calculations, I've recently written a package for scipy that uses Steve
Fortune's sweep-line code to calculate Delaunay triangulations. I don't
think there are any public implementations of Delaunay triangulation in
pure Python, though, if that's what you want. You can easily find more
sample code in other languages by googling.

http://svn.scipy.org/svn/scipy/branches/newscipy/Lib/sandbox/delaunay/

Shi Mu

unread,
Nov 10, 2005, 4:44:25 PM11/10/05
to Alex Hunsley, pytho...@python.org
On 11/10/05, Alex Hunsley <la...@tardis.ed.ac.uk> wrote:
> Alan Gauld wrote:
>
> >>As in Pythagoras?
> >>
> >>
> >
> >
> >
> >>Or as in triangulation on a 2D surface, navigation etc.?
> >>
> >>
> >
> >
> >
> >>Or, do you mean radio triangulation by directional signal propagation
> >>
> >>
> >
> >
> >
> >>Or, do you mean drawing a triangle in Tkinter?
> >>
> >>
> >
> >Or even triangulation of currency from EU currency to EU currency
> >via the euro?
> >
> >See:
> >http://www.sysmod.com/eurofaq.htm#Triangulation
> >
> >Alan G.
> >
> >
> This Shi Mu character is a little frustrating. They won't even respond
> to peoples polite responses for clarification....
> Hit'n'run help requests.
>
>
>
the Internet is down for one day and so wonderful to have so many
responses. i have checked all the links you guys mentioned. what i
want is delaunay triangulation and the available ones online are
written in C, Java and FORTRAN. I want to see some in Python because
it is hard for me to figure out using python to do Fortune's sweeping
line algorithm. Is python is not good in doing that kind of
computation or some other reason?
Thanks a lot for all of your responses!!!

Robert Kern

unread,
Nov 10, 2005, 5:37:33 PM11/10/05
to pytho...@python.org
Shi Mu wrote:

> the Internet is down for one day and so wonderful to have so many
> responses. i have checked all the links you guys mentioned. what i
> want is delaunay triangulation and the available ones online are
> written in C, Java and FORTRAN. I want to see some in Python because
> it is hard for me to figure out using python to do Fortune's sweeping
> line algorithm. Is python is not good in doing that kind of
> computation or some other reason?

I know someone once mentioned that they tried writing one of the
Delaunay triangulation algorithms in pure Python and abandoned it for
being unusably slow.

0 new messages