!!---------------------------------------------------------------------- !! *** tau_forced_daily.h90 *** !!---------------------------------------------------------------------- !!---------------------------------------------------------------------- !! tau : update the surface stress - daily fields in NetCDF file !!---------------------------------------------------------------------- !! * local modules variables INTEGER :: & numtau, & ! logical unit for the i-component of the wind data numtav, & ! logical unit for the j-component of the wind data ndaytau ! new day for ers/ncep tau forcing !!---------------------------------------------------------------------- !! OPA 9.0 , LOCEAN-IPSL (2005) !! $Header$ !! This software is governed by the CeCILL licence see modipsl/doc/NEMO_CeCILL.txt !!---------------------------------------------------------------------- CONTAINS SUBROUTINE tau( kt ) !!--------------------------------------------------------------------- !! *** ROUTINE tau *** !! !! ** Purpose : provide to the ocean the stress at each time step !! !! ** Method : Read the daily surface stress components in NetCDF !! file. They are given in the (i,j) referential !! The i-component is given at U-point (INTERP package) !! The j-component is given at V-point (INTERP package) !! !! CAUTION: never mask the surface stress field ! !! !! ** Action : update at each time-step the two components of the !! surface stress in both (i,j) and geographical referencial !! !! History : !! 4.0 ! 91-03 (G. Madec) Original code !! 6.0 ! 92-07 (M. Imbard) !! 8.1 ! 00-08 (D. Ludicone) adapted to ERS-NCEP !! 8.5 ! 02-11 (G. Madec) F90: Free form and module !! ! 03-07 (C. Ethe, G. Madec) daily generic forcing !!---------------------------------------------------------------------- USE iom ! NetCDF library INTEGER, INTENT( in ) :: kt ! ocean time step !!--------------------------------------------------------------------- ! -------------------- ! ! First call kt=nit000 ! ! -------------------- ! IF( kt == nit000 ) THEN ndaytau = 0 ! initialization IF(lwp) THEN WRITE(numout,*) ' ' WRITE(numout,*) ' tau : DAILY wind stress in NetCDF files' ENDIF ! open the files CALL iom_open ( 'taux_1d.nc', numtau ) CALL iom_open ( 'tauy_1d.nc', numtav ) ENDIF ! ----------------- ! ! Read daily file ! ! ----------------- ! IF ( ndaytau /= nday ) THEN ndaytau = nday ! Read daily wind stress data CALL iom_get ( numtau, jpdom_data, 'taux', taux, nday_year ) CALL iom_get ( numtav, jpdom_data, 'tauy', tauy, nday_year ) IF (lwp .AND. nitend-nit000 <= 100 ) THEN WRITE(numout,*) WRITE(numout,*) ' read daily wind stress ok' WRITE(numout,*) WRITE(numout,*) ' day: ', ndastp , ' taux: 1 multiply by ', 1. CALL prihre( taux, jpi, jpj, 1, jpi, 20, 1, jpj, 10, 1., numout ) WRITE(numout,*) WRITE(numout,*) ' day: ', ndastp , ' tauy: 1 multiply by ', 1. CALL prihre( tauy, jpi, jpj, 1, jpi, 20, 1, jpj, 10, 1., numout ) WRITE(numout,*) ' ' ENDIF CALL FLUSH(numout) ENDIF ! Save components in geographical ref on U grid tauxg(:,:) = taux(:,:) tauyg(:,:) = tauy(:,:) ! ------------------- ! ! Last call kt=nitend ! ! ------------------- ! ! Closing of the 2 files IF( kt == nitend ) THEN CALL iom_close( numtau ) CALL iom_close( numtav ) ENDIF END SUBROUTINE tau