!!!! output !!!!
      k=365
      open(80,file="ulast.asc")
      open(81,file="vlast.asc")
       do j=2,178
        do i=2,358
         if(lon(i,j).ge.120.5.and.lon(i,j).le.160.5)then
         if(lat(i,j).ge.20.5.and.lat(i,j).le.49.5)then
         if(uf(i-1,j-1,k).gt.-5.and.vf(i-1,j-1,k).gt.-5)then
         write(80,300) lon(i,j),lat(i,j),uf(i-1,j-1,k)
         write(81,300) lon(i,j),lat(i,j),vf(i-1,j-1,k)
         endif
         endif
         endif

        enddo
       enddo
      close(80)
      close(81)
300   format(3f10.4)

!121-161(31) 120.5E-160.5E
!41-70(20) 49.5-20.5N
      do j=41,70
       do i=121,161
       slaf(i-120,j-40)=sla3d(i,j,365)
       enddo
      enddo

      open(80,file='slaf.bin',form='unformatted',
     & access="direct",recl=41*30*4)
      write(80,rec=1) slaf
      close(80)
