Home > omviz > tsrich.m

tsrich

PURPOSE ^

TSRICH calculates gradient Richardson Number from TSEPIC.CDF files

SYNOPSIS ^

function [Ri,jd]=tsrich(cdf,sta);

DESCRIPTION ^

 TSRICH calculates gradient Richardson Number from TSEPIC.CDF files

 Usage: [Ri,jd]=tsrich(cdf,sta);

  Requires: SWSTATE from Rich Pawlowitz's OCEAN toolbox for
            the calculation of density

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [Ri,jd]=tsrich(cdf,sta);
0002 % TSRICH calculates gradient Richardson Number from TSEPIC.CDF files
0003 %
0004 % Usage: [Ri,jd]=tsrich(cdf,sta);
0005 %
0006 %  Requires: SWSTATE from Rich Pawlowitz's OCEAN toolbox for
0007 %            the calculation of density
0008 %
0009 swstatet=ones(size(s))*4;
0010 [w,jd]=tsvel(cdf,sta);
0011 [svan,sigma]=swstate(s,t,zeros(size(t)));
0012 dens=1+sigma/1000;
0013 dz=diff(z);
0014 g=9.81;
0015 N=g*(diff(dens.').')./(ones(length(jd),1)*dz);
0016 shear=(diff(w.').')./(ones(length(jd),1)*dz);
0017 Ri=N./(real(shear).^2 + imag(shear).^2);

Generated on Thu 01-Dec-2005 08:50:35 by m2html © 2003