bugGNU Octave - Bugs: bug #66266, (communications) polyval cannot...

 
 

bug #66266: (communications) polyval cannot take Galois class in octave 10

Submitter:  Dmitri A. Sergatskov <dasergatskov>
Submitted:  Fri 27 Sep 2024 06:27:08 PM UTC
   
 
Category:  Octave Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Unexpected Error or Warning
Status:  None Assigned to:  None
Originator Name:  Open/Closed:  * Open
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Thu 03 Oct 2024 06:46:31 PM UTC, comment #3: 

I added a Galois-specific polyval function and uncommented the tests in comms accordingly. This will be part of the next package minor release.

Nir Krakauer <nir_krakauer>
Wed 02 Oct 2024 05:41:45 PM UTC, comment #2: 

The Communications manual says "Other Octave functions work correctly with Galois Fields and so overloaded
versions are not necessary. This include such functions as size and polyval."

Clearly, this is no longer the case. The culprit could be http://hg.savannah.gnu.org/hgweb/octave/rev/23523700b6b8 ("polyval.m:  ...Use isfloat to require that inputs be floating point numeric (Matlab compatibility)."), or maybe an earlier change to polyval.

For now I commented out the failing tests in comms. In the longer term, it would be nice to have an overloaded version of polyval for Galois field inputs.

Nir Krakauer <nir_krakauer>
Fri 27 Sep 2024 07:14:30 PM UTC, comment #1: 

I verified that this does not work back to version 8.4.0.
Essentially, the problem is due to the check:


octave:1> pkg load communications
octave:2> poly1 = gf ([2, 4, 5, 1], 3)
poly1 =
GF(2^3) array. Primitive Polynomial = D^3+D+1 (decimal 11)

Array elements =

   2   4   5   1

octave:3> isfloat(poly1)
ans = 0


Which seems to be unnecessary since "poly1" can be operated as usual array.

Dmitri.
--

Dmitri A. Sergatskov <dasergatskov>
Fri 27 Sep 2024 06:27:08 PM UTC, original submission:  

Running "test comms" in octave 10 and with hg snapshot of communications I see:


polyval: P must be a numeric floating point vector


This occur at

y0 = polyval (poly1, x0);

and perhaps later in

ck1 = polyval (poly1, roots1);


"poly1" is a Galois field array:

octave:5> poly1 = gf ([2, 4, 5, 1], 3)
poly1 =
GF(2^3) array. Primitive Polynomial = D^3+D+1 (decimal 11)

Array elements =

   2   4   5   1

octave:6> whos poly1
Variables visible from the current scope:

variables in scope: top scope

  Attr   Name        Size                     Bytes  Class
  ====   ====        ====                     =====  =====
         poly1       1x4                         16  galois

Total is 4 elements using 16 bytes


Apparently the code worked before, but not anymore.
Not sure what have changed and what is the proper fix.

Dmitri.
--

Dmitri A. Sergatskov <dasergatskov>

 

(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 nir_krakauer (Posted a comment)
  • -email is unavailable- added by dasergatskov (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    No changes have been made to this item

    Back to the top

    Powered by Savane 3.14-f13d.
    Corresponding source code