[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #53397] Delaunay returns inconsistent (cw/ccw)
From: |
jsh |
Subject: |
[Octave-bug-tracker] [bug #53397] Delaunay returns inconsistent (cw/ccw) orientations in 2d |
Date: |
Tue, 20 Mar 2018 21:48:33 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:59.0) Gecko/20100101 Firefox/59.0 |
URL:
<http://savannah.gnu.org/bugs/?53397>
Summary: Delaunay returns inconsistent (cw/ccw) orientations
in 2d
Project: GNU Octave
Submitted by: jsh
Submitted on: Wed 21 Mar 2018 01:48:31 AM UTC
Category: Octave Function
Severity: 3 - Normal
Priority: 5 - Normal
Item Group: Matlab Compatibility
Status: None
Assigned to: None
Originator Name:
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: 4.2.2
Operating System: Any
_______________________________________________________
Details:
In Octave the delaunay/delaunayn function calls returns inconsistent (both
clockwise and counter-clockwise) orientations in 2d, while Matlab seems to
return only counter-clockwise oriented triangulations:
p = [0 0;1 0;1 1;0 1;.5 .5]
t = delaunay( p );
d12 = p(t(:,2),:) - p(t(:,1),:);
d13 = p(t(:,3),:) - p(t(:,1),:);
a = ( d12(:,1).*d13(:,2) - d12(:,2).*d13(:,1) )/2;
is_clockwise = a<0
This can easily be fixed in post triangulation with
t(is_clockwise,2:3) = t(is_clockwise,[3,2]);
but it could be good to make it consistent and built-in by default.
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?53397>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-bug-tracker] [bug #53397] Delaunay returns inconsistent (cw/ccw) orientations in 2d,
jsh <=