Re: [Rd] Trigonometric functions (PR#7728)

From: Thomas Lumley <tlumley_at_u.washington.edu>
Date: Tue 15 Mar 2005 - 23:08:25 GMT

On Wed, 16 Mar 2005 s.ruiter@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



R-devel@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Wed Mar 16 11:20:48 2005

This archive was generated by hypermail 2.1.8 : Mon 20 Feb 2006 - 03:21:01 GMT