bugGNU Octave - Bugs: bug #51560, [octave-forge] (communications)...


bug #51560: [octave-forge] (communications) Wrong dimension in pskmod.m output

Submitted by:  Roland Baudin <roland65>
Submitted on:  Mon 24 Jul 2017 03:05:49 PM UTC  
Category: Octave Forge PackageSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Incorrect Result
Status: NoneAssigned to: None
Originator Name: Open/Closed: Open
Release: 4.2.1Operating System: Any

Add a New Comment(Rich Markup)

You are not logged in

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


Wed 02 Aug 2017 09:14:55 PM UTC, comment #1:

no files attached?

I did try the fix and it works fine for both vector and matrix input for d. It does throw an error for nD vectors where transpose is not defined. matlab's pskmod is odd though for ndim>2. (the help only specifies vectors and matrices so I guess that's fair.) for a 10x1x2 input, the output is 10x1x2. But for a 1x10x2 input, the output gets concatenated to 20x1. I'm thinking venturing into undocumented matlab there negates the need for compatibility, but it might be nice if Octave's version was consistent for nD>2...

Nicholas Jankowski <nrjank>
Mon 24 Jul 2017 03:05:49 PM UTC, original submission:

The dimensions of the pskmod output matrix should be the same as the input. This is not true when the input is a column vector. Then the output is a line vector.

Example to reproduce the bug:

d = randint (10, 1, 4); % d is 10 x 1
y = pskmod (d, 4, pi/4); % y is 1 x 10 instead of 10 x 1

To fix the issue, I simply added the lines:

if (size(x,2) == 1)
y = y.';

just before the endfunction line in the pskmod.m code.

The fixed function is attached.

Roland Baudin <roland65>


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

Attach File(s):

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 jwe (Updated the item)
  • -unavailable- added by nrjank (Posted a comment)
  • -unavailable- added by roland65 (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):



    Follows 1 latest change.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 12 Aug 2017 12:35:29 AM UTCjweSummaryWrong dimension in pskmod.m output (communications package)=>[octave-forge] (communications) Wrong dimension in pskmod.m output

    Back to the top

    Powered by Savane 3.1-cleanup1