/[MITgcm]/MITgcm_contrib/gael/bulkMatlab/quickcow_load_atlas.m
ViewVC logotype

Annotation of /MITgcm_contrib/gael/bulkMatlab/quickcow_load_atlas.m

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


Revision 1.1 - (hide annotations) (download)
Tue Feb 19 21:28:59 2008 UTC (17 years, 4 months ago) by gforget
Branch: MAIN
CVS Tags: HEAD
matlab script to compute bulk formulae forcing etc.

1 gforget 1.1 function [ustress_cur,vstress_cur]=quickcow_load_atlas();
2     %loads the fields and does the interpolation to the 1x1 ECCO grid
3     domaine_global_def;
4    
5     mask=squeeze(tmask3D(:,:,1));
6    
7     rep_in='/net/ross/raid0/gforget/DATAbin/QSCATcow/';
8     list_names=strvcat('january','february','march','april','may','june','july','august','september','october','november','december');
9    
10     for vcur=1:2;
11     if vcur==1; eval(['ncload ' rep_in 'wind_stress_zonal_monthly_maps.nc;']); ustress_cur=NaN*zeros(jpi,jpj,12);
12     else; eval(['ncload ' rep_in 'wind_stress_meridional_monthly_maps.nc;']); vstress_cur=NaN*zeros(jpi,jpj,12);
13     end;
14     for mcur=1:12
15     tmp1=zeros(jpi,jpj); tmp2=zeros(jpi,jpj);
16     eval(['tmp3=' deblank(list_names(mcur,:)) ''';']);
17     tmp4=1*(tmp3>-1000); tmp3(tmp3<-1000)=0;
18     for icur=1:4; for jcur=1:4;
19     tmp1(:,11:150)=tmp1(:,11:150)+tmp3(icur:4:end,jcur:4:end);
20     tmp2(:,11:150)=tmp2(:,11:150)+tmp4(icur:4:end,jcur:4:end);
21     end;end;
22     %tmp1(find(tmp2>0))=tmp1(find(tmp2>0))./tmp2(find(tmp2>0)); tmp1(find(tmp2==0))=NaN;
23     %tmp1(find(tmp2>8))=tmp1(find(tmp2>8))./tmp2(find(tmp2>8)); tmp1(find(tmp2<=8))=NaN;
24     tmp1(find(tmp2>15))=tmp1(find(tmp2>15))./tmp2(find(tmp2>15)); tmp1(find(tmp2<=15))=NaN;
25    
26     if vcur==1; ustress_cur(:,:,mcur)=tmp1;
27     else; vstress_cur(:,:,mcur)=tmp1; end;
28     end%for mcur=1:12
29     end%for vcur=1:2;
30    
31    
32    
33    
34    

  ViewVC Help
Powered by ViewVC 1.1.22