Re: Good documentation
- Posted by Shian_Lee Apr 01, 2015
- 2170 views
trig_range
include arcsin.e public type trig_range(object x)
values passed to arccos and arcsin must be in the inclusive range [-1,+1]
arcsin
include arcsin.e public function arcsin(trig_range x)
returns an angle in a right triangle given its sine.
Arguments:
- trig_range : an atom or a sequence of atomic items; each value is a trig_range ratio.
Returns:
An object, the same shape as trig_range, each atom is an angle measured in radians.
Errors:
The arcsin function requires arguments in the inclusive [ -1..1 ] range; a typecheck error occurs otherwise.
Comments:
/| hypotenuse c/ | a opposite /__| A b adjacent angle The right triangle abc
The arcsin (angle in radians) is the inverse function of the sin (ratio of a/c ) function .
The argument to the arcsin function must be in the inclusive range of -1 to +1 .
The return value is an angle, measured in radians, in the inclussive range of -PI/2 to +PI/2 .
The arcsin may be applied to an atom or to all atomic items in a sequence.
Note:
The arcsin function is not as fast as the arctan function.
Example 1:
s = arcsin({-1,0,1}) ? s --> {-1.570796327, 0, 1.570796327} include std/mathcon.e ? PI/2 --> 1.570796327
Example 2:
In the right triangle
/| hypotenuse 5/ | 4 opposite /__| A 3 adjacent angle The right triangle abc
the sine of A is opposite/hypotenuse. Given the ratio 4/5, what is the angle A in radians?
include std/math.e atom r = arcsin( 4/5 ) ? r --> 0.927295218 r = rad2deg(r) ? r --> 53.13010235
See Also:
That's it! That's what I meant! The basic knowledge. Not more then this!
Till now I cannot use arcsin without Wikipedia...
From your new example and description I can see what arcsin is all about.
Shian.