Opened 10 years ago

Closed 10 years ago

Last modified 3 years ago

#762 closed Bug (fixed)

BUG in wind stress over ice when NEC computer + CORE bulk formulae

Reported by: gm Owned by: nemo
Priority: high Milestone:
Component: OCE Version: release-3.2
Severity: Keywords: CORE NEC SBC ice


This critical bug only concerns NEC users having sea-ice defined (key_lim3 or key_lim3)

sbcblk_core.F90 : the following lines can be found in the blk_ice_core routine:

      ! ----------------------------------------------------------------------------- !
      !    Wind components and module relative to the moving ocean ( U10m - U_ice )   !
      ! ----------------------------------------------------------------------------- !
      SELECT CASE( cd_grid )
      CASE( 'I' )                  ! B-grid ice dynamics :   I-point (i.e. F-point with sea-ice indexation)
         !                           and scalar wind at T-point ( = | U10m - U_ice | ) (masked)
#if defined key_vectopt_loop
         DO jj = 2, jpjm1
            DO ji = 2, jpim1   ! B grid : NO vector opt
               ! ... scalar wind at I-point (fld being at T-point)
               zwndi_f = 0.25 * (  sf(jp_wndi)%fnow(ji-1,jj  ,1) + sf(jp_wndi)%fnow(ji  ,jj  ,1)   &
                  &              + sf(jp_wndi)%fnow(ji-1,jj-1,1) + sf(jp_wndi)%fnow(ji  ,jj-1,1)  ) - pui(ji,jj)

Due to an out-of-bound problem (see ticket #380) the loop over ji index is always from 2 to jpim1.

When key_vectopt_loop is defined (always the case on vector computer such as NEC), the NEC compiler instruction !CDIR COLLAPSE is active.

Therefore the two DO-loops on jj and ji are collapsed. The computation is then done from jpj +2 to (jpj-1)*(jpi-2) whereas it should be done until [ (jpj-1)*jpi -1 ].

In ORCA2-LIM (same for ORCA05, 025…), this means that the lines jpj-1 and half the line jpj-2 will not be computed ! The stress at the surface of the ice will be zero there, resulting in a strange ice thinkness pattern at the north fold….

The solution is simply to remove the following three lines :

#if defined key_vectopt_loop

This problem concerns v3.2 and v3.3beta.

In v3.1, the out-of-bound problem was there (ticket #380) and so not this huge zeroing of ice stress.


PS: many thanks to Frederic Dupont who was the first to point out the ice anomalies near the north fold in the reference ORCA2-LIM simulation performed with CORE2 forcing

Commit History (2)


nemo_v3_2:Apply the bug correction in CORE bulk on NEC, see ticket #762


v3.3beta: #762 Bug correction in CORE bulk on NEC

Change History (8)

comment:1 Changed 10 years ago by gm

Done in v3.3beta see changeset:2412 together with stylistic only modifications in sbcblk_clio.F90

comment:2 Changed 10 years ago by cetlod

  • Resolution set to fixed
  • Status changed from new to closed

Done in v3.2 consolided version, see changeset:2419

comment:3 Changed 4 years ago by nicolasmartin

  • Keywords & removed

comment:4 Changed 4 years ago by nicolasmartin

  • Keywords with removed

comment:5 Changed 4 years ago by nicolasmartin

  • Keywords nemo_v3_2* added

comment:6 Changed 4 years ago by nicolasmartin

  • Keywords CORE added; core removed

comment:7 Changed 4 years ago by nicolasmartin

  • Keywords SBC added; bulk removed

comment:8 Changed 3 years ago by nemo

  • Keywords nemo_v3_2* removed
Note: See TracTickets for help on using tickets.