bugGNU Octave - Bugs: bug #34147, hex2dec function doesn't work for...

 
 

bug #34147: hex2dec function doesn't work for cell string inputs

Submitted by:  None
Submitted on:  Sat 27 Aug 2011 09:51:09 AM UTC  
 
Category: LibrariesSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Feature Request
Status: FixedAssigned to: None
Originator Name: Diego BorroOriginator Email: -unavailable-
Open/Closed: ClosedRelease: 3.2.4
Operating System: Microsoft Windows

Add a New Comment(Rich Markup)
   

You are not logged in

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

 

Tue 20 Sep 2011 12:24:50 AM UTC, comment #4:

New feature added in this changeset (http://hg.savannah.gnu.org/hgweb/octave/rev/36afcd6fc45f). You can build from source to see the change or wait until the 3.6 release this fall.

Rik <rik5>
Project Administrator
Sat 03 Sep 2011 04:44:20 AM UTC, comment #3:

I think I have a patch for this that works on the development branch. Could you run two more tests for me against Matlab?

I'm looking to see whether the cell case also returns a column vector and how it is ordered.

Rik <rik5>
Project Administrator
Sat 27 Aug 2011 08:09:56 PM UTC, comment #2:

Yes, I can verify that the following code works perfectly in Matlab R2010a.

That's why I sent my question. I wanted to know if Octave had that functionality.

Anyway, many thanks for the quick answer. I will use what you say in Octave.

Anonymous
Sat 27 Aug 2011 01:50:15 PM UTC, comment #1:

Neither the documentation for Octave nor the documentation for Matlab (http://www.mathworks.com/help/techdoc/ref/hex2dec.html) say that hex2dec() can accept cell array of string inputs. It does accept char array inputs. For example,

Can you verify that Matlab accepts cell arrays of strings with the following code?

Rik <rik5>
Project Administrator
Sat 27 Aug 2011 09:51:09 AM UTC, original submission:

Depending on the argument, hex2dec function doesn't work properly. For example, if we put

The result is 27 (correct).

But if we use cells for introducing more than one value like in:

The result is an error:

error: binary operator `==' not implemented for `cell' by `scalar' operations
error: evaluating argument list element number 1
error: evaluating argument list element number 1
error: called from:
error: C:\Octave\3.2.4_gcc-4.4.0\share\octave\3.2.4\m\strings\strjust.m at line 51, column 5
error: C:\Octave\3.2.4_gcc-4.4.0\share\octave\3.2.4\m\strings\base2dec.m at line 74, column 3
error: C:\Octave\3.2.4_gcc-4.4.0\share\octave\3.2.4\m\strings\hex2dec.m at line 47, column 7

Anonymous

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by None (Submitted the item)
  •  

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

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 20 Sep 2011 12:24:50 AM UTCrik5StatusNeed Info=>Fixed
      Open/ClosedOpen=>Closed
    Sat 03 Sep 2011 04:44:20 AM UTCrik5StatusNone=>Need Info
    Sat 27 Aug 2011 01:50:15 PM UTCrik5Item GroupSegfault, Bus Error, etc.=>Feature Request
      Summaryhex2dec function doesn\'t work properly.=>hex2dec function doesn't work for cell string inputs

    Back to the top


    Powered by Savane 3.1-cleanup1