[R] Subject: Re: BUG: atan(1i) / 5 = NaN+Infi ?
Duncan Murdoch
murdoch@dunc@n @end|ng |rom gm@||@com
Thu Sep 12 17:21:02 CEST 2024
On 2024-09-12 11:08 a.m., Jonathan Dushoff wrote:
>> In this case, I do think we should look into the consequences of
>> indeed distinguishing
>> <double> * <complex>
>> <complex> * <double> and
>> <complex> / <double>
>> from their respective current {1. coerce to complex, 2. use complex arith}
>> arithmetic.
>
> I'm wondering whether – if this indeed gets opened up – it might also
> make sense to calculate <double> x / <complex> y using real arithmetic
> (as x*y / |y|²)
That's not the correct formula, is it? I think the result should be x *
Conj(y) / Mod(y)^2 . So that would involve <double> * <complex> and
<complex> / <double>, not just real arithmetic.
Duncan Murdoch
More information about the R-help
mailing list