Opened 5 years ago

Closed 5 years ago

Last modified 3 years ago

#1603 closed Bug (fixed)

BUG in traadv_tvd.F90 in case of passive tracers and sub-time stepping (trunk & v3.6 stable)

Reported by: gm Owned by: flavoni
Priority: low Milestone: 2015 release-3.6
Component: OCE Version: release-3.6
Severity: Keywords: TRA TVD advection
Cc:

Description

Issue: in the routine tra_adv_tvd_zts found in module traadv_tvd.F90 a local array size is hard coded for T-S : the advection scheme can't be used for passive tracers.

This concerns both the trunk and the v3.6_stable.

Solution: replace the following 2 lines:

 328   ||       CALL wrk_alloc( jpi, jpj, jpk, 3, ztrs )

...

566   ||       CALL wrk_dealloc( jpi, jpj, jpk, 3, ztrs )

by

 328   ||       CALL wrk_alloc( jpi, jpj, jpk, kjpt+1, ztrs )

...

 566   ||       CALL wrk_dealloc( jpi, jpj, jpk, kjpt+1, ztrs )

Commit History (0)

(No commits)

Change History (8)

comment:1 Changed 5 years ago by flavoni

  • Owner changed from NEMO team to flavoni

comment:2 Changed 5 years ago by flavoni

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

fix for 3_6_stable in revision 6086.
Not need fix in the trunk.

comment:3 Changed 4 years ago by mathiot

At the 3.6 STABLE (r6751) version, NEMO never tries to access or to write to ztrs(:,:,:,jl≥4). NEMO only tries to access or to write to jtb, jtn and jta and these value are between 1 and 3 with a clever technique to swap the indexes. So I am not sure the hard coded allocation was wrong with passive tracers.

comment:4 Changed 4 years ago by acc

I agree, the allocation is independent of the number of tracers, This bug fix was unnecessary (albeit benign expect for the temporary waste of space).

comment:5 Changed 4 years ago by nicolasmartin

  • Keywords advection added; ADV removed

comment:6 Changed 4 years ago by nicolasmartin

  • Keywords nemo_v3_6* added

comment:7 Changed 3 years ago by nemo

  • Keywords release-3.6* added; nemo_v3_6* removed

comment:8 Changed 3 years ago by nemo

  • Keywords release-3.6* removed
Note: See TracTickets for help on using tickets.