1 | ;+ |
---|
2 | ; .. _fig15_timeseries_mjo.pro: |
---|
3 | ; |
---|
4 | ; ======================== |
---|
5 | ; fig15_timeseries_mjo.pro |
---|
6 | ; ======================== |
---|
7 | ; |
---|
8 | ; DESCRIPTION |
---|
9 | ; =========== |
---|
10 | ; |
---|
11 | ; .. graphviz:: |
---|
12 | ; |
---|
13 | ; digraph fig15_timeseries_mjo { |
---|
14 | ; |
---|
15 | ; tropflux_general [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/TropFlux_19890101_20091231.nc"]; |
---|
16 | ; ncep2 [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/NCEP2_flux_19890101_20090729.nc"]; |
---|
17 | ; erai [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/erai_fluxes_19930101_20090801_TROP_oafluxgrid.nc"]; |
---|
18 | ; ncep1 [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/fluxe_ncep1_19890101_20091231.nc"]; |
---|
19 | ; shf_oafluxgrid [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/shf_oafluxgrid_1985_2008.nc"]; |
---|
20 | ; lhf_oafluxgrid [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/lhf_oafluxgrid_1985_2008.nc"]; |
---|
21 | ; lwr_oafluxgrid [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/lwr_oafluxgrid_1985_2007.nc"]; |
---|
22 | ; swr_oafluxgrid [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/swr_oafluxgrid_1985_2007.nc"]; |
---|
23 | ; olr_oafluxgrid [shape=ellipse,fontname=Courier,label="${PROJECT_ID}/olr_oafluxgrid_30n30s_19890101_20091231.nc"]; |
---|
24 | ; |
---|
25 | ; figure [shape=ellipse,fontname=Courier,label="${PROJECT_OD}/WHOTS_validation_net_2004_2007_all_v10.ps"]; |
---|
26 | ; |
---|
27 | ; fig15_timeseries_mjo [shape=box, |
---|
28 | ; fontname=Courier, |
---|
29 | ; color=blue, |
---|
30 | ; URL="http://forge.ipsl.jussieu.fr/tropflux/broswrer/trunk/src/paper01/fig15/fig15_timeseries_mjo.pro", |
---|
31 | ; label="${TROPFLUX}/src/paper01/fig15/fig15_timeseries_mjo.pro"]; |
---|
32 | ; |
---|
33 | ; {tropflux_general swr_oafluxgrid lwr_oafluxgrid lhf_oafluxgrid shf_oafluxgrid ncep2 ncep1} -> {fig15_timeseries_mjo} -> {figure} |
---|
34 | ; } |
---|
35 | ; |
---|
36 | ; SEE ALSO |
---|
37 | ; ======== |
---|
38 | ; |
---|
39 | ; :ref:`project_profile.sh` |
---|
40 | ; :ref:`project_init.pro` |
---|
41 | ; :ref:`cm_project.pro` |
---|
42 | ; |
---|
43 | ; EXAMPLES |
---|
44 | ; ======== |
---|
45 | ; |
---|
46 | ; :: |
---|
47 | ; |
---|
48 | ; fig15_timeseries_mjo |
---|
49 | ; |
---|
50 | ; TODO |
---|
51 | ; ==== |
---|
52 | ; |
---|
53 | ; make it work on cratos : missing data |
---|
54 | ; |
---|
55 | ; coding rules |
---|
56 | ; |
---|
57 | ; complete description |
---|
58 | ; |
---|
59 | ; handle IO error |
---|
60 | ; |
---|
61 | ; EVOLUTIONS |
---|
62 | ; ========== |
---|
63 | ; |
---|
64 | ; $Id$ |
---|
65 | ; |
---|
66 | ; $URL$ |
---|
67 | ; |
---|
68 | ; - fplod 20110420T122720Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
69 | ; |
---|
70 | ; * remove hard coding path |
---|
71 | ; * add graphviz |
---|
72 | ; * externalize functions |
---|
73 | ; |
---|
74 | ; - fplod 20110411T142955Z aedon.locean-ipsl.upmc.fr (Darwin) |
---|
75 | ; |
---|
76 | ; * minimal header |
---|
77 | ; |
---|
78 | ;- |
---|
79 | pro fig15_timeseries_mjo |
---|
80 | @cm_general |
---|
81 | @cm_project |
---|
82 | reinitplt, /z,/invert |
---|
83 | key_portrait = 1 |
---|
84 | ; |
---|
85 | openps, FILENAME = project_od_env+'fig15_timeseries_mjo.ps' |
---|
86 | date1=20071001 |
---|
87 | date2=20080331 |
---|
88 | date1=19990101 |
---|
89 | date2=20021231 |
---|
90 | box=[50,80,-12,-5] |
---|
91 | ; |
---|
92 | file_trop=project_id_env+'TropFlux_19890101_20091231.nc' |
---|
93 | initncdf, file_trop |
---|
94 | shf_trop=read_ncdf("shf", date1, date2, box=box, file=file_trop,/nostr) |
---|
95 | lhf_trop=read_ncdf("lhf", date1, date2, box=box, file=file_trop,/nostr) |
---|
96 | swr_trop=read_ncdf("swr", date1, date2, box=box, file=file_trop,/nostr) |
---|
97 | lwr_trop=read_ncdf("lwr", date1, date2, box=box, file=file_trop,/nostr) |
---|
98 | ; ref_lw=-1*lwr_trop |
---|
99 | trop=swr_trop+(lwr_trop+lhf_trop+shf_trop) |
---|
100 | help, trop |
---|
101 | trop=grossemoyenne(trop, "xy",/nan) |
---|
102 | ; |
---|
103 | file_ncep=project_id_env+'NCEP2_flux_19890101_20090729.nc' |
---|
104 | initncdf, file_ncep |
---|
105 | shf=read_ncdf("shf", date1, date2, box=box, file=file_ncep,/nostr) |
---|
106 | lhf=read_ncdf("lhf", date1, date2, box=box, file=file_ncep,/nostr) |
---|
107 | lwr=read_ncdf("lwr", date1, date2, box=box, file=file_ncep,/nostr) |
---|
108 | swr=read_ncdf("swr", date1, date2, box=box, file=file_ncep,/nostr) |
---|
109 | ; |
---|
110 | nce2=swr-(lwr+lhf+shf) |
---|
111 | nce2=grossemoyenne(nce2, "xy",/nan) |
---|
112 | help, nce2 |
---|
113 | ; |
---|
114 | file_erai=project_id_env+'erai_fluxes_19930101_20090801_TROP_oafluxgrid.nc' |
---|
115 | initncdf, file_erai |
---|
116 | shf=read_ncdf("shf", date1, date2, box=box, file=file_erai,/nostr) |
---|
117 | lhf=read_ncdf("lhf", date1, date2, box=box, file=file_erai,/nostr) |
---|
118 | lwr=read_ncdf("lwr", date1, date2, box=box, file=file_erai,/nostr) |
---|
119 | swr=read_ncdf("swr", date1, date2, box=box, file=file_erai,/nostr) |
---|
120 | swr=-1*swr |
---|
121 | era=swr-(lwr+lhf+shf) |
---|
122 | era=grossemoyenne(era, "xy",/nan) |
---|
123 | help, era |
---|
124 | ; |
---|
125 | file=project_id_env+'fluxe_ncep1_19890101_20091231.nc' |
---|
126 | initncdf, file |
---|
127 | lwr=read_ncdf("lwr", date1, date2, box=box, file=file,/nostr) |
---|
128 | swr=read_ncdf("swr", date1, date2, box=box, file=file,/nostr) |
---|
129 | lhf=read_ncdf("lhf", date1, date2, box=box, file=file,/nostr) |
---|
130 | shf=read_ncdf("shf", date1, date2, box=box, file=file,/nostr) |
---|
131 | ; |
---|
132 | nce=swr+shf+lhf+lwr |
---|
133 | nce=grossemoyenne(nce, "xy",/nan) |
---|
134 | help, nce |
---|
135 | ; |
---|
136 | file_oaf=project_id_env+'shf_oafluxgrid_1985_2008.nc' |
---|
137 | initncdf, file_oaf |
---|
138 | shf=read_ncdf("shf", date1, date2, box=box, file=file_oaf,/nostr) |
---|
139 | file_oaf=project_id_env+'lhf_oafluxgrid_1985_2008.nc' |
---|
140 | initncdf, file_oaf |
---|
141 | lhf=read_ncdf("lhf", date1, date2, box=box, file=file_oaf,/nostr) |
---|
142 | file_oaf=project_id_env+'lwr_oafluxgrid_1985_2007.nc' |
---|
143 | initncdf, file_oaf |
---|
144 | lwr=read_ncdf("lwr", date1, date2, box=box, file=file_oaf,/nostr) |
---|
145 | file_oaf=project_id_env+'swr_oafluxgrid_1985_2007.nc' |
---|
146 | initncdf, file_oaf |
---|
147 | swr=read_ncdf("swr", date1, date2, box=box, file=file_oaf,/nostr) |
---|
148 | swr_trop=swr |
---|
149 | oafl=swr-(lwr+lhf+shf) |
---|
150 | help, oafl |
---|
151 | oafl=grossemoyenne(oafl, "xy",/nan) |
---|
152 | ; |
---|
153 | file=project_id_env+"olr_oafluxgrid_30n30s_19890101_20091231.nc" |
---|
154 | initncdf, file |
---|
155 | olr=read_ncdf("olr", date1-1, date2, box=box, file=file,/nostr) |
---|
156 | olr=grossemoyenne(olr, "xy",/nan) |
---|
157 | ; |
---|
158 | help, olr |
---|
159 | ; |
---|
160 | save, olr,trop, nce2, era, nce, filename="netflux_sctr_1999_2002.idl" |
---|
161 | ; |
---|
162 | trop_hf=trop*0. |
---|
163 | nce2_hf=trop*0. |
---|
164 | era_hf=trop*0. |
---|
165 | nce_hf=trop*0. |
---|
166 | ; |
---|
167 | Thf=30 |
---|
168 | Tlf=90 |
---|
169 | tsamp=1. ; monthly |
---|
170 | freq=findgen(jpt/2+1)/(jpt*tsamp) |
---|
171 | freq=[freq,-1.*reverse(freq(1:jpt/2))] |
---|
172 | peri=1./(abs(freq) > 1.e-20)*(2*(freq ge 0)-1.) |
---|
173 | ; Variance |
---|
174 | msk_spec=float((abs(peri) ge Thf) and (abs(peri) le Tlf)) |
---|
175 | ts=reform(trop) |
---|
176 | ff_ts=fft(ts) |
---|
177 | ff_ts_f=ff_ts*msk_spec |
---|
178 | trop_hf=float(fft(ff_ts_f,/inverse)) |
---|
179 | ; |
---|
180 | ts=reform(nce2) |
---|
181 | ff_ts=fft(ts) |
---|
182 | ff_ts_f=ff_ts*msk_spec |
---|
183 | nce2_hf=float(fft(ff_ts_f,/inverse)) |
---|
184 | ; |
---|
185 | ts=reform(era) |
---|
186 | ff_ts=fft(ts) |
---|
187 | ff_ts_f=ff_ts*msk_spec |
---|
188 | era_hf=float(fft(ff_ts_f,/inverse)) |
---|
189 | ; |
---|
190 | ts=reform(nce) |
---|
191 | ff_ts=fft(ts) |
---|
192 | ff_ts_f=ff_ts*msk_spec |
---|
193 | nce_hf=float(fft(ff_ts_f,/inverse)) |
---|
194 | ; |
---|
195 | help, trop_hf, nce2_hf, era_hf, nce_hf |
---|
196 | nsmooth=15. |
---|
197 | ; |
---|
198 | pltt, ts_smooth(olr,nsmooth,/nan), "t",/rempl, small=[1,3,1], $ |
---|
199 | charsize=1.1, title="a) Outgoing Longwave Radiation", subtitle="" |
---|
200 | ; |
---|
201 | pltt, ts_smooth(trop,nsmooth,/nan), "t",/rempl, -70,130, $ |
---|
202 | small=[1,3,2],/noer, charsize=1.1, title="b) Net Heat Flux", subtitle="" |
---|
203 | pltt, ts_smooth(era,nsmooth,/nan), "t",/ov1d, color=250 |
---|
204 | pltt, ts_smooth(nce2,nsmooth,/nan), "t",/ov1d, color=150 |
---|
205 | pltt, ts_smooth(nce,nsmooth,/nan), "t",/ov1d, color=50 |
---|
206 | ; |
---|
207 | pltt, trop_hf, "t",/rempl, -80,80, $ |
---|
208 | small=[1,3,3],/noer, title="c) 30-90 day Net Heat Flux", charsize=1.1, subtitle="" |
---|
209 | pltt, era_hf, "t",/ov1d, color=250 |
---|
210 | pltt, nce2_hf, "t",/ov1d, color=150 |
---|
211 | pltt, nce_hf, "t",/ov1d, color=50 |
---|
212 | ; |
---|
213 | closeps |
---|
214 | ; |
---|
215 | end |
---|