source: trunk/MESOSCALE/PLOT/SPEC/GW/gravitwaveprof.pro @ 205

Last change on this file since 205 was 131, checked in by aslmd, 14 years ago

mars

M 130 mars/libf/phymars/callradite.F
M 130 mars/README
no more need to modify callradite.F prior to compilation
[but still dimradmars.h must be modified]

--> in callradite.F we now have

-- DEFAULT name_iaer(1) is "dust_conrath"
-- IF (doubleq.AND.active) name_iaer(1) = "dust_doubleq"
-- IF (water.AND.activice) name_iaer(2) = "h2o_ice"

M 130 000-USERS
small meeting about SVN for "planeto" team

M 130 mars/libf/phymars/meso_physiq.F
purely cosmetic changes

M 130 mesoscale/PLOT/MINIMAL/map_latlon.pro
M 130 mesoscale/PLOT/SPEC/GW/gravitwave2.pro
M 130 mesoscale/PLOT/SPEC/GW/gravitwaveprof.pro
M 130 mesoscale/PLOT/SPEC/GW/gravitwave_inc.pro
A 0 mesoscale/PLOT/SPEC/MAP/defs/THARSIS_newphys_bugnoRAC_RACgcm_TAUTES.map_uvt_inc.pro
M 130 mesoscale/PLOT/SPEC/MAP/map_uvt.pro
graphic stuff for GW studies and H2O cycle

  • Property svn:executable set to *
