C============================================================== C c calculation of longitudinal harmonics c c in NCAR/NCEP Geopotential height data C c============================================================== c------------------------------ 3-hourly data for Nov-Apr PARAMETER (IDAY=1448) PARAMETER (ILON=64) PARAMETER (ILAT=36) parameter (kgit=23) parameter (nvar=3) REAL ave_Clim(ILON,ILAT,kgit,nvar), $av_10_1(ILON,ILAT,kgit,nvar),av_10_2(ILON,ILAT,kgit,nvar), $av_10_3(ILON,ILAT,kgit,nvar),av_10_4(ILON,ILAT,kgit,nvar), $ aus1(ILON,ILAT,kgit,nvar),aus2(ILON,ILAT,kgit,nvar), $ aus3(ILON,ILAT,kgit,nvar),aus4(ILON,ILAT,kgit,nvar), $ aus5(ILON,ILAT,kgit,nvar),aus6(ILON,ILAT,kgit,nvar), $ aus7(ILON,ILAT,kgit,nvar),aus8(ILON,ILAT,kgit,nvar), $ aus9(ILON,ILAT,kgit,nvar),aus10(ILON,ILAT,kgit,nvar) C....OUTPUTFILES OPEN (1300, FILE='UVT_ave_1981_90.dx', $ form='unformatted', $ access='direct', status='new',recl=4*ILON*ILAT*kgit*nvar) c....INPUTFILE OPEN (101,FILE= $'e:/Merra2/Climate/1981/uvt_merra2_1980_1981_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (102,FILE= $'e:/Merra2/Climate/1982/uvt_merra2_1981_1982_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (103,FILE= $'e:/Merra2/wQBO/1983/uvt_merra2_1982_1983_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (104,FILE= $'e:/Merra2/Climate/1984/uvt_merra2_1983_1984_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (105,FILE= $'e:/Merra2/wQBO/1985/uvt_merra2_1984_1985_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (106,FILE= $'e:/Merra2/Climate/1986/uvt_merra2_1985_1986_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (107, $FILE='e:/Merra2/eQBO/1987/uvt_merra2_1986_1987_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (108,FILE= $'e:/Merra2/Climate/1988/uvt_merra2_1987_1988_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (109, $FILE='e:/Merra2/eQBO/1989/uvt_merra2_1988_1989_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (110,FILE= $'e:/Merra2/Climate/1990/uvt_merra2_1989_1990_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) c DO l=1,IDAY read(101,rec=l) aus1 read(102,rec=l) aus2 read(103,rec=l) aus3 read(104,rec=l) aus4 read(105,rec=l) aus5 read(106,rec=l) aus6 read(107,rec=l) aus7 read(108,rec=l) aus8 read(109,rec=l) aus9 read(110,rec=l) aus10 do mm=1,3 do k=1,kgit do j=1,ILAT do i=1,ILON av_10_1(i,j,k,mm)=(aus1(i,j,k,mm)+aus2(i,j,k,mm)+ $ aus3(i,j,k,mm)+aus4(i,j,k,mm)+ $ aus5(i,j,k,mm)+aus6(i,j,k,mm)+ $ aus7(i,j,k,mm)+aus8(i,j,k,mm)+ $ aus9(i,j,k,mm)+aus10(i,j,k,mm))/10. end do end do end do end do write(1300,rec=l) av_10_1 END DO close (110) close (109) close (108) close (107) close (106) close (105) close (104) close (103) close (102) close (101) close (1300) C....OUTPUTFILES OPEN (1301, FILE='UVT_ave_1991_00.dx', $ form='unformatted', $ access='direct', status='new',recl=4*ILON*ILAT*kgit*nvar) c....INPUTFILE OPEN (201,FILE= $'e:/Merra2/Climate/1991/uvt_merra2_1990_1991_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (202,FILE= $'e:/Merra2/Climate/1992/uvt_merra2_1991_1992_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (203, $FILE='e:/Merra2/wQBO/1993/uvt_merra2_1992_1993_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (204,FILE= $'e:/Merra2/Climate/1994/uvt_merra2_1993_1994_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (205, $FILE='e:/Merra2/wQBO/1995/uvt_merra2_1994_1995_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (206, $FILE='e:/Merra2/eQBO/1996/uvt_merra2_1995_1996_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (207, $FILE='e:/Merra2/wQBO/1997/uvt_merra2_1996_1997_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (208, $FILE='e:/Merra2/eQBO/1998/uvt_merra2_1997_1998_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (209, $FILE='e:/Merra2/wQBO/1999/uvt_merra2_1998_1999_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (210, $FILE='e:/Merra2/eQBO/2000/uvt_merra2_1999_2000_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) c DO l=1,IDAY read(201,rec=l) aus1 read(202,rec=l) aus2 read(203,rec=l) aus3 read(204,rec=l) aus4 read(205,rec=l) aus5 read(206,rec=l) aus6 read(207,rec=l) aus7 read(208,rec=l) aus8 read(209,rec=l) aus9 read(210,rec=l) aus10 do mm=1,3 do k=1,kgit do j=1,ILAT do i=1,ILON av_10_2(i,j,k,mm)=(aus1(i,j,k,mm)+aus2(i,j,k,mm)+ $ aus3(i,j,k,mm)+aus4(i,j,k,mm)+ $ aus5(i,j,k,mm)+aus6(i,j,k,mm)+ $ aus7(i,j,k,mm)+aus8(i,j,k,mm)+ $ aus9(i,j,k,mm)+aus10(i,j,k,mm))/10. end do end do end do end do write(1301,rec=l) av_10_2 END DO close (210) close (209) close (208) close (207) close (206) close (205) close (204) close (203) close (202) close (201) close (1301) C....OUTPUTFILES OPEN (1302, FILE='UVT_ave_2001_2010.dx', $ form='unformatted', $ access='direct', status='new',recl=4*ILON*ILAT*kgit*nvar) c....INPUTFILE OPEN (301,FILE= $'e:/Merra2/Climate/2001/uvt_merra2_2000_2001_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (302, $FILE='e:/Merra2/wQBO/2002/uvt_merra2_2001_2002_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (303, $FILE='e:/Merra2/eQBO/2003/uvt_merra2_2002_2003_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (304, $FILE='e:/Merra2/wQBO/2004/uvt_merra2_2003_2004_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (305, $FILE='e:/Merra2/eQBO/2005/uvt_merra2_2004_2005_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (306,FILE= $'e:/Merra2/Climate/2006/uvt_merra2_2005_2006_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (307, $FILE='e:/Merra2/eQBO/2007/uvt_merra2_2006_2007_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (308, $FILE='e:/Merra2/wQBO/2008/uvt_merra2_2007_2008_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (309,FILE= $'e:/Merra2/Climate/2009/uvt_merra2_2008_2009_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (310, $FILE='e:/Merra2/eQBO/2010/uvt_merra2_2009_2010_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) c DO l=1,IDAY read(301,rec=l) aus1 read(302,rec=l) aus2 read(303,rec=l) aus3 read(304,rec=l) aus4 read(305,rec=l) aus5 read(306,rec=l) aus6 read(307,rec=l) aus7 read(308,rec=l) aus8 read(309,rec=l) aus9 read(310,rec=l) aus10 do mm=1,3 do k=1,kgit do j=1,ILAT do i=1,ILON av_10_3(i,j,k,mm)=(aus1(i,j,k,mm)+aus2(i,j,k,mm)+ $ aus3(i,j,k,mm)+aus4(i,j,k,mm)+ $ aus5(i,j,k,mm)+aus6(i,j,k,mm)+ $ aus7(i,j,k,mm)+aus8(i,j,k,mm)+ $ aus9(i,j,k,mm)+aus10(i,j,k,mm))/10. end do end do end do end do write(1302,rec=l) av_10_3 END DO close (310) close (309) close (308) close (307) close (306) close (305) close (304) close (303) close (302) close (301) close (1302) C....OUTPUTFILES OPEN (1303, FILE='UVT_av_2011_2020.dx', $ form='unformatted', $ access='direct', status='new',recl=4*ILON*ILAT*kgit*nvar) OPEN (1304, FILE='UVT_av_Climate.dx', $ form='unformatted', $ access='direct', status='new',recl=4*ILON*ILAT*kgit*nvar) c....INPUTFILE OPEN (401,FILE= $'e:/Merra2/Climate/2011/uvt_merra2_2010_2011_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (402, $FILE='e:/Merra2/eQBO/2012/uvt_merra2_2011_2012_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (403, $FILE='e:/Merra2/wQBO/2013/uvt_merra2_2012_2013_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (404,FILE= $'e:/Merra2/Climate/2014/uvt_merra2_2013_2014_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (405,FILE= $'e:/Merra2/Climate/2015/uvt_merra2_2014_2015_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (406,FILE= $'e:/Merra2/Climate/2016/uvt_merra2_2015_2016_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (407,FILE= $'e:/Merra2/Climate/2017/uvt_merra2_2016_2017_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (408,FILE= $'e:/Merra2/Climate/2018/uvt_merra2_2017_2018_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (409,FILE= $'e:/Merra2/Climate/2019/uvt_merra2_2018_2019_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) OPEN (410,FILE= $'e:/Merra2/Climate/2020/uvt_merra2_2019_2020_x64y36z23v3.bin', $ form='unformatted', $ access='direct', status='old',recl=4*ILON*ILAT*kgit*nvar) c DO l=1,IDAY read(401,rec=l) aus1 read(402,rec=l) aus2 read(403,rec=l) aus3 read(404,rec=l) aus4 read(405,rec=l) aus5 read(406,rec=l) aus6 read(407,rec=l) aus7 read(408,rec=l) aus8 read(409,rec=l) aus9 read(410,rec=l) aus10 c do mm=1,3 do k=1,kgit do j=1,ILAT do i=1,ILON av_10_4(i,j,k,mm)=(aus1(i,j,k,mm)+aus2(i,j,k,mm)+ $ aus3(i,j,k,mm)+aus4(i,j,k,mm)+ $ aus5(i,j,k,mm)+aus6(i,j,k,mm)+ $ aus7(i,j,k,mm)+aus8(i,j,k,mm)+ $ aus9(i,j,k,mm)+aus10(i,j,k,mm))/10. ave_Clim(i,j,k,mm)=(av_10_1(i,j,k,mm)+ $ av_10_2(i,j,k,mm)+ $ av_10_3(i,j,k,mm)+ $ av_10_4(i,j,k,mm))/2. end do end do end do end do write(1303,rec=l) av_10_4 write(1304,rec=l) ave_Clim END DO STOP END