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 15015 for NEMO/branches/2021/ticket2680_C1D_PAPA/tests/ISOMIP+/MY_SRC/tradmp.F90 – NEMO

Ignore:
Timestamp:
2021-06-17T19:17:25+02:00 (3 years ago)
Author:
gsamson
Message:

merge trunk into branch (#2680)

Location:
NEMO/branches/2021/ticket2680_C1D_PAPA
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2021/ticket2680_C1D_PAPA

    • Property svn:externals
      •  

        old new  
        99 
        1010# SETTE 
        11 ^/utils/CI/sette@14244        sette 
         11^/utils/CI/sette@HEAD        sette 
         12 
  • NEMO/branches/2021/ticket2680_C1D_PAPA/tests/ISOMIP+/MY_SRC/tradmp.F90

    r13982 r15015  
    1111   !!  NEMO      1.0  ! 2002-08  (G. Madec, E. Durand)  free form + modules 
    1212   !!            3.2  ! 2009-08  (G. Madec, C. Talandier)  DOCTOR norm for namelist parameter 
    13    !!            3.3  ! 2010-06  (C. Ethe, G. Madec) merge TRA-TRC  
     13   !!            3.3  ! 2010-06  (C. Ethe, G. Madec) merge TRA-TRC 
    1414   !!            3.4  ! 2011-04  (G. Madec, C. Ethe) Merge of dtatem and dtasal + suppression of CPP keys 
    1515   !!            3.6  ! 2015-06  (T. Graham)  read restoring coefficient in a file 
     
    2626   USE c1d            ! 1D vertical configuration 
    2727   USE trd_oce        ! trends: ocean variables 
    28    USE trdtra         ! trends manager: tracers  
     28   USE trdtra         ! trends manager: tracers 
    2929   USE zdf_oce        ! ocean: vertical physics 
    3030   USE phycst         ! physical constants 
     
    7575      !!---------------------------------------------------------------------- 
    7676      !!                   ***  ROUTINE tra_dmp  *** 
    77       !!                   
     77      !! 
    7878      !! ** Purpose :   Compute the tracer trend due to a newtonian damping 
    7979      !!      of the tracer field towards given data field and add it to the 
    8080      !!      general tracer trends. 
    8181      !! 
    82       !! ** Method  :   Newtonian damping towards t_dta and s_dta computed  
     82      !! ** Method  :   Newtonian damping towards t_dta and s_dta computed 
    8383      !!      and add to the general tracer trends: 
    8484      !!                     ta = ta + resto * (t_dta - tb) 
     
    101101      IF( ln_timing )   CALL timing_start('tra_dmp') 
    102102      ! 
    103       IF( l_trdtra )   THEN                    !* Save ta and sa trends 
    104          ALLOCATE( ztrdts(jpi,jpj,jpk,jpts) )  
    105          ztrdts(:,:,:,:) = pts(:,:,:,:,Krhs)  
     103      IF( l_trdtra .OR. iom_use('hflx_dmp_cea') .OR. iom_use('sflx_dmp_cea') ) THEN   !* Save ta and sa trends 
     104         ALLOCATE( ztrdts(jpi,jpj,jpk,jpts) ) 
     105         ztrdts(:,:,:,:) = pts(:,:,:,:,Krhs) 
    106106      ENDIF 
    107107      !                           !==  input T-S data at kt  ==! 
     
    140140      END SELECT 
    141141      ! 
     142      ! outputs (clem trunk) 
     143      IF( iom_use('hflx_dmp_cea') )       & 
     144         &   CALL iom_put('hflx_dmp_cea', & 
     145         &   SUM( ( pts(:,:,:,jp_tem,Krhs) - ztrdts(:,:,:,jp_tem) ) * e3t(:,:,:,Kmm), dim=3 ) * rcp * rho0 ) ! W/m2 
     146      IF( iom_use('sflx_dmp_cea') )       & 
     147         &   CALL iom_put('sflx_dmp_cea', & 
     148         &   SUM( ( pts(:,:,:,jp_sal,Krhs) - ztrdts(:,:,:,jp_sal) ) * e3t(:,:,:,Kmm), dim=3 ) * rho0 )       ! g/m2/s 
     149      ! 
    142150      IF( l_trdtra )   THEN       ! trend diagnostic 
    143151         ztrdts(:,:,:,:) = pts(:,:,:,:,Krhs) - ztrdts(:,:,:,:) 
    144152         CALL trd_tra( kt, Kmm, Krhs, 'TRA', jp_tem, jptra_dmp, ztrdts(:,:,:,jp_tem) ) 
    145153         CALL trd_tra( kt, Kmm, Krhs, 'TRA', jp_sal, jptra_dmp, ztrdts(:,:,:,jp_sal) ) 
    146          DEALLOCATE( ztrdts )  
     154         DEALLOCATE( ztrdts ) 
    147155      ENDIF 
    148156      !                           ! Control print 
     
    158166      !!---------------------------------------------------------------------- 
    159167      !!                  ***  ROUTINE tra_dmp_init  *** 
    160       !!  
    161       !! ** Purpose :   Initialization for the newtonian damping  
     168      !! 
     169      !! ** Purpose :   Initialization for the newtonian damping 
    162170      !! 
    163171      !! ** Method  :   read the namtra_dmp namelist and check the parameters 
    164172      !!---------------------------------------------------------------------- 
    165       INTEGER ::   ios, imask   ! local integers  
     173      INTEGER ::   ios, imask   ! local integers 
    166174      ! 
    167175      NAMELIST/namtra_dmp/ ln_tradmp, nn_zdmp, cn_resto 
Note: See TracChangeset for help on using the changeset viewer.