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 13617 for NEMO/releases/r4.0/r4.0-HEAD/src/ICE/iceitd.F90 – NEMO

Ignore:
Timestamp:
2020-10-16T10:07:20+02:00 (4 years ago)
Author:
clem
Message:

4.0-HEAD: optimization of both Prather and UMx advection schemes. Related to ticket #2552

File:
1 edited

Legend:

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

    r13284 r13617  
    615615         END DO 
    616616         ! 
    617 !!clem   CALL tab_2d_1d( npti, nptidx(1:npti), h_i_1d(1:npti), h_i(:,:,jl) ) 
    618          CALL tab_2d_1d( npti, nptidx(1:npti), a_i_1d(1:npti), a_i(:,:,jl) ) 
    619          CALL tab_2d_1d( npti, nptidx(1:npti), v_i_1d(1:npti), v_i(:,:,jl) ) 
    620          ! 
    621          DO ji = 1, npti 
    622             jdonor(ji,jl)  = jl  
    623             ! how much of a_i you send in cat sup is somewhat arbitrary 
    624 !!clem: these do not work properly after a restart (I do not know why) => not sure it is still true 
    625 !!          zdaice(ji,jl)  = a_i_1d(ji) * ( h_i_1d(ji) - hi_max(jl) + epsi10 ) / h_i_1d(ji)   
    626 !!          zdvice(ji,jl)  = v_i_1d(ji) - ( a_i_1d(ji) - zdaice(ji,jl) ) * ( hi_max(jl) - epsi10 ) 
    627 !!clem: these do not work properly after a restart (I do not know why) => not sure it is still true 
    628 !!          zdaice(ji,jl)  = a_i_1d(ji) 
    629 !!          zdvice(ji,jl)  = v_i_1d(ji) 
    630 !!clem: these are from UCL and work ok 
    631             zdaice(ji,jl)  = a_i_1d(ji) * 0.5_wp 
    632             zdvice(ji,jl)  = v_i_1d(ji) - zdaice(ji,jl) * ( hi_max(jl) + hi_max(jl-1) ) * 0.5_wp 
    633          END DO 
    634          ! 
    635          IF( npti > 0 ) THEN 
     617         IF( npti > 0 ) THEN             
     618            !!clem   CALL tab_2d_1d( npti, nptidx(1:npti), h_i_1d(1:npti), h_i(:,:,jl) ) 
     619            CALL tab_2d_1d( npti, nptidx(1:npti), a_i_1d(1:npti), a_i(:,:,jl) ) 
     620            CALL tab_2d_1d( npti, nptidx(1:npti), v_i_1d(1:npti), v_i(:,:,jl) ) 
     621            ! 
     622            DO ji = 1, npti 
     623               jdonor(ji,jl)  = jl  
     624               ! how much of a_i you send in cat sup is somewhat arbitrary 
     625               !!clem: these do not work properly after a restart (I do not know why) => not sure it is still true 
     626               !!          zdaice(ji,jl)  = a_i_1d(ji) * ( h_i_1d(ji) - hi_max(jl) + epsi10 ) / h_i_1d(ji)   
     627               !!          zdvice(ji,jl)  = v_i_1d(ji) - ( a_i_1d(ji) - zdaice(ji,jl) ) * ( hi_max(jl) - epsi10 ) 
     628               !!clem: these do not work properly after a restart (I do not know why) => not sure it is still true 
     629               !!          zdaice(ji,jl)  = a_i_1d(ji) 
     630               !!          zdvice(ji,jl)  = v_i_1d(ji) 
     631               !!clem: these are from UCL and work ok 
     632               zdaice(ji,jl)  = a_i_1d(ji) * 0.5_wp 
     633               zdvice(ji,jl)  = v_i_1d(ji) - zdaice(ji,jl) * ( hi_max(jl) + hi_max(jl-1) ) * 0.5_wp 
     634            END DO 
     635            ! 
    636636            CALL itd_shiftice( jdonor(1:npti,:), zdaice(1:npti,:), zdvice(1:npti,:) )  ! Shift jl=>jl+1 
    637637            ! Reset shift parameters 
     
    656656         END DO 
    657657         ! 
    658          CALL tab_2d_1d( npti, nptidx(1:npti), a_i_1d(1:npti), a_i(:,:,jl+1) ) ! jl+1 is ok 
    659          CALL tab_2d_1d( npti, nptidx(1:npti), v_i_1d(1:npti), v_i(:,:,jl+1) ) ! jl+1 is ok 
    660          DO ji = 1, npti 
    661             jdonor(ji,jl) = jl + 1 
    662             zdaice(ji,jl) = a_i_1d(ji)  
    663             zdvice(ji,jl) = v_i_1d(ji) 
    664          END DO 
    665          ! 
    666658         IF( npti > 0 ) THEN 
     659            CALL tab_2d_1d( npti, nptidx(1:npti), a_i_1d(1:npti), a_i(:,:,jl+1) ) ! jl+1 is ok 
     660            CALL tab_2d_1d( npti, nptidx(1:npti), v_i_1d(1:npti), v_i(:,:,jl+1) ) ! jl+1 is ok 
     661            ! 
     662            DO ji = 1, npti 
     663               jdonor(ji,jl) = jl + 1 
     664               zdaice(ji,jl) = a_i_1d(ji)  
     665               zdvice(ji,jl) = v_i_1d(ji) 
     666            END DO 
     667            ! 
    667668            CALL itd_shiftice( jdonor(1:npti,:), zdaice(1:npti,:), zdvice(1:npti,:) )  ! Shift jl+1=>jl 
    668669            ! Reset shift parameters 
Note: See TracChangeset for help on using the changeset viewer.