BB___ASN

=ASN= toc

Description
> This function returns the arc sine of the given number or expression. > The result is expressed in **radians**. > The opposite is the SIN function.

Syntax

 * 1) ASN(//Number//)

Hints

 * 1) ASN(//Number//) defined only for -1<=//Number//<=1 (otherwise, you'll get "out of range" error).
 * 2) Most mathematical operations in Just BASIC can be performed on Literal Numbers, Numeric Variables, or Numeric Expressions that consist of Literal Numbers, Numeric Variables, or both.
 * 3) There are 2 * pi radians in a full circle of 360 degrees. A formula to convert degrees to radians is: radians = degrees divided by 57.29577951.

Example
code format="lb" Print ASN(1) Print ASN(0.5) Print ASN(-0.2) Print ASN(-1/2) End code

Calculate PI
code format="lb" Function pi 'return the value of PI   pi = Asn(1) * 2 End Function code

Radians to Degrees
code format="lb" Function rad2deg(num) 'returns the given radians as degrees rad2deg = 90 / Asn(1) * num End Function code

Degrees to Radians
code format="lb" Function deg2rad(num) 'returns the given degrees as radians deg2rad = Asn(1) / 90 * num End Function code