asin
This page explains how to use the asin function in APL.
Use the asin function in APL to compute the arc sine (inverse sine) of a numeric expression. The function returns the angle, in radians, whose sine equals the input value. The input must be in the range [-1, 1]; values outside this range return null.
asin is useful when you work with normalized ratios or rates and need to map them to angular values. For example, you can use asin to encode success or error rates as phase angles for cyclic signal analysis.
Usage
Syntax
APL
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
x | real | Yes | A real number in the range [-1, 1]. |
Returns
- The arc sine of
xin radians, in the range [-π/2, π/2]. nullifx< -1 orx> 1.
Example
Use asin to compute the arcsine of a value and return the angle in radians.
Query
Output
| result |
|---|
| 0.5236 |
List of related functions
- acos: Returns the arc cosine. Use it when the cosine encoding is more appropriate for your data.
- atan: Returns the arc tangent. Use it when the input isn't bounded to [-1, 1].
- sin: Returns the sine. Use it to apply the forward transformation before using
asinas the inverse. - radians: Converts degrees to radians. Use it if your angle data is in degrees before passing it to
asin. - degrees: Converts radians to degrees. Use it to convert the
asinresult into degrees.