Difference between revisions of "SHIP:Sail:acos"

From Serious Documentation
Jump to: navigation, search
(Created page with "__NOTOC__ {{SailFuncTableStart|}}<onlyinclude> |{{SailFunc|acos}}||{{DataType|Float}}||style="text-align:center;"|v5.1.0||Returns the radians angle of a value that is in the r...")
 
Line 22: Line 22:
 
! scope="col" style="text-align:left" | Return
 
! scope="col" style="text-align:left" | Return
 
! scope="col" style="text-align:left" | {{DataType|Float}}
 
! scope="col" style="text-align:left" | {{DataType|Float}}
! scope="col" style="text-align:left" | asin(value)
+
! scope="col" style="text-align:left" | acos(value)
 
|}
 
|}
  

Revision as of 11:16, 30 September 2016

Function Returns Introduced Description
acos Float v5.1.0 Returns the radians angle of a value that is in the range of -1 to +1Badge SHIPv5.gif

See Also:

Prototype

Float acos(Float value);

Parameters/Return Value

Parameter Data Type Description
value Float the value, from range -1 to +1, to take the arccos of
Return Float acos(value)

Detailed Description

The acos() function returns the arccos of the supplied value within the range of -1 to +1. If you want to return an angle in degrees you can use toDegrees(acos(value))

Examples

Example Result Notes
toDegrees(acos(1/2)); 90
toDegrees(acos(sqrt(2)/2)); 45
toDegrees(acos(sqrt(3)/2)); 30
toDegrees(acos(2)); nan