Purpose
Returns the arc-sine value of a number. You can call this function from the MapBasic window in MapInfo Pro.
Syntax
Asin( num_expr )
num_expr is a numeric expression from one to negative one, inclusive.
Return Value
Float
Description
The Asin() function returns the arc-sine of the numeric num_expr value. In other words, Asin() returns the angle whose sine is equal to num_expr.
The result returned from Asin() represents an angle, expressed in radians. This angle will be somewhere between -Pi/2 and Pi/2 radians (given that Pi is approximately equal to 3.141593, and given that Pi/2 radians represents 90 degrees).
To convert a degree value to radians, multiply that value by DEG_2_RAD. To convert a radian value into degrees, multiply that value by RAD_2_DEG. (Note that your program will need to Include "MAPBASIC.DEF" in order to reference DEG_2_RAD or RAD_2_DEG).
Since sine values range between one and negative one, the expression num_expr should represent a value no larger than one (1) and no smaller than negative one (-1).
Example
Include "MAPBASIC.DEF"
Dim x, y As Float
x = 0.5
y = Asin(x) * RAD_2_DEG
' y will now be equal to 30,
' since the sine of 30 degrees is 0.5
See Also:
Acos() function, Atn() function, Cos() function, Sin() function, Tan() function