# Calculate x,y line terminiating point of section of a circle

I have a Cartesian plane running from -41 to 41 on the x and y axes and a circle centered on 0,0 with a radius of 41 divided up into a number of sections of different areas. I know the percentage area of each section (ie: section 1 is 16.1% of the total area of the circle, section 2 is 13% of the total circle, etc -- think pie chart).

I need to calculate the x and y coordinates of the circumference points for each of the dividing lines of the section.

I am trying to programatically draw a 'pie chart' by dividing the circle into a number of points on he circumference from 0,0.

Here is my calculated data:

-
Are you given that the first section begins at $(41,0)$? It seems like unless you are given some starting point, the solution set would be closed under rotations. –  A.E Jul 1 '13 at 17:50
By section, you mean sector right? –  OmerPT Jul 1 '13 at 17:51
@Orangutango The first section begins at 0,41 –  Art Jul 1 '13 at 17:52
Do you have knowledge of Trigonometry? because your question is pretty simple and the basic trigonometric functions are exactly what you need. –  OmerPT Jul 1 '13 at 17:53
@OmerPT I did about 20 years ago and have been trying to recall based off of posts on here. From what I could gather, if i could find the angle of each section, the cos(angle) = x and the sin(angle) = y. I attempted to multiple the percentage of each sector times 360, since there are 360 degress in a circle. I figured that each one of these would be the individual angle of the sector, and I could add all of the previous angles to get the current total angle –  Art Jul 1 '13 at 17:57

The angle represented by each percentage is just that percentage multiplied by $2 \pi$. So if the first sector starts at $(41,0)$, horizontal to the left, and we go clockwise, the terminating point for that sector is $(41 \cos (0.161\cdot 2 \pi), -41 \sin (0.161\cdot 2 \pi)) \approx (21.75,-34.75)$, where the minus sign comes from going clockwise instead of counterclockwise. The total angle of sectors $1$ and $2$ is then $0.291$ of the circle, so the ending point will be $(41 \cos (0.291\cdot 2 \pi), -41 \sin (0.291\cdot 2 \pi))\approx(-10.45,-39.58)$