# Need the math script to determine the X/Y Coordinate from

**URL:** <https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747>\
**Category:** Uncategorized\
**Created:** [April 19, 2002, 8:28pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747 "2002-04-19T20:28:55Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [April 19, 2002, 8:28pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747/1 "2002-04-19T20:28:55Z")

</div>

An ARC.\r\rHello ALL Math Genious!\rI need to get information on how to calculate the X/Y Coordinate of a given PIE Chart.\r\rLet’s say I have a circle Divided into 4-5 (not necessarily equal in size) Pie Charts. Now How do I calculate for the X/Y Coordinate of the Center ARC of each pie section?\r\rDid this make sense?\r\rbasically it’s a circle with a crossSection right in the middle and i want the X/Y coordinate of one of the Sections.\r\r\rThanks in Advance\r\rAngelo\r\rP.S. KUDOS to the first one with the solutions.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [April 19, 2002, 8:32pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747/2 "2002-04-19T20:32:59Z")

</div>

I’m unclear, can you draw something and post it? i don’t really understand. I know someone here (if not me) can figure it out, but I can tell what you want…🙂 sorry…

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [April 19, 2002, 8:42pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747/3 "2002-04-19T20:42:23Z")

</div>

Im trying to figure out a formula to figure out the X/Y Coordinate of a given point on a circle.\r\rI can figure out the Area of a circle pretty easy…What I want to do now is try and figure out how to track something on a particular Circular Image. \r\rAlmost like a regular clock with the Minutes and the Hours indicator, I want to be able to TRACK ANY POINT of that circle. By using the X/Y coordinate within hte AREA of that circle.\r\rI hope this helps.\r\rThanks

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [April 19, 2002, 8:50pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747/4 "2002-04-19T20:50:45Z")

</div>

I don’t understand. Maybe someone else will. Sorry. It just doesn’t make any sense to me. You are probly explaining it good enough, but I just spend 2 hours trying to fix a flash file for a friend of mine and my brain is fried.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [April 19, 2002, 8:53pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747/5 "2002-04-19T20:53:22Z")

</div>

Thanks for trying… i really appreciate it. \r\rAs always, This place is THE BEST place to get info on Flash, If it was not for this board, I would not have been able to keep my current job!\r\r\rKeep up the good work.\r\rBTW- it’s been about 2-4 months since my last posts.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [April 19, 2002, 11:57pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747/6 "2002-04-19T23:57:12Z")

</div>

i’m not sure just what you mean either, but this might get you started …\r\rremember trig?\r\rmake a movie of a largish, unfilled circle with it’s registration point at its center.\r\rwithin that movie, make a movie of a small filled circle, also with it’s registration point at its center.\r\rselect the small circle movie and put this code on it:

```auto
 \r\ronClipEvent(mouseUp){\r\r var x = _parent._xmouse;\r\r var y = _parent._ymouse;\r\r var r = _parent._width/ ((x<0) ? -2 : 2);\r\r var ang = Math.atan(y/x);\r\r _x = Math.cos(ang)*r;\r\r _y = Math.sin(ang)*r;\r\r}

```

\r\rclick away.

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [April 22, 2002, 3:52pm UTC](https://forum.kirupa.com/t/need-the-math-script-to-determine-the-x-y-coordinate-from/2747/7 "2002-04-22T15:52:12Z")

</div>

Thanks for the Reply!\r\rAs always- The best place to get your Flash answers!\r\r\rIm extremely greatful\r\r\rMike
