; Procedure to plot SLODAR results ; Input: month and date of the evening pro glseeing, mm, dd ; slodar data selection restore, 'slodar.idl' ; ---------slodar structure: ; prof = { UTyear: 0, UTmonth: 0, UTday: 0, UT: 0.0, $ ; r0: 0.0, alt:FLTARR(9), Intcn2:FLTARR(9) } ; wrong (evening) dates in the CN2 files! eve = where((slodat.UTmonth eq mm) and (slodat.UTday eq dd) ) morn = -1 nmorn = 0 ; Correct UT dates ;eve = where((slodat.UTmonth eq mm) and (slodat.UTday eq dd) and (slodat.UThour gt 12) ) ;dd1 = dd+1 & mm1 = mm ;if (dd1 gt 30) then begin dd1=1 & mm1=mm+1 & endif ;morn = where((slodat.UTmonth eq mm1) and (slodat.UTday eq dd1) and (slodat.UThour lt 12) ) neve = n_elements(eve) nmorn = n_elements(morn) nslo = neve + nmorn if (nslo eq 0) then return prof = slodat[0] out = replicate(prof,nslo) out(0:neve-1) = slodat(eve) ;out(neve:nslo-1) = slodat(morn) utslo = fltarr(nslo) for i=0,nslo-1 do utslo[i] = out[i].UT print, 'Total SLODAR profiles found: ', nslo print, 'UT range: ',utslo[0], utslo[nslo-1] nalt = 8 tmp = fltarr(nslo,nalt) for i=0,nslo-1 do tmp(i,*) = out[i].intcn2(0:nalt-1) ; -------------------- SODAR data selection restore, 'sodar.idl' ; prof = { UTyear: 0, UTmonth: 0, UTday: 0, UThour:0.0, UTmin:0.0, $ ; nlevels:40, alt:FLTARR(40), ct2:FLTARR(40) } eve = where((spdat.UTmonth eq mm) and (spdat.UTday eq dd) and (spdat.UThour gt 12) ) dd1 = dd+1 & mm1 = mm if (dd1 gt 30) then begin dd1=1 & mm1=mm+1 & endif morn = where((spdat.UTmonth eq mm1) and (spdat.UTday eq dd1) and (spdat.UThour lt 12) ) neve = n_elements(eve) nmorn = n_elements(morn) nsod = neve + nmorn prof = spdat[0] sod = replicate(prof,nsod) sod(0:neve-1) = spdat(eve) sod(neve:nsod-1) = spdat(morn) nalt = 40 utsod = fltarr(nsod) for i=0,nsod-1 do utsod[i] = sod[i].UThour+sod[i].UTmin/60. utsod(0:neve-1) = utsod(0:neve-1)-24. utsod = utsod +3 - 1./6. ; from local time to UT print, 'Total SODAR profiles found: ', nsod print, 'UT range: ',utsod[0], utsod[nsod-1] ;--------MASS-DIMM data -------------------------------- restore, 'massdimm.idl' ; mddat structure: ; prof = { UTyear: 0, UTmonth: 0, UTday: 0, UTmass:0.0, $ ; fsee:0.0, Intcn2:FLTARR(6), UTdimm:0.0, see:0.0 } ;eve = where((mddat.UTmonth eq mm) and (mddat.UTday eq dd) and (mddat.UTmass gt 12) ) dd1 = dd+1 & mm1 = mm if (dd1 gt 30) then begin dd1=1 & mm1=mm+1 & endif morn = where((mddat.UTmonth eq mm1) and (mddat.UTday eq dd1) and (mddat.UTmass lt 12) ) ;neve = n_elements(eve) neve = 0 nmorn = n_elements(morn) nmd = neve + nmorn prof = mddat[0] md = replicate(prof,nmd) ; md(0:neve-1) = mddat(eve) md(neve:nmd-1) = mddat(morn) utmd = fltarr(nmd) for i=0,nmd-1 do utmd[i] = md[i].UTmass ;---------------------------------------------------- ; Data analysis ;------------------------------------------------------- p = 772D0 ; pressure, hpa t = 10D0 ; temperature, Celsius coef = (8e-5*p*(273+t)^(-2))^2*1d13 sodsee = fltarr(nsod) for i=0,nsod-1 do sodsee[i] =(total(sod[i].ct2)*20*coef/6.8)^0.6 slosee = fltarr(nslo) hmax = 500 for i=0,nslo-1 do begin dh = out[i].alt[1] - out[i].alt[0] int = 0. for j=0,7 do if (out[i].alt[j] le hmax) then int = int+out[i].intcn2[j] slosee[i] =(int/6.8e2)^0.6 endfor mdsee = fltarr(nmd) for i=0,nmd-1 do begin gint = (md[i].see^(5./3.) - md[i].fsee^(5./3.) ) > 0. mdsee[i] = gint^0.6 endfor !p.charsize = 1.5 !x.style=1 plot, utslo(0:nslo-2), slosee(0:nslo-2), xtitle='UT, hours', ytitle='Seeing, arcsec',xr=[0,9],yr=[0,1.5] oplot, utsod, sodsee, psym=2 oplot, utmd, mdsee, linestyle=2 xyouts, 4, 1.3, 'Dec '+string(dd,format='(I2)')+'/'+string(dd1,format='(I2)') ;stop end