arctand function
Author |
Message |
sashman
|
Posted: Sat Apr 23, 2005 10:03 am Post subject: arctand function |
|
|
i'm trying to calculate the tan of an angle in a program i'm making, but the only function in turing is arctan and arctand, but those are just inverse tan. arctand would give me the angle, but i already have the angle. What i need is the calculate the tan of an angle.
e.g. arctand (root(3)) = 60
what i need is tan (60) = root(3)
is ther a function in turing that's simply tan, or do i have to do make some wierd combination. thanks for your help. |
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
Cervantes
![](http://compsci.ca/v3/uploads/user_avatars/1023105758475ab2e040bde.jpg)
|
Posted: Sat Apr 23, 2005 10:28 am Post subject: (No subject) |
|
|
Turing 4.0.5 has tan and tand. I'm not sure, but I seem to remember something about previous versions having tan, just that it's not documented.
Anyways, here's some math:
tan (theta) = sin (theta) / cos (theta)
sin (theta) = y/r
cos (theta) = x/r
sin (theta) / cos (theta) = (y/r) / (x/r) = (y/r) * (r/x) = y/x = tan (theta) |
|
|
|
|
![](images/spacer.gif) |
sashman
|
Posted: Sat Apr 23, 2005 10:54 am Post subject: (No subject) |
|
|
sweeet it works. thanks for the help |
|
|
|
|
![](images/spacer.gif) |
|
|