bugGNU Octave - Bugs: bug #61690, Behavior of sum() with empty inputs

 
 

bug #61690: Behavior of sum() with empty inputs

Submitted by:  Guillaume <gyom>
Submitted on:  Fri 17 Dec 2021 02:23:58 PM UTC  
 
Category:  Octave Function Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Matlab Compatibility
Status:  None Assigned to:  None
Originator Name:  guillaume Open/Closed:  Open
Release:  dev Operating System:  Any

Add a New Comment (Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Fri 17 Dec 2021 02:23:58 PM UTC, original submission:  

There is a difference between Octave and Matlab with sum() when the first input is empty and a dimension is provided:

Octave:

octave:1> sum([])
ans = 0
octave:2> sum([],1)
ans = 0

Matlab:

>> sum([])
ans =
     0
>> sum([],1)
ans =
  1x0 empty double row vector

Guillaume <gyom>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by gyom (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    No changes have been made to this item

    Back to the top


    Powered by Savane 3.7