[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #59890] inf+1i*inf gives nan+1i*inf
From: |
Rik |
Subject: |
[Octave-bug-tracker] [bug #59890] inf+1i*inf gives nan+1i*inf |
Date: |
Sat, 16 Jan 2021 14:34:52 -0500 (EST) |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.66 Safari/537.36 |
Follow-up Comment #5, bug #59890 (project octave):
The core piece is this statement
1i*Inf
In Octave this results in NaN + Infi, while in Matlab it is 0 + Infi. It
would seem that
(x + yi) * C = C*x + C*yi
except when x or y is zero in which case Matlab does not bother with the
multiplication.
Octave ordinarily just passes a multiplication like this down to BLAS. Either
Matlab is checking for zeros and not performing multiplications on those
values as is done for sparse matrices. Or maybe they have their own
customized version of BLAS to do this action, or maybe there is a flag to pass
to BLAS that determines how the non-finite values NaN, +Inf, -Inf are handled.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?59890>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/