[85] | 1 | pro gravitwaveprof |
---|
| 2 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 3 | |
---|
| 4 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 5 | path='/donnees/aslmd/MODELES/LMD_MM_MARS/TESTGW/' |
---|
| 6 | experiment='mcd_lt16_rcpcst' |
---|
| 7 | ;experiment='mcd_lt16' |
---|
| 8 | ;experiment='short_mcd_lt16_rcpcst' |
---|
| 9 | ;experiment='short_mcd_lt16' |
---|
| 10 | ;experiment='short_mcd_lt16_calcprho' |
---|
| 11 | ;experiment='mcd_lt16_calcprho' |
---|
| 12 | ;experiment='short_mcd_lt16_calcprho_tot' |
---|
| 13 | ;experiment='colder_gcm_add_short' |
---|
| 14 | ;experiment='colder_gcm_add' |
---|
| 15 | experiment='' |
---|
| 16 | ;experiment='colder_gcm_add_3.9_fine_rad_mountain' |
---|
| 17 | file=path+experiment+'_wrfout_d01_9999-09-09_09:00:00_z' |
---|
| 18 | charvar='W' & charvarc='W' |
---|
| 19 | charvar='tk' & charvarc='W' |
---|
| 20 | charvar='tk' & charvarc='W' & cond=1 |
---|
| 21 | charvar='tpot' & charvarc='tpot' |
---|
| 22 | ;charvar='PTOT' & charvarc='PTOT' |
---|
| 23 | charvar='tk' & charvarc='tk' |
---|
| 24 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 25 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 26 | ; |
---|
| 27 | ; |
---|
| 28 | ; |
---|
| 29 | what_I_plot=0. & overcontour=0. |
---|
| 30 | ;SPAWN, '\rm param_plot.idl ; cp gravitwave_inc2.pro param_plot.idl' |
---|
| 31 | ; |
---|
| 32 | ; |
---|
| 33 | ; |
---|
| 34 | getcdf, $ |
---|
| 35 | file=file, $ |
---|
| 36 | charvar=charvar, $ |
---|
| 37 | invar=invar |
---|
| 38 | getcdf, $ |
---|
| 39 | file=file, $ |
---|
| 40 | charvar=charvarc, $ |
---|
| 41 | invar=invarc |
---|
| 42 | getcdf, $ |
---|
| 43 | file=file, $ |
---|
| 44 | charvar='vert', $ |
---|
| 45 | invar=vert |
---|
| 46 | getcdf, $ |
---|
| 47 | file=file, $ |
---|
| 48 | charvar='PTOT', $ |
---|
| 49 | invar=columnp |
---|
| 50 | ; |
---|
| 51 | ; |
---|
| 52 | ; |
---|
| 53 | for nt=1,10 do begin |
---|
| 54 | ;for nt=3,3 do begin |
---|
| 55 | ;for nt=1,1 do begin |
---|
| 56 | ;for nx=0,59 do begin |
---|
| 57 | ;for nx=1,1 do begin |
---|
| 58 | ;for nx=999,999 do begin ;; moyenne ;; attention a la montagne !!! |
---|
| 59 | for nx=30,30 do begin |
---|
| 60 | zefile=experiment+'_'+charvar+'_'+string(nt+100,'(I0)')+'_'+string(nx+100,'(I0)') |
---|
| 61 | ; |
---|
| 62 | ; |
---|
| 63 | ; |
---|
| 64 | PS_Start, filename=zefile+'.ps' |
---|
| 65 | print, zefile+'.ps' |
---|
| 66 | !P.Charsize = 1.2 |
---|
| 67 | !p.charthick = 2.0 |
---|
| 68 | !p.thick = 2.0 |
---|
| 69 | !x.thick = 2.0 |
---|
| 70 | !y.thick = 2.0 |
---|
| 71 | ; |
---|
| 72 | ; |
---|
| 73 | ; |
---|
| 74 | what_I_plot = reform(invar(*,1,*,nt)) |
---|
| 75 | |
---|
| 76 | ;logp = -10.*alog(reform(columnp(nx,1,*,nt))/610.) |
---|
| 77 | ;vert = logp |
---|
| 78 | |
---|
| 79 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 80 | file=path+experiment+'/input_sounding' & header='' & nlines_header=1 & ncol = 5 |
---|
| 81 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 82 | nlines = FILE_LINES(file)-nlines_header & data=FLTARR(ncol,nlines) |
---|
| 83 | OPENR, lun, file, /GET_LUN & READF, lun, header & READF, lun, data & CLOSE, lun & FREE_LUN, lun |
---|
| 84 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 85 | mcd_column = reform(data(0,*)) |
---|
| 86 | calc_tpot = reform(data(1,*)) |
---|
| 87 | |
---|
| 88 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 89 | file=path+experiment+'/input_therm' & ncol = 5 |
---|
| 90 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 91 | nlines = FILE_LINES(file) & data=FLTARR(ncol,nlines) |
---|
| 92 | OPENR, lun, file, /GET_LUN & READF, lun, data & CLOSE, lun & FREE_LUN, lun |
---|
| 93 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
---|
| 94 | pressure = reform(data(2,*)) |
---|
| 95 | mcd_tpot = reform(data(4,*)) |
---|
| 96 | |
---|
| 97 | |
---|
| 98 | ;nx = 1;30;59;10 |
---|
| 99 | if (nx lt 999) then begin |
---|
| 100 | overplot = reform(what_I_plot(nx,*)) |
---|
| 101 | endif else begin |
---|
| 102 | overplot = TOTAL(what_I_plot,1) / n_elements(reform(what_I_plot(*,0))) |
---|
| 103 | endelse |
---|
| 104 | overplot_column = vert/1000. |
---|
| 105 | column = mcd_column/1000. |
---|
| 106 | mention = '' |
---|
| 107 | alt = [0.,150.] |
---|
| 108 | SPAWN, '\rm param_plot.idl' |
---|
| 109 | |
---|
| 110 | ;what_I_plot = pressure |
---|
| 111 | ; what_I_plot = calc_tpot |
---|
| 112 | ;overplot = alog(overplot) / alog(10.) |
---|
| 113 | ;overplot = overplot[where(overplot lt 35.)] ;; evite les valeurs impossibles |
---|
| 114 | ;what_I_plot = alog(what_I_plot) / alog(10.) |
---|
| 115 | ;minfield_init = -5. |
---|
| 116 | ;maxfield_init = 3. |
---|
| 117 | ; ;;tpot |
---|
| 118 | ; minfield_init = 2. |
---|
| 119 | ; maxfield_init = 4. |
---|
| 120 | |
---|
| 121 | what_I_plot = mcd_tpot |
---|
| 122 | minfield_init = 100. |
---|
| 123 | maxfield_init = 250. |
---|
| 124 | |
---|
| 125 | ;what_I_plot = 100. * abs(calc_tpot - overplot) / overplot |
---|
| 126 | ;minfield_init = 0.000001 |
---|
| 127 | ;maxfield_init = 100. |
---|
| 128 | |
---|
| 129 | profile, $ |
---|
| 130 | what_I_plot, $ ; 1D vertical profile |
---|
| 131 | column, $ ; altitudes |
---|
| 132 | alt=alt, $ ; altitude range [altmin, altmax] |
---|
| 133 | minfield=minfield_init, $ ; minimum value of plotted field (=0: calculate) |
---|
| 134 | maxfield=maxfield_init, $ ; maximum value of plotted field (=0: calculate) |
---|
| 135 | inprofile=overplot, $ ; another vertical profile to overplot |
---|
| 136 | incolumn=overplot_column, $ ; altitudes of the other vertical profile (in case /= column) |
---|
| 137 | ; discrete=discrete, $ ; show the profile points (= type of points in !psym) |
---|
| 138 | ; title_plot=title_user, $ ; title of the plot ('Profile' is default) |
---|
| 139 | ; title_axis=title_axis, $ ; title of the [x,y] axis (['Field','Altitude'] is default) |
---|
| 140 | mention=mention ; add text precision within the plot window (default is nothing or '') |
---|
| 141 | |
---|
| 142 | ;; sponge layer |
---|
| 143 | w=where(FINITE(overplot) ne 0) |
---|
| 144 | oplot, [minfield_init,maxfield_init], [max(overplot_column[w])-50.,max(overplot_column[w])-50.], linestyle=1 |
---|
| 145 | |
---|
| 146 | ;calc_tk = calc_tpot * (pressure/610.)^(1/4.4) |
---|
| 147 | ;oplot, calc_tk, column, linestyle=3 |
---|
| 148 | |
---|
| 149 | PS_End, /PNG |
---|
| 150 | endfor |
---|
| 151 | endfor |
---|
| 152 | end |
---|