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 5836 for trunk/NEMOGCM/NEMO/OPA_SRC/SBC/sbcisf.F90 – NEMO

Ignore:
Timestamp:
2015-10-26T15:49:40+01:00 (9 years ago)
Author:
cetlod
Message:

merge the simplification branch onto the trunk, see ticket #1612

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEMOGCM/NEMO/OPA_SRC/SBC/sbcisf.F90

    r5721 r5836  
    1818   USE eosbn2          ! equation of state 
    1919   USE sbc_oce         ! surface boundary condition: ocean fields 
     20   USE zdfbfr          ! 
     21   ! 
     22   USE in_out_manager  ! I/O manager 
     23   USE iom             ! I/O manager library 
     24   USE fldread         ! read input field at current time step 
    2025   USE lbclnk          ! 
    21    USE iom             ! I/O manager library 
    22    USE in_out_manager  ! I/O manager 
    2326   USE wrk_nemo        ! Memory allocation 
    2427   USE timing          ! Timing 
    2528   USE lib_fortran     ! glob_sum 
    26    USE zdfbfr 
    27    USE fldread         ! read input field at current time step 
    28  
    29  
    3029 
    3130   IMPLICIT NONE 
    3231   PRIVATE 
    3332 
    34    PUBLIC   sbc_isf, sbc_isf_div, sbc_isf_alloc  ! routine called in sbcmod and divcur 
     33   PUBLIC   sbc_isf, sbc_isf_div, sbc_isf_alloc  ! routine called in sbcmod and divhor 
    3534 
    3635   ! public in order to be able to output then  
     
    7271#  include "domzgr_substitute.h90" 
    7372   !!---------------------------------------------------------------------- 
    74    !! NEMO/OPA 3.0 , LOCEAN-IPSL (2008) 
     73   !! NEMO/OPA 3.7 , LOCEAN-IPSL (2015) 
    7574   !! $Id$ 
    7675   !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt) 
    7776   !!---------------------------------------------------------------------- 
    78  
    7977CONTAINS 
    8078  
    81   SUBROUTINE sbc_isf(kt) 
    82     INTEGER, INTENT(in)          ::   kt         ! ocean time step 
    83     INTEGER                      ::   ji, jj, jk, ijkmin, inum, ierror 
    84     INTEGER                      ::   ikt, ikb   ! top and bottom level of the isf boundary layer 
    85     REAL(wp)                     ::   rmin 
    86     REAL(wp)                     ::   zhk 
    87     REAL(wp)                     ::   zt_frz, zpress 
    88     CHARACTER(len=256)           ::   cfisf , cvarzisf, cvarhisf   ! name for isf file 
    89     CHARACTER(LEN=256)           :: cnameis                     ! name of iceshelf file 
    90     CHARACTER (LEN=32)           :: cvarLeff                    ! variable name for efficient Length scale 
    91     INTEGER           ::   ios           ! Local integer output status for namelist read 
    92       ! 
     79   SUBROUTINE sbc_isf(kt) 
    9380      !!--------------------------------------------------------------------- 
     81      !!                     ***  ROUTINE sbc_isf  *** 
     82      !!--------------------------------------------------------------------- 
     83      INTEGER, INTENT(in)          ::   kt         ! ocean time step 
     84      ! 
     85      INTEGER                      ::   ji, jj, jk, ijkmin, inum, ierror 
     86      INTEGER                      ::   ikt, ikb   ! top and bottom level of the isf boundary layer 
     87      REAL(wp)                     ::   rmin 
     88      REAL(wp)                     ::   zhk 
     89      REAL(wp)                     ::   zt_frz, zpress 
     90      CHARACTER(len=256)           ::   cfisf , cvarzisf, cvarhisf   ! name for isf file 
     91      CHARACTER(LEN=256)           :: cnameis                     ! name of iceshelf file 
     92      CHARACTER (LEN=32)           :: cvarLeff                    ! variable name for efficient Length scale 
     93      INTEGER           ::   ios           ! Local integer output status for namelist read 
     94      !! 
    9495      NAMELIST/namsbc_isf/ nn_isfblk, rn_hisf_tbl, ln_divisf, ln_conserve, rn_gammat0, rn_gammas0, nn_gammablk, & 
    95                          & sn_fwfisf, sn_qisf, sn_rnfisf, sn_depmax_isf, sn_depmin_isf, sn_Leff_isf 
    96       ! 
     96         &                sn_fwfisf, sn_qisf, sn_rnfisf, sn_depmax_isf, sn_depmin_isf, sn_Leff_isf 
     97      !!--------------------------------------------------------------------- 
    9798      ! 
    9899      !                                         ! ====================== ! 
     
    107108902      IF( ios /= 0 ) CALL ctl_nam ( ios , 'namsbc_isf in configuration namelist', lwp ) 
    108109         IF(lwm) WRITE ( numond, namsbc_isf ) 
    109  
    110110 
    111111         IF ( lwp ) WRITE(numout,*) 
     
    210210            END DO 
    211211         END DO 
    212           
     212         ! 
    213213      END IF 
    214214 
     
    298298         !  
    299299      END IF 
    300    
     300      !   
    301301  END SUBROUTINE sbc_isf 
     302 
    302303 
    303304  INTEGER FUNCTION sbc_isf_alloc() 
     
    320321  END FUNCTION 
    321322 
    322   SUBROUTINE sbc_isf_bg03(kt) 
    323    !!========================================================================== 
    324    !!                 *** SUBROUTINE sbcisf_bg03  *** 
    325    !! add net heat and fresh water flux from ice shelf melting 
    326    !! into the adjacent ocean using the parameterisation by 
    327    !! Beckmann and Goosse (2003), "A parameterization of ice shelf-ocean 
    328    !!     interaction for climate models", Ocean Modelling 5(2003) 157-170. 
    329    !!  (hereafter BG) 
    330    !!========================================================================== 
    331    !!---------------------------------------------------------------------- 
    332    !!   sbc_isf_bg03      : routine called from sbcmod 
    333    !!---------------------------------------------------------------------- 
    334    !! 
    335    !! ** Purpose   :   Add heat and fresh water fluxes due to ice shelf melting 
    336    !! ** Reference :   Beckmann et Goosse, 2003, Ocean Modelling 
    337    !! 
    338    !! History : 
    339    !!      !  06-02  (C. Wang) Original code 
    340    !!---------------------------------------------------------------------- 
    341  
    342     INTEGER, INTENT ( in ) :: kt 
    343  
     323 
     324   SUBROUTINE sbc_isf_bg03(kt) 
     325      !!========================================================================== 
     326      !!                 *** SUBROUTINE sbcisf_bg03  *** 
     327      !! add net heat and fresh water flux from ice shelf melting 
     328      !! into the adjacent ocean using the parameterisation by 
     329      !! Beckmann and Goosse (2003), "A parameterization of ice shelf-ocean 
     330      !!     interaction for climate models", Ocean Modelling 5(2003) 157-170. 
     331      !!  (hereafter BG) 
     332      !!========================================================================== 
     333      !!---------------------------------------------------------------------- 
     334      !!   sbc_isf_bg03      : routine called from sbcmod 
     335      !!---------------------------------------------------------------------- 
     336      !! 
     337      !! ** Purpose   :   Add heat and fresh water fluxes due to ice shelf melting 
     338      !! ** Reference :   Beckmann et Goosse, 2003, Ocean Modelling 
     339      !! 
     340      !! History : 
     341      !!      !  06-02  (C. Wang) Original code 
     342      !!---------------------------------------------------------------------- 
     343      INTEGER, INTENT ( in ) :: kt 
     344      ! 
    344345    INTEGER :: ji, jj, jk, jish  !temporary integer 
    345346    INTEGER :: ijkmin 
     
    385386             qisf(ji,jj) = 0._wp ; fwfisf(ji,jj) = 0._wp 
    386387          END IF 
    387        ENDDO 
    388     ENDDO 
     388       END DO 
     389    END DO 
    389390    ! 
    390391    IF( nn_timing == 1 )  CALL timing_stop('sbc_isf_bg03') 
     392      ! 
    391393  END SUBROUTINE sbc_isf_bg03 
     394 
    392395 
    393396   SUBROUTINE sbc_isf_cav( kt ) 
     
    438441      ! 
    439442      ! 
    440 !CDIR COLLAPSE 
    441443      DO jj = 1, jpj 
    442444         DO ji = 1, jpi 
     
    492494 
    493495! More complicated 3 equation thermodynamics as in MITgcm 
    494 !CDIR COLLAPSE 
    495496         DO jj = 2, jpj 
    496497            DO ji = 2, jpi 
     
    561562      ! 
    562563      IF( nn_timing == 1 )  CALL timing_stop('sbc_isf_cav') 
    563  
     564      ! 
    564565   END SUBROUTINE sbc_isf_cav 
     566 
    565567 
    566568   SUBROUTINE sbc_isf_gammats(gt, gs, zqhisf, zqwisf, ji, jj, lit ) 
     
    689691               END IF 
    690692      END IF 
    691  
     693      ! 
    692694   END SUBROUTINE 
     695 
    693696 
    694697   SUBROUTINE sbc_isf_tbl( varin, varout, cptin ) 
     
    752755      IF (cptin == 'T') CALL lbc_lnk(varout,'T',1.) 
    753756      IF (cptin == 'U' .OR. cptin == 'V') CALL lbc_lnk(varout,'T',-1.) 
    754  
     757      ! 
    755758   END SUBROUTINE sbc_isf_tbl 
    756759       
     
    819822      ! 
    820823   END SUBROUTINE sbc_isf_div 
    821                          
     824 
     825 
    822826   FUNCTION tinsitu( ptem, psal, ppress ) RESULT( pti ) 
    823827      !!---------------------------------------------------------------------- 
     
    870874      ! 
    871875   END FUNCTION tinsitu 
    872    ! 
     876 
     877 
    873878   FUNCTION fsatg( pfps, pfpt, pfphp ) 
    874879      !!---------------------------------------------------------------------- 
Note: See TracChangeset for help on using the changeset viewer.