dump_oce.f90 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. ! =====================
  2. ! SUBROUTINE OCEAN_DUMP
  3. ! =====================
  4. subroutine oce_dump
  5. use oceanmod
  6. character (len=256) :: yfn
  7. call step2cal(nstep,ntspd,iyea,imon,iday,ihou,imin)
  8. write(yfn,'("ocean_dump_",I4.4,4I2.2)') iyea,imon,iday,ihou,imin
  9. open(72,file=yfn)
  10. 100 format(a16,i16)
  11. write (72,100) 'nfluko',nfluko
  12. write (72,100) 'ndiag',ndiag
  13. write (72,100) 'noutput',noutput
  14. write (72,100) 'nout',nout
  15. write (72,100) 'nocean',nocean
  16. write (72,100) 'newsurf',newsurf
  17. write (72,100) 'ntspd',ntspd
  18. write (72,100) 'nperpetual_ocean',nperpetual_ocean
  19. write (72,100) 'nprint',nprint
  20. write (72,100) 'nprhor',nprhor
  21. write (72,100) 'nstep',nstep
  22. write (72,100) 'nrestart',nrestart
  23. write (72,100) 'naccuout',naccuout
  24. 200 format(a16,e20.10)
  25. write (72,200) 'taunc',taunc
  26. write (72,200) 'dlayer(1)',dlayer(1)
  27. write (72,200) 'vdiffk',vdiffk
  28. write (72,200) 'dtmix',dtmix
  29. write (72,200) 'solar_day',solar_day
  30. call oce_dump_hor('gw',gw)
  31. call oce_dump_hor('ysst',ysst)
  32. call oce_dump_hor('ymld',ymld)
  33. call oce_dump_hor('yls',yls)
  34. ! call oce_dump_hor('yicec',yicec)
  35. ! call oce_dump_hor('yiced',yiced)
  36. ! call oce_dump_hor('yheat',yheat)
  37. ! call oce_dump_hor('yfresh',yfresh)
  38. ! call oce_dump_hor('ytaux',ytaux)
  39. ! call oce_dump_hor('ytauy',ytauy)
  40. ! call oce_dump_hor('yust3',yust3)
  41. call oce_dump_hor('yiflux',yiflux)
  42. call oce_dump_hor('ydsst',ydsst)
  43. ! call oce_dump_hor('yclsst2',yclsst2)
  44. ! call oce_dump_hor('yfsst2',yfsst2)
  45. call oce_dump_hor('yheata',yheata)
  46. call oce_dump_hor('yfssta',yfssta)
  47. call oce_dump_hor('yifluxa',yifluxa)
  48. call oce_dump_hor('ydssta',ydssta)
  49. call oce_dump_hor14('yclsst',yclsst)
  50. call oce_dump_hor14('yfsst',yfsst)
  51. close(72)
  52. end
  53. subroutine oce_dump_hor(ya,pa)
  54. use oceanmod
  55. character (len=*) :: ya
  56. real :: pa(NHOR)
  57. write(72,'(/A)') trim(ya)
  58. do j = 1 , NHOR , 4
  59. write(72,'(i6,2x,4e18.10)') j,pa(j:j+3)
  60. enddo
  61. return
  62. end
  63. subroutine oce_dump_hor14(ya,pa)
  64. use oceanmod
  65. character (len=*) :: ya
  66. real :: pa(NHOR,14)
  67. do mon = 1 , 14
  68. write(72,'(/I2,2X,A)') mon-1,trim(ya)
  69. do j = 1 , NHOR , 4
  70. write(72,'(i6,2x,4e18.10)') j,pa(j:j+3,mon)
  71. enddo
  72. enddo
  73. return
  74. end