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 7646 for trunk/NEMOGCM/NEMO/TOP_SRC/TRP/trcadv.F90 – NEMO

Ignore:
Timestamp:
2017-02-06T10:25:03+01:00 (7 years ago)
Author:
timgraham
Message:

Merge of dev_merge_2016 into trunk. UPDATE TO ARCHFILES NEEDED for XIOS2.
LIM_SRC_s/limrhg.F90 to follow in next commit due to change of kind (I'm unable to do it in this commit).
Merged using the following steps:

1) svn merge --reintegrate svn+ssh://forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk .
2) Resolve minor conflicts in sette.sh and namelist_cfg for ORCA2LIM3 (due to a change in trunk after branch was created)
3) svn commit
4) svn switch svn+ssh://forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk
5) svn merge svn+ssh://forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/branches/2016/dev_merge_2016 .
6) At this stage I checked out a clean copy of the branch to compare against what is about to be committed to the trunk.
6) svn commit #Commit code to the trunk

In this commit I have also reverted a change to Fcheck_archfile.sh which was causing problems on the Paris machine.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEMOGCM/NEMO/TOP_SRC/TRP/trcadv.F90

    r6140 r7646  
    5757   INTEGER ::              nadv             ! chosen advection scheme 
    5858   ! 
    59    REAL(wp) ::   r2dttrc  ! vertical profile time-step, = 2 rdt 
    60    !                                                    ! except at nitrrc000 (=rdt) if neuler=0 
    61  
    6259   !! * Substitutions 
    6360#  include "vectopt_loop_substitute.h90" 
     
    8784      ! 
    8885      CALL wrk_alloc( jpi,jpj,jpk,   zun, zvn, zwn ) 
    89       ! 
    90       IF( ( neuler == 0 .AND. kt == nittrc000 ) .OR. ln_top_euler ) THEN     ! at nittrc000 
    91          r2dttrc =  rdttrc           ! = rdttrc (use or restarting with Euler time stepping) 
    92       ELSEIF( kt <= nittrc000 + nn_dttrc ) THEN          ! at nittrc000 or nittrc000+1 
    93          r2dttrc = 2. * rdttrc       ! = 2 rdttrc (leapfrog) 
    94       ENDIF 
    9586      !                                               !==  effective transport  ==! 
    96       DO jk = 1, jpkm1 
    97          zun(:,:,jk) = e2u  (:,:) * e3u_n(:,:,jk) * un(:,:,jk)                   ! eulerian transport 
    98          zvn(:,:,jk) = e1v  (:,:) * e3v_n(:,:,jk) * vn(:,:,jk) 
    99          zwn(:,:,jk) = e1e2t(:,:)                 * wn(:,:,jk) 
    100       END DO 
    101       ! 
    102       IF( ln_vvl_ztilde .OR. ln_vvl_layer ) THEN                                 ! add z-tilde and/or vvl corrections 
    103          zun(:,:,:) = zun(:,:,:) + un_td(:,:,:) 
    104          zvn(:,:,:) = zvn(:,:,:) + vn_td(:,:,:) 
    105       ENDIF 
    106       ! 
    107       IF( ln_ldfeiv .AND. .NOT. ln_traldf_triad )   &  
    108          &              CALL ldf_eiv_trp( kt, nittrc000, zun, zvn, zwn, 'TRC' )  ! add the eiv transport 
    109       ! 
    110       IF( ln_mle    )   CALL tra_adv_mle( kt, nittrc000, zun, zvn, zwn, 'TRC' )  ! add the mle transport 
    111       ! 
    112       zun(:,:,jpk) = 0._wp                                                       ! no transport trough the bottom 
    113       zvn(:,:,jpk) = 0._wp 
    114       zwn(:,:,jpk) = 0._wp 
    115       ! 
     87      IF( l_offline ) THEN 
     88         zun(:,:,:) = un(:,:,:)     ! effective transport already in un/vn/wn 
     89         zvn(:,:,:) = vn(:,:,:) 
     90         zwn(:,:,:) = wn(:,:,:) 
     91      ELSE 
     92         !        
     93         DO jk = 1, jpkm1 
     94            zun(:,:,jk) = e2u  (:,:) * e3u_n(:,:,jk) * un(:,:,jk)                   ! eulerian transport 
     95            zvn(:,:,jk) = e1v  (:,:) * e3v_n(:,:,jk) * vn(:,:,jk) 
     96            zwn(:,:,jk) = e1e2t(:,:)                 * wn(:,:,jk) 
     97         END DO 
     98         ! 
     99         IF( ln_vvl_ztilde .OR. ln_vvl_layer ) THEN                                 ! add z-tilde and/or vvl corrections 
     100            zun(:,:,:) = zun(:,:,:) + un_td(:,:,:) 
     101            zvn(:,:,:) = zvn(:,:,:) + vn_td(:,:,:) 
     102         ENDIF 
     103         ! 
     104         IF( ln_ldfeiv .AND. .NOT. ln_traldf_triad )   &  
     105            &              CALL ldf_eiv_trp( kt, nittrc000, zun, zvn, zwn, 'TRC' )  ! add the eiv transport 
     106         ! 
     107         IF( ln_mle    )   CALL tra_adv_mle( kt, nittrc000, zun, zvn, zwn, 'TRC' )  ! add the mle transport 
     108         ! 
     109         zun(:,:,jpk) = 0._wp                                                       ! no transport trough the bottom 
     110         zvn(:,:,jpk) = 0._wp 
     111         zwn(:,:,jpk) = 0._wp 
     112         ! 
     113      ENDIF 
    116114      ! 
    117115      SELECT CASE ( nadv )                      !==  compute advection trend and add it to general trend  ==! 
Note: See TracChangeset for help on using the changeset viewer.