Languages
[Edit]
EN

Java - Math.acos() method example

3 points
Created by:
Warren-X
443

The Math.acos function returns number in radians in the range 0 to Math.PI. Based on this function we are able to calculate the inverted cosine function value.

 Another way to look at acos function:


1. Documentation

Edit
Syntax

Note: Classes in the java.lang package are imported automatically, so it is not necessary to do it manually - we use just Math.acos() call.

Parameters

number - double value that represents the result of the operation adjacent / hypotenuse on the right triangle.

number should be in the range -1 to +1.

Result

number value in radians in the range 0 to Math.PI (primitive value).

If the value can not be calculated NaN is returned.

Description

acos is a static method that takes only one parameter and returns an approximation of the result of the mathematical function arccosine(x).

2. Working with degrees

Edit

References

Edit
  1. Inverse trigonometric functions - Wikipedia

1
Donate to Dirask
Our content is created by volunteers - like Wikipedia. If you think, the things we do are good, donate us. Thanks!
Join to our subscribers to be up to date with content, news and offers.

Java - Math object

Native Advertising
🚀
Get your tech brand or product in front of software developers.
For more information Contact us
Dirask - we help you to
solve coding problems.
Ask question.

❤️💻 🙂

Join