diff scripts/signal/unwrap.m @ 7208:a730e47fda4d

[project @ 2007-11-28 02:32:41 by jwe]
author jwe
date Wed, 28 Nov 2007 02:32:42 +0000
parents a1dbe9d80eee
children 83a8781b529d
line wrap: on
line diff
--- a/scripts/signal/unwrap.m
+++ b/scripts/signal/unwrap.m
@@ -46,7 +46,7 @@
   else
     ## Find the first non-singleton dimension
     dim  = 1;
-    while (dim < nd + 1 && sz (dim) == 1)
+    while (dim < nd + 1 && sz(dim) == 1)
       dim = dim + 1;
     endwhile
     if (dim > nd)
@@ -62,7 +62,7 @@
   tol = abs (tol);
   
   rng = 2*pi;
-  m = sz (dim);
+  m = sz(dim);
 
   ## Handle case where we are trying to unwrap a scalar, or only have
   ## one sample in the specified dimension.
@@ -75,10 +75,10 @@
   ## as large values, and the sign will show direction.
   idx = cell ();
   for i = 1:nd
-    idx {i} = 1:sz(i);
+    idx{i} = 1:sz(i);
   endfor
-  idx {dim} = [1,1:m-1];
-  d = a (idx {:}) - a;
+  idx{dim} = [1,1:m-1];
+  d = a(idx{:}) - a;
 
   ## Find only the peaks, and multiply them by the range so that there
   ## are kronecker deltas at each wrap point multiplied by the range