program reada dimension iyr(10),icnt(10),x(72,19) character hem*2,var*4,stat*4 c c reads monthly means of gelman stratospheric grids. c hem = hemisphere (NH or SH) c surf = pressure surface in mb c var = variable ID (TEMP or HGHT) c stat = statistic ID (MEAN or STDV) c nmon = number of months in mean, always 1 for year-month mean c number of months in average for long-term mean c mon = month of this field ( 1 to 12) c the following iyr/icnt pairs give year and count for that year. c for a year-month mean there will be only one pair. c iyr = year c icnt = number of fields in mean for this year (iyr) c c x = grid of data values; temp in deg K, height in geopotential meters c as i = 1,72; lon = 0 to 355E (eastward) c as j = 1,19; lat = 0 to 90N or 90S c c NOTE - Gelman sometimes has more than one mean for the same month. c The field count seems to indicate that the total fields for c the combination of these identical months is about right for c one month of data. These splits are generated when CAC makes c changes to their stratospheric corrections. c ku=5 nr=0 10 read(ku,1001,end=90) hem,surf,var,stat,nmon, 2 mon,(iyr(i),icnt(i),i=1,nmon) nr=nr+1 1001 format (a2,1x,f4.1,1x,a4,1x,a4,i3,31i3) read(ku,1002)((x(i,j),j=1,19),i=1,72) 1002 format(19f8.0) ave=0. xmx=x(1,1) xmn=x(1,1) do 20 j=1,19 do 20 i=1,72 ave=ave+x(i,j) if(x(i,j).gt.xmx) xmx=x(i,j) if(x(i,j).lt.xmn) xmn=x(i,j) 20 continue ave=ave/(19*72) write(*,1004)hem,surf,var,stat,ave,xmn,xmx,nmon,mon, 2 (iyr(i),icnt(i),i=1,nmon) 1004 format (a2,1x,f4.1,1x,a4,1x,a4,3f10.3,i3,21i3) go to 10 90 continue write(*,1003)nr 1003 format(' grids read = ',i8) end