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 8868 for branches/2017/dev_METO_2017/NEMOGCM/NEMO/OPA_SRC/ASM/asminc.F90 – NEMO

Ignore:
Timestamp:
2017-12-01T09:43:23+01:00 (6 years ago)
Author:
timgraham
Message:

Merged dev_r8789_sbc into branch

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_METO_2017/NEMOGCM/NEMO/OPA_SRC/ASM/asminc.F90

    r8030 r8868  
    2020   !!   dyn_asm_inc    : Apply the dynamic (u and v) increments 
    2121   !!   ssh_asm_inc    : Apply the SSH increment 
     22   !!   ssh_asm_div    : Apply divergence associated with SSH increment 
    2223   !!   seaice_asm_inc : Apply the seaice increment 
    2324   !!---------------------------------------------------------------------- 
     
    4849   PUBLIC   dyn_asm_inc    !: Apply the dynamic (u and v) increments 
    4950   PUBLIC   ssh_asm_inc    !: Apply the SSH increment 
     51   PUBLIC   ssh_asm_div    !: Apply the SSH divergence 
    5052   PUBLIC   seaice_asm_inc !: Apply the seaice increment 
    5153 
     
    768770            ENDIF 
    769771            ! 
     772#if defined key_asminc 
     773         ELSE IF( kt == nitiaufin_r+1 ) THEN 
     774            ! 
     775            ssh_iau(:,:) = 0._wp 
     776            ! 
     777#endif 
    770778         ENDIF 
    771779         !                          !----------------------------------------- 
     
    792800   END SUBROUTINE ssh_asm_inc 
    793801 
     802   SUBROUTINE ssh_asm_div( kt, phdivn ) 
     803      !!---------------------------------------------------------------------- 
     804      !!                  ***  ROUTINE ssh_asm_div  *** 
     805      !! 
     806      !! ** Purpose :   ssh increment with z* is incorporated via a correction of the local divergence           
     807      !!                across all the water column 
     808      !! 
     809      !! ** Method  : 
     810      !!                CAUTION : sshiau is positive (inflow) decreasing the 
     811      !!                          divergence and expressed in m/s 
     812      !! 
     813      !! ** Action  :   phdivn   decreased by the ssh increment 
     814      !!---------------------------------------------------------------------- 
     815      INTEGER, INTENT(IN) :: kt                               ! ocean time-step index 
     816      REAL(wp), DIMENSION(:,:,:), INTENT(inout) ::   phdivn   ! horizontal divergence 
     817      !! 
     818      INTEGER  ::   jk                                        ! dummy loop index 
     819      REAL(wp), DIMENSION(:,:)  , POINTER       ::   ztim     ! local array 
     820      !!---------------------------------------------------------------------- 
     821      !  
     822#if defined key_asminc 
     823      CALL ssh_asm_inc( kt ) !==   (calculate increments) 
     824      ! 
     825      IF( ln_linssh ) THEN  
     826         phdivn(:,:,1) = phdivn(:,:,1) - ssh_iau(:,:) / e3t_n(:,:,1) * tmask(:,:,1) 
     827      ELSE  
     828         CALL wrk_alloc( jpi,jpj, ztim) 
     829         ztim(:,:) = ssh_iau(:,:) / ( ht_n(:,:) + 1.0 - ssmask(:,:) ) 
     830         DO jk = 1, jpkm1                                  
     831            phdivn(:,:,jk) = phdivn(:,:,jk) - ztim(:,:) * tmask(:,:,jk)  
     832         END DO 
     833         ! 
     834         CALL wrk_dealloc( jpi,jpj, ztim) 
     835      ENDIF 
     836#endif 
     837      ! 
     838   END SUBROUTINE ssh_asm_div 
    794839 
    795840   SUBROUTINE seaice_asm_inc( kt, kindic ) 
Note: See TracChangeset for help on using the changeset viewer.