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 13449 – NEMO

Changeset 13449


Ignore:
Timestamp:
2020-09-03T16:40:10+02:00 (4 years ago)
Author:
gsamson
Message:

add sst_m & sss_m init in ice_rst_read when using SAS + simplified ice restart; ticket #2518

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/releases/r4.0/r4.0-HEAD/src/ICE/icerst.F90

    r13445 r13449  
    1818   USE phycst  , ONLY : rt0 
    1919   USE sbc_oce , ONLY : nn_fsbc, ln_cpl 
     20   USE sbc_oce , ONLY : nn_components, jp_iam_sas   ! SAS ss[st]_m init 
     21   USE sbc_oce , ONLY : sst_m, sss_m                ! SAS ss[st]_m init 
     22   USE oce     , ONLY : tsn                         ! SAS ss[st]_m init 
     23   USE eosbn2  , ONLY : l_useCT, eos_pt_from_ct     ! SAS ss[st]_m init 
    2024   USE iceistate      ! sea-ice: initial state 
    2125   USE icectl         ! sea-ice: control 
     
    280284         CALL ctl_warn('ice_rst_read: you are attempting to use an unsuitable ice restart') 
    281285         ! 
    282          IF( .NOT. ln_iceini ) THEN 
     286         IF( .NOT. ln_iceini .OR. nn_iceini_file == 2 ) THEN 
    283287            CALL ctl_stop('STOP', 'ice_rst_read: you need ln_ice_ini=T and nn_iceini_file=0 or 1') 
    284288         ELSE 
     
    286290         ENDIF 
    287291         ! 
     292         IF( nn_components == jp_iam_sas ) THEN   ! SAS case: ss[st]_m were not initialized by sbc_ssm_init 
     293            ! 
     294            IF(lwp) WRITE(numout,*) '  SAS: default initialisation of ss[st]_m arrays used in ice_istate' 
     295            IF( l_useCT )  THEN    ;   sst_m(:,:) = eos_pt_from_ct( tsn(:,:,1,jp_tem), tsn(:,:,1,jp_sal) ) 
     296            ELSE                   ;   sst_m(:,:) = tsn(:,:,1,jp_tem) 
     297            ENDIF 
     298            sss_m(:,:) = tsn(:,:,1,jp_sal) 
     299         ENDIF 
     300         ! 
    288301         CALL ice_istate( nit000 ) 
    289302         ! 
Note: See TracChangeset for help on using the changeset viewer.