Subject: CGAL users discussion list
List archive
- From: Efraim Fogel <>
- To:
- Subject: Re: [cgal-discuss] Another insert_curve & Arrangment problem
- Date: Sun, 01 Nov 2009 14:32:27 +0200
I wasn't able to reproduce using CGAL 3.5.
Ben Strasser wrote:
> Hello,
>
> the following Arrangement program crashes for me. What am I doing wrong?
>
> #include <CGAL/Cartesian.h>
> #include <CGAL/Arrangement_2.h>
> #include <CGAL/Arr_segment_traits_2.h>
> #include <CGAL/MP_Float.h>
> #include <CGAL/Quotient.h>
>
> typedef CGAL::Cartesian<CGAL::Quotient<CGAL::MP_Float> > Kernel;
> typedef CGAL::Point_2<Kernel> Point;
> typedef CGAL::Segment_2<Kernel> Segment;
> typedef CGAL::Ray_2<Kernel> Ray;
> typedef CGAL::Vector_2<Kernel> Vector;
> typedef CGAL::Arrangement_2<CGAL::Arr_segment_traits_2<Kernel> >
> Arrangement;
> int main(){
> Arrangement arr;
>
> CGAL::insert_curve(arr, Segment(Point(3.12834,-1.30888),
> Point(-4.09958,2.70984)));
> CGAL::insert_curve(arr, Segment(Point(3.12834,-1.30888),
> Point(-3.64611,-2.7549)));
> CGAL::insert_curve(arr, Segment(Point(3.12834,-1.30888),
> Point(-3.47212,1.66325)));
> CGAL::insert_curve(arr, Segment(Point(3.12834,-1.30888),
> Point(2.48026,0.00888205)));
> CGAL::insert_curve(arr, Segment(Point(3.12834,-1.30888),
> Point(2.44273,0.214056)));
> CGAL::insert_curve(arr, Segment(Point(3.12834,-1.30888),
> Point(0.973117,0.767958)));
> CGAL::insert_curve(arr, Segment(Point(-4.09958,2.70984),
> Point(-3.64611,-2.7549)));
> CGAL::insert_curve(arr, Segment(Point(-4.09958,2.70984),
> Point(-3.47212,1.66325)));
> CGAL::insert_curve(arr, Segment(Point(-4.09958,2.70984),
> Point(2.48026,0.00888205)));
> CGAL::insert_curve(arr, Segment(Point(-4.09958,2.70984),
> Point(5.07653,2.86381)));
> CGAL::insert_curve(arr, Segment(Point(-4.09958,2.70984),
> Point(2.44273,0.214056))); // assert fires here
> }
>
> The error message is
>
> CGAL error: assertion violation!
> Expr: new_face != old_face
> File: /usr/include/CGAL/Arrangement_2/Arrangement_2_functions.h
> Line: 3282
> Explanation:
> terminate called after throwing an instance of
> 'CGAL::Assertion_exception'
> what(): CGAL ERROR: assertion violation!
> Expr: new_face != old_face
> File: /usr/include/CGAL/Arrangement_2/Arrangement_2_functions.h
> Line: 3282
> Aborted
>
> I also tried the Exact_predicates_exact_constructions_kernel without
> GMP. The result is exactly the same.
>
> I compile with
>
> g++ -O0 foo.cpp -lCGAL -o foo
>
> my compiler version is
> g++ (Ubuntu 4.3.2-1ubuntu12) 4.3.2
>
> I am uncertain as to what my exact cgal version is as I installed it
> through the package system. The package version is
> 3.3.1-2ubuntu1 (interpid)
>
> Thanks for your time,
> Ben Strasser
--
____ _ ____ _
/_____/_) o /__________ __ //
(____ ( ( ( (_/ (_/-(-'_(/
_/
- Re: [cgal-discuss] Another insert_curve & Arrangment problem, Efraim Fogel, 11/01/2009
- <Possible follow-up(s)>
- Re: [cgal-discuss] Another insert_curve & Arrangment problem, Sylvain Pion, 11/01/2009
Archive powered by MHonArc 2.6.16.