Mercurial > hg > octave-nkf
annotate scripts/signal/fftshift.m @ 20815:a260a6acb70f
fix test failures introduced by a22d8a2eb0e5
* scripts/ode/private/integrate_adaptive.m: fix stepping backwards, fix
invocation of OutputFcn, fix text of some error messages
* scripts/ode/private/integrate_const.m: remove use of option OutputSave
* scripts/ode/private/integrate_n_steps.m: remove use of option OutputSave
author | Carlo de Falco <carlo.defalco@polimi.it> |
---|---|
date | Sun, 11 Oct 2015 23:09:01 +0200 |
parents | abbe33bf0c74 |
children |
rev | line source |
---|---|
19898
4197fc428c7d
maint: Update copyright notices for 2015.
John W. Eaton <jwe@octave.org>
parents:
17744
diff
changeset
|
1 ## Copyright (C) 1997-2015 Vincent Cautaerts |
3426 | 2 ## |
3922 | 3 ## This file is part of Octave. |
4 ## | |
5 ## Octave is free software; you can redistribute it and/or modify it | |
6 ## under the terms of the GNU General Public License as published by | |
7016 | 7 ## the Free Software Foundation; either version 3 of the License, or (at |
8 ## your option) any later version. | |
3426 | 9 ## |
3922 | 10 ## Octave is distributed in the hope that it will be useful, but |
3191 | 11 ## WITHOUT ANY WARRANTY; without even the implied warranty of |
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
3426 | 13 ## General Public License for more details. |
14 ## | |
3191 | 15 ## You should have received a copy of the GNU General Public License |
7016 | 16 ## along with Octave; see the file COPYING. If not, see |
17 ## <http://www.gnu.org/licenses/>. | |
3191 | 18 |
3449 | 19 ## -*- texinfo -*- |
11469
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
20 ## @deftypefn {Function File} {} fftshift (@var{x}) |
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
21 ## @deftypefnx {Function File} {} fftshift (@var{x}, @var{dim}) |
20375
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
22 ## Perform a shift of the vector @var{x}, for use with the @code{fft} and |
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
23 ## @code{ifft} functions, in order the move the frequency 0 to the center of |
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
24 ## the vector or matrix. |
3191 | 25 ## |
20375
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
26 ## If @var{x} is a vector of @math{N} elements corresponding to @math{N} time |
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
27 ## samples spaced by @nospell{@math{dt}}, then |
13233
914c0b103a3d
fftshift.m: Better explain operation in docstring (Bug #33581).
Rik <octave@nomad.inbox5.com>
parents:
12540
diff
changeset
|
28 ## @code{fftshift (fft (@var{x}))} corresponds to frequencies |
3191 | 29 ## |
3449 | 30 ## @example |
13233
914c0b103a3d
fftshift.m: Better explain operation in docstring (Bug #33581).
Rik <octave@nomad.inbox5.com>
parents:
12540
diff
changeset
|
31 ## f = [ -(ceil((N-1)/2):-1:1)*df 0 (1:floor((N-1)/2))*df ] |
3449 | 32 ## @end example |
3191 | 33 ## |
13929
9cae456085c2
Grammarcheck of documentation before 3.6.0 release.
Rik <octave@nomad.inbox5.com>
parents:
13268
diff
changeset
|
34 ## @noindent |
16826
a4969508008e
doc: Periodic spellcheck of the documentation.
Rik <rik@octave.org>
parents:
14363
diff
changeset
|
35 ## where @nospell{@math{df} = 1 / @math{dt}}. |
13233
914c0b103a3d
fftshift.m: Better explain operation in docstring (Bug #33581).
Rik <octave@nomad.inbox5.com>
parents:
12540
diff
changeset
|
36 ## |
20375
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
37 ## If @var{x} is a matrix, the same holds for rows and columns. If @var{x} |
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
38 ## is an array, then the same holds along each dimension. |
4844 | 39 ## |
20375
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
40 ## The optional @var{dim} argument can be used to limit the dimension along |
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
41 ## which the permutation occurs. |
f1d0f506ee78
doc: Update more docstrings to have one sentence summary as first line.
Rik <rik@octave.org>
parents:
19898
diff
changeset
|
42 ## @seealso{ifftshift} |
3449 | 43 ## @end deftypefn |
3191 | 44 |
45 ## Author: Vincent Cautaerts <vincent@comf5.comm.eng.osaka-u.ac.jp> | |
46 ## Created: July 1997 | |
47 ## Adapted-By: jwe | |
48 | |
11469
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
49 function retval = fftshift (x, dim) |
3191 | 50 |
4844 | 51 if (nargin != 1 && nargin != 2) |
6046 | 52 print_usage (); |
3191 | 53 endif |
54 | |
20447
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
55 if (! (isnumeric (x) || islogical (x) || ischar (x))) |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
56 error ("fftshift: X must be a vector or matrix"); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
57 endif |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
58 |
4844 | 59 if (nargin == 2) |
13233
914c0b103a3d
fftshift.m: Better explain operation in docstring (Bug #33581).
Rik <octave@nomad.inbox5.com>
parents:
12540
diff
changeset
|
60 if (! (isscalar (dim) && dim > 0 && dim == fix (dim))) |
914c0b103a3d
fftshift.m: Better explain operation in docstring (Bug #33581).
Rik <octave@nomad.inbox5.com>
parents:
12540
diff
changeset
|
61 error ("fftshift: dimension DIM must be a positive integer"); |
4844 | 62 endif |
11469
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
63 nd = ndims (x); |
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
64 sz = size (x); |
4844 | 65 sz2 = ceil (sz(dim) / 2); |
66 idx = cell (); | |
12676
2783fa95cab7
Use common code idiom for creating cell array for indexing ND-arrays
Rik <octave@nomad.inbox5.com>
parents:
12540
diff
changeset
|
67 idx = repmat ({':'}, nd, 1); |
7208 | 68 idx{dim} = [sz2+1:sz(dim), 1:sz2]; |
11469
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
69 retval = x(idx{:}); |
3191 | 70 else |
11469
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
71 if (isvector (x)) |
12463
189baf055143
fftshift.m: Fix broken function documented in bug 32442
Karsten Trulsen <karstent@math.uio.no>
parents:
11587
diff
changeset
|
72 xl = length (x); |
189baf055143
fftshift.m: Fix broken function documented in bug 32442
Karsten Trulsen <karstent@math.uio.no>
parents:
11587
diff
changeset
|
73 xx = ceil (xl/2); |
189baf055143
fftshift.m: Fix broken function documented in bug 32442
Karsten Trulsen <karstent@math.uio.no>
parents:
11587
diff
changeset
|
74 retval = x([xx+1:xl, 1:xx]); |
20447
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
75 else |
11469
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
76 nd = ndims (x); |
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
77 sz = size (x); |
4844 | 78 sz2 = ceil (sz ./ 2); |
79 idx = cell (); | |
8507 | 80 for i = 1:nd |
4844 | 81 idx{i} = [sz2(i)+1:sz(i), 1:sz2(i)]; |
82 endfor | |
11469
c776f063fefe
Overhaul m-script files to use common variable name between code and documentation.
Rik <octave@nomad.inbox5.com>
parents:
10793
diff
changeset
|
83 retval = x(idx{:}); |
4844 | 84 endif |
3191 | 85 endif |
86 | |
87 endfunction | |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
88 |
13233
914c0b103a3d
fftshift.m: Better explain operation in docstring (Bug #33581).
Rik <octave@nomad.inbox5.com>
parents:
12540
diff
changeset
|
89 |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
90 %!test |
17314
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
91 %! x = [0:7]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
92 %! y = fftshift (x); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
93 %! assert (y, [4 5 6 7 0 1 2 3]); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
94 %! assert (fftshift (y), x); |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
95 |
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
96 %!test |
17314
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
97 %! x = [0:6]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
98 %! y = fftshift (x); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
99 %! assert (y, [4 5 6 0 1 2 3]); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
100 %! assert (fftshift (y), [1 2 3 4 5 6 0]); |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
101 |
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
102 %!test |
17314
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
103 %! x = [0:7]'; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
104 %! y = fftshift (x); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
105 %! assert (y, [4;5;6;7;0;1;2;3]); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
106 %! assert (fftshift (y), x); |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
107 |
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
108 %!test |
17314
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
109 %! x = [0:6]'; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
110 %! y = fftshift (x); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
111 %! assert (y, [4;5;6;0;1;2;3]); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
112 %! assert (fftshift (y), [1;2;3;4;5;6;0]); |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
113 |
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
114 %!test |
17314
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
115 %! x = [0:3]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
116 %! x = [x;2*x;3*x+1;4*x+1]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
117 %! y = fftshift (x); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
118 %! assert (y, [[7 10 1 4];[9 13 1 5];[2 3 0 1];[4 6 0 2]]); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
119 %! assert (fftshift (y), x); |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
120 |
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
121 %!test |
17314
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
122 %! x = [0:3]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
123 %! x = [x;2*x;3*x+1;4*x+1]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
124 %! y = fftshift (x,1); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
125 %! assert (y, [[1 4 7 10];[1 5 9 13];[0 1 2 3];[0 2 4 6]]); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
126 %! assert (fftshift (y,1), x); |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
127 |
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
128 %!test |
17314
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
129 %! x = [0:3]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
130 %! x = [x;2*x;3*x+1;4*x+1]; |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
131 %! y = fftshift (x,2); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
132 %! assert (y, [[2 3 0 1];[4 6 0 2];[7 10 1 4];[9 13 1 5]]); |
7f27a3cbdb41
Use Octave coding convention of 1 space after '%!' test prefix.
Rik <rik@octave.org>
parents:
16826
diff
changeset
|
133 %! assert (fftshift (y,2), x); |
12540
b3c158b8941c
Add tests for fftshift.m.
Robert T. Short <octave@phaselockedsystems.com.com>
parents:
12463
diff
changeset
|
134 |
20447
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
135 %!test |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
136 %! x = "abcdefg"; |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
137 %! y = fftshift (x); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
138 %! assert (y, "efgabcd"); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
139 %! assert (fftshift (y), "bcdefga"); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
140 |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
141 ## Test N-dimensional input (bug #45207) |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
142 %!test |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
143 %! x = [0:3]; |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
144 %! x = x + x' + reshape (x, [1 1 4]); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
145 %! y1 = [4 5 2 3; 5 6 3 4; 2 3 0 1; 3 4 1 2]; |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
146 %! y = fftshift (x); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
147 %! assert (y, reshape ([y1 + 2, y1 + 3, y1, y1 + 1], [4 4 4])); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
148 %! assert (fftshift (y), x); |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
149 |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
150 %% Test input validation |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
151 %!error fftshift () |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
152 %!error fftshift (1, 2, 3) |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
153 %!error fftshift (0:3, -1) |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
154 %!error fftshift (0:3, 0:3) |
abbe33bf0c74
fftshift.m, ifftshift.m: Restore support for N-dimensional arrays (bug #45207)
Mike Miller <mtmiller@octave.org>
parents:
20375
diff
changeset
|
155 |