Skip to content

Uninitialized do_i values in MOM_tracer_advect.F90:advect_x() #952

@adcroft

Description

@adcroft

The contents of do_i(i+1,j) are not initialized at I=ie when used in the loops at https://github.com/NOAA-GFDL/MOM6/blob/dev/gfdl/src/tracer/MOM_tracer_advect.F90#L707

      if (associated(Tr(m)%ad_x)) then ; do I=is-1,ie ; if (do_i(i,j) .or. do_i(i+1,j)) then
        Tr(m)%ad_x(I,j,k) = Tr(m)%ad_x(I,j,k) + flux_x(I,j,m)*Idt
      endif ; enddo ; endif

and https://github.com/NOAA-GFDL/MOM6/blob/dev/gfdl/src/tracer/MOM_tracer_advect.F90#L737

      do I=is-1,ie ; if (do_i(i,j) .or. do_i(i+1,j)) then
        Tr(m)%ad2d_x(I,j) = Tr(m)%ad2d_x(I,j) + flux_x(I,j,m)*Idt
      endif ; enddo

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions