ooo_intp.F90 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. MODULE ooo_intp
  2. !!======================================================================
  3. !! *** MODULE ooo_intp ***
  4. !! ** Purpose : Run NEMO observation operator in offline mode
  5. !!======================================================================
  6. !! NEMO modules
  7. USE in_out_manager
  8. USE diaobs
  9. !! Offline obs_oper modules
  10. USE ooo_read
  11. USE ooo_data
  12. IMPLICIT NONE
  13. PRIVATE
  14. PUBLIC ooo_interp
  15. !! $Id: ooo_intp.F90 2355 2015-05-20 07:11:50Z ufla $
  16. CONTAINS
  17. SUBROUTINE ooo_interp
  18. !!----------------------------------------------------------------------
  19. !! *** SUBROUTINE ooo_interp ***
  20. !!
  21. !! ** Purpose : To interpolate the model as if it were running online.
  22. !!
  23. !! ** Method : 1. Populate model counterparts
  24. !! 2. Call dia_obs at appropriate time steps
  25. !!----------------------------------------------------------------------
  26. INTEGER :: istp ! time step index
  27. !! Loop over entire run
  28. istp = nit000
  29. nstop = 0
  30. DO WHILE ( istp <= nitend .AND. nstop == 0 )
  31. IF (jifile <= n_files + 1) THEN
  32. IF ( MOD(istp, nn_ooo_freq) == nit000 ) THEN
  33. !! Read next model counterpart
  34. CALL ooo_rea_dri(jifile)
  35. jifile = jifile + 1
  36. ENDIF
  37. !! Interpolate single time step
  38. CALL dia_obs(istp)
  39. ENDIF
  40. !! Increment model step
  41. istp = istp + 1
  42. END DO
  43. END SUBROUTINE ooo_interp
  44. END MODULE ooo_intp