%THis is a script to compute velocity (U,V) from sea surface height data in
%NWtopex.mat

I=1:30;J=1:65;
I2=1:2:30;J2=1:2:65;
dZdx=diff(SSH,1,2).*((1./dx)*ones(1,65));
dZdy=diff(SSH,1,1)./dy;dZdy=diff(SSH,1,1)./dy;
f=2*7.29e-5*sin(pi/180*lat(:));
g=9.8;
U=(-g./f(I)*ones(1,length(J))).*dZdy(I,J);
V=(g./f(I)*ones(1,length(J))).*dZdx(I,J);

