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 5530 for branches/2015/dev_r5021_UKMO1_CICE_coupling/NEMOGCM/NEMO/OPA_SRC/DIA – NEMO

Ignore:
Timestamp:
2015-07-02T15:38:54+02:00 (9 years ago)
Author:
davestorkey
Message:

Updating 2015/dev_r5021_UKMO1_CICE_coupling branch to rev 5518 of trunk
(= NEMO 3.6_stable branching point).

Location:
branches/2015/dev_r5021_UKMO1_CICE_coupling/NEMOGCM/NEMO/OPA_SRC/DIA
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/2015/dev_r5021_UKMO1_CICE_coupling/NEMOGCM/NEMO/OPA_SRC/DIA/diadct.F90

    r5445 r5530  
    176176 
    177177     !open output file 
    178      IF( lwp ) THEN 
     178     IF( lwm ) THEN 
    179179        CALL ctl_opn( numdct_vol,  'volume_transport', 'NEW', 'FORMATTED', 'SEQUENTIAL', -1, numout,  .FALSE. ) 
    180180        CALL ctl_opn( numdct_heat, 'heat_transport'  , 'NEW', 'FORMATTED', 'SEQUENTIAL', -1, numout,  .FALSE. ) 
     
    283283           DO jsec=1,nb_sec 
    284284 
    285               IF( lwp )CALL dia_dct_wri(kt,jsec,secs(jsec)) 
     285              IF( lwm )CALL dia_dct_wri(kt,jsec,secs(jsec)) 
    286286             
    287287              !nullify transports values after writing 
  • branches/2015/dev_r5021_UKMO1_CICE_coupling/NEMOGCM/NEMO/OPA_SRC/DIA/diafwb.F90

    r5443 r5530  
    166166         CASE ( 1 )                                  !  ORCA_R1 configurations 
    167167            !                                        ! ======================= 
    168             ! This dirty section will be suppressed by simplification process: all this will come back in input files 
    169             ! Currently these hard-wired indices relate to the original (pre-v3.6) configuration  
    170             ! which had a grid-size of 362x292. 
    171             ! This grid has been extended southwards for use with the under ice-shelf options (isf) introduced in v3.6.  
    172             ! The original domain can still be used optionally if the isf code is not activated.  
    173             ! An adjustment (isrow) is made to the hard-wired indices if the extended domain (362x332) is being used. 
    174             !  
    175             IF    ( jpjglo == 292 ) THEN  ;  isrow = 0  ! Using pre-v3.6 files or adjusted start row from isf-extended grid 
    176             ELSEIF( jpjglo == 332 ) THEN  ;  isrow = 40 ! Using full isf­extended domain.  
    177             ENDIF                                       ! Adjust j­indices to account for more southerly starting latitude 
     168            ! This dirty section will be suppressed by simplification process: 
     169            ! all this will come back in input files 
     170            ! Currently these hard-wired indices relate to configuration with 
     171            ! extend grid (jpjglo=332) 
     172            isrow = 332 - jpjglo 
     173            ! 
    178174            ii0 = 283           ;   ii1 = 283 
    179             ij0 = 201 + isrow   ;   ij1 = 201 + isrow 
     175            ij0 = 241 - isrow   ;   ij1 = 241 - isrow 
    180176            !                                        ! ======================= 
    181177         CASE DEFAULT                                !    ORCA R05 or R025 
     
    223219         CASE ( 1 )                                  !  ORCA_R1 configurations 
    224220            !                                        ! ======================= 
    225             !  This dirty section will be suppressed by simplification process: 
    226             !  all this will come back in input files 
    227             IF    ( jpjglo == 292 ) THEN  ;  isrow = 0   
    228             ELSEIF( jpjglo == 332 ) THEN  ;  isrow = 39 
    229             ENDIF                                       
     221            ! This dirty section will be suppressed by simplification process: 
     222            ! all this will come back in input files 
     223            ! Currently these hard-wired indices relate to configuration with 
     224            ! extend grid (jpjglo=332) 
     225            isrow = 332 - jpjglo 
    230226            ii0 = 282           ;   ii1 = 282 
    231             ij0 = 201 + isrow   ;   ij1 = 201 + isrow 
     227            ij0 = 240 - isrow   ;   ij1 = 240 - isrow 
    232228            !                                        ! ======================= 
    233229         CASE DEFAULT                                !    ORCA R05 or R025 
     
    275271         CASE ( 1 )                                  !  ORCA_R1 configurations 
    276272            !                                        ! ======================= 
    277             !  This dirty section will be suppressed by simplification process: 
    278             !  all this will come back in input files 
    279             IF    ( jpjglo == 292 ) THEN  ;  isrow = 0   
    280             ELSEIF( jpjglo == 332 ) THEN  ;  isrow = 39 
    281             ENDIF                                       
     273            ! This dirty section will be suppressed by simplification process: 
     274            ! all this will come back in input files 
     275            ! Currently these hard-wired indices relate to configuration with 
     276            ! extend grid (jpjglo=332) 
     277            isrow = 332 - jpjglo 
    282278            ii0 = 331           ;   ii1 = 331 
    283             ij0 = 176 + isrow   ;   ij1 = 176 + isrow 
     279            ij0 = 215 - isrow   ;   ij1 = 215 - isrow 
    284280            !                                        ! ======================= 
    285281         CASE DEFAULT                                !    ORCA R05 or R025 
     
    327323         CASE ( 1 )                                  !  ORCA_R1 configurations 
    328324            !                                        ! ======================= 
    329             !  This dirty section will be suppressed by simplification process: 
    330             !  all this will come back in input files 
    331             IF    ( jpjglo == 292 ) THEN  ;  isrow = 0   
    332             ELSEIF( jpjglo == 332 ) THEN  ;  isrow = 39 
    333             ENDIF                                       
     325            ! This dirty section will be suppressed by simplification process: 
     326            ! all this will come back in input files 
     327            ! Currently these hard-wired indices relate to configuration with 
     328            ! extend grid (jpjglo=332) 
     329            isrow = 332 - jpjglo 
    334330            ii0 = 297           ;   ii1 = 297 
    335             ij0 = 230 + isrow   ;   ij1 = 230 + isrow 
     331            ij0 = 269 - isrow   ;   ij1 = 269 - isrow 
    336332            !                                        ! ======================= 
    337333         CASE DEFAULT                                !    ORCA R05 or R025 
  • branches/2015/dev_r5021_UKMO1_CICE_coupling/NEMOGCM/NEMO/OPA_SRC/DIA/diawri.F90

    r5443 r5530  
    4646   USE iom 
    4747   USE ioipsl 
     48   USE dynspg_oce, ONLY: un_adv, vn_adv ! barotropic velocities      
     49 
    4850#if defined key_lim2 
    4951   USE limwri_2  
     
    125127      !! 
    126128      INTEGER                      ::   ji, jj, jk              ! dummy loop indices 
     129      INTEGER                      ::   jkbot                   ! 
    127130      REAL(wp)                     ::   zztmp, zztmpx, zztmpy   !  
    128131      !! 
     
    148151         CALL iom_put( "e3w" , fse3w_n(:,:,:) ) 
    149152      ENDIF 
     153 
     154      CALL iom_put( "ssh" , sshn )                 ! sea surface height 
     155      if( iom_use('ssh2') )   CALL iom_put( "ssh2", sshn(:,:) * sshn(:,:) )   ! square of sea surface height 
    150156       
    151157      CALL iom_put( "toce", tsn(:,:,:,jp_tem) )    ! 3D temperature 
     
    154160         DO jj = 1, jpj 
    155161            DO ji = 1, jpi 
    156                z2d(ji,jj) = tsn(ji,jj,MAX(mbathy(ji,jj),1),jp_tem) 
     162               jkbot = mbkt(ji,jj) 
     163               z2d(ji,jj) = tsn(ji,jj,jkbot,jp_tem) 
    157164            END DO 
    158165         END DO 
     
    165172         DO jj = 1, jpj 
    166173            DO ji = 1, jpi 
    167                z2d(ji,jj) = tsn(ji,jj,MAX(mbathy(ji,jj),1),jp_sal) 
     174               jkbot = mbkt(ji,jj) 
     175               z2d(ji,jj) = tsn(ji,jj,jkbot,jp_sal) 
    168176            END DO 
    169177         END DO 
    170178         CALL iom_put( "sbs", z2d )                ! bottom salinity 
     179      ENDIF 
     180 
     181      IF ( iom_use("taubot") ) THEN                ! bottom stress 
     182         z2d(:,:) = 0._wp 
     183         DO jj = 2, jpjm1 
     184            DO ji = fs_2, fs_jpim1   ! vector opt. 
     185               zztmpx = (  bfrua(ji  ,jj) * un(ji  ,jj,mbku(ji  ,jj))  & 
     186                      &  + bfrua(ji-1,jj) * un(ji-1,jj,mbku(ji-1,jj))  )       
     187               zztmpy = (  bfrva(ji,  jj) * vn(ji,jj  ,mbkv(ji,jj  ))  & 
     188                      &  + bfrva(ji,jj-1) * vn(ji,jj-1,mbkv(ji,jj-1))  )  
     189               z2d(ji,jj) = rau0 * SQRT( zztmpx * zztmpx + zztmpy * zztmpy ) * tmask(ji,jj,1)  
     190               ! 
     191            ENDDO 
     192         ENDDO 
     193         CALL lbc_lnk( z2d, 'T', 1. ) 
     194         CALL iom_put( "taubot", z2d )            
    171195      ENDIF 
    172196          
     
    176200         DO jj = 1, jpj 
    177201            DO ji = 1, jpi 
    178                z2d(ji,jj) = un(ji,jj,MAX(mbathy(ji,jj),1)) 
     202               jkbot = mbku(ji,jj) 
     203               z2d(ji,jj) = un(ji,jj,jkbot) 
    179204            END DO 
    180205         END DO 
    181206         CALL iom_put( "sbu", z2d )                ! bottom i-current 
    182207      ENDIF 
     208#if defined key_dynspg_ts 
     209      CALL iom_put(  "ubar", un_adv(:,:)      )    ! barotropic i-current 
     210#else 
     211      CALL iom_put(  "ubar", un_b(:,:)        )    ! barotropic i-current 
     212#endif 
    183213       
    184214      CALL iom_put( "voce", vn(:,:,:)         )    ! 3D j-current 
     
    187217         DO jj = 1, jpj 
    188218            DO ji = 1, jpi 
    189                z2d(ji,jj) = vn(ji,jj,MAX(mbathy(ji,jj),1)) 
     219               jkbot = mbkv(ji,jj) 
     220               z2d(ji,jj) = vn(ji,jj,jkbot) 
    190221            END DO 
    191222         END DO 
    192223         CALL iom_put( "sbv", z2d )                ! bottom j-current 
     224      ENDIF 
     225#if defined key_dynspg_ts 
     226      CALL iom_put(  "vbar", vn_adv(:,:)      )    ! barotropic j-current 
     227#else 
     228      CALL iom_put(  "vbar", vn_b(:,:)        )    ! barotropic j-current 
     229#endif 
     230 
     231      CALL iom_put( "woce", wn )                   ! vertical velocity 
     232      IF( iom_use('w_masstr') .OR. iom_use('w_masstr2') ) THEN   ! vertical mass transport & its square value 
     233         ! Caution: in the VVL case, it only correponds to the baroclinic mass transport. 
     234         z2d(:,:) = rau0 * e12t(:,:) 
     235         DO jk = 1, jpk 
     236            z3d(:,:,jk) = wn(:,:,jk) * z2d(:,:) 
     237         END DO 
     238         CALL iom_put( "w_masstr" , z3d )   
     239         IF( iom_use('w_masstr2') )   CALL iom_put( "w_masstr2", z3d(:,:,:) * z3d(:,:,:) ) 
    193240      ENDIF 
    194241 
Note: See TracChangeset for help on using the changeset viewer.