[Rd] Trigonometric functions (PR#7728)

Thomas Lumley tlumley at u.washington.edu
Wed Mar 16 00:08:25 CET 2005


On Wed, 16 Mar 2005 s.ruiter at ru.nl wrote:

>
> Why does
>
> asin(1)
> result in:
> 1.570796

Because the arcsin of 1 is pi/2 radians.

> and
>
> x<-sqrt(2)
> asin(x^2-1)
> result in:
> NaN

Because you can't take the arcsin of 2^2-1=3.

 	-thomas



More information about the R-devel mailing list