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 8488 for branches/2017/dev_r8183_ICEMODEL/NEMOGCM/NEMO/LIM_SRC_3/icevar.F90 – NEMO

Ignore:
Timestamp:
2017-09-01T16:47:58+02:00 (7 years ago)
Author:
clem
Message:

compilation bugs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_r8183_ICEMODEL/NEMOGCM/NEMO/LIM_SRC_3/icevar.F90

    r8486 r8488  
    132132         om_i (:,:) = SUM( oa_i(:,:,:)              , dim=3 ) * z1_at_i(ji,jj) 
    133133         ! 
    134          tm_i (:,:) = r1_nlay_i * SUM( SUM( t_i(:,:,:,:) * v_i(:,:,:), dim=4 ) , dim=3 ) * z1_vt_i(:,:) 
    135          smt_i(:,:) = r1_nlay_i * SUM( SUM( s_i(:,:,:,:) * v_i(:,:,:), dim=4 ) , dim=3 ) * z1_vt_i(:,:) 
    136 ! 
     134         tm_i (:,:) = 0._wp 
     135         smt_i(:,:) = 0._wp 
     136         DO jl = 1, jpl 
     137            DO jk = 1, nlay_i 
     138               tm_i (:,:) = tm_i (:,:) + r1_nlay_i * t_i(:,:,jk,jl) * v_i(:,:,jl) * z1_vt_i(:,:) 
     139               smt_i(:,:) = smt_i(:,:) + r1_nlay_i * s_i(:,:,jk,jl) * v_i(:,:,jl) * z1_vt_i(:,:) 
     140            END DO 
     141         END DO 
     142         ! 
    137143!!gm  QUESTION 1 : why salinity is named smt_i  and not just sm_i ?   since the 4D field is named s_i. (NB for temp: tm_i, t_i) 
    138144         ! 
     
    402408         END DO 
    403409      END DO 
    404       WHERE( vt_i(:,:) > epsi20 )   bvm_i(:,:) = SUM( bv_i(:,:,:) * v_i(:,:,:) , dim=3 ) / vt_i(:,:) 
    405       ELSEWHERE                     bvm_i(:,:) = 0._wp 
    406      END WHERE 
    407      ! 
     410      WHERE( vt_i(:,:) > epsi20 )   ;   bvm_i(:,:) = SUM( bv_i(:,:,:) * v_i(:,:,:) , dim=3 ) / vt_i(:,:) 
     411      ELSEWHERE                     ;   bvm_i(:,:) = 0._wp 
     412      END WHERE 
     413      ! 
    408414   END SUBROUTINE ice_var_bv 
    409415 
Note: See TracChangeset for help on using the changeset viewer.