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 3335 for branches/2012/dev_r3322_NOCS09_SAS/NEMOGCM/NEMO/SAS_SRC/sbcsas.F90 – NEMO

Ignore:
Timestamp:
2012-03-30T09:33:25+02:00 (12 years ago)
Author:
sga
Message:

Branch dev_r3322_NOCS09_SAS: remove interior ocean allocation

add allocation of surface fields used by LIM codes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2012/dev_r3322_NOCS09_SAS/NEMOGCM/NEMO/SAS_SRC/sbcsas.F90

    r3331 r3335  
    9898      ssu_m(:,:) = sf_sas(jf_uwd)%fnow(:,:,1) * umask(:,:,1)    ! u-velocity 
    9999      ssv_m(:,:) = sf_sas(jf_vwd)%fnow(:,:,1) * vmask(:,:,1)    ! v-velocity  
     100      ! 
     101      tsn(:,:,1,jp_tem) = sst_m(:,:) 
     102      tsn(:,:,1,jp_sal) = sss_m(:,:) 
     103      ub (:,:,1       ) = ssu_m(:,:) 
     104      vb (:,:,1       ) = ssv_m(:,:) 
    100105 
    101106      IF(ln_ctl) THEN                  ! print control 
     
    123128      INTEGER  :: ifpr                               ! dummy loop indice 
    124129      INTEGER  :: jfld                               ! dummy loop arguments 
    125       INTEGER  :: inum, idv, idimv                   ! local integer 
     130      INTEGER  :: inum, idv, idimv, jpm              ! local integer 
    126131      !! 
    127132      CHARACTER(len=100)            ::  cn_dir   !   Root directory for location of core files 
     
    177182      CALL fld_fill( sf_sas, slf_d, cn_dir, 'sbc_sas_init', 'Data in file', 'namsbc_sas' ) 
    178183      ! 
     184      ! lim code currently uses surface temperature and salinity in tsn array for initialisation 
     185      ! and ub, vb arrays in ice dynamics 
     186      ! so allocate enough of arrays to use 
     187      ! 
     188      jpm = MAX(jp_tem, jp_sal) 
     189      ALLOCATE( tsn(jpi,jpj,1,jpm), STAT=ierr0 ) 
     190      ALLOCATE( ub(jpi,jpj,1)     , STAT=ierr1 ) 
     191      ALLOCATE( vb(jpi,jpj,1)     , STAT=ierr2 ) 
     192      ierr = ierr0 + ierr1 + ierr2 
     193      IF( ierr > 0 ) THEN 
     194         CALL ctl_stop('sbc_sas_init: unable to allocate surface arrays') 
     195      ENDIF 
     196      ! 
    179197   END SUBROUTINE sbc_sas_init 
    180198 
Note: See TracChangeset for help on using the changeset viewer.