Ignore:
Timestamp:
2019-11-25T23:31:07+01:00 (10 months ago)
Author:
laurent
Message:

Syntax improvements and minor bug fixes…

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r11085_ASINTER-05_Brodeau_Advanced_Bulk/src/OCE/SBC/sbcblk_algo_ecmwf.F90

    r11845 r11962  
    4444   PRIVATE 
    4545 
    46    PUBLIC :: ECMWF_INIT, TURB_ECMWF 
     46   PUBLIC :: SBCBLK_ALGO_ECMWF_INIT, TURB_ECMWF 
    4747 
    4848   !! ECMWF own values for given constants, taken form IFS documentation... 
     
    6161 
    6262 
    63    SUBROUTINE ecmwf_init(l_use_cs, l_use_wl) 
     63   SUBROUTINE sbcblk_algo_ecmwf_init(l_use_cs, l_use_wl) 
    6464      !!--------------------------------------------------------------------- 
    65       !!                  ***  FUNCTION ecmwf_init  *** 
     65      !!                  ***  FUNCTION sbcblk_algo_ecmwf_init  *** 
    6666      !! 
    6767      !! INPUT : 
     
    7777         ierr = 0 
    7878         ALLOCATE ( dT_wl(jpi,jpj), Hz_wl(jpi,jpj), STAT=ierr ) 
    79          IF( ierr > 0 ) CALL ctl_stop( ' ECMWF_INIT => allocation of dT_wl & Hz_wl failed!' ) 
     79         IF( ierr > 0 ) CALL ctl_stop( ' SBCBLK_ALGO_ECMWF_INIT => allocation of dT_wl & Hz_wl failed!' ) 
    8080         dT_wl(:,:)  = 0._wp 
    8181         Hz_wl(:,:)  = rd0 ! (rd0, constant, = 3m is default for Zeng & Beljaars) 
     
    8484         ierr = 0 
    8585         ALLOCATE ( dT_cs(jpi,jpj), STAT=ierr ) 
    86          IF( ierr > 0 ) CALL ctl_stop( ' ECMWF_INIT => allocation of dT_cs failed!' ) 
     86         IF( ierr > 0 ) CALL ctl_stop( ' SBCBLK_ALGO_ECMWF_INIT => allocation of dT_cs failed!' ) 
    8787         dT_cs(:,:) = -0.25_wp  ! First guess of skin correction 
    8888      END IF 
    89    END SUBROUTINE ecmwf_init 
     89   END SUBROUTINE sbcblk_algo_ecmwf_init 
    9090 
    9191 
     
    182182      LOGICAL :: l_zt_equal_zu = .FALSE.      ! if q and t are given at same height as U 
    183183      ! 
    184       REAL(wp), DIMENSION(jpi,jpj) ::  & 
    185          &  u_star, t_star, q_star, & 
    186          &  dt_zu, dq_zu,    & 
    187          &  znu_a,           & !: Nu_air, Viscosity of air 
    188          &  Linv,            & !: 1/L (inverse of Monin Obukhov length... 
    189          &  z0, z0t, z0q 
    190       ! 
    191       REAL(wp), DIMENSION(:,:), ALLOCATABLE :: & 
    192          &                zsst,   &  ! to back up the initial bulk SST 
    193          &                pdTc,   &  ! SST increment "dT" for cool-skin correction           [K] 
    194          &                pdTw       ! SST increment "dT" for warm layer correction          [K] 
    195       ! 
    196       REAL(wp), DIMENSION(jpi,jpj) ::   func_m, func_h 
    197       REAL(wp), DIMENSION(jpi,jpj) ::   ztmp0, ztmp1, ztmp2 
     184      REAL(wp), DIMENSION(jpi,jpj) ::  u_star, t_star, q_star 
     185      REAL(wp), DIMENSION(jpi,jpj) :: dt_zu, dq_zu      
     186      REAL(wp), DIMENSION(jpi,jpj) :: znu_a !: Nu_air, Viscosity of air 
     187      REAL(wp), DIMENSION(jpi,jpj) :: Linv  !: 1/L (inverse of Monin Obukhov length... 
     188      REAL(wp), DIMENSION(jpi,jpj) :: z0, z0t, z0q 
     189      ! 
     190      REAL(wp), DIMENSION(:,:), ALLOCATABLE :: zsst  ! to back up the initial bulk SST 
     191      ! 
     192      REAL(wp), DIMENSION(jpi,jpj) :: func_m, func_h 
     193      REAL(wp), DIMENSION(jpi,jpj) :: ztmp0, ztmp1, ztmp2 
    198194      CHARACTER(len=40), PARAMETER :: crtnm = 'turb_ecmwf@sbcblk_algo_ecmwf.F90' 
    199195      !!---------------------------------------------------------------------------------- 
    200196 
    201       IF ( kt == nit000 ) CALL ECMWF_INIT(l_use_cs, l_use_wl) 
     197      IF ( kt == nit000 ) CALL SBCBLK_ALGO_ECMWF_INIT(l_use_cs, l_use_wl) 
    202198 
    203199      l_zt_equal_zu = .FALSE. 
     
    367363            CALL WL_ECMWF( Qsw, ztmp1, u_star, zsst ) 
    368364            !! Updating T_s and q_s !!! 
    369             T_s(:,:) = zsst(:,:) + dT_wl(:,:)*tmask(:,:,1) 
     365            T_s(:,:) = zsst(:,:) + dT_wl(:,:)*tmask(:,:,1) ! 
    370366            IF( l_use_cs ) T_s(:,:) = T_s(:,:) + dT_cs(:,:)*tmask(:,:,1) 
    371367            q_s(:,:) = rdct_qsat_salt*q_sat(MAX(T_s(:,:), 200._wp), slp(:,:)) 
Note: See TracChangeset for help on using the changeset viewer.