/[MITgcm]/MITgcm/verification/tutorial_global_oce_latlon/diags_matlab/mit_meridflux.m
ViewVC logotype

Annotation of /MITgcm/verification/tutorial_global_oce_latlon/diags_matlab/mit_meridflux.m

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Sat Aug 12 19:37:25 2006 UTC (17 years, 8 months ago) by jmc
Branch: MAIN
moved from verification/global_ocean.90x40x15/diags_matlab ;
 add Header and Name; use "quiver" instead of NaNquiver (<- not standard);

1 jmc 1.1 function T = mit_meridflux(surface_flux,dx,dy)
2     % function T = mit_meridflux(surface_flux,dx,dy)
3    
4     % $Header: $
5     % $Name: $
6    
7     if nargin == 2
8     area = dx;
9     elseif nargin == 3
10     area = dx.*dy;
11     else
12     error('need two or three input parameters')
13     end
14     [nx ny nt] = size(surface_flux);
15     for kt=1:nt
16     fdxdy(:,:,kt) = change(surface_flux(:,:,kt),'==',NaN,0).*area;
17     end
18    
19     T = squeeze(sum(cumsum(fdxdy,2),1));
20    
21     return

  ViewVC Help
Powered by ViewVC 1.1.22