SMOOTH2 --- SMOOTH a uniformly sampled 2d array of data, within a user- defined window, via a damped least squares technique smooth2 < stdin n1= n2= [optional parameters ] > stdout Required Parameters: n1= number of samples in the 1st (fast) dimension n2= number of samples in the 2nd (slow) dimension Optional Parameters: r1=0 smoothing parameter in the 1 direction r2=0 smoothing parameter in the 2 direction win=0,n1,0,n2 array for window range rw=0 smoothing parameter for window function efile= =efilename if set write relative error(x1) to efilename Notes: Larger r1 and r2 result in a smoother data. Recommended ranges of r1 ", and r2 are from 1 to 20. The file verror gives the relative error between the original velocity and the smoothed one, as a function of depth. If the error is between 0.01 and 0.1, the smoothing parameters are suitable. Otherwise, consider increasing or decreasing the smoothing parameter values. Smoothing can be implemented in a selected window. The range of 1st dimension for window is from win[0] to win[1]; the range of 2nd dimension is from win[2] to win[3]. Smoothing the window function (i.e. blurring the edges of the window) may be done by setting a nonzero value for rw, otherwise the edges of the window will be sharp. Credits: CWP: Zhen-yue Liu, adapted for par/main by John Stockwell 1 Oct 92 Windowing feature added by Zliu on 16 Nov 1992