atan(t) function quadrant issues, atan2(x,y) not an option
2 views (last 30 days)
Show older comments
1) Is there a command in matlab to find the reflex angle?
I can write a script to do it but I would hope a function already exists. Something along these lines:
angle = 500
500/360 = 1.3889
360*0.3889 = 140.0040
1.1) The "atan(t)" function does not properly work for angles in quadrants other then the first one. Matlab has the "atan2(x,y)" function for that but lets say we are working with angles only and don't know "x" or "y" or "hypotenuse", and since we don't know the "quadrant" either we can't really use "asin(t)" or "acos(t)" or "atan(t)" to find them; paradox as that's what we want in the first place.
I am writing a script right now to basically compute the reflex angle then figure out what quadrant it's in then add either "nothing" or "pi" or "2pi" to "atan(t)" to get the appropriate "atan(t)" angle value.
I was really hoping a function that does all this already exists in matlab as it seems pretty rudimentary. Anyone know if it actually exists?
Thanks
0 Comments
Accepted Answer
More Answers (0)
See Also
Categories
Find more on Logical in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!