The atan() function in p5.js is used to calculate the inverse of tan() or arc tangent of a value ranging in between -Infinity to Infinity (exclusive) and gives result in the range of -π/2 to π/2.
Parameters: This function accepts a parameter “P” which is a value ranging from -1 to 1 and whose arc tangent is calculated.
Return Value: It returns the arc tangent of a value and its range is in between -π/2 to π/2.
Below program illustrates the atan() function in p5.js:
Example: This example uses atan() function to get arc tangent of a value.
- PHP | atan( ) Function
- How to get the function name inside a function in PHP ?
- PHP | Ds\Map xor() Function
- p5.js | str() function
- p5.js | value() Function
- PHP | Ds\Map put() Function
- PHP | exp() Function
- p5.js | hex() function
- PHP | dir() Function
- PHP | each() Function
- p5.js | nf() Function
- p5.js | nfs() Function
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.