New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 7352 for branches/2016/dev_r7233_CMIP6_diags_trunk_version/NEMOGCM/NEMO/OPA_SRC/TRA/traadv_ubs.F90 – NEMO

Ignore:
Timestamp:
2016-11-28T17:52:03+01:00 (7 years ago)
Author:
timgraham
Message:

Changes suggested byt reviewer

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2016/dev_r7233_CMIP6_diags_trunk_version/NEMOGCM/NEMO/OPA_SRC/TRA/traadv_ubs.F90

    r7236 r7352  
    1919   USE trdtra         ! trends manager: tracers  
    2020   USE diaptr         ! poleward transport diagnostics 
     21   USE diaar5         ! AR5 diagnostics 
     22 
    2123   ! 
     24   USE iom 
    2225   USE lib_mpp        ! I/O library 
    2326   USE lbclnk         ! ocean lateral boundary condition (or mpp link) 
     
    3235   PUBLIC   tra_adv_ubs   ! routine called by traadv module 
    3336 
    34    LOGICAL :: l_trd  ! flag to compute trends or not 
     37   LOGICAL :: l_trd   ! flag to compute trends 
     38   LOGICAL :: l_ptr   ! flag to compute poleward transport 
     39   LOGICAL :: l_hst   ! flag to compute heat transport 
     40 
    3541 
    3642   !! * Substitutions 
     
    109115      ! 
    110116      l_trd = .FALSE. 
    111       IF( ( cdtype == 'TRA' .AND. l_trdtra ) .OR. ( cdtype == 'TRC' .AND. l_trdtrc ) ) l_trd = .TRUE. 
     117      l_hst = .FALSE. 
     118      l_ptr = .FALSE. 
     119      IF( ( cdtype == 'TRA' .AND. l_trdtra ) .OR. ( cdtype == 'TRC' .AND. l_trdtrc ) )      l_trd = .TRUE. 
     120      IF(   cdtype == 'TRA' .AND. ln_diaptr )                                               l_ptr = .TRUE.  
     121      IF(   cdtype == 'TRA' .AND. ( iom_use("uadv_heattr") .OR. iom_use("vadv_heattr") .OR. & 
     122         &                          iom_use("uadv_salttr") .OR. iom_use("vadv_salttr")  ) ) l_hst = .TRUE. 
    112123      ! 
    113124      ztw (:,:, 1 ) = 0._wp      ! surface & bottom value : set to zero for all tracers 
     
    176187             CALL trd_tra( kt, cdtype, jn, jptra_yad, ztv, pvn, ptn(:,:,:,jn) ) 
    177188         END IF 
    178          !                                 ! "Poleward" heat and salt transports (contribution of upstream fluxes) 
    179          IF( cdtype == 'TRA' .AND. ln_diaptr ) CALL dia_ptr_ohst_components( jn, 'adv', ztv(:,:,:) ) 
     189         !      
     190         !                                ! "Poleward" heat and salt transports (contribution of upstream fluxes) 
     191         IF( l_ptr )  CALL dia_ptr_hst( jn, 'adv', ztv(:,:,:) ) 
     192         !                                !  heati/salt transport 
     193         IF( l_hst )  CALL dia_ar5_hst( jn, 'adv', ztu(:,:,:), ztv(:,:,:) ) 
     194         ! 
    180195         ! 
    181196         !                       !== vertical advective trend  ==! 
Note: See TracChangeset for help on using the changeset viewer.