##### Personal tools
You are here: Home Sunflower Assignment
« September 2020 »
September
SuMoTuWeThFrSa
12345
6789101112
13141516171819
20212223242526
27282930

# Sunflower Assignment

### CGAL Availability and Installation

You can obtain the latest CGAL public release from here.
The Window installer for Boost can be obtained from here. The entire collection of version 1.47.0 can obtained from here.
The CGAL installation manual is available here.
A LiveCD with CGAL 4.0 is available at http://uploading.com/files/ae8bd87b/cgal-4-livecd-ubuntu-10.04-desktop-i386.iso/. (I'll try to move it to a local place next week.)

### Clarification

• Reflecting a counterclockwise-winding Fibonacci spiral arc about any line containing the spiral source-point results with a clockwise-winding spiral arc. In particular, obtain a clockwise-winding arc by reflecting the corresponding counterclockwise-winding arc about the line x+y=0.
• Let c1,c2,... denote the circular arcs that sequentially compose a Fibonacci spiral. Set the source point of the spiral to be the bottom right corner of the square bounding c1.
• The last argument, ε, of the second program indicates an error bound. It is given as two integers, a and b, such that ε = a/b.
• Instead of using the CGAL free function rational_rotation_approximation() to obtain a rotation the sine and cosine of the angle of which can be represented as rational numbers, you may use the Aff_transformation_2 construct of CGAL, and in particular its constructor of approximates rotations.
• Observe that both, rational_rotation_approximation() and Aff_transformation_2() , accepts a direction, say d(x,y) as one of their arguments. Suppose that you need to rotate a point by the angle a = (2*Π/fn)*i for some i > 0.You may compute d = (cos(a),sin(a)) using machine double floating-point arithmetic, and bound the error of the sine and cosine of the rotation angle with respect to the sine and cosine of the angle defined by d (and not with respect to the sine and cosine of a).
• The output points should include end-points and points that split the spirals into x-monotone sub-curves. However, duplications should be avoided.
• You may assume that the constructed clockwise-winding spiral arcs are pairwise disjoint except perhaps at the origin; the same holds for the counterclockwise-winding spiral arcs.

### Test Case

Input
Output
5 2 1 5 2 1 5 1 1000 85 0.01 0.01
4 10 1 4 10 1 10 1 1000
27127 8.11 1.00

### Submission

Prepare short text that explains how to run the program, what files are you submitting, a short description of the alg. and the implementation, and put your name and id on it. If it's hard printed, give it to Danny or bring it to me. If it's electronically, add it to an archive of all files. Send the archive to efifogel@gmail.com via email.