JavaScript Math atan() methodThe JavaScript math atan() method returns the arctangent of the given number in the form of radians. The value returned by atan() method lies between -Math.PI/2 to Math.PI/2. SyntaxThe atan() method is represented by the following syntax: Parameternum - A number. ReturnThe arctangent of the number. JavaScript Math atan() method exampleHere, we will understand atan() method through various examples. Example 1Let's see a simple example of atan() method. Test it NowOutput: -0.7853981633974483 0 0.4636476090008061 0.7853981633974483 Example 2Let's see an example of atan() method that contains infinity as an argument. Test it NowOutput: 1.5707963267948966 -1.5707963267948966 Example 3Here, you can test atan() method with your own test cases. Test it Now
Next TopicJavaScript Math
|
JavaTpoint offers too many high quality services. Mail us on h[email protected], to get more information about given services.
JavaTpoint offers college campus training on Core Java, Advance Java, .Net, Android, Hadoop, PHP, Web Technology and Python. Please mail your requirement at [email protected].
Duration: 1 week to 2 week