Commit e18808b8 authored by j.schaeper's avatar j.schaeper
Browse files

fix fftfreq after Leons changes

parent a4030ca7
Pipeline #103313 passed with stage
in 3 minutes and 14 seconds
......@@ -65,6 +65,13 @@ for jj = 1:ndim
xi{jj} = ifftshift( ( -floor(0.5*N(jj)) : floor(0.5*(N(jj)-1)) ).' * ( 2*pi / (N(jj)*dx(jj)) ) );
end
if ndim > 1
for jj = 1:ndim
xi{jj} = reshape( xi{jj}, [ones([1,jj-1]), N(jj), ones([1,ndim-jj])] );
end
end
% Unpack cell-array
varargout = xi;
......
......@@ -47,7 +47,7 @@ if nargin < 2
dx = ones(size(N));
end
xi = cell([numel(N),1]);
xi = cell(numel(N),1);
[xi{:}] = fftfreq(N, dx);
XiSq = xi{1}.^2;
for dim = 2:numel(xi)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment