We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexSuggestions & BugsWebsite,  Documentation,  Book Bugs › 'atan()' complete reference
Page Index Toggle Pages: 1
'atan()' complete reference (Read 1675 times)
'atan()' complete reference
Apr 20th, 2005, 11:35pm
 
I don't know if I should be reporting bugs about the Complete Reference, anyway, I guess it doesn't hurt.

Three changes to be made in the reference for atan():
- in the Examples remove the angleMode(DEGREES) line
- in the Description remove the sentence about the angleMode
- in the Parameters: -1 and 1 -> -Infinity and Infinity (both excluded)

http://processing.org/reference/atan_.html

Quote:
Examples                

float a = PI/3;
float t = tan(a);
float at = atan(t);
// Prints "1.0471976 : 1.7320509 : 1.0471976"
println(a + " : " + t + " : " +  at);


float a = PI + PI/3.0;
float t = tan(a);
float at = atan(t);
// Prints "4.1887903 : 1.7320513 : 1.0471977"
println(a + " : " + t + " : " +  at);


angleMode(DEGREES);
float a = 30;
float t = tan(a);
float at = atan(t);
// Prints "30.0 : 0.57735026 : 30.0"
println(a + " : " + t + " : " +  at);


Description               The inverse of tan(), returns the arc tangent of a value. This function expects the values in the range of -Infinity to Infinity (exclusive) and values are returned in the range -PI/2 to PI/2 or from -90 to 90 depending on the current angle mode.
             
Syntax              

atan(value)

             
Parameters              
value               float: numbers between -1 and 1
Re: 'atan()' complete reference
Reply #1 - Apr 21st, 2005, 1:39am
 
yes, please let me know about all errors in all references. thank you for the detail.

i found similar bugs in asin(), acos(), cos(), sin() and tan(). all fixed now.
Page Index Toggle Pages: 1