acos
Summary
Returns the arc cosine (or inverse cosine) of a number.
Syntax
Math.acos( number )
- number
- Required. The required number argument is a numeric expression.
Return Value
The arc cosine of the number argument, in radians.
Examples
The following code shows how to use the acos function.
var v1 = Math.acos(-1.0);
var v2 = Math.cos(-1.0);
document.write(v1);
document.write("<br/>");
document.write(v2);
// Output:
// 3.141592653589793
// 0.5403023058681398
Remarks
Applies To : Math Object
See also
Other articles
- Math.asin Function
- Math.atan Function
- Math.cos Function
- Math.sin Function
- Math.tan Function
- Math Object
Attributions
Microsoft Developer Network: Article