Functions | |
if (nargin==2||nargin==1) if(nargin | |
else | if (length(h)==sz(i)) dx |
else | error ("dimensionality mismatch in %d-th spacing vector", i) = diff (varargin{i})(:) |
endif endif endfor | elseif (nargin-1==nd) tmp |
else | if (length(varargin{i})==sz(i)) dx |
endif endif endfor else | print_usage () |
szi (i) | |
DD (idx2{:}) | |
if (sz(i)==3) DD(idx1 | |
Variables | |
function | D |
endif | nd = ndims (M) |
sz = size (M) | |
dx = cell (1, nd) | |
else | h = varargin{1} |
endif for | i |
endif | idx = cell (1, nd) |
idx1 = idx2 = idx3 = idx | |
szi = sz | |
h1 = repmat (shiftdim (dx{i}(1 : sz(i) - 2), 1 - i), szi) | |
h2 = repmat (shiftdim (dx{i}(2 : sz(i) - 1), 1 - i), szi) |
id DD | ( | ) |
if | ( | sz(i) | = = 3 |
) |
else if | ( | length(varargin{i}) | = = sz (i) |
) |
else if | ( | length(h) | = = sz (i) |
) |
szi | ( | i | ) |
dx = cell (1, nd) |
else h = varargin{1} |
endif h2 = repmat (shiftdim (dx{i}(2 : sz(i) - 1), 1 - i), szi) |
sz = size (M) |
szi = sz |