1 |
gforget |
1.1 |
|
2 |
gforget |
1.5 |
doOmit3Dfields=0; |
3 |
gforget |
1.6 |
if mygrid.memoryLimit~=0; doOmit3Dfields=1; end; |
4 |
gforget |
1.5 |
|
5 |
gforget |
1.1 |
if userStep==1;%diags to be computed |
6 |
gforget |
1.2 |
%here _s stands for cumulative sum and _2s for cumulative sum of squares |
7 |
|
|
%the _s should be stated first |
8 |
gforget |
1.7 |
listDiags=['SIatmQnt_s SIatmQnt_2s SIatmFW_s SIatmFW_2s oceQnet_s oceQnet_2s ' ... |
9 |
|
|
'oceFWflx_s oceFWflx_2s fldTZ_s fldTZ_2s fldTM_s fldTM_2s ' ... |
10 |
|
|
'curlTau_s curlTau_2s fldETAN_s fldETAN_2s ' ... |
11 |
|
|
'fldSSH_s fldSSH_2s fldMLD_s fldMLD_2s']; |
12 |
gforget |
1.5 |
if ~doOmit3Dfields; |
13 |
gforget |
1.7 |
listDiags=[listDiags ' THETA_s THETA_2s SALT_s SALT_2s WVELMASS_s WVELMASS_2s']; |
14 |
gforget |
1.5 |
end; |
15 |
gforget |
1.4 |
|
16 |
gforget |
1.1 |
elseif userStep==2;%input files and variables |
17 |
gforget |
1.5 |
listFlds={ 'SIatmQnt','SIatmFW ','oceQnet ','oceFWflx','oceTAUX','oceTAUY','ETAN','sIceLoad','MXLDEPTH'}; |
18 |
|
|
if ~doOmit3Dfields; |
19 |
|
|
listFlds={listFlds{:} ,'THETA','SALT','WVELMASS'}; |
20 |
|
|
end; |
21 |
gforget |
1.1 |
listFldsNames=deblank(listFlds); |
22 |
gforget |
1.5 |
listFiles={'state_3d_set1','trsp_3d_set1','state_2d_set1','other_2d_set1'}; |
23 |
|
|
listSubdirs={[dirModel 'diags/OTHER/' ],[dirModel 'diags/STATE/' ],[dirModel 'diags/TRSP/' ]}; |
24 |
gforget |
1.4 |
|
25 |
|
|
elseif userStep==3;%computation |
26 |
gforget |
1.1 |
%mask fields: |
27 |
|
|
SIatmQnt=SIatmQnt.*mygrid.mskC(:,:,1); |
28 |
|
|
SIatmFW=SIatmFW.*mygrid.mskC(:,:,1); |
29 |
|
|
oceQnet=oceQnet.*mygrid.mskC(:,:,1); |
30 |
|
|
oceFWflx=oceFWflx.*mygrid.mskC(:,:,1); |
31 |
|
|
fldTX=oceTAUX.*mygrid.mskW(:,:,1); |
32 |
|
|
fldTY=oceTAUY.*mygrid.mskS(:,:,1); |
33 |
|
|
%compute Eastward/Northward wind stresses: |
34 |
|
|
[fldTZ,fldTM]=calc_UEVNfromUXVY(fldTX,fldTY); |
35 |
|
|
%compute wind stress curl: |
36 |
gforget |
1.6 |
%curlTau=calc_UV_curl(fldTX, fldTY,1 );%the doMask argument should not matter as msk was already applied |
37 |
|
|
curlTau=NaN*fldTZ; |
38 |
gforget |
1.1 |
%mask and re-arrange fields: |
39 |
|
|
fldETAN=ETAN.*mygrid.mskC(:,:,1); |
40 |
gforget |
1.7 |
fldSSH=(ETAN+sIceLoad/myparms.rhoconst).*mygrid.mskC(:,:,1); |
41 |
gforget |
1.1 |
fldMLD=MXLDEPTH.*mygrid.mskC(:,:,1); |
42 |
|
|
% |
43 |
gforget |
1.5 |
if ~doOmit3Dfields; |
44 |
|
|
THETA=THETA.*mygrid.mskC; |
45 |
|
|
SALT=SALT.*mygrid.mskC; |
46 |
|
|
WVELMASS=WVELMASS.*mygrid.mskC; |
47 |
|
|
end; |
48 |
gforget |
1.2 |
% |
49 |
|
|
if ii>1; |
50 |
|
|
fileMatPrev=['diags_set_' tmp1 '_' num2str(listTimes(ii-1)) '.mat']; |
51 |
gforget |
1.4 |
listTimesBak=listTimes; |
52 |
gforget |
1.2 |
load([dirMat fileMatPrev]); |
53 |
gforget |
1.4 |
listTimes=listTimesBak; |
54 |
gforget |
1.2 |
end; |
55 |
|
|
for jj=1:length(listDiags)/2; |
56 |
gforget |
1.7 |
myDiag=listDiags{1+2*(jj-1)}(1:end-2); |
57 |
gforget |
1.2 |
if ii==1; |
58 |
|
|
eval([myDiag '_s=0*' myDiag ';']); |
59 |
|
|
eval([myDiag '_2s=0*' myDiag '.^2;']); |
60 |
|
|
end; |
61 |
|
|
eval([myDiag '_s=' myDiag '_s+' myDiag ';']); |
62 |
|
|
eval([myDiag '_2s=' myDiag '_2s+' myDiag '.^2;']); |
63 |
|
|
end; |
64 |
|
|
|
65 |
gforget |
1.4 |
%===================== COMPUTATIONAL SEQUENCE ENDS =========================% |
66 |
|
|
%===================== PLOTTING SEQUENCE BEGINS =========================% |
67 |
|
|
|
68 |
|
|
elseif userStep==0;%loading / post-processing of mat files |
69 |
|
|
|
70 |
|
|
%load last cumsum |
71 |
gforget |
1.11 |
alldiag=diags_read_from_mat(dirMat,[fileMat '_*.mat'],'',myparms.recInAve(2)); |
72 |
gforget |
1.4 |
%load first cumsum |
73 |
|
|
if myparms.recInAve(1)>1; |
74 |
gforget |
1.11 |
tmpdiag=diags_read_from_mat(dirMat,[fileMat '_*.mat'],'',myparms.recInAve(1)-1); |
75 |
gforget |
1.4 |
for ii=1:length(alldiag.listDiags); |
76 |
|
|
tmp0=alldiag.listDiags{ii}; |
77 |
|
|
if ~strcmp(tmp0,'listTimes')&~strcmp(tmp0,'listSteps'); |
78 |
|
|
tmp1=getfield(alldiag,alldiag.listDiags{ii}); |
79 |
|
|
tmp2=getfield(tmpdiag,alldiag.listDiags{ii}); |
80 |
|
|
alldiag=setfield(alldiag,tmp0,tmp1-tmp2); |
81 |
|
|
end; |
82 |
|
|
end; |
83 |
|
|
end; |
84 |
gforget |
1.7 |
%ensure backward compatibility |
85 |
|
|
if ~isfield(alldiag,'WVELMASS_s'); alldiag.WVELMASS_s=NaN*alldiag.THETA_s; end; |
86 |
|
|
if ~isfield(alldiag,'WVELMASS_2s'); alldiag.WVELMASS_2s=NaN*alldiag.THETA_2s; end; |
87 |
|
|
if ~isfield(alldiag,'fldSSH_s'); alldiag.fldSSH_s=alldiag.fldETANLEADS_s; end; |
88 |
|
|
if ~isfield(alldiag,'fldSSH_2s'); alldiag.fldSSH_2s=alldiag.fldETANLEADS_2s; end; |
89 |
|
|
jj=find(strcmp(alldiag.listDiags,'fldETANLEADS_s')); |
90 |
|
|
if ~isempty(jj); alldiag.listDiags{jj}='fldSSH_s'; end; |
91 |
|
|
jj=find(strcmp(alldiag.listDiags,'fldETANLEADS_2s')); |
92 |
|
|
if ~isempty(jj); alldiag.listDiags{jj}='fldSSH_2s'; end; |
93 |
gforget |
1.4 |
% |
94 |
|
|
n=diff(myparms.recInAve)+1; |
95 |
gforget |
1.8 |
for jj=1:length(alldiag.listDiags)/2; |
96 |
|
|
tmp0=alldiag.listDiags{1+2*(jj-1)}; |
97 |
gforget |
1.4 |
if ~strcmp(tmp0,'listTimes')&~strcmp(tmp0,'listSteps'); |
98 |
|
|
tmp1=1/n*getfield(alldiag,tmp0); |
99 |
|
|
tmp2=1/n*getfield(alldiag,[tmp0(1:end-1) '2s']); |
100 |
|
|
tmp2=(tmp2-tmp1.^2); |
101 |
|
|
tmp2=n/(n-1)*tmp2; |
102 |
|
|
%tmp2(tmp2<0)=0; |
103 |
|
|
tmp2=sqrt(tmp2); |
104 |
|
|
alldiag=setfield(alldiag,[tmp0(1:end-2) '_mean'],tmp1); |
105 |
|
|
alldiag=setfield(alldiag,[tmp0(1:end-2) '_std'],tmp2); |
106 |
|
|
end; |
107 |
|
|
end; |
108 |
|
|
|
109 |
|
|
diagsWereLoaded=1 |
110 |
|
|
|
111 |
|
|
elseif userStep==-1;%plotting |
112 |
|
|
|
113 |
|
|
if isempty(setDiagsParams); |
114 |
|
|
choicePlot={'all'}; |
115 |
|
|
else; |
116 |
|
|
choicePlot=setDiagsParams; |
117 |
|
|
end; |
118 |
|
|
|
119 |
gforget |
1.6 |
|
120 |
|
|
%===== start with state variables |
121 |
|
|
|
122 |
|
|
if sum(strcmp(choicePlot,'all'))|sum(strcmp(choicePlot,'surface')); |
123 |
|
|
|
124 |
|
|
if addToTex; write2tex(fileTex,1,'sea surface height',2); end; |
125 |
|
|
|
126 |
|
|
%ETAN: |
127 |
|
|
fld=alldiag.fldETAN_mean; |
128 |
|
|
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]/100; title0='sea surface height (EXCLUDING ice)'; |
129 |
|
|
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.05; end; |
130 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
131 |
|
|
myCaption={myYmeanTxt,'mean -- sea surface height (EXCLUDING ice, in m)'}; |
132 |
|
|
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
133 |
|
|
|
134 |
|
|
%ETANLEADS: |
135 |
gforget |
1.7 |
fld=alldiag.fldSSH_mean; |
136 |
gforget |
1.6 |
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]/100; title0='sea surface height (INCLUDING ice)'; |
137 |
|
|
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.05; end; |
138 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
139 |
|
|
myCaption={myYmeanTxt,'mean -- sea surface height (INCLUDING ice, in m)'}; |
140 |
|
|
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
141 |
|
|
|
142 |
|
|
if multiTimes; |
143 |
|
|
%ETAN: |
144 |
|
|
fld=alldiag.fldETAN_std; |
145 |
|
|
cc=[0:25:500]/2500; title0='std(ETAN)'; |
146 |
|
|
if doAnomalies; cc=scaleAnom*[0:0.1:1]*0.02; end; |
147 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
148 |
|
|
myCaption={myYmeanTxt,' standard deviation -- sea surface height (EXCLUDING ice, in m)'}; |
149 |
|
|
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
150 |
|
|
|
151 |
|
|
%ETANLEADS: |
152 |
gforget |
1.7 |
fld=alldiag.fldSSH_std; |
153 |
gforget |
1.6 |
cc=[0:25:500]/2500; title0='std(ETANLEADS)'; |
154 |
|
|
if doAnomalies; cc=scaleAnom*[0:0.1:1]*0.02; end; |
155 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
156 |
|
|
myCaption={myYmeanTxt,' standard deviation -- sea surface height (INCLUDING ice, in m)'}; |
157 |
|
|
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
158 |
|
|
end; |
159 |
|
|
|
160 |
|
|
end; |
161 |
|
|
|
162 |
|
|
if ( sum(strcmp(choicePlot,'all'))|sum(strcmp(choicePlot,'subsrfc')) )&(~doOmit3Dfields); |
163 |
|
|
|
164 |
|
|
if addToTex; write2tex(fileTex,1,'3D state variables',2); end; |
165 |
|
|
|
166 |
|
|
cc_mean=1/100*[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]; |
167 |
|
|
cc_std=1/250*[0:25:500]; |
168 |
|
|
kkList=[1 11 20 28 37 44]; |
169 |
|
|
vvList={'THETA','SALT','WVELMASS'}; |
170 |
|
|
|
171 |
|
|
for vv=1:length(vvList); |
172 |
|
|
vvtxt=vvList{vv}; |
173 |
|
|
eval(['fld_mean=alldiag.' vvtxt '_mean;']); |
174 |
|
|
eval(['fld_std=alldiag.' vvtxt '_std;']); |
175 |
|
|
if strcmp(vvtxt,'WVELMASS');%convert into mm/day |
176 |
|
|
fld_mean=fld_mean*86400*365/1e3; |
177 |
|
|
fld_std=fld_std*86400*365/1e3; |
178 |
|
|
end; |
179 |
|
|
for kk=kkList; |
180 |
|
|
if strcmp(vvtxt,'WVELMASS')&kk==1; kk=2; end; |
181 |
|
|
if mygrid.RC(kk)>=-50; facD=0.5; |
182 |
|
|
elseif mygrid.RC(kk)>=-150; facD=1; |
183 |
|
|
elseif mygrid.RC(kk)>=-500; facD=2.5; |
184 |
|
|
elseif mygrid.RC(kk)>=-2000; facD=10; |
185 |
|
|
else; facD=20; |
186 |
|
|
end; |
187 |
|
|
% |
188 |
heimbach |
1.9 |
if strcmp(vvtxt,'THETA'); nm='temperature (in degC)'; facV=1; |
189 |
gforget |
1.6 |
elseif strcmp(vvtxt,'SALT'); nm='salinity (in psu)'; facV=10; |
190 |
|
|
elseif strcmp(vvtxt,'WVELMASS'); nm='vertical velocity (in mm/year)'; facV=10; |
191 |
|
|
else; error('not yet implemented'); |
192 |
|
|
end; |
193 |
|
|
% |
194 |
|
|
|
195 |
|
|
title0=sprintf('%s at %4dm',nm,round(-mygrid.RC(kk))); |
196 |
|
|
|
197 |
|
|
%time mean map: |
198 |
|
|
fld=fld_mean(:,:,kk).*mygrid.mskC(:,:,kk); |
199 |
|
|
if doAnomalies; |
200 |
|
|
cc=scaleAnom/facV/facD*cc_mean; |
201 |
|
|
elseif strcmp(vvtxt,'WVELMASS'); |
202 |
|
|
cc=1/facV*cc_mean; |
203 |
|
|
else; |
204 |
|
|
cc=prctile(facV*fld,[2.5 97.5]); |
205 |
|
|
cc=[floor(cc(1)):ceil(cc(end))]/facV; |
206 |
|
|
%ensure at least 10 color levels |
207 |
|
|
fac0=1; |
208 |
|
|
while length(cc)<15; |
209 |
|
|
fac0=fac0*2; |
210 |
|
|
cc=prctile(fac0*facV*fld,[2.5 97.5]); |
211 |
|
|
cc=[floor(cc(1)):ceil(cc(end))]/facV/fac0; |
212 |
|
|
end; |
213 |
|
|
%ensure at most 10 color levels |
214 |
|
|
fac0=1; |
215 |
|
|
while length(cc)>30; |
216 |
|
|
fac0=fac0/2; |
217 |
|
|
cc=prctile(fac0*facV*fld,[2.5 97.5]); |
218 |
|
|
cc=[floor(cc(1)):ceil(cc(end))]/facV/fac0; |
219 |
|
|
end; |
220 |
|
|
end; |
221 |
|
|
% |
222 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
223 |
|
|
myCaption={myYmeanTxt,'mean -- ',title0}; |
224 |
|
|
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
225 |
|
|
|
226 |
gforget |
1.7 |
if multiTimes; |
227 |
gforget |
1.6 |
fld=fld_std(:,:,kk).*mygrid.mskC(:,:,kk); |
228 |
|
|
cc=1/facV/facD*cc_std; |
229 |
|
|
if strcmp(vvtxt,'WVELMASS'); cc=1/facV*cc_std; end; |
230 |
|
|
if doAnomalies; cc=scaleAnom*cc; end; |
231 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
232 |
|
|
myCaption={myYmeanTxt,' standard deviation -- ',title0}; |
233 |
|
|
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
234 |
|
|
end; |
235 |
|
|
|
236 |
|
|
end;%for kk=... |
237 |
|
|
end;%for vv=... |
238 |
|
|
end;%if ( sum(strcmp(... |
239 |
|
|
|
240 |
|
|
|
241 |
|
|
%now do surface fluxes and forcing fields |
242 |
|
|
|
243 |
gforget |
1.4 |
if sum(strcmp(choicePlot,'all'))|sum(strcmp(choicePlot,'qnet')); |
244 |
|
|
|
245 |
gforget |
1.6 |
if addToTex; write2tex(fileTex,1,'air-sea heat flux',2); end; |
246 |
|
|
|
247 |
gforget |
1.4 |
%qnet from ocean+ice: |
248 |
|
|
fld=-alldiag.SIatmQnt_mean; |
249 |
|
|
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]; title0='QNET to ocean+ice'; |
250 |
|
|
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*10; end; |
251 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
252 |
heimbach |
1.10 |
myCaption={myYmeanTxt,'mean -- QNET to ocean+ice (W/m$^2$)'}; |
253 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
254 |
|
|
|
255 |
|
|
%qnet to ocean: |
256 |
|
|
fld=alldiag.oceQnet_mean; |
257 |
|
|
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]; title0='QNET to ocean'; |
258 |
|
|
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*10; end; |
259 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
260 |
heimbach |
1.10 |
myCaption={myYmeanTxt,'mean -- QNET to ocean (W/m$^2$)'}; |
261 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
262 |
|
|
|
263 |
|
|
if multiTimes; |
264 |
|
|
%qnet from ocean+ice: |
265 |
|
|
fld=alldiag.SIatmQnt_std; |
266 |
|
|
cc=[[0:5:25] 35 [50:25:200] [250 300]]; title0='std(QNET to ocean+ice)'; |
267 |
|
|
if doAnomalies; cc=scaleAnom*[0:0.1:1]*5; end; |
268 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
269 |
heimbach |
1.10 |
myCaption={myYmeanTxt,' standard deviation -- QNET to ocean+ice (W/m$^2$)'}; |
270 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
271 |
|
|
|
272 |
|
|
%qnet from ocean: |
273 |
|
|
fld=alldiag.oceQnet_std; |
274 |
|
|
cc=[[0:5:25] 35 [50:25:200] [250 300]]; title0='std(QNET to ocean)'; |
275 |
|
|
if doAnomalies; cc=scaleAnom*[0:0.1:1]*5; end; |
276 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
277 |
heimbach |
1.10 |
myCaption={myYmeanTxt,' standard deviation -- QNET to ocean (W/m$^2$)'}; |
278 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
279 |
|
|
end; |
280 |
|
|
|
281 |
|
|
end; |
282 |
|
|
|
283 |
|
|
|
284 |
|
|
if sum(strcmp(choicePlot,'all'))|sum(strcmp(choicePlot,'fwf')); |
285 |
|
|
|
286 |
heimbach |
1.9 |
if addToTex; write2tex(fileTex,1,'air-sea freshwater flux',2); end; |
287 |
gforget |
1.6 |
|
288 |
gforget |
1.4 |
%FW flux from ocean+ice: |
289 |
|
|
fld=-alldiag.SIatmFW_mean/1000;%conversion to m/s |
290 |
|
|
fld=fld*86400*1000;%conversion to mm/day |
291 |
heimbach |
1.9 |
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]*0.06; title0='E-P-R to ocean+ice'; |
292 |
gforget |
1.4 |
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.5; end; |
293 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
294 |
heimbach |
1.9 |
myCaption={myYmeanTxt,'mean -- E-P-R from ocean+ice (mm/day)'}; |
295 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
296 |
|
|
|
297 |
|
|
%FW flux from ocean: |
298 |
|
|
fld=-alldiag.oceFWflx_mean/1000;%conversion to m/s |
299 |
|
|
fld=fld*86400*1000;%conversion to mm/day |
300 |
heimbach |
1.9 |
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]*0.06; title0='E-P-R to ocean'; |
301 |
gforget |
1.4 |
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.5; end; |
302 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
303 |
heimbach |
1.9 |
myCaption={myYmeanTxt,'mean -- E-P-R from ocean (mm/day)'}; |
304 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
305 |
|
|
|
306 |
|
|
if multiTimes; |
307 |
|
|
%empmr from ocean+ice: |
308 |
|
|
fld=alldiag.SIatmFW_std*86400;%conversion to mm/day |
309 |
heimbach |
1.9 |
cc=[[0:5:25] 35 [50:25:200] [250 300]]*0.04; title0='std(E-P-R to ocean+ice)'; |
310 |
gforget |
1.4 |
if doAnomalies; cc=scaleAnom*[0:0.1:1]*0.5; end; |
311 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
312 |
heimbach |
1.10 |
myCaption={myYmeanTxt,' standard deviation -- E-P-R to ocean+ice (W/m$^2$)'}; |
313 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
314 |
|
|
|
315 |
|
|
%empmr from ocean: |
316 |
|
|
fld=alldiag.oceFWflx_std*86400;%conversion to mm/day |
317 |
heimbach |
1.9 |
cc=[[0:5:25] 35 [50:25:200] [250 300]]*0.04; title0='std(E-P-R to ocean)'; |
318 |
gforget |
1.4 |
if doAnomalies; cc=scaleAnom*[0:0.1:1]*0.5; end; |
319 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
320 |
heimbach |
1.10 |
myCaption={myYmeanTxt,' standard deviation -- E-P-R to ocean (W/m$^2$)'}; |
321 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
322 |
|
|
end; |
323 |
|
|
|
324 |
|
|
end; |
325 |
|
|
|
326 |
|
|
if sum(strcmp(choicePlot,'all'))|sum(strcmp(choicePlot,'tau')); |
327 |
|
|
|
328 |
gforget |
1.6 |
if addToTex; write2tex(fileTex,1,'surface wind stress',2); end; |
329 |
|
|
|
330 |
gforget |
1.4 |
%zonal wind stress: |
331 |
|
|
fld=alldiag.fldTZ_mean; |
332 |
|
|
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]/500; title0='zonal wind stress'; |
333 |
|
|
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.01; end; |
334 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
335 |
heimbach |
1.10 |
myCaption={myYmeanTxt,'mean -- zonal wind stress (N/m$^2$)'}; |
336 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
337 |
|
|
|
338 |
|
|
%meridional wind stress: |
339 |
|
|
fld=alldiag.fldTM_mean; |
340 |
|
|
cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]/500; title0='meridional wind stress'; |
341 |
|
|
if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.01; end; |
342 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
343 |
heimbach |
1.10 |
myCaption={myYmeanTxt,'mean -- meridional wind stress (N/m$^2$)'}; |
344 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
345 |
|
|
|
346 |
gforget |
1.6 |
%fld=alldiag.curlTau_mean; |
347 |
|
|
%cc=[[-250:50:-100] [-75 -50] [-35:10:35] [50 75] [100:50:250]]/5e8; title0='wind stress curl'; |
348 |
|
|
%if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.01; end; |
349 |
|
|
%figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
350 |
heimbach |
1.10 |
%myCaption={myYmeanTxt,'mean -- wind stress curl (N/m$^3$)'}; |
351 |
gforget |
1.6 |
%if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
352 |
gforget |
1.4 |
|
353 |
|
|
if multiTimes; |
354 |
|
|
%zonal wind stress: |
355 |
|
|
fld=alldiag.fldTZ_std; |
356 |
|
|
cc=[[0:5:25] 35 [50:25:200] [250 300]]/2000; title0='std(tauZ)'; |
357 |
|
|
if doAnomalies; cc=scaleAnom*[0:0.1:1]*0.005; end; |
358 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
359 |
heimbach |
1.10 |
myCaption={myYmeanTxt,' standard deviation -- tauZ (W/m$^2$)'}; |
360 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
361 |
|
|
|
362 |
|
|
%meridional wind stress: |
363 |
|
|
fld=alldiag.fldTM_std; |
364 |
|
|
cc=[[0:5:25] 35 [50:25:200] [250 300]]/2000; title0='std(tauM)'; |
365 |
|
|
if doAnomalies; cc=scaleAnom*[0:0.1:1]*0.005; end; |
366 |
|
|
figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
367 |
heimbach |
1.10 |
myCaption={myYmeanTxt,' standard deviation -- tauM (W/m$^2$)'}; |
368 |
gforget |
1.4 |
if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
369 |
|
|
|
370 |
gforget |
1.6 |
%fld=alldiag.curlTau_std; |
371 |
|
|
%cc=[[0:5:25] 35 [50:25:200] [250 300]]/1e9; title0='wind stress curl'; |
372 |
|
|
%if doAnomalies; cc=scaleAnom*[-1:0.1:1]*0.01; end; |
373 |
|
|
%figureL; m_map_gcmfaces(fld,0,{'myCaxis',cc},{'do_m_coast',1},{'myTitle',title0}); |
374 |
heimbach |
1.10 |
%myCaption={myYmeanTxt,'standard deviation -- tauCurl (N/m$^3$)'}; |
375 |
gforget |
1.6 |
%if addToTex; write2tex(fileTex,2,myCaption,gcf); end; |
376 |
gforget |
1.4 |
end; |
377 |
|
|
|
378 |
|
|
end; |
379 |
|
|
|
380 |
gforget |
1.1 |
end; |
381 |
gforget |
1.4 |
|
382 |
|
|
|