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

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

[Octave-bug-tracker] [bug #46514] circshift calling syntax


From: Richard
Subject: [Octave-bug-tracker] [bug #46514] circshift calling syntax
Date: Tue, 24 Nov 2015 14:03:57 +0000
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:42.0) Gecko/20100101 Firefox/42.0

URL:
  <http://savannah.gnu.org/bugs/?46514>

                 Summary: circshift calling syntax
                 Project: GNU Octave
            Submitted by: crobar
            Submitted on: Tue 24 Nov 2015 14:03:56 GMT
                Category: Octave Function
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Matlab Compatibility
                  Status: None
             Assigned to: None
         Originator Name: Richard Crozier
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 4.0.0
        Operating System: Any

    _______________________________________________________

Details:

circshift in ML supports the following calling syntax:


Y = circshift(X,K,DIM) circularly shifts along the dimension DIM.


where X is the matrix, K is a scalar integer and DIM is the dimension in which
to shift. Octave does not support it. It could probably be added by just
adding a recursive call to circshift like:


if (nargin == 3)
  if isscalar (n)
    k = zeros (1,dim);
    k(dim) = n;
    y = circshift (x,k);
    return;
  else
    error ("n must be a scalar if calling circshift with three arguments.");
  endif
endif





    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?46514>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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