octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #61690] Behavior of sum() with empty inputs


From: Sarrah Bastawala
Subject: [Octave-bug-tracker] [bug #61690] Behavior of sum() with empty inputs
Date: Mon, 4 Apr 2022 18:08:06 -0400 (EDT)

Follow-up Comment #3, bug #61690 (project octave):

I have submitted a patch that resolves the bug upto my knowledge. Here are the
results after the fix:

octave:3> sum([],1)
ans = [](1x0)
octave:4> sum([],2)
ans = [](0x1)


which is clearly compatible with Matlab that shows the following results:

>> sum([],1)

ans =

  1×0 empty double row vector

>> sum([],2)

ans =

  0×1 empty double column vector


Hopefully a maintainer or mentor sees this bug and approves of the change
soon!


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?61690>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]