Subject: CGAL users discussion list
List archive
- From: Narusaki <>
- To:
- Subject: [cgal-discuss] Dual edge of Apollonius Graph
- Date: Tue, 17 Feb 2015 20:32:26 -0800 (PST)
Hi everyone,
I'm totally new to CGAL and recently I want to use the Apollonius Graph in
the library to construct the weighted Voronoi diagram under CGAL 4.5 and
Microsoft Visual Studio 2010. For the rendering purpose I define a stream
class whose main part is the operator<< with Segment_2 as parameter, and I
use it as the parameter of the draw_dual_edge() method of the
Apollonius_graph_2 class. However, I found the weird thing as follow:
If I use the following two sites (in the format of (x, y, w) where x and y
are coordinates and w is weight):
(0.80410481369434716 0.89234204587973531 0)
(0.064896832669279911 -0.51119635852810019 -0.72435163677780512)
in which case the diagram should be a hyperbola, it shows like three rays as
follow:
<http://cgal-discuss.949826.n4.nabble.com/file/n4660456/p3.png>
if I multiple each x, y and w by 10^4, it shows as follow, with a reasonable
hyperbola and an extra ray:
<http://cgal-discuss.949826.n4.nabble.com/file/n4660456/p1.png>
Now I have two questions:
1. I don't know too much about this but I guess it's sth about the accuracy.
Here I'm just using the double type as follow:
typedef double NT;
typedef CGAL::Simple_cartesian<NT> K;
I try to use the MP_float type, the draw_dual_edge() method of
Apollonius_graph_2 seems to have some compiling error with the division(/)
operator as follow:
error C2676: binary '/' : 'CGAL::MP_Float' does not define this operator or
a conversion to a type acceptable to the predefined operator
So is it an accuracy issue and what should I do about it?
2. Why there is an extra ray starting from the center of this branch of
hyperbola?
--
View this message in context:
http://cgal-discuss.949826.n4.nabble.com/Dual-edge-of-Apollonius-Graph-tp4660456.html
Sent from the cgal-discuss mailing list archive at Nabble.com.
- [cgal-discuss] Dual edge of Apollonius Graph, Narusaki, 02/18/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Narusaki, 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Narusaki, 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Narusaki, 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Narusaki, 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Olivier Devillers, 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Narusaki, 02/20/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Narusaki, 02/19/2015
- Re: [cgal-discuss] Dual edge of Apollonius Graph, Sebastien Loriot (GeometryFactory), 02/19/2015
Archive powered by MHonArc 2.6.18.