File size: 9.4 KB
Line 
1pro gravitwaveprof
2;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
3
4;
5; faire avant api avec kappa 3.9
6;
7
8;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
9        path='../TESTGW/'
10        path='/tmp7/aslmd/'
11path='/home/aslmd/GRAVITWAVE/'
12        experiment='mcd_lt16_rcpcst'
13        ;experiment='mcd_lt16'
14        ;experiment='short_mcd_lt16_rcpcst'
15        ;experiment='short_mcd_lt16'
16        ;experiment='short_mcd_lt16_calcprho'
17        ;experiment='mcd_lt16_calcprho'
18        ;experiment='short_mcd_lt16_calcprho_tot'
19        ;experiment='colder_gcm_add_short'
20        ;experiment='colder_gcm_add'
21        experiment=''
22        ;experiment='wind15'
23        ;experiment='wind20c'
24        ;experiment='colder_gcm_add_3.9_fine_rad_mountain'
25        experiment='test'
26experiment='GW_MARS_highwind_3D.157077'
27experiment='GW_MARS_highwind_3D_lower_opacity.161436'
28experiment='GW_MARS_highwind_3D_loweropacity_lotspoints.161468'
29experiment='GW_MARS_highwind_3D_loweropacity_morepoints.161542'
30;experiment='GW_MARS_highwind_3D_loweropacity_morepoints_LT15.161544'
31;experiment='GW_MARS_highwind_3D_loweropacity_morepoints_LTcst.168440'
32;experiment='GW_MARS_highwind_3D_loweropacity_morepoints_widehill.168468'
33        file=path+experiment+'_wrfout_d01_9999-09-09_09:00:00_z'
34file=path+experiment+'/wrfout_d01_9999-09-09_09:00:00_z'
35;file=path+experiment+'/wrfout_d01_9999-09-09_10:00:00_z'
36;file=path+experiment+'/wrfout_d01_9999-09-09_11:00:00_z'
37charvar='W' & charvarc='W'
38charvar='tk' & charvarc='W'
39charvar='tk' & charvarc='W' & cond=1
40charvar='tpot' & charvarc='tpot'
41;charvar='PTOT' & charvarc='PTOT'
42charvar='tk' & charvarc='tk'
43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
44nts=1  & nte=15   & nxs=0   & nxe=59
45nts=3  & nte=nts  & nxs=999 & nxe=999 ;; moyenne ;; attention a la montagne !!!
46nts=4  & nte=nts  & nxs=31  & nxe=nxs ;; AU CENTRE ! sinon choisir le point en traçant de 0a 59
47nts=1  & nte=nts  & nxs=0   & nxe=59
48nts=4  & nte=nts  & nxs=0   & nxe=59
49nts=1  & nte=15   & nxs=31  & nxe=31
50nts=1  & nte=15   & nxs=45  & nxe=45
51nts=9  & nte=9    & nxs=0   & nxe=59
52nts=1  & nte=13   & nxs=59  & nxe=59
53nts=8  & nte=8    & nxs=0   & nxe=121
54nts=1  & nte=9    & nxs=59  & nxe=59
55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
56nts=1  & nte=10  & nxs=50   & nxe=50
57;nts=1  & nte=1  & nxs=6   & nxe=6
58nts=1  & nte=100  & nxs=50   & nxe=50
59nts=1  & nte=100  & nxs=60   & nxe=60
60nts=1  & nte=100  & nxs=20   & nxe=20
61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
62;
63;
64;
65what_I_plot=0. & overcontour=0.
66;SPAWN, '\rm param_plot.idl ; cp gravitwave_inc2.pro param_plot.idl'
67;
68;
69;
70getcdf, $
71        file=file, $
72        charvar=charvar, $
73        invar=invar
74;getcdf, $
75;        file=file, $
76;        charvar=charvarc, $
77;        invar=invarc
78getcdf, $
79        file=file, $
80        charvar='vert', $
81        invar=vert
82getcdf, $
83        file=file, $
84        charvar='PTOT', $
85        invar=columnp
86;;
87;;
88;;
89        s = size(invar) & middle = floor(s[2]/2) & print, 'PLOT at y subs ', middle
90        nte = min(s[4]-1,nte) & print, 'nte ', nte
91        mean_invar = TOTAL(invar(*,*,*,nts:nte),4) / float(nte-nts+1)
92        ;mean_columnp = TOTAL(columnp(*,*,*,nts:nte),4) / float(nte-nts+1)
93        anomal_invar = invar & for i=0,s[4]-1 do anomal_invar(*,*,*,i) = anomal_invar(*,*,*,i) - mean_invar
94;;
95;;
96;;
97;       goto, perturb
98for nt=nts,nte do begin
99for nx=nxs,nxe do begin
100;
101zefile=experiment+'_'+charvar+'_'+string(nt+100,'(I0)')+'_'+string(nx+100,'(I0)')
102;
103;
104;
105  PS_Start, filename=zefile+'.ps'
106  print, zefile+'.ps'
107  !P.Charsize = 1.2
108  !p.charthick = 2.0
109  !p.thick = 2.0
110  !x.thick = 2.0
111  !y.thick = 2.0
112;
113;
114;
115;;what_I_plot = reform(invar(*,1,*,nt))
116;what_I_plot = reform(invar(*,59,*,nt))
117what_I_plot = reform(invar(*,middle,*,nt))
118
119   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
120   file=path+experiment+'/input_sounding' & header='' & nlines_header=1 & ncol = 5
121   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
122   nlines = FILE_LINES(file)-nlines_header & data=FLTARR(ncol,nlines)
123   OPENR, lun, file, /GET_LUN & READF, lun, header & READF, lun, data & CLOSE, lun & FREE_LUN, lun
124   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
125   mcd_column      = reform(data(0,*))
126   calc_tpot       = reform(data(1,*))
127
128   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
129   file=path+experiment+'/input_therm' & ncol = 5
130   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
131   nlines = FILE_LINES(file) & data=FLTARR(ncol,nlines)
132   OPENR, lun, file, /GET_LUN & READF, lun, data & CLOSE, lun & FREE_LUN, lun
133   ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
134   pressure        = reform(data(2,*))
135   mcd_tpot        = reform(data(4,*))   
136
137   if (nx lt 999) then begin
138     what_I_plot = reform(what_I_plot(nx,*))
139   endif else begin
140     what_I_plot = TOTAL(what_I_plot,1) / n_elements(reform(what_I_plot(*,0)))
141   endelse
142
143     ;;;;;;;;;;;
144     ;;;;;;;;;;;
145     ;;;;;;;;;;;
146     column = vert/1000.
147     overplot_column = mcd_column/1000.
148     alt = [20.,150.]
149     alt = [40.,100.]
150     alt = [40.,80.]
151     alt = [0.,120.]
152     ;;;;;;;;;;;
153     ;;;;;;;;;;;
154     ;mention = ''
155     SPAWN, '\rm param_plot.idl'
156     minfield_init = 85.  ;100.
157     maxfield_init = 185. ;250.
158     title_axis = ['Temperature (K)','Altitude (km)']
159     overplot = mcd_tpot
160     ;;;;;;;;;;;
161     SPAWN, "echo 'intervaly=10.' >> param_plot.idl"
162     SPAWN, "echo 'intervalx=5.' >> param_plot.idl"
163     ;;;;;;;;;;;
164
165        ;overplot = reform(mean_invar(nx,middle,*))
166        ;overplot_column = column
167
168;;;;;;;;;;;;;;;;;;;;;;;;;;;; PLOT PRESSION mettre profile en log
169;column = reform(columnp(nx,middle,*,nt))
170;overplot_column = pressure
171;       ;;overplot = mean_invar
172;       ;;overplot_column = mean_columnp
173;alt = [1.e2,1.e-3]
174;title_axis = ['Temperature (K)','Pressure (Pa)']
175;;;;;;;;;;;;;;;;;;;;;;;;;;;;; PLOT PRESSION
176
177;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
178;; calculer la CAPE ? Tsat - Tenv / Tenv
179
180
181                        ;what_I_plot = pressure
182                        ;       what_I_plot = calc_tpot
183                        ;overplot = alog(overplot) / alog(10.)
184                        ;overplot = overplot[where(overplot lt 35.)] ;; evite les valeurs impossibles
185                        ;what_I_plot = alog(what_I_plot) / alog(10.)
186                        ;minfield_init = -5.
187                        ;maxfield_init = 3.
188                        ;       ;;tpot
189                        ;       minfield_init = 2.
190                        ;       maxfield_init = 4.
191                        ;what_I_plot = 100. * abs(calc_tpot - overplot) / overplot
192                        ;minfield_init = 0.000001
193                        ;maxfield_init = 100.
194
195   profile, $
196        what_I_plot, $                          ; 1D vertical profile
197        column, $                               ; altitudes     
198        alt=alt, $                              ; altitude range [altmin, altmax]
199        minfield=minfield_init, $               ; minimum value of plotted field (=0: calculate)
200        maxfield=maxfield_init, $               ; maximum value of plotted field (=0: calculate)
201        inprofile=overplot, $                   ; another vertical profile to overplot
202        incolumn=overplot_column, $             ; altitudes of the other vertical profile (in case /= column)
203;        discrete=discrete, $                    ; show the profile points (= type of points in !psym)
204;        title_plot=title_user, $                ; title of the plot ('Profile' is default)
205        title_axis=title_axis, $                ; title of the [x,y] axis (['Field','Altitude'] is default)
206        mention=mention                         ; add text precision within the plot window (default is nothing or '')
207
208        ;;; sponge layer
209        ;w=where(FINITE(overplot) ne 0)
210        ;oplot, [minfield_init,maxfield_init], [max(overplot_column[w])-50.,max(overplot_column[w])-50.], linestyle=1
211
212        ;column = columnp
213        ;@tempcond.inc
214        ;yeye = reform(overplot(nx,1,*,nt))
215        ;;w = where(yeye le 0.) & yeye[w] = !VALUES.F_NAN
216        ;;oplot, yeye, vert/1000., linestyle=1
217
218@tempcond.inc
219overplot = reform(overplot(nx,middle,*,nt))
220oplot, overplot, overplot_column, linestyle=1
221
222        ;calc_tk = calc_tpot * (pressure/610.)^(1/4.4)
223        ;oplot, calc_tk, column, linestyle=3
224
225PS_End, /PNG
226endfor
227endfor
228
229perturb:
230PS_Start, filename=experiment+'_'+charvar+'_perturb_'+string(nxs+100,'(I0)')+'.ps'
231
232     what_I_plot_loop = reform(anomal_invar(nxs,middle,*,*))
233
234     what_I_plot = reform(what_I_plot_loop(*,nts))
235     column = vert/1000.
236     ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
237     alt = [0.,120.]
238     minfield_init = -30.
239     maxfield_init = 30.
240     title_axis = ['Temperature anomaly (K)','Altitude (km)']
241                ;; peut pas changer     
242                ;SPAWN, "echo 'intervaly=10.' >> param_plot.idl"
243                ;SPAWN, "echo 'intervalx=5.' >> param_plot.idl"
244     ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
245     profile, $
246        what_I_plot, $                          ; 1D vertical profile
247        column, $                               ; altitudes     
248        alt=alt, $                              ; altitude range [altmin, altmax]
249        minfield=minfield_init, $               ; minimum value of plotted field (=0: calculate)
250        maxfield=maxfield_init, $               ; maximum value of plotted field (=0: calculate)
251        inprofile=overplot, $                   ; another vertical profile to overplot
252        incolumn=overplot_column, $             ; altitudes of the other vertical profile (in case /= column)
253;        discrete=discrete, $                    ; show the profile points (= type of points in !psym)
254;        title_plot=title_user, $                ; title of the plot ('Profile' is default)
255        title_axis=title_axis, $                ; title of the [x,y] axis (['Field','Altitude'] is default)
256        mention=mention                         ; add text precision within the plot window (default is nothing or '')
257
258     for iii=nts+1, nte do begin
259        overplot = reform(what_I_plot_loop(*,iii))
260        overplot_column = column
261        oplot, overplot, overplot_column
262     endfor
263
264        ;temppp = reform(mean_invar(nxs,middle,*))
265        ;hache = 191.*temppp/3.72/1000.
266        ;ok = column / ( 2. * hache )
267        ;print, exp(ok)
268        ;yeah = exp(ok)
269        ;oplot, yeah, column
270
271PS_End, /PNG
272
273end
Note: See TracBrowser for help on using the repository browser.