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 14644 for NEMO/branches/2020/dev_r14116_HPC-04_mcastril_Mixed_Precision_implementation_final/src/OCE/DYN/sshwzv.F90 – NEMO

Ignore:
Timestamp:
2021-03-26T15:33:49+01:00 (3 years ago)
Author:
sparonuz
Message:

Merge trunk -r14642:HEAD

Location:
NEMO/branches/2020/dev_r14116_HPC-04_mcastril_Mixed_Precision_implementation_final
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2020/dev_r14116_HPC-04_mcastril_Mixed_Precision_implementation_final

    • Property svn:externals
      •  

        old new  
        99 
        1010# SETTE 
        11 ^/utils/CI/sette_wave@13990         sette 
         11^/utils/CI/sette@14244        sette 
  • NEMO/branches/2020/dev_r14116_HPC-04_mcastril_Mixed_Precision_implementation_final/src/OCE/DYN/sshwzv.F90

    r14219 r14644  
    5454#  include "domzgr_substitute.h90" 
    5555#  include "single_precision_substitute.h90" 
    56  
    5756   !!---------------------------------------------------------------------- 
    5857   !! NEMO/OCE 4.0 , NEMO Consortium (2018) 
     
    263262 
    264263 
    265    SUBROUTINE ssh_atf( kt, Kbb, Kmm, Kaa, pssh, pssh_f ) 
     264   SUBROUTINE ssh_atf( kt, Kbb, Kmm, Kaa, pssh ) 
    266265      !!---------------------------------------------------------------------- 
    267266      !!                    ***  ROUTINE ssh_atf  *** 
     
    280279      INTEGER                         , INTENT(in   ) ::   kt             ! ocean time-step index 
    281280      INTEGER                         , INTENT(in   ) ::   Kbb, Kmm, Kaa  ! ocean time level indices 
    282       REAL(dp), DIMENSION(jpi,jpj,jpt)          , TARGET, INTENT(inout) ::   pssh           ! SSH field 
    283       REAL(dp), DIMENSION(jpi,jpj    ), OPTIONAL, TARGET, INTENT(  out) ::   pssh_f         ! filtered SSH field 
    284       ! 
    285       REAL(dp) ::   zcoef   ! local scalar 
    286       REAL(dp), POINTER, DIMENSION(:,:) ::   zssh   ! pointer for filtered SSH  
     281      REAL(dp), DIMENSION(jpi,jpj,jpt), INTENT(inout) ::   pssh           ! SSH field 
     282      ! 
     283      REAL(wp) ::   zcoef   ! local scalar 
    287284      !!---------------------------------------------------------------------- 
    288285      ! 
     
    294291         IF(lwp) WRITE(numout,*) '~~~~~~~ ' 
    295292      ENDIF 
    296       !              !==  Euler time-stepping: no filter, just swap  ==! 
    297       IF ( .NOT.( l_1st_euler ) ) THEN   ! Only do time filtering for leapfrog timesteps 
    298          IF( PRESENT( pssh_f ) ) THEN   ;   zssh => pssh_f 
    299          ELSE                           ;   zssh => pssh(:,:,Kmm) 
    300          ENDIF 
    301          !                                                  ! filtered "now" field 
    302          pssh(:,:,Kmm) = pssh(:,:,Kmm) + rn_atfp * ( pssh(:,:,Kbb) - 2 * pssh(:,:,Kmm) + pssh(:,:,Kaa) ) 
     293      ! 
     294      IF( .NOT.l_1st_euler ) THEN   ! Apply Asselin time filter on Kmm field (not on euler 1st) 
    303295         ! 
    304          IF( .NOT.ln_linssh ) THEN                          ! "now" <-- with forcing removed 
     296         IF( ln_linssh ) THEN                ! filtered "now" field 
     297            pssh(:,:,Kmm) = pssh(:,:,Kmm) + rn_atfp * ( pssh(:,:,Kbb) - 2 * pssh(:,:,Kmm) + pssh(:,:,Kaa) ) 
     298            ! 
     299         ELSE                                ! filtered "now" field with forcing removed 
    305300            zcoef = rn_atfp * rn_Dt * r1_rho0 
    306             pssh(:,:,Kmm) = pssh(:,:,Kmm) - zcoef * (     emp_b(:,:) - emp   (:,:)   & 
    307                &                             - rnf_b(:,:)        + rnf   (:,:)       & 
    308                &                             + fwfisf_cav_b(:,:) - fwfisf_cav(:,:)   & 
    309                &                             + fwfisf_par_b(:,:) - fwfisf_par(:,:)   ) * ssmask(:,:) 
     301            pssh(:,:,Kmm) = pssh(:,:,Kmm) + rn_atfp * ( pssh(:,:,Kbb) - 2 * pssh(:,:,Kmm) + pssh(:,:,Kaa) )   & 
     302               &                          - zcoef   * (         emp_b(:,:) -        emp(:,:)   & 
     303               &                                              - rnf_b(:,:) +        rnf(:,:)   & 
     304               &                                       + fwfisf_cav_b(:,:) - fwfisf_cav(:,:)   & 
     305               &                                       + fwfisf_par_b(:,:) - fwfisf_par(:,:)   ) * ssmask(:,:) 
    310306 
    311307            ! ice sheet coupling 
    312308            IF( ln_isf .AND. ln_isfcpl .AND. kt == nit000+1 )   & 
    313                &   pssh(:,:,Kbb) = pssh(:,:,Kbb) - rn_atfp * rn_Dt * ( risfcpl_ssh(:,:) - 0.0 ) * ssmask(:,:) 
     309               &   pssh(:,:,Kbb) = pssh(:,:,Kbb) - rn_atfp * rn_Dt * ( risfcpl_ssh(:,:) - 0._wp ) * ssmask(:,:) 
    314310 
    315311         ENDIF 
Note: See TracChangeset for help on using the changeset viewer